Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lost Update in material history #116

Open
FabianMauz opened this issue Aug 5, 2021 · 1 comment
Open

Lost Update in material history #116

FabianMauz opened this issue Aug 5, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@FabianMauz
Copy link
Collaborator

If 2 users edit the same material, a lost update is possible:

User 1 : Load the material M with property E1
User 2 : Load the material M with property E1
User 1 : change the property E1 -> E2
User 1 : Save the material M -> saved history : oldValue : E1, newValue: E2
User 2 : Change property E1 -> E3
User 2 : Save the material M -> saved history : oldValue : E1, newValue: E3

E1 is wrong in this case and should be E2.

@FabianMauz FabianMauz added the bug Something isn't working label Aug 5, 2021
@FabianMauz
Copy link
Collaborator Author

A possible solution would be to check before saving the history delta whether the "old value" has changed in the meantime and adjust the delta if necessary.
This (updating and saving) would have to be done within one transaction, i.e. in the same TransactionScope.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant