[jboss-user] Optimistic Locking in EJB3

Karsten Ohme widerstand at t-online.de
Wed Jan 30 18:55:38 EST 2008


Hi,

I have some questions regarding optimistic locking.

1) Can it happen in my container managed bean?

2) How can I deal with it? Can I find out if my container just started
the transaction? Can I repeat the transaction it in this case?

3) As far as I would guess optimistic locking does not lock the
database, so concurrent transaction can be executed on the same data
without delay regardless if they write or read? I.e if a whole
transaction will last 5 seconds where multiple services are involved,
within these 5 seconds also other transactions from the same bean can be
started and handled?

Regards,
Karsten




More information about the jboss-user mailing list