Update and OCC

Change things safely 

Update whole entity, with all fields:

Additional way to quickly update a PrimaryKey entity:

Update just specific columns:

Optimistic Concurrency Control

Protect your updates

 

OptimisticConcurrencyIndicator

Implement and point to the column for OCC controlling.
If you want to create your own OCC logic, provide it into handleOCC() method

 

OptimisticConcurrencyForPrimaryKey

The default OCC logic for PrimaryKey entities, is provided into this interface.
The column object type can be either numeric or date related.
Point OCC column into getOCCColumn()

 

Split your update to rows

Try to avoid area updates. It may bring database locks.
It’s better to switch it to single row updates


Example:
Entity Staff is configured to use OCC over LastUpdate column.
Records with equal or lower value, will be rejected:

Share This Page

FACEBOOK COMMENTS WILL BE SHOWN ONLY WHEN YOUR SITE IS ONLINE

©Elephant Software Klaudiusz Wojtkowiak
e-mail: contact@daobab.io