That's the contract for the bean producer, the server does the trick...
All the books talk about how to program EJBs, not how to make EJB servers...
Check out javax.sql, specially interfaces DataSource and
ConnectionEventListener, for a more comprehensive answer
HTH
JP
-----Original Message-----
From: Dave Glasser [mailto:[EMAIL PROTECTED]]
Sent: Sábado, 13 de Enero de 2001 16:41
To: [EMAIL PROTECTED]
Subject: Calling close() on a java.sql.Connection (Monson-Haefel)
In Richard Monson-Haefel's book *Enterprise JavaBeans*, each time he
uses a database Connection that he's gotten from a DataSource, he
calls close() on it when he's finished with it. Am I missing
something, or does this not make sense? It's my understanding that
once close() is called on a Connection, it can never be used again.
How can a container acheive connection pooling this way? Also,
wouldn't calling close() on a connection necessarily commit or roll
back any in-progress transactions on that connection, possibly hosing
any in-progress container-managed transaction?
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".