Download and API Reference

  • concept
All production-ready Couchbase Spark connector artifacts are downloadable through Maven Central. Prerelease versions are available through our Couchbase Maven repository for easy consumption. The same Couchbase Spark connector library is used for both Scala and PySpark.

Current Release for Apache Spark 4.X

For Apache Spark 4.1 and 4.2, use:

  • GroupId: com.couchbase.client

  • ArtifactId: spark-connector_2.13

  • Version: 4.0.0

In SBT use:

libraryDependencies += "com.couchbase.client" %% "spark-connector" % "4.0.0"

The library package can also be downloaded: Download (Scala 2.13 / Java) | API Reference

Note that the download also contains an assembled jar, which means they contain all the dependencies in one "fat jar". This means that you don’t need to juggle multiple dependencies if you want to use the jar as part of Spark’s command line access tools (like the shell) or add it to the classpath of workers.

Current Release for Apache Spark 3.5

Use this release if working with Apache Spark 3.5. (Older versions of Apache Spark are end-of-life and no longer supported). The coordinates for the artifacts are:

Scala 2.12:
  • GroupId: com.couchbase.client

  • ArtifactId: spark-connector_2.12

  • Version: 3.5.5

Scala 2.13:
  • GroupId: com.couchbase.client

  • ArtifactId: spark-connector_2.13

  • Version: 3.5.5

In SBT use:

libraryDependencies += "com.couchbase.client" %% "spark-connector" % "3.5.5"

The library package can also be downloaded: Download (Scala 2.12 / Java) | Download (Scala 2.13 / Java) | API Reference

Note that the download also contains an assembled jar, which means they contain all the dependencies in one "fat jar". This means that you don’t need to juggle multiple dependencies if you want to use the jar as part of Spark’s command line access tools (like the shell) or add it to the classpath of workers.

Using from PySpark

The same library is used for PySpark.

PySpark users should download the package:

and then follow the PySpark documentation.

Using from Java or Other JVM Languages

The Couchbase Spark connector can also be used in a Java (or Kotlin, Clojure etc.) application. Simply import the library coordinates above into your build of choice (such as Maven or Gradle).