Module: SidekiqIteration
- Defined in:
- lib/sidekiq_iteration.rb,
lib/sidekiq_iteration/version.rb,
lib/sidekiq_iteration/iteration.rb,
lib/sidekiq_iteration/throttling.rb,
lib/sidekiq_iteration/enumerators.rb,
lib/sidekiq_iteration/csv_enumerator.rb,
lib/sidekiq_iteration/job_retry_patch.rb,
lib/sidekiq_iteration/nested_enumerator.rb,
lib/sidekiq_iteration/active_record_enumerator.rb
Defined Under Namespace
Modules: Enumerators, Iteration, JobRetryPatch, Throttling Classes: ActiveRecordEnumerator, CsvEnumerator, NestedEnumerator
Constant Summary collapse
- VERSION =
"0.4.0"
Class Attribute Summary collapse
-
.default_retry_backoff ⇒ Object
Configures a delay duration to wait before resuming an interrupted job.
- .logger ⇒ Object
-
.max_job_runtime ⇒ Object
Use this to always interrupt the job after it’s been running for more than N seconds.
- .stopping ⇒ Object
Class Attribute Details
.default_retry_backoff ⇒ Object
Configures a delay duration to wait before resuming an interrupted job.
Defaults to nil which means interrupted jobs will be retried immediately. This value will be ignored when an interruption is raised by a throttle enumerator, where the throttle backoff value will take precedence over this setting.
36 37 38 |
# File 'lib/sidekiq_iteration.rb', line 36 def default_retry_backoff @default_retry_backoff end |
.logger ⇒ Object
46 47 48 |
# File 'lib/sidekiq_iteration.rb', line 46 def logger @logger ||= Sidekiq.logger end |
.max_job_runtime ⇒ Object
Use this to always interrupt the job after it’s been running for more than N seconds.
This setting will make it to always interrupt a job after it’s been iterating for 5 minutes. Defaults to nil which means that jobs will not be interrupted except on termination signal.
25 26 27 |
# File 'lib/sidekiq_iteration.rb', line 25 def max_job_runtime @max_job_runtime end |
.stopping ⇒ Object
51 52 53 |
# File 'lib/sidekiq_iteration.rb', line 51 def stopping @stopping end |