This version of the documentation is archived and no longer supported. View the current documentation to learn how to upgrade your version of the Scala driver.
The recommended way to get started with the Scala driver in your project is by using a dependency management system. To manually download the MongoDB Scala driver, see the Scala driver Maven repository.
The following sections contain the Reactive Streams-based Scala implementation for asynchronous stream processing with non-blocking back pressure.
Scala 2.12 Based Driver
If you are using Maven to manage your
packages, add the following entry to your pom.xml
dependencies list:
<dependencies> <dependency> <groupId>org.mongodb.scala</groupId> <artifactId>mongo-scala-driver_2.12</artifactId> <version>5.0.0</version> </dependency> </dependencies>
If you are using sbt to manage your
packages, add the following entry to your build.sbt
file:
libraryDependencies += "org.mongodb.scala" %% "mongo-scala-driver" % "5.0.0"
Scala 2.11 Based Driver
If you are using Maven to manage your
packages, add the following entry to your pom.xml
dependencies list:
<dependencies> <dependency> <groupId>org.mongodb.scala</groupId> <artifactId>mongo-scala-driver_2.11</artifactId> <version>5.0.0</version> </dependency> </dependencies>
If you are using sbt to manage your
packages, add the following entry to your build.sbt
file:
libraryDependencies += "org.mongodb.scala" %% "mongo-scala-driver" % "5.0.0"