According to my test, they can:
model Machine:
class Machine < ActiveRecord::Base
def perform
Delayed::Job.enqueue Secondary.create!
end
end
model Secondary:
class Secondary < ActiveRecord::Base
def perform
logger.info("Inside secondary perform method (WIN)")
Proof.create!
end
end
from the console:
Delay :: Job.enqueue Machine.create!
As a result, an instance Proofand the magazines "Internal secondary ..." are created.
James source
share