Something more about Connection Pool:
1. Connection Polling is the process of reusing existing active connections instead of creating new connections when a request is made to the database.
2. When the connection manager recieves a request for a new connection, it checks its pool for available connections. If a connection is available, it returns, if no connections available, and the maximum pool size has not been reached, a new connection is created and returned.
3. If the maximal connection pool size has been reached, the connection requested is added to the queue.
4. Minimal pool size default is 0. When your application requires consistence, sometimes we set this value to be 5 even the application is inactive for long period of time.
5. Maximal pool size default 100.
6. To implement connection pooling. The connection string must be exactly the same, case sensitive and even space in the string should be the same.
7. The user ID must be the same for every user or service in the pool.
8. The process ID must be the same, it is impossible to share connection across processes.
9. Where is pool located? Connection pool is a client side technology, which means the database doesn't know anything about the connection pools involved in your application.
10. When is pool created? When the first connection is instantiated, a connection pool group is created, but the first connection pool is not created until the first connection is opened.
No comments:
Post a Comment