Hi, Toby.

toby cabot wrote:

> More data: AccountEJB.java from the Sun j2ee tutorial grabs a Connection
> in setEntityContext(), holds onto it until unsetEntityContext(), and
> uses it for all database work in the mean time.  This doesn't seem to
> agree with the 1.1 spec (page 168) which shows example code grabbing and
> releasing the Connection in the same method.
> 
> If I hack the code to grab and release in each method then it seems to
> work as expected.  Guess I'll point this out to Sun.
> 
> Am I right in thinking that holding on to the Connection is a bad idea
> and interferes with the container's container-managed demarcation?

According to the spec, no, that should work fine. This currently doesn't
work in JBoss however.

It is on my list of things to do when I get around to it if no one else
has done it already.

Toby.


_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to