Categories: None [Edit]
resque-progress
A Resque plugin that provides helpers for progress updates from within your
jobs.
For example:
class MyJob
extend Resque::Plugins::Progress
def self.perform(meta_id, *args)
(0..10).each do |i|
at(i, 10, "Lifted #{num} heavy things. #{10-num} more to go!")
heavy_lifting(i)
end
end
end
meta0 = MyJob.enqueue('stuff')
meta0.progress.num_complete # => 0
meta0.progress.total # => 10
meta0.progress.percent # => 100
meta0.progress.message # => nil
# later
meta1 = MyJob.get_meta('03c9e1a045ad012dd20500264a19273c')
meta1.progress.num_complete # => 4
meta1.progress.total # => 10
meta1.progress.percent # => 40
meta1.progress.message # => 'Lifted 4 heavy things. 6 more to go!'
Total
Ranking: 11,454 of 183,107
Downloads: 185,031
Daily
Ranking: 14,473 of 183,092
Downloads: 28
Downloads Trends
Ranking Trends
Num of Versions Trends
Popular Versions (Major)
Popular Versions (Major.Minor)
Depended by
Rank | Downloads | Name |
---|---|---|
51,925 | 19,090 | resque-integration |
145,627 | 3,556 | resque-single |
Depends on
Rank | Downloads | Name |
---|---|---|
874 | 44,213,537 | resque |
7,690 | 407,974 | resque-meta |
Owners
# | Gravatar | Handle |
---|---|---|
1 | webs |