Documentation Home
MySQL Connector/Python Developer Guide
Related Documentation Download this Manual
PDF (US Ltr) - 0.6Mb
PDF (A4) - 0.6Mb
HTML Download (TGZ) - 82.8Kb
HTML Download (Zip) - 95.5Kb


MySQL Connector/Python Developer Guide  /  Connector/Python API Reference  /  pooling.PooledMySQLConnection Class

10.4 pooling.PooledMySQLConnection Class

This class is used by MySQLConnectionPool to return a pooled connection instance. It is also the class used for connections obtained with calls to the connect() method that name a connection pool (see Section 9.1, “Connector/Python Connection Pooling”).

PooledMySQLConnection pooled connection objects are similar to MySQLConnection unpooled connection objects, with these differences:

  • To release a pooled connection obtained from a connection pool, invoke its close() method, just as for any unpooled connection. However, for a pooled connection, close() does not actually close the connection but returns it to the pool and makes it available for subsequent connection requests.

  • A pooled connection cannot be reconfigured using its config() method. Connection changes must be done through the pool object itself, as described by Section 9.1, “Connector/Python Connection Pooling”.

  • A pooled connection has a pool_name property that returns the pool name.


User Comments
User comments in this section are, as the name implies, provided by MySQL users. The MySQL documentation team is not responsible for, nor do they endorse, any of the information provided here.
Sign Up Login You must be logged in to post a comment.