cancel
Showing results for 
Search instead for 
Did you mean: 

Database update conflict resolution

cshar
Champ in-the-making
Champ in-the-making
I have a requirement where I need to build an approval process to update the database tables. I am building a web application in struts 2 and planning to use activiti as a backend engine via REST api of activiti. I would like to understand if activiti has a built in conflict resolution process that will stop 2 users from updating the same DB values via 2 change requests.

1. User A creates a change request C1 to update database table field FLD_VALUE.
2. User B creates a change request C2 to update same database table field FLD_VALUE for same record.

How can activiti detect this as a conflict and flag these 2 change requests as conflicting? Thanks.
3 REPLIES 3

martin_grofcik
Confirmed Champ
Confirmed Champ
Hi Cshar,

Activiti BPMN implementation does not cover resources. (You have to detect resource conflict from my point of view).
I see 2 possibilities:
- extend activiti model to cover resources too
- implement resource conflict detection outside of activiti (external service)

Regards
Martin

cshar
Champ in-the-making
Champ in-the-making
Thank you Martin. Could you advise what is the industry standard to handle conflict resolutions? Since you have such an experience on BPM you may have some suggestions around scenarios like these. Thanks!

jbarrez
Star Contributor
Star Contributor
From a low level point of view, you can use traditional database transactions to make sure no two users are changing data of one element at the same time.