Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Connection Pool

 
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am currently working on an application that requires the creation of a Database Connection Pool class. The problem is that I haven't created such a class before and I can't seem to find any sound documentation outlining guidelines on what is required or used to create a connection pool. Could you guys either provide a sample class or point to some documentation that would help out.
Thanks in advance,
Wasif Akbar
 
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
wasif..
contact me off line :
praveen.balaji@iflexsolutions.com
i wrote a small conection pooling class for myself. This one supports multiple drivers and multiple database connecitons.
-praveen.
 
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
or you could do a search...
I'm pretty sure Javaworld has an article on Object pooling.
Dave
 
Praveen Balaji
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yeah.. it's pretty much object pooling.. except if you want something special done!!
for example, I have a cleaner thread that runs and cleans the connection pool at regular intervals. Such things!!
 
author
Posts: 3252
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
With all due respect, few home-grown connection pools are worth the disk space they occupy, and building your own connection pool is just about as useful as trying to patent a circular device facilitating horizontal transport of goods and persons (unless you're Australian, that is). (Praveen, I'm not implying anything specific about your pool, as I don't know it).
Try the Struts GenericDataSource class. A robust connection pool that turns any old JDBC driver into an industry-standard DataSource, so that you can simply replace it by a "native" DataSource if you get a driver or deploy in an environment that has one available, now that makes solid sense. Proprietary pools don't. Much less writing your own proprietary pool.
- Peter
[This message has been edited by Peter den Haan (edited November 02, 2001).]
 
Do the next thing next. That’s a pretty good rule. Read the tiny ad, that’s a pretty good rule, too.
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic