Domanda

My application is Multi-user application with server and client. In this one form is access by multiple user at the same time and they can perform save as draft or submit action.

The issue is that I want to control simultaneous editing of form by multi user.

For Example: User X is editing a value of textfield, checkbox and perform save as draft. And at the same time User Y edit the same value and submit form. Is there any way to control simultaneous form editing. any pointer?

I am using java , spring 3 , hibernate JPA in application.

È stato utile?

Soluzione

You're looking for optimistic concurrency control. With JPA/Hibernate, it can be as simple as adding an @Version annotated field in your entity.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top