File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes Connection Pooling Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Connection Pooling" Watch "Connection Pooling" New topic
Author

Connection Pooling

CM Saritha
Greenhorn

Joined: Nov 23, 2006
Posts: 2
Hi,

How can we make connection pooling using core Java.
Can any one please give me a solution...

Thanks.
David O'Meara
Rancher

Joined: Mar 06, 2001
Posts: 13459

"Saritha",
Welcome to the JavaRanch.

We're a friendly group, but we do require members to have valid display names.

Display names must be two words: your first name, a space, then your last name. Fictitious names are not allowed.

Please edit your profile and correct your display name since accounts with invalid display names get deleted, often without warning

thanks,
Dave
Prabhu Venkatachalam
Ranch Hand

Joined: Nov 16, 2005
Posts: 502

There is aready a open source utils for creating Db pooling. Have a look at this URL.

However, if you want to create one your own,

Create a set of connection using JDBC and store it using some collection classes. whenever new connection is requested, use it from the existing one. This will reduce connection creation time.


Prabhu Venkatachalam<br />SCJP 1.4,SCWCD 1.4<br />prabhu.venkatachalam@gmail.com
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39535
    
  27
Word of advice: Use an existing library instead of trying to create your own. There are a number of issue that can introduce hard-to-find bugs that you need to deal with, like synchronization of threads and proper handling of transactions, that it'd save you time to go with a ready-made solution.


Ping & DNS - updated with new look and Ping home screen widget
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Connection Pooling
 
Similar Threads
connection pooling
Questions on EJB
suggest a concept for workshop
Tomcat Performance
Connection Pooling