Uploaded image for project: 'C++ Driver'
  1. C++ Driver
  2. CXX-688

how to use connection pool in 1.0.0+

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Won't Fix
    • Icon: Critical - P2 Critical - P2
    • None
    • legacy-1.0.5
    • API

    Description

      We were using 2.6compact bcanch in the last one year. Now we are goting to move to the current l.0.0+legacy branch to get a full support for mongo 3.0.
      howerver, we find that there is no connpool.h file in 1.0.0+branch and no DBConnectionPool class.

      If we directly use instance from DBClientReplicaSet or its parent classes with pointer, the connection can't be released in time event we destroy the pointer, so that if we create tens of thousands of instances, we will catch socket limit exception. That's why we use DBConnectionPool, connection can be reused, and we can also call done() method to explictily release connection.

      Attachments

        Activity

          People

            Unassigned Unassigned
            yanbo8502 yanbo
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: