Skip to content

Add sidekiq_retries_exhausted to Import::LoadPlaceholderReferencesWorker to fail imports

This issue came from this discussion !156704 (comment 1988576343).

About

The Import::LoadPlaceholderReferencesWorker added in !156704 (merged) is responsible for batch loading placeholder user reference data from Redis to PostgreSQL.

Problem

If the worker exhausts its retries, it should fail the import.

Proposal

We should add sidekiq_retries_exhausted logic to the worker to fail the import.

We will also need to add sidekiq_options retry: 6 to lower the retries to 6, as it currently has the default of 25 which takes weeks to reach the limit of.

Within sidekiq_retries_exhausted will need to be logic that can fail any type of import, based on the arguments of the worker, which is import_source and import_uid (which is likely to be an ID).

Edited by Luke Duncalfe