Class: AWS::Flow::GenericWorker

Inherits:
Object
  • Object
show all
Defined in:
lib/aws/decider/worker.rb

Overview

A generic Activity/Workflow worker class.

Direct Known Subclasses

ActivityWorker, WorkflowWorker

Instance Method Summary collapse

Constructor Details

#initialize(service, domain, task_list_to_poll, *args, &block) ⇒ GenericWorker

Creates a new GenericWorker

Parameters:

  • service

    The AWS service class to use.

  • domain

    The SWF domain to use.

  • task_list_to_poll

    The list of tasks to poll for this worker.

  • args

    Arguments for the workflow worker.

  • block (WorkerOptions)

    A set of WorkerOptions for the worker.



39
40
41
42
43
44
45
# File 'lib/aws/decider/worker.rb', line 39

def initialize(service, domain, task_list_to_poll, *args, &block)
  @service = service
  @domain = domain
  @task_list = task_list_to_poll
  @options = Utilities::interpret_block_for_options(WorkerOptions, block)
  args.each { |klass_or_instance| add_implementation(klass_or_instance) } if args
end