Class: AWS::SimpleWorkflow::ActivityType

Inherits:
Type
  • Object
show all
Defined in:
lib/aws/simple_workflow/activity_type.rb

Overview

Registering an ActivityType

To register an activity type you should use the #activity_types method on the domain:

domain.activity_types.register('name', 'version', { ... })

See AWS::SimpleWorkflow::ActivityTypeCollection#register for a complete list of options.

Deprecating an activity type

ActivityType inherits from the generic Type base class. Defined in Type are a few useful methods including:

You can use these to deprecate an activity type:

domain.activity_types['name','version'].deprecate

Instance Attribute Summary collapse

Attributes inherited from Type

#domain, #name, #version

Method Summary

Methods inherited from Type

#deprecate, #deprecated?, #initialize

Constructor Details

This class inherits a constructor from AWS::SimpleWorkflow::Type

Instance Attribute Details

#creation_dateTime (readonly)

When the workflow type was registered.

Returns:

  • (Time)

    the current value of creation_date



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def creation_date
  @creation_date
end

#default_task_heartbeat_timeoutInteger, ... (readonly)

The default maximum time specified when registering the activity type, before which a worker processing a task must report progress. If the timeout is exceeded, the activity task is automatically timed out. If the worker subsequently attempts to record a heartbeat or return a result, it will be ignored.

The return value may be an integer (number of seconds), the symbol :none (implying no timeout) or nil (not specified).

Returns:

  • (Integer, :none, nil)

    the current value of default_task_heartbeat_timeout



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def default_task_heartbeat_timeout
  @default_task_heartbeat_timeout
end

#default_task_listString? (readonly)

The default task list specified for this activity type at registration. This default task list is used if a task list is not provided when a task is scheduled.

Returns:

  • (String, nil)

    the current value of default_task_list



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def default_task_list
  @default_task_list
end

#default_task_schedule_to_close_timeoutInteger, ... (readonly)

The default maximum duration specified when registering the activity type, for tasks of this activity type. You can override this default when scheduling a task.

The return value may be an integer (number of seconds), the symbol :none (implying no timeout) or nil (not specified).

Returns:

  • (Integer, :none, nil)

    the current value of default_task_schedule_to_close_timeout



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def default_task_schedule_to_close_timeout
  @default_task_schedule_to_close_timeout
end

#default_task_schedule_to_start_timeoutInteger, ... (readonly)

The optional default maximum duration specified when registering the activity type, that a task of an activity type can wait before being assigned to a worker.

The return value may be an integer (number of seconds), the symbol :none (implying no timeout) or nil (not specified).

Returns:

  • (Integer, :none, nil)

    the current value of default_task_schedule_to_start_timeout



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def default_task_schedule_to_start_timeout
  @default_task_schedule_to_start_timeout
end

#default_task_start_to_close_timeoutInteger, ... (readonly)

The default maximum duration for activity tasks of this type.

The return value may be an integer (number of seconds), the symbol :none (implying no timeout) or nil (not specified).

Returns:

  • (Integer, :none, nil)

    the current value of default_task_start_to_close_timeout



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def default_task_start_to_close_timeout
  @default_task_start_to_close_timeout
end

#deprecation_dateTime? (readonly)

When the workflow type was deprecated, or nil if the workflow type has not been deprecated.

Returns:

  • (Time, nil)

    the current value of deprecation_date



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def deprecation_date
  @deprecation_date
end

#descriptionString? (readonly)

The description of this workflow type, or nil if was not set when it was registered.

Returns:

  • (String, nil)

    the current value of description



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def description
  @description
end

#statusSymbol (readonly)

The status of this workflow type. The status will either be :registered or :deprecated.

Returns:

  • (Symbol)

    the current value of status



86
87
88
# File 'lib/aws/simple_workflow/activity_type.rb', line 86

def status
  @status
end