Sidekiq Worker classes - aavedula/how-to-notes GitHub Wiki
In addition, I wanted to highlight a few things about the Sidekiq Worker classes. These classes are specifically intended for use when we want to enqueue some work and let it run in the background. Things like the import jobs for each of MDS assessments, or patient matching. In this case, you just need to do some work, so a PORO ("plain old Ruby object") would be fine.
One last thing, if you were using a Sidekiq worker, you'd want to call DeleteMDSAssessmentsWithNoExternalIdWorker.perform_later which enqueues the job, rather than running it directly. Later when sidekiq processes the job, it will call the perform method, but you should almost never (with the possible exception of in test code) run the perform method manually.