Found during mongomirror testing. Driver vended at commit 58da8e604dddd89f6c03a5ecf3cb406e646685df from master branch.
WARNING: DATA RACE Read at 0x00c0000eea50 by goroutine 90: github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology.(*pool).get() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology/pool.go:164 +0x26f github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology.(*Server).Connection() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology/server.go:206 +0x110 github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology.(*SelectedServer).Connection() <autogenerated>:1 +0x78 github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver.Operation.Execute() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/operation.go:232 +0x218 github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/operation.(*Insert).Execute() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/operation/insert.go:105 +0x4b4 github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/mongo.(*Collection).insert() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/mongo/collection.go:287 +0xa0f github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/mongo.(*Collection).InsertOne() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/mongo/collection.go:302 +0x39c github.com/10gen/mongomirror/mongomirror.sourceFailoverTestCase.func1() /Users/david/golang/src/github.com/10gen/mongomirror/mongomirror/mongomirror_internal_test.go:5374 +0x35b Previous write at 0x00c0000eea50 by goroutine 55: sync/atomic.AddInt64() /usr/local/go/src/runtime/race_amd64.s:276 +0xb github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology.(*Server).ProcessError() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology/pool.go:75 +0xbe9 github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology.(*SelectedServer).ProcessError() <autogenerated>:1 +0x6d github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver.Operation.Execute() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/operation.go:332 +0x2d7b github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/operation.(*Command).Execute() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/x/mongo/driver/operation/command.go:73 +0x2eb github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/mongo.(*Database).RunCommand() /Users/david/golang/src/github.com/10gen/mongomirror/vendor/go.mongodb.org/mongo-driver/mongo/database.go:171 +0x23f github.com/10gen/mongomirror/mongomirror.sourceFailoverTestCase() /Users/david/golang/src/github.com/10gen/mongomirror/mongomirror/mongomirror_internal_test.go:5421 +0x828 github.com/10gen/mongomirror/mongomirror.TestSourceFailoverApplyingOplog() /Users/david/golang/src/github.com/10gen/mongomirror/mongomirror/mongomirror_internal_test.go:5543 +0x575 testing.tRunner() /usr/local/go/src/testing/testing.go:865 +0x163