Follow-up from "Fix param passed to ProcessCancelledSubscriptionWorker"
The following discussion from !9703 should be addressed:
-
@vitallium started a discussion: (+1 comment) Note to myself to create an issue to address that later. Attempting to schedule a business related operation in background via Sidekiq for more than 1 hour or something could cause many side effects:
- Sidekiq can lose this job since Redis pushes out old keys if the queue is full or reaches OOM.
- The exact time for the passed
perform_at
is not guaranteed because the queue can be full or all workers can be busy. - The logic here is a bit strange too:
ProcessCancelledSubscriptionService
callsProcessCancelledSubscriptionWorker
which callsProcessCancelledSubscriptionService
again. I think we can simplify that by performing an async job all the time without needing to callProcessCancelledSubscriptionService
.