etre
etre copied to clipboard
Update mongodb driver from 1.17.1 to 2.10.0
Since this was a major version upgrade there are numerous backward incompatible API changes. Fortunately our usage is pretty basic and few of these affected us.
The main changes were:
- Replacing primitive.ObjectID related methods with bson.ObjectID equivalent (primitive was merged into the bson package)
- Connect no longer requires two-step NewClient+Connect. You just call Connect directly.
- A change to how Distinct returned values
The migration guide for 1.x -> 2.x is https://github.com/mongodb/mongo-go-driver/blob/master/docs/migration-2.0.md