« Previous | Next » 

Revision 1bce7b1f

ID1bce7b1f6f80d0c0254c973ad68bba63d515c0a3

Added by Georgios D. Tsoukalas about 11 years ago

pool context manager, http pool AssertionError fix

Refs #3492

1 Introduce a generic PooledObject class to act both
as a context manager for getting and putting back
an object from a pool.

2 Implement a class PooledHTTPConnection(PooledObject)
as a sublcass of the one in (1)

3 Eliminate httplib.HTTPConnection patching of close().
Eliminate put/get_http_connection.
The httplib.HTTPConnection object is no longer released
back to the pool via a method on it.
One must explicitly put it to the pool,
or use the PooledObject context manager in (2) above.

4 Update lib.astakos, lib.quotaholder.http,
synnefo.api.delegate, pithos.api.delegate to use
PooledHTTPConnection.

5 Update tests

Files

  • added
  • modified
  • copied
  • renamed
  • deleted

View differences