Skip to content

Commit cd3d81a

Browse files
committed
revisions
1 parent 7985cd8 commit cd3d81a

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1414

1515
### Possible breaking changes
1616

17-
Calls to the Ecto adapter itself should not require any changes. However, if you make direct calls to the `Mongo` driver, you will need to update some of them to account for the `mongodb` -> `mongodb_driver` upgrade. See [Migrating to 2.0.0](./README.md#migrating-to-200) in the Readme.
17+
Calls to the Ecto adapter itself should not require any changes. However, if you make direct calls to the `Mongo` driver, you will need to update some of them to account for the `mongodb` -> `mongodb_driver` upgrade. See [Migrating to 2.0](./README.md#migrating-to-20) in the Readme.
1818

1919
## 1.1.2
2020
* Add support for loading nil dates

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -122,11 +122,11 @@ Additionally special values are translated as follows:
122122

123123
The adapter and the driver are tested against most recent versions from 5.0, 6.0, and 7.0.
124124

125-
## Migrating to 2.0.0
125+
## Migrating to 2.0
126126

127-
Release 2.0.0 changes the underlying driver from [`mongodb`](https://github.com/elixir-mongo/mongodb) to [`mongodb_driver`](https://github.com/zookzook/elixir-mongodb-driver) 1.4.0. Calls to the Ecto adapter itself should not require any changes. Some config options are no longer used and can be simply deleted: `pool`, `pool_overflow`, `pool_timeout`.
127+
Release 2.0 changes the underlying driver from [`mongodb`](https://github.com/elixir-mongo/mongodb) to [`mongodb_driver`](https://github.com/zookzook/elixir-mongodb-driver) 1.4.0. Calls to the Ecto adapter itself should not require any changes. Some config options are no longer used and can be simply deleted: `pool`, `pool_overflow`, `pool_timeout`.
128128

129-
If you make direct calls to the `Mongo` driver, you will need to update some of them to account for the `mongodb` -> `mongodb_driver` upgrade. These include:
129+
If you make direct calls to the `Mongo` driver, you will need to update some of them to account for the `mongodb` -> `mongodb_driver` upgrade. Also, remember to replace `:mongodb` with `{:mongodb_driver, "~> 1.4.0"}` in your `mix.exs`. The known updates are:
130130
1. `Mongo` functions no longer accept a `pool` option or `MyApp.Repo.Pool` module argument. Instead, a pool PID is expected:
131131
```elixir
132132
# Old driver call
@@ -146,8 +146,8 @@ If you make direct calls to the `Mongo` driver, you will need to update some of
146146
end
147147
```
148148
2. [`Mongo.command`](https://hexdocs.pm/mongodb_driver/1.4.1/Mongo.html#command/3) requires a keyword list instead of a document. E.g., instead of `Mongo.command(MyApp.Repo.pool(), %{listCollections: 1}, opts)`, do `Mongo.command(MyApp.Repo.pool(), [listCollections: 1], opts)`.
149-
3. `Mongo.ReadPreferences.defaults` -> `Mongo.ReadPreference.merge_defaults`
150-
4. When passing a `hint` to `Mongo.find_one` (etc.), if the index does not exist, an error is now returned.
149+
3. `Mongo.ReadPreferences.defaults` is renamed to `Mongo.ReadPreference.merge_defaults`.
150+
4. When passing a `hint` to `Mongo.find_one` etc., if the hinted index does not exist, an error is now returned.
151151

152152
## Contributing
153153

0 commit comments

Comments
 (0)