Skip to content
This repository was archived by the owner on Nov 18, 2024. It is now read-only.

Commit

Permalink
BDOG-1323 Bump major version and update README
Browse files Browse the repository at this point in the history
  • Loading branch information
colin-lamed committed Mar 9, 2021
1 parent 9ca866f commit ecf16ce
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 deletions.
17 changes: 12 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

# simple-reactivemongo

[![Apache-2.0 license](http://img.shields.io/badge/license-Apache-brightgreen.svg)](http://www.apache.org/licenses/LICENSE-2.0.html)
[![Apache-2.0 license](http://img.shields.io/badge/license-Apache-brightgreen.svg)](http://www.apache.org/licenses/LICENSE-2.0.html)

Provides simple serialization for [ReactiveMongo](http://reactivemongo.org) - reactive, asynchronous and non-blocking Scala driver for MongoDB.

Expand All @@ -10,9 +10,16 @@ This started as a fork of [Play-ReactiveMongo](https://github.com/ReactiveMongo/
With some minimal effort, as the ReactiveMongo people had already done the majority of the work, we felt that adding a base repository class creates a library without some
of the issues the other simpler libraries have.

## Upgrading from 7.x.x to 8.x.x?

### Major changes:

* Library is built for Scala 2.12 and Play 2.6, 2.7 and 2.8.
* The deprecated `MongoDbConnection` has been removed (since it depended on a static Play application which is no longer available in Play 2.8). Inject `ReactiveMongoComponent` instead.

## Upgrading from 6.x.x to 7.x.x?

###Major changes:
### Major changes:

* The dependency to HMRC's fork of `reactivemongo` has been dropped in favour of the original `reactivemongo` driver. Version 7.x.x depends now on `reactivemongo` 0.16.0.
* It got merged with `play-reactivemongo` so all classes which used to be provided by that library are now in `simple-reactivemongo` (for instance `ReactiveMongoHmrcModule` Play module and `ReactiveMongoComponent`). As a consequence `simple-reactivemongo` should be the only dependency a service would require for interactions with `MongoDB`. There will be no new version of `play-reactivemongo` depending on the `simple-reactivemongo` 7.x.x or above.
Expand All @@ -25,12 +32,12 @@ of the issues the other simpler libraries have.

## Upgrading from 5.x.x to 6.x.x?

With version 6.x.x of simple-reactivemongo, we are moving to the latest version of reactivemongo which comes with a few braking changes documented here:
With version 6.x.x of simple-reactivemongo, we are moving to the latest version of reactivemongo which comes with a few braking changes documented here:
http://reactivemongo.org/releases/0.12/documentation/release-details.html#breaking-changes

You will most likely encounter some of the following issues. Please have a look on how we recommend to fix them.

#### No Json serializer as JsObject found
#### No Json serializer as JsObject found

Due to keeping parity with upstream, companion objects for inner classes do not have the ImplicitBSONHandlers handlers.
If you see an error like this:
Expand All @@ -42,7 +49,7 @@ import reactivemongo.play.json.ImplicitBSONHandlers._

#### WriteResult is no longer an Exception

The type hierarchy of the trait `WriteResult` has changed in new version of reactivemongo.
The type hierarchy of the trait `WriteResult` has changed in new version of reactivemongo.
It’s no longer an Exception. As it no longer represents errors in the public API, the following properties have been removed: `errmsg`, `hasErrors`, `inError` and `message`.

simple-reactivemongo previously exposed `inError`, something that is no longer possible.
Expand Down
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ lazy val simpleReactiveMongo = Project("simple-reactivemongo", file("."))
.disablePlugins(JUnitXmlReportPlugin)
.settings(
makePublicallyAvailableOnBintray := true,
majorVersion := 7
majorVersion := 8
)
.settings(
scalaVersion := "2.12.13",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class ReactiveMongoComponentImpl @Inject()(
lifecycle: ApplicationLifecycle)
extends ReactiveMongoComponent {

val logger = Logger("application")
private val logger = Logger("application")

logger.info("ReactiveMongoPlugin starting...")

Expand Down

0 comments on commit ecf16ce

Please sign in to comment.