Plugin newbie here. I’m trying to adapt a plugin which takes about an hour to run. Looking at /sidekiq, I see the job is running every 30 minutes. So before the first job is finished, another instance of the same job starts, creating duplicate results. How can I prevent this?
One option of course is to make the job run in its allowed 30 minutes, but there are other constraints, and I would rather let it run as long as it wants.
I tried this, but it doesn’t seem to prevent a second instance of the job from running:
DistributedMutex.synchronize("custom_digest", validity: 180.minutes)