Implement `SchemaLock` to prevent breaking the dependent tables
What does this MR do and why?
This MR implements a utility class to lock the schema versions for models and locks the Vulnerability
and Vulnerabilities::Finding
model schemas.
Related to #349315 (closed).
Why do we need the schema lock?
Data from the vulnerabilities
and vulnerability_occurrences
tables are being replicated to the vulnerability_reads
table to separate the "Read Queries" from "Command Queries" to speed up querying the vulnerabilities therefore we need to make sure that there will be no breaking changes introduced for the vulnerabilities
and the vulnerability_occurrences
tables.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Mehmet Emin INAC