• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Connection

 
Jun Hong
Ranch Hand
Posts: 181
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
Can I cache a Connection object on client side. Will this affect the performance of database. Say the database allows 25 connections and if I cache one only 19 connections are left.
Jun Hong
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Caching of database Connections is normally handled via a central Conection Pooling mechanism. The pool opens all the required connections and you request connections from the pool and not directly from the database.
I hope I understood your question correctly. This assumes that the application is acting as a client to a database server, and the application itself may be a server to the next tier.
Dave
 
Stanley Tan
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yeah, look into connection pooling which should be handled seamlessly by the container (for example, Resin). If you have any specific questions, you can post them here!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic