Module: Resque
- Defined in:
- lib/resque-jobs-per-fork.rb
Defined Under Namespace
Classes: Worker
Class Method Summary collapse
-
.after_perform_jobs_per_fork(&block) ⇒ Object
the ‘after_perform_jobs_per_fork` hook will run in the child perform right before the child perform terminates.
-
.after_perform_jobs_per_fork=(after_perform_jobs_per_fork) ⇒ Object
Set the after_perform_jobs_per_fork proc.
-
.before_perform_jobs_per_fork(&block) ⇒ Object
the ‘before_perform_jobs_per_fork` hook will run in the child perform right before the child perform starts.
-
.before_perform_jobs_per_fork=(before_perform_jobs_per_fork) ⇒ Object
Set the before_perform_jobs_per_fork proc.
Class Method Details
.after_perform_jobs_per_fork(&block) ⇒ Object
the ‘after_perform_jobs_per_fork` hook will run in the child perform right before the child perform terminates
Call with a block to set the hook. Call with no arguments to return the hook.
26 27 28 |
# File 'lib/resque-jobs-per-fork.rb', line 26 def self.after_perform_jobs_per_fork(&block) block ? (@after_perform_jobs_per_fork = block) : @after_perform_jobs_per_fork end |
.after_perform_jobs_per_fork=(after_perform_jobs_per_fork) ⇒ Object
Set the after_perform_jobs_per_fork proc.
31 32 33 |
# File 'lib/resque-jobs-per-fork.rb', line 31 def self.after_perform_jobs_per_fork=(after_perform_jobs_per_fork) @after_perform_jobs_per_fork = after_perform_jobs_per_fork end |
.before_perform_jobs_per_fork(&block) ⇒ Object
the ‘before_perform_jobs_per_fork` hook will run in the child perform right before the child perform starts
Call with a block to set the hook. Call with no arguments to return the hook.
12 13 14 |
# File 'lib/resque-jobs-per-fork.rb', line 12 def self.before_perform_jobs_per_fork(&block) block ? (@before_perform_jobs_per_fork = block) : @before_perform_jobs_per_fork end |
.before_perform_jobs_per_fork=(before_perform_jobs_per_fork) ⇒ Object
Set the before_perform_jobs_per_fork proc.
17 18 19 |
# File 'lib/resque-jobs-per-fork.rb', line 17 def self.before_perform_jobs_per_fork=(before_perform_jobs_per_fork) @before_perform_jobs_per_fork = before_perform_jobs_per_fork end |