Hi

I have discovered a deadlock problem with Orion 1.1.16 which I suspect is a
bug:

I do the following (in the servlet tier):

1. Begin a user transaction (getting the userTransaction from
java:comp/UserTransaction).
2. Then create a new entity bean
3. Then execute a finder method which should return, among others, the newly
created entity bean.
4. Commit the transaction

The finder method locks in the database access.
All bean methods are set to the "Required" transaction property. This means
that they should participate in the user transaction (and not create their
own).
The database access isolation level is set to "committed".
I am using SQL Server 7.0 and used the Enterprise Manager to investigate the
problem.
It appears that the create and finder methods are associated with different
sessions in the database and therefore cause the lock.
When I change the isolation level to "uncommitted" the deadlock disappears.
This is as expected when the two methods run in different sessions.

As far as I can see this should not happen, i.e. the container should use
the same session (and transaction) for both methods.

Please correct me if I am wrong but this is what I understand that the J2EE
framework is suppose to do.

Thanks
Hans Barnard

PS. I get the same behaviour with the stable version, 1.0.3b


Reply via email to