Created
July 6, 2014 04:21
-
-
Save agmcleod/206e96272bd8a104f7b1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# app/jobs/custom_job.rb | |
class CustomJob < Struct.new(:record_id) | |
def perform | |
record = Record.find record_id | |
record.attachment_one | |
record.attachment_two | |
end | |
end | |
# Then in your app, queue via: | |
Delayed::Job.enqueue CustomJob.new(record.id) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment