Update topology.Server type

XMLWordPrintableJSON

    • Type: New Feature
    • Resolution: Fixed
    • Priority: Major - P3
    • 1.1.0
    • Affects Version/s: None
    • Component/s: Core API
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      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.

              Assignee:
              Kristofer Brandow (Inactive)
              Reporter:
              Kristofer Brandow (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: