Can someone tell me precisely how to integrate acts_as_paranoid with DelayedJob? I've tried creating a class Delayed::Backend::ActiveRecord::Job and adding acts_as_paranoid to it but even if I use an initializer and require the new class, acts_as_paranoid doesn't seem to do anything.
I'm not getting any errors so paranoia seems to be installed correctly and the job is cleanly deleted when it completes successfully - which is of course what I'm trying to prevent.
Happy to try any debugging suggestions if nobody reads this and immediately knows how I've screwed up.
Turns out I fell for the 'default scope' problem.
acts_as_paranoidchanges the default scope so that afindonly returns entries that have not been soft-deleted. If you want to see ALL entries, including the soft-deleted one, you need to either addwith_deletedas a scope for your query or, when addingacts_as_paranoidto your class, add as per the example:With either of these changes, things are working.