/AWS1/IF_SWF=>REGISTERACTIVITYTYPE()¶
About RegisterActivityType¶
Registers a new activity type along with its configuration settings in the specified domain.
A TypeAlreadyExists fault is returned if the type already exists in the
domain. You cannot change any configuration settings of the type after its registration, and
it must be registered as a new version.
Access Control
You can use IAM policies to control this action's access to Amazon SWF resources as follows:
-
Use a
Resourceelement with the domain name to limit the action to only specified domains. -
Use an
Actionelement to allow or deny permission to call this action. -
Constrain the following parameters by using a
Conditionelement with the appropriate keys.-
defaultTaskList.name: String constraint. The key isswf:defaultTaskList.name. -
name: String constraint. The key isswf:name. -
version: String constraint. The key isswf:version.
-
If the caller doesn't have sufficient permissions to invoke the action, or the
parameter values fall outside the specified constraints, the action fails. The associated
event attribute's cause parameter is set to OPERATION_NOT_PERMITTED.
For details and example IAM policies, see Using IAM to Manage Access to Amazon SWF
Workflows in the Amazon SWF Developer Guide.
Method Signature¶
METHODS /AWS1/IF_SWF~REGISTERACTIVITYTYPE
IMPORTING
!IV_DOMAIN TYPE /AWS1/SWFDOMAINNAME OPTIONAL
!IV_NAME TYPE /AWS1/SWFNAME OPTIONAL
!IV_VERSION TYPE /AWS1/SWFVERSION OPTIONAL
!IV_DESCRIPTION TYPE /AWS1/SWFDESCRIPTION OPTIONAL
!IV_DEFTASKSTARTTOCLOSETMOUT TYPE /AWS1/SWFDURINSECONDSOPTIONAL OPTIONAL
!IV_DEFTASKHEARTBEATTIMEOUT TYPE /AWS1/SWFDURINSECONDSOPTIONAL OPTIONAL
!IO_DEFAULTTASKLIST TYPE REF TO /AWS1/CL_SWFTASKLIST OPTIONAL
!IV_DEFAULTTASKPRIORITY TYPE /AWS1/SWFTASKPRIORITY OPTIONAL
!IV_DEFTASKSCHDTOSTARTTIMEOUT TYPE /AWS1/SWFDURINSECONDSOPTIONAL OPTIONAL
!IV_DEFTASKSCHDTOCLOSETIMEOUT TYPE /AWS1/SWFDURINSECONDSOPTIONAL OPTIONAL
RAISING
/AWS1/CX_SWFLIMITEXCEEDEDFAULT
/AWS1/CX_SWFOPNOTPERMITTEDFA00
/AWS1/CX_SWFTYPEALRDYEXFAULT
/AWS1/CX_SWFUNKNOWNRESRCFAULT
/AWS1/CX_SWFCLIENTEXC
/AWS1/CX_SWFSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_domain TYPE /AWS1/SWFDOMAINNAME /AWS1/SWFDOMAINNAME¶
The name of the domain in which this activity is to be registered.
iv_name TYPE /AWS1/SWFNAME /AWS1/SWFNAME¶
The name of the activity type within the domain.
The specified string must not contain a
:(colon),/(slash),|(vertical bar), or any control characters (\u0000-\u001f|\u007f-\u009f). Also, it must not be the literal stringarn.
iv_version TYPE /AWS1/SWFVERSION /AWS1/SWFVERSION¶
The version of the activity type.
The activity type consists of the name and version, the combination of which must be unique within the domain.
The specified string must not contain a
:(colon),/(slash),|(vertical bar), or any control characters (\u0000-\u001f|\u007f-\u009f). Also, it must not be the literal stringarn.
Optional arguments:¶
iv_description TYPE /AWS1/SWFDESCRIPTION /AWS1/SWFDESCRIPTION¶
A textual description of the activity type.
iv_deftaskstarttoclosetmout TYPE /AWS1/SWFDURINSECONDSOPTIONAL /AWS1/SWFDURINSECONDSOPTIONAL¶
If set, specifies the default maximum duration that a worker can take to process tasks of this activity type. This default can be overridden when scheduling an activity task using the
ScheduleActivityTaskDecision.The duration is specified in seconds, an integer greater than or equal to
0. You can useNONEto specify unlimited duration.
iv_deftaskheartbeattimeout TYPE /AWS1/SWFDURINSECONDSOPTIONAL /AWS1/SWFDURINSECONDSOPTIONAL¶
If set, specifies the default maximum time before which a worker processing a task of this type must report progress by calling RecordActivityTaskHeartbeat. If the timeout is exceeded, the activity task is automatically timed out. This default can be overridden when scheduling an activity task using the
ScheduleActivityTaskDecision. If the activity worker subsequently attempts to record a heartbeat or returns a result, the activity worker receives anUnknownResourcefault. In this case, Amazon SWF no longer considers the activity task to be valid; the activity worker should clean up the activity task.The duration is specified in seconds, an integer greater than or equal to
0. You can useNONEto specify unlimited duration.
io_defaulttasklist TYPE REF TO /AWS1/CL_SWFTASKLIST /AWS1/CL_SWFTASKLIST¶
If set, specifies the default task list to use for scheduling tasks of this activity type. This default task list is used if a task list isn't provided when a task is scheduled through the
ScheduleActivityTaskDecision.
iv_defaulttaskpriority TYPE /AWS1/SWFTASKPRIORITY /AWS1/SWFTASKPRIORITY¶
The default task priority to assign to the activity type. If not assigned, then
0is used. Valid values are integers that range from Java'sInteger.MIN_VALUE(-2147483648) toInteger.MAX_VALUE(2147483647). Higher numbers indicate higher priority.For more information about setting task priority, see Setting Task Priority in the in the Amazon SWF Developer Guide..
iv_deftaskschdtostarttimeout TYPE /AWS1/SWFDURINSECONDSOPTIONAL /AWS1/SWFDURINSECONDSOPTIONAL¶
If set, specifies the default maximum duration that a task of this activity type can wait before being assigned to a worker. This default can be overridden when scheduling an activity task using the
ScheduleActivityTaskDecision.The duration is specified in seconds, an integer greater than or equal to
0. You can useNONEto specify unlimited duration.
iv_deftaskschdtoclosetimeout TYPE /AWS1/SWFDURINSECONDSOPTIONAL /AWS1/SWFDURINSECONDSOPTIONAL¶
If set, specifies the default maximum duration for a task of this activity type. This default can be overridden when scheduling an activity task using the
ScheduleActivityTaskDecision.The duration is specified in seconds, an integer greater than or equal to
0. You can useNONEto specify unlimited duration.
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
lo_client->registeractivitytype(
io_defaulttasklist = new /aws1/cl_swftasklist( |string| )
iv_defaulttaskpriority = |string|
iv_deftaskheartbeattimeout = |string|
iv_deftaskschdtoclosetimeout = |string|
iv_deftaskschdtostarttimeout = |string|
iv_deftaskstarttoclosetmout = |string|
iv_description = |string|
iv_domain = |string|
iv_name = |string|
iv_version = |string|
).