Skip to content

Use `:delayed` or `:sticky` data_consistency for cleanup policy workers

What does this MR do and why?

As part of the Sidekiq Database Performance, we have identified Sidekiq workers that would benefit from redirecting their database reads to the replica.

To achieve this, we update data_consistency attribute of the following workers to sticky or delayed:

  • app/workers/packages/cleanup/execute_policy_worker.rb
  • app/workers/packages/debian/cleanup_dangling_package_files_worker.rb
  • app/workers/packages/cleanup_package_registry_worker.rb
  • app/workers/packages/cleanup_package_file_worker.rb
  • app/workers/dependency_proxy/cleanup_manifest_worker.rb
  • app/workers/dependency_proxy/cleanup_blob_worker.rb
  • app/workers/dependency_proxy/cleanup_dependency_proxy_worker.rb
  • app/workers/dependency_proxy/image_ttl_group_policy_worker.rb
  • app/workers/purge_dependency_proxy_cache_worker.rb

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

N/A

How to set up and validate locally

The changes shouldn't affect any functionality, so we suppose nothing is broken since the specs are 🍏

Related to #368042 (closed)

Edited by Moaz Khalifa

Merge request reports

Loading