Draft: Throttle sidekiq workers using the health checks framework
What does this MR do and why?
This is the first iteration of #404898 (closed).
In this we use the database health check framework which is being used in BBM to throttle Sidekiq workers as well.
Steps involved:
- Sidekiq worker which are database intensive should opt-in by calling perform_database_health_check!.
- A new sidekiq server middleware has been introduced to perform the db health check, on any Stop signals the job will be skipped and re-queued (with a delay of 3s).
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
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.
Related to #404898 (closed)
Edited by Prabakaran Murugesan