Skip Headers

# Pessimistic Locking

Previous

Next

With pessimistic locking, the first user who accesses the data with the purpose of updating it locks the data until completing the update. The disadvantage of this approach is that it may lead to reduced concurrency and deadlocks.

Consider using pessimistic locking support at the query level (see "Configuring Named Query Options").

If are using CMP, you may consider using bean-level pessimistic locking support (see "Configuring Named Query Options").