-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added eval jobs as a low ceremony way of declaring jobs without an ex…
…plicit class (poor man's block marshalling)
- Loading branch information
Showing
2 changed files
with
40 additions
and
6 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
2 comments
on commit 89c3a0b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are welcome to submit that as a changeset :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI – I believe this commit makes delayed_job incompatible with Rails < 2.2 because of the Array.first and friends. I fixed it by adding in the same core extensions that were introduced to Rails with this commit:
http://github.com/rails/rails/commit/22af62
I’ll make a note in the wiki that explains the workaround for others who might run into this issue.
Any reason why you didn’t wrote
object = EvaledJob.new(&block)
and put the other Job.create outside the if?