The topology.Server type will require the following changes:
- Remove the context.Context argument from Connect, since it's not actually used
- Move the topo parameter from the NewServer method to the Connect method
- This is necessary because Disconnect sets this to nil. If we can't reset it then a Server can no longer be connected usefully after it is disconnected
- Rename Connection to ConnectionLegacy
- Add a new method Connection that implements the Connection method of the driver.Server interface
- Make Server implement driver.ErrorProcessor to handle SDAM errors.
- Update Server to use topology.pool and return topology.Connection from Server.Connection and topology.connectionLegacy from Server.ConnectionLegacy.
- Implement a semaphore for max connections.
- This used to be contained in the connection.Pool implementation, but it's simpler to have the topology.Server type track this now that the pool is a private type within the topology package.
- has to be done after
-
GODRIVER-929 Create topology.pool type
- Closed
-
GODRIVER-930 Implement base driver.Connection type
- Closed
- has to be done before
-
GODRIVER-928 Update topology.Topology type
- Closed
- is depended on by
-
GODRIVER-628 Connections survive primary stepdown
- Closed
-
GODRIVER-755 Add background goroutine per server to close expired, idle connections
- Closed