Workbler allows you to do background jobs when you deploy your JRuby on Rails application as war file
License
jerryluk/workbler
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Workbler ======== Workbler allows you to run background jobs when you deploy your JRuby on Rails application as war file. Getting Started =============== 1. Install and start RabbitMQ (see below) 2. Install warbler gem: jruby -S gem install warbler 3. Install JRuby RabbitMQ Client: jruby -S gem install rabbitmq-jruby-client 4. Install Workbler Plugin: jruby script/plugin install git://github.com/jerryluk/workbler.git 5. Run the Workbler generator: jruby script/generate workbler workble 6. Code Code Code 7. To run background task in development mode, open a new terminal, and run "jruby script/workbler" in the app directory 8. When you are ready to deploy, run: "warble" 9. Deploy your railsapp.war file to your favorite Java application server Example Usage ============= Create a worker class in app/workers/test_worker: class TestWorker < Workbler::Worker def test(options) logger.info("SyncWorker with options: #{options.inspect}") end end In anywhere of your code, do: Workbler.run(:test_worker, :test, { :something => 123 }) Configuration ============= Please see config/workbler.yml Installing RabbitMQ on OS X =========================== 1. Install MacPorts 2. sudo port install rabbitmq-server To run RabbitMQ 3. sudo rabbitmq-server Credits ======= Special thanks to Nick Sieger. He wrote the wonderful StartupScriptLauncher which this project would not exist without it. Copyright (c) 2010 Jerry Luk, released under the MIT license
About
Workbler allows you to do background jobs when you deploy your JRuby on Rails application as war file
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published