Sha256: d926192f4c1c2440456eaf60083dc8fbd6c54245a5b9c7a572237277637e6026

Contents?: true

Size: 1.49 KB

Versions: 2

Compression:

Stored size: 1.49 KB

Contents

= Backgrounded

The cleanest way to integrate background processing into your application.

Backgrounded provides a thin wrapper around any background processing framework that implements the Backgrounded handler API which makes it trivial to swap out processing frameworks with no impact to your code.

= Features
* clean and concise API which removes any dependency on external "worker" jobs and allows you to execute any model method in the background
* integrates with any background processing framework (DelayedJob, Resque, JobFu, Workling, etc)
* background methods can be actually unit tested by using an 'in process' runner

= Usage

  class User
    def do_stuff
    end
    def self.do_something_else
    end
  end

  user = User.new
  # execute instance method in background
  user.backgrounded.do_stuff

  # execute class method in background
  User.backgrounded.do_something_else

= Installation

Bundler Gemfile configuration

  gem 'backgrounded'

= Configuration

Backgrounded packages handlers for popular frameworks in separate gems.  Just drop in the gem for your particular framework or write your own!

== Resque
see http://github.com/wireframe/backgrounded-resque

== JobFu
see http://github.com/jnstq/job_fu/tree

== Custom Handlers

  # config/initializers/backgrounded.rb
  class MyHandler
    def request(object, method, *args)
      #process the call however you want!
    end
  end
  Backgrounded.handler = MyHandler.new

== Copyright

Copyright (c) 2012 Ryan Sonnek. See LICENSE for details.

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
backgrounded-2.0.0.pre2 README.rdoc
backgrounded-2.0.0.pre1 README.rdoc