• Post Reply Bookmark Topic Watch Topic
  • New Topic

Connection Pooling

 
Rick Charles
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Guyz,

i have a question regarding connection pooling.Say i have 10 connection in my connection pool and all 10 connections are engaged. if the 11th client comes in and requests for a connection, what will happen ? whether will it create a new connection ?

Thanks in advance
Rick
 
Jan Cumps
Bartender
Posts: 2620
14
C++ Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
will it create a new connection
Depending on your configuration (and on the pool you use), the pool will wait until a connection becomes available again (for a given time), or the pool will fail to give you a connection, or the pool will grow.

In commons-pool, these three ways of handling an exhausted pool are named: WHEN_EXHAUSTED_BLOCK, WHEN_EXHAUSTED_FAIL, WHEN_EXHAUSTED_GROW

Regards, Jan
 
Muhammad Saifuddin
Ranch Hand
Posts: 1325
Android Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
this article JDBC Connection Pooling Best Practices
by David Murphy might help you more on that.. read it and implement it..
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!