[M] Rename ElasticCommitIndexerWorker
Background
The ElasticCommitIndexerWorker originally handled indexing for blobs, commits, and wikis. Now the wiki indexing is handled by ElasticWikiIndexerWorker so the wiki argument in ElasticCommitIndexerWorker is unused. Also, because ElasticCommitIndexerWorker is pretty old it is not namespace-d and does live inside a bounded context.
Proposal
Instead of doing #408358 (closed), Dmitry proposed to rename this worker and follow the process of renaming a worker class. The new worker should call a service class instead of doing all the work inside the perform method.
- Create the newly named worker to
Search::Elastic::NEW_WORKER_NAME, and have the old worker call the new worker’s #perform method. Introduce a feature flag to control when we start scheduling the new worker. (Release M).
Any old worker jobs that are still in the queue will delegate to the new worker. When this version is deployed, it is no longer relevant which version of the job is scheduled or which Sidekiq handles it, an old-Sidekiq will use the old worker’s full implementation, a new-Sidekiq will delegate to the new worker.
-
Link the newly created FF issue to #518704 (closed)
-
Enable feature flag in non-production environments:
-
/chatops run feature set rename_commit_indexer_worker true --dev --pre --staging --staging-ref
-
Reference: https://docs.gitlab.com/development/sidekiq/compatibility_across_updates/#renaming-worker-classes