mikebridge commented on PR #44015:
URL: https://github.com/apache/superset/pull/44015#issuecomment-5589447976

   @aminghadersohi — ready for review when you have a moment. Concurrency fix 
on version restore: _do_restore() previously never coordinated with a 
concurrent writer, so an edit committed between the command's read and its 
revert could be silently lost. It now does a single `db.session.refresh(entity, 
with_for_update=True)` after validate() — a locking read that both serialises 
the revert and reloads the current committed state (a plain non-locking refresh 
would return a stale snapshot on MySQL/InnoDB REPEATABLE READ → silent partial 
restore); a hard-delete in the read→lock window maps to 404, not 422.
   
   A cross-model independent pass already went over this and caught the 
MySQL-RR issue (now fixed) — its consolidated report is in the spec repo. The 
dialect-independent regression guard is a unit test asserting the 
`with_for_update=True` flag (fails if dropped), plus a hard-delete→404 test and 
an end-to-end overwrite integration test. The same MySQL-RR staleness on the 
ordinary PUT/update path is tracked separately as sc-120014.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to