Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-2337

Clearing connectionPools should close connections

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Works as Designed
    • Icon: Major - P3 Major - P3
    • None
    • None
    • Connectivity
    • None

    Description

      ExclusiveConnectionPool's Clear() appears to simply abandons all existing connections without closing them.

      If Clear becomes a blocking operation then we're going to need a ClearAsync version also.

      Closing the connections in the background is dangerous because it creates a possible race conditions where connections are opened faster than they are closed leading to resource exhaustion. 

       

      Attachments

        Activity

          People

            vincent.kam@mongodb.com Vincent Kam (Inactive)
            vincent.kam@mongodb.com Vincent Kam (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: