Public Member Functions | |
def | __init__ |
def | return_socket |
def | socket |
Public Attributes | |
pid | |
pool_size | |
socket_factory | |
sockets | |
Static Public Attributes | |
sock = None | |
Static Private Attributes | |
list | __slots__ = ["sockets", "socket_factory", "pool_size", "pid"] |
A simple connection pool. Uses thread-local socket per thread. By calling return_socket() a thread can return a socket to the pool. Right now the pool size is capped at 10 sockets - we can expose this as a parameter later, if needed.
Definition at line 151 of file connection.py.
def pymongo::connection::_Pool::__init__ | ( | self, | ||
socket_factory | ||||
) |
Definition at line 166 of file connection.py.
def pymongo::connection::_Pool::return_socket | ( | self | ) |
Definition at line 195 of file connection.py.
def pymongo::connection::_Pool::socket | ( | self | ) |
Definition at line 174 of file connection.py.
list pymongo::connection::_Pool::__slots__ = ["sockets", "socket_factory", "pool_size", "pid"] [static, private] |
Definition at line 161 of file connection.py.
Definition at line 167 of file connection.py.
Definition at line 168 of file connection.py.
pymongo::connection::_Pool::sock = None [static] |
Definition at line 164 of file connection.py.
Definition at line 169 of file connection.py.
Definition at line 171 of file connection.py.