• Post Reply Bookmark Topic Watch Topic
  • New Topic

What is the difference between Connection Pooling and Object Pooling

 
Mahendran Aiyappan
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can any one specify the difference between Connection Pooling and Object Pooling.I have studied about Connection Pooling, like sharing one or two connections by more than one beans. But Object pooling...


Thanks
Mahendran
 
Masoud Kalali
Author
Ranch Hand
Posts: 531
Java Mac OS X Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Connection pooling is an specefic kind of object pooling .
in connection pooling we create some connections in a pool and give them to any client who need to use a connection , the the user turn back the connection to the pool after it complete its task.
connections remaining in the pool is configurable , you can configure how much time a connection should stay idel , pool size, time out , increment policy .....


in object pooling we create a pool of objects that are not easy to instaciate , we create them and put them in the pool , and when we want to use them there is no need to instanciate the Object again , instead we may change some of its properties.

usually pooling used when creating and destroying some objects are resource consumer.


hth
 
Mahendran Aiyappan
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much Mr.Masoud Kalali
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!