Re: Question about JNDI resources

2005-01-19 Thread Harry Mantheakis
I think I found the answer to my own question in the Commons DBCP documentation: http://jakarta.apache.org/commons/dbcp/apidocs/org/apache/commons/dbcp/datas ources/package-summary.html Under the JNDI section, the last paragraph states: The reference to the DataSource could be maintained,

Re: Question about JNDI resources

2005-01-19 Thread Harry Mantheakis
> It sounds plausible to hold onto the DataSource once you had it. I do, with PostgreSQL. > And then there is an issue of synchronization? Hmm... You got me thinking there :-) I have always assumed that a DataSource reference retrieved from a JNDI lookup is a singleton - IOW the connection

Re: Question about JNDI resources

2005-01-18 Thread Parsons Technical Services
e profiler time. And then there is an issue of synchronization? Doug - Original Message - From: "Alan Deikman" <[EMAIL PROTECTED]> To: Sent: Monday, January 17, 2005 1:42 PM Subject: Question about JNDI resources I'm just learning this stuff, but having good success s

Re: Question about JNDI resources

2005-01-17 Thread Tim Funk
You should be able to store a reference to the Datasource and that should be all you need. Its probably not done that way in the examples since static variables are frowned upon. JNDI lookups are usually almost as faster a Hash lookup. So the speed is fairly negligible. -Tim Alan Deikman wrote

Question about JNDI resources

2005-01-17 Thread Alan Deikman
I'm just learning this stuff, but having good success so far. In my SQL-backed bean I use a JDBCResource as per the documentation: protected static Connection getConnection() { //System.out.println("User.getConnection Attempting to get connection"); try { Context initConte

Question about JNDI resources

2005-01-14 Thread Alan Deikman
I'm just learning this stuff, but having good success so far. In my SQL-backed bean I use a JDBCResource as per the documentation: protected static Connection getConnection() { //System.out.println("User.getConnection Attempting to get connection"); try { Context initCo