This week's giveaway is in the Spring forum.
We're giving away four copies of REST with Spring (video course) and have Eugen Paraschiv on-line!
See this thread for details.
The moose likes JDBC and Relational Databases and the fly likes doubt in connection pooling Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "doubt in connection pooling " Watch "doubt in connection pooling " New topic

doubt in connection pooling

Sriram.Narayanan Thiagarajan

Joined: Jul 21, 2006
Posts: 26
In Connection pooling

does all connections go through only one session or
they create their own session.

Thanks in advance
Jeanne Boyarsky
author & internet detective

Joined: May 26, 2003
Posts: 32818

Yes, a database session is open until the connection is closed - not just returned to the pool. This is how we can get a StaleConnection error. Sometimes a connection is in the pool that is no longer valid.

[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
I agree. Here's the link:
subject: doubt in connection pooling
It's not a secret anymore!