File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes OO, Patterns, UML and Refactoring and the fly likes Implement Datasource Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » OO, Patterns, UML and Refactoring
Bookmark "Implement Datasource" Watch "Implement Datasource" New topic

Implement Datasource

Atul Mishra
Ranch Hand

Joined: Jun 08, 2006
Posts: 140

What is a best way to implement the datasource ? I use tomcat 5.0 and have configured datasource in the server. I am using DAO pattern to interact with the client.

Now my DAO should call database specific classes which obtains a connection from the datasource I implemented in Tomcat.

Which way/pattern should I use ? Is there a preferred implementation for a datasource[like a factory or something]

Please suggest me some good links of reading.

Scott Ambler
Ranch Hand

Joined: Dec 12, 2003
Posts: 608 has some good material on how to interact with databases.

- Scott

<a href="" target="_blank" rel="nofollow">Scott W. Ambler</a><br />Practice Leader Agile Development, IBM Rational<br /> <br />Now available: <a href="" target="_blank" rel="nofollow">Refactoring Databases: Evolutionary Database Design</a>
I agree. Here's the link:
subject: Implement Datasource
It's not a secret anymore!