Getting Started
The recommended way to get started using Morphia in your project is with a dependency management system such as maven or gradle. To use Morphia using either build tool, you will need to update your build configuration with the following information.
<dependencies>
<dependency>
<groupId>dev.morphia.morphia</groupId>
<artifactId>morphia-core</artifactId>
<version>2.5.0-SNAPSHOT</version>
</dependency>
</dependencies>
If you want to use a -SNAPSHOT
build you will need to add the appropriate repository information to you pom:
<repositories>
<repository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
Gradle users can use the following dependency declaration:
dependencies {
compile 'dev.morphia.morphia:morphia-core:2.5.0-SNAPSHOT'
}
To use -SNAPSHOT
builds, an additional repository will be needed:
repositories {
maven {
url 'https://oss.sonatype.org/content/repositories/snapshots'
}
}
Morphia 2.0 requires Java 11 or greater. Morphia is actively tested on server versions 6 and above. Older server versions are not tested but, generally, should work though no guarantees are made. Morphia 2.5 and beyond require a minimum driver version of 5.0. |