After investigation in T202404#4555480 it was determined that we can probably / should run the constraint checks of an entity after each edit.
Flipping the switch on such a feature could cause increased load on the cluster so the default behaviour should remain the same.
There should be a configuration variable allowing a % of edits to trigger the job, probably using a random number on each edit to see if the edit gets the job run.
Deployment timeline to be decided and filed as a separate ticket.
Acceptance Criteria
- There should be a Job to run the constraint checks of a single entity, by entity ID.
- Jobs should have deduplication
- Job must be JSON serializable T204031#4578447
- The default of this feature should not change current behaviour (None of these jobs will be run without extra configuration)
- There should be a configuration variable allowing a % of edits to have the constraint checks run as a job.
- There should be a way to track the run time of these jobs (min max average and count)