Skip to content

Optimistic locking for Issue and Merge Requests

Valery Sizov requested to merge lock_for_issuable into master

What does this MR do?

It implements Optimistic Locking http://api.rubyonrails.org/classes/ActiveRecord/Locking/Optimistic.html for Issues and MRs but in a bit custom way. We use it for cases when either title or description field is involved in the change.

Why was this MR needed?

We have to prevent data losing.

What are the relevant issue numbers?

https://gitlab.com/gitlab-org/gitlab-ce/issues/12940

Screenshots (if relevant)

Screen_Shot_2016-07-09_at_15.33.02

Merge request reports