Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: earzur/resque-mongo
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: nfo/resque-mongo
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Able to merge. These branches can be automatically merged.
Loading
Showing with 1,269 additions and 504 deletions.
  1. +2 −1 .gitignore
  2. +11 −0 .travis.yml
  3. +12 −0 Gemfile
  4. +41 −0 Gemfile.lock
  5. +87 −0 HISTORY.md
  6. +1 −1 LICENSE
  7. +157 −70 README.markdown
  8. +18 −6 Rakefile
  9. +30 −12 bin/resque
  10. +0 −8 deps.rip
  11. +14 −0 docs/HOOKS.md
  12. +1 −1 examples/demo/README.markdown
  13. +1 −0 examples/god/resque.god
  14. +3 −3 examples/monit/resque.monit
  15. +2 −0 lib/nfo-resque-mongo.rb
  16. +73 −31 lib/resque.rb
  17. +1 −1 lib/resque/errors.rb
  18. +18 −2 lib/resque/failure.rb
  19. +13 −0 lib/resque/failure/base.rb
  20. +22 −106 lib/resque/failure/hoptoad.rb
  21. +59 −3 lib/resque/failure/mongo.rb
  22. +15 −1 lib/resque/failure/multiple.rb
  23. +51 −0 lib/resque/failure/redis.rb
  24. +15 −15 lib/resque/helpers.rb
  25. +5 −7 lib/resque/job.rb
  26. +10 −0 lib/resque/plugin.rb
  27. +12 −6 lib/resque/queue_stats.rb
  28. +49 −18 lib/resque/server.rb
  29. BIN lib/resque/server/public/favicon.ico
  30. +60 −54 lib/resque/server/public/ranger.js
  31. +17 −17 lib/resque/server/public/reset.css
  32. +7 −3 lib/resque/server/public/style.css
  33. +3 −3 lib/resque/server/test_helper.rb
  34. +36 −14 lib/resque/server/views/failed.erb
  35. +0 −1 lib/resque/server/views/key_sets.erb
  36. +4 −4 lib/resque/server/views/layout.erb
  37. +10 −2 lib/resque/server/views/next_more.erb
  38. +4 −4 lib/resque/server/views/queues.erb
  39. +15 −1 lib/resque/server/views/stats.erb
  40. +35 −4 lib/resque/server/views/workers.erb
  41. +10 −7 lib/resque/server/views/working.erb
  42. +4 −1 lib/resque/tasks.rb
  43. +1 −1 lib/resque/version.rb
  44. +51 −28 lib/resque/worker.rb
  45. +22 −20 { → lib}/tasks/redis.rake
  46. 0 { → lib}/tasks/resque.rake
  47. +5 −5 resque-mongo.gemspec
  48. +25 −0 test/hoptoad_test.rb
  49. +63 −2 test/job_hooks_test.rb
  50. +7 −7 test/job_plugins_test.rb
  51. +1 −1 test/plugin_test.rb
  52. +19 −2 test/queue_stats_test.rb
  53. +8 −14 test/resque-web_test.rb
  54. +26 −9 test/resque_test.rb
  55. +54 −2 test/test_helper.rb
  56. +59 −6 test/worker_test.rb
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.DS_Store
pkg
nbproject
*.gem
*.gem
11 changes: 11 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
rvm:
- 1.8.7
- 1.9.2
gemfile:
- Gemfile
env:
- DB=mongodb
script: "bundle exec rake test"
notifications:
recipients:
- nicolas.fouche@gmail.com
12 changes: 12 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
source :rubygems

gemspec

group :test do
gem "rake"
gem "rack-test", "~> 0.5"
gem "mocha", "~> 0.9.7"
gem "leftright", :platforms => :mri_18
gem "yajl-ruby", "~>0.8.2", :platforms => :mri
gem "json", "~>1.5.3", :platforms => :jruby
end
41 changes: 41 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
PATH
remote: .
specs:
nfo-resque-mongo (1.17.1)
mongo (>= 1.0)
multi_json (~> 1.0)
sinatra (>= 0.9.2)
vegas (~> 0.1.2)

GEM
remote: http://rubygems.org/
specs:
bson (1.3.1)
leftright (0.9.1)
mocha (0.9.12)
mongo (1.3.1)
bson (>= 1.3.1)
multi_json (1.0.3)
rack (1.3.2)
rack-test (0.6.1)
rack (>= 1.0)
rake (0.9.2)
sinatra (1.2.6)
rack (~> 1.1)
tilt (< 2.0, >= 1.2.2)
tilt (1.3.2)
vegas (0.1.8)
rack (>= 1.0.0)
yajl-ruby (0.8.2)

PLATFORMS
ruby

DEPENDENCIES
json (~> 1.5.3)
leftright
mocha (~> 0.9.7)
nfo-resque-mongo!
rack-test (~> 0.5)
rake
yajl-ruby (~> 0.8.2)
87 changes: 87 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,90 @@
## 1.17.2 (2011-10-27)

* [resque-mongo] Fix for the gem mongo 2.x.

## 1.17.1 (2011-05-27)

* Reverted `exit` change. Back to `exit!`.

## 1.17.0 (2011-05-26)

* Workers exit with `exit` instead of `exit!`. This means you
can now use `at_exit` hooks inside workers.
* More monit typo fixes.
* Fixed bug in Hoptoad backend.
* Web UI: Wrap preformatted arguments.

## 1.16.1 (2011-05-17)

* Bugfix: Resque::Failure::Hoptoad.configure works again
* Bugfix: Loading rake tasks

## 1.16.0 (2011-05-16)

* Optional Hoptoad backend extracted into hoptoad_notifier. Install the gem to use it.
* Added `Worker#paused?` method
* Bugfix: Properly reseed random number generator after forking.
* Bugfix: Resque.redis=(<a Redis::Namespace>)
* Bugfix: Monit example stdout/stderr redirection
* Bugfix: Removing single failure now works with multiple failure backends
* Web: 'Remove Queue' now requires confirmation
* Web: Favicon!
* Web Bugfix: Dates display in Safari
* Web Bugfix: Dates display timezone
* Web Bugfix: Race condition querying working workers
* Web Bugfix: Fix polling /workers/all in resque-web

## 1.15.0 (2011-03-18)

* Fallback to Redis.connect. Makes ENV variables and whatnot work.
* Fixed Sinatra 1.2 compatibility

## 1.14.0 (2011-03-17)

* Sleep interval can now be a float
* Added Resque.inline to allow in-process performing of jobs (for testing)
* Fixed tests for Ruby 1.9.2
* Added Resque.validate(klass) to validate a Job
* Decode errors are no longer ignored to help debugging
* Web: Sinatra 1.2 compatibility
* Fixed after_enqueue hook to actually run in `Resque.enqueue`
* Fixed very_verbose timestamps to use 24 hour time (AM/PM wasn't included)
* Fixed monit example
* Fixed Worker#pid

## 1.13.0 (2011-02-07)

* Depend on redis-namespace >= 0.10
* README tweaks
* Use thread_safe option when setting redis url
* Bugfix: worker pruning

## 1.12.0 (2011-02-03)

* Added pidfile writing from `rake resque:work`
* Added Worker#pid method
* Added configurable location for `rake install`
* Bugfix: Errors in failure backend are rescue'd
* Bugfix: Non-working workers no longer counted in "working" count
* Bugfix: Don't think resque-web is a worker

## 1.11.0 (2010-08-23)

* Web UI: Group /workers page by hostnames

## 1.10.0 (2010-08-23)

* Support redis:// string format in `Resque.redis=`
* Using new cross-platform JSON gem.
* Added `after_enqueue` plugin hook.
* Added `shutdown?` method which can be overridden.
* Added support for the "leftright" gem when running tests.
* Grammarfix: In the README

## 1.9.10 (2010-08-06)

* Bugfix: before_fork should get passed the job

## 1.9.9 (2010-07-26)

* Depend on redis-namespace 0.8.0
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2009 Chris Wanstrath
Copyright (c) Chris Wanstrath

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
Loading