Skip to content

Commit f889243

Browse files
committed
build(native): add optional datafusion-spark dependency behind spark feature
1 parent bbd700a commit f889243

2 files changed

Lines changed: 49 additions & 0 deletions

File tree

‎native/Cargo.lock‎

Lines changed: 39 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎native/Cargo.toml‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ default = [
3838
"object-store-aws",
3939
"object-store-gcp",
4040
"object-store-http",
41+
"spark",
4142
]
4243
object-store-aws = ["object_store/aws"]
4344
object-store-gcp = ["object_store/gcp"]
@@ -67,12 +68,21 @@ protoc = ["datafusion-substrait?/protoc"]
6768
# invoked in a build that compiled the feature off, so the Java surface is
6869
# unchanged either way.
6970
runtime-metrics = ["dep:tokio-metrics"]
71+
# Apache Spark-compatible functions, registered when a caller builds a
72+
# context with `SessionContextBuilder.withSparkFunctions()`. On by default so
73+
# Java callers don't have to think about features; builds that strip it get a
74+
# clear runtime error from the JVM if the flag is requested.
75+
spark = ["dep:datafusion-spark"]
7076

7177
[dependencies]
7278
arrow = { version = "58", features = ["ffi"] }
7379
async-trait = "0.1"
7480
datafusion = { version = "53.1.0", features = ["avro"] }
7581
datafusion-proto = "53.1.0"
82+
# Apache Spark-compatible functions + expression planners. Optional and
83+
# gated behind the `spark` feature (in the default set). The `core` feature
84+
# of the crate is what exposes `SessionStateBuilderSpark`.
85+
datafusion-spark = { version = "53.1.0", features = ["core"], optional = true }
7686
datafusion-substrait = { version = "53.1.0", optional = true }
7787
futures = "0.3"
7888
jni = "0.21"

0 commit comments

Comments
 (0)