Explain in detail the fundamental of connection pooling
Explain in detail the fundamental of connection pooling?
When a connection is opened first time a connection pool is created and is based on the
exact match of the connection string given to create the connection object. Connection
pooling only works if the connection string is the same. If the connection string is different,
then a new connection will be opened, and connection pooling won't be used.
Lets try to explain the same pictorially. In the above figure you can see there are three requests “Request1”, “Request2” and “Request3”. “Request1” and “Request3” have same connection string so no new connection object is created for “Request3” as the connection string is same. They share the same object “ConObject1”. But new object “ConObject2” is created for “Request2” as the connection string is different.
Note: - The difference between the connection string is that one has “User id=sa” and other has “User id=Testing”.
2007-10-24, 6245👍, 0💬
When should the method invokeLater() be used? This method is used to ensure that Swing components ar...
How To Return Top 5 Rows? - MySQL FAQs - SQL SELECT Statements with JOIN and Subqueries If you want ...
How To Export Data to a CSV File? - Oracle DBA FAQ - Introduction to Oracle SQL Developer If you wan...
How do I force the Dispose method to be called automatically, as clients can forget to call Dispose ...
Can each Java object keep track of all the threads that want to exclusively access to it?