-
Notifications
You must be signed in to change notification settings - Fork 141
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Create scala project folder for Flint Signed-off-by: Chen Dai <[email protected]> * Ignore .bsp folder Signed-off-by: Chen Dai <[email protected]> * Add README Signed-off-by: Chen Dai <[email protected]> --------- Signed-off-by: Chen Dai <[email protected]>
- Loading branch information
Showing
6 changed files
with
123 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# IDE files | ||
.idea/ | ||
*.iml | ||
|
||
# Compiled output | ||
target/ | ||
project/target/ | ||
|
||
# Log files | ||
logs/ | ||
|
||
# sbt-specific files | ||
.sbtserver | ||
.sbt/ | ||
.bsp/ | ||
|
||
# Miscellaneous | ||
.DS_Store | ||
*.class | ||
*.log | ||
*.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# OpenSearch Flint | ||
|
||
OpenSearch Flint is ... It consists of two modules: | ||
|
||
- `flint-core`: a module that contains Flint specification and client. | ||
- `flint-spark-integration`: a module that provides Spark integration for Flint and derived dataset based on it. | ||
|
||
## Prerequisites | ||
|
||
+ Spark 3.3.1 | ||
+ Scala 2.12.14 | ||
|
||
## Usage | ||
|
||
To use this application, you can run Spark with Flint extension: | ||
|
||
``` | ||
spark-sql --conf "spark.sql.extensions=org.opensearch.flint.FlintSparkExtensions" | ||
``` | ||
|
||
## Build | ||
|
||
To build and run this application with Spark, you can run: | ||
|
||
``` | ||
sbt clean publishLocal | ||
``` | ||
|
||
## Code of Conduct | ||
|
||
This project has adopted an [Open Source Code of Conduct](../CODE_OF_CONDUCT.md). | ||
|
||
## Security | ||
|
||
If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](http://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public GitHub issue. | ||
|
||
## License | ||
|
||
See the [LICENSE](../LICENSE.txt) file for our project's licensing. We will ask you to confirm the licensing of your contribution. | ||
|
||
## Copyright | ||
|
||
Copyright OpenSearch Contributors. See [NOTICE](../NOTICE) for details. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
lazy val scala212 = "2.12.14" | ||
lazy val sparkVersion = "3.3.1" | ||
|
||
ThisBuild / version := "0.1.0-SNAPSHOT" | ||
|
||
ThisBuild / scalaVersion := scala212 | ||
|
||
lazy val root = (project in file(".")) | ||
.aggregate(flintCore, flintSparkIntegration) | ||
.settings( | ||
name := "flint" | ||
) | ||
|
||
lazy val flintCore = (project in file("flint-core")) | ||
.settings( | ||
name := "flint-core", | ||
scalaVersion := scala212 | ||
) | ||
|
||
lazy val flintSparkIntegration = (project in file("flint-spark-integration")) | ||
.dependsOn(flintCore) | ||
.settings( | ||
name := "flint-spark-integration", | ||
scalaVersion := scala212, | ||
libraryDependencies ++= Seq( | ||
"org.apache.spark" %% "spark-core" % sparkVersion, | ||
"org.apache.spark" %% "spark-sql" % sparkVersion | ||
) | ||
) |
10 changes: 10 additions & 0 deletions
10
flint/flint-core/src/main/scala/org/opensearch/flint/core/FlintIndex.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
package org.opensearch.flint.core | ||
|
||
class FlintIndex { | ||
|
||
} |
14 changes: 14 additions & 0 deletions
14
...nt-spark-integration/src/main/scala/org/opensearch/flint/spark/FlintSparkExtensions.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
package org.opensearch.flint.spark | ||
|
||
import org.apache.spark.sql.SparkSessionExtensions | ||
|
||
class FlintSparkExtensions extends (SparkSessionExtensions => Unit) { | ||
|
||
override def apply(v1: SparkSessionExtensions): Unit = { | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
sbt.version = 1.8.2 |