Skip to content

/AWS1/IF_ECS=>LISTDAEMONTASKDEFINITIONS()

About ListDaemonTaskDefinitions

Returns a list of daemon task definitions that are registered to your account. You can filter the results by family name, status, or both to find daemon task definitions that match your criteria.

Method Signature

METHODS /AWS1/IF_ECS~LISTDAEMONTASKDEFINITIONS
  IMPORTING
    !IV_FAMILYPREFIX TYPE /AWS1/ECSSTRING OPTIONAL
    !IV_FAMILY TYPE /AWS1/ECSSTRING OPTIONAL
    !IV_REVISION TYPE /AWS1/ECSDAEMNTSKDEFNREVSNFILT OPTIONAL
    !IV_STATUS TYPE /AWS1/ECSDAEMNTASKDEFNSTATFILT OPTIONAL
    !IV_SORT TYPE /AWS1/ECSSORTORDER OPTIONAL
    !IV_NEXTTOKEN TYPE /AWS1/ECSSTRING OPTIONAL
    !IV_MAXRESULTS TYPE /AWS1/ECSBOXEDINTEGER OPTIONAL
  RETURNING
    VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_ecslstdaemtaskdefnrsp
  RAISING
    /AWS1/CX_ECSACCESSDENIEDEX
    /AWS1/CX_ECSCLIENTEXCEPTION
    /AWS1/CX_ECSINVALIDPARAMETEREX
    /AWS1/CX_ECSSERVEREXCEPTION
    /AWS1/CX_ECSCLIENTEXC
    /AWS1/CX_ECSSERVEREXC
    /AWS1/CX_RT_TECHNICAL_GENERIC
    /AWS1/CX_RT_SERVICE_GENERIC.

IMPORTING

Optional arguments:

iv_familyprefix TYPE /AWS1/ECSSTRING /AWS1/ECSSTRING

The full family name to filter the ListDaemonTaskDefinitions results with. Specifying a familyPrefix limits the listed daemon task definitions to daemon task definition families that start with the familyPrefix string.

iv_family TYPE /AWS1/ECSSTRING /AWS1/ECSSTRING

The exact name of the daemon task definition family to filter results with.

iv_revision TYPE /AWS1/ECSDAEMNTSKDEFNREVSNFILT /AWS1/ECSDAEMNTSKDEFNREVSNFILT

The revision filter to apply. Specify LAST_REGISTERED to return only the last registered revision for each daemon task definition family.

iv_status TYPE /AWS1/ECSDAEMNTASKDEFNSTATFILT /AWS1/ECSDAEMNTASKDEFNSTATFILT

The daemon task definition status to filter the ListDaemonTaskDefinitions results with. By default, only ACTIVE daemon task definitions are listed. If you set this parameter to DELETE_IN_PROGRESS, only daemon task definitions that are in the process of being deleted are listed. If you set this parameter to ALL, all daemon task definitions are listed regardless of status.

iv_sort TYPE /AWS1/ECSSORTORDER /AWS1/ECSSORTORDER

The order to sort the results. Valid values are ASC and DESC. By default (ASC), daemon task definitions are listed in ascending order by family name and revision number.

iv_nexttoken TYPE /AWS1/ECSSTRING /AWS1/ECSSTRING

The nextToken value returned from a ListDaemonTaskDefinitions request indicating that more results are available to fulfill the request and further calls will be needed. If maxResults was provided, it's possible for the number of results to be fewer than maxResults.

This token should be treated as an opaque identifier that is only used to retrieve the next items in a list and not for other programmatic purposes.

iv_maxresults TYPE /AWS1/ECSBOXEDINTEGER /AWS1/ECSBOXEDINTEGER

The maximum number of daemon task definition results that ListDaemonTaskDefinitions returned in paginated output. When this parameter is used, ListDaemonTaskDefinitions only returns maxResults results in a single page along with a nextToken response element. The remaining results of the initial request can be seen by sending another ListDaemonTaskDefinitions request with the returned nextToken value. This value can be between 1 and 100. If this parameter isn't used, then ListDaemonTaskDefinitions returns up to 100 results and a nextToken value if applicable.

RETURNING

oo_output TYPE REF TO /aws1/cl_ecslstdaemtaskdefnrsp /AWS1/CL_ECSLSTDAEMTASKDEFNRSP

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.

DATA(lo_result) = lo_client->listdaemontaskdefinitions(
  iv_family = |string|
  iv_familyprefix = |string|
  iv_maxresults = 123
  iv_nexttoken = |string|
  iv_revision = |string|
  iv_sort = |string|
  iv_status = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  LOOP AT lo_result->get_daemontaskdefinitions( ) into lo_row.
    lo_row_1 = lo_row.
    IF lo_row_1 IS NOT INITIAL.
      lv_string = lo_row_1->get_arn( ).
      lv_timestamp = lo_row_1->get_registeredat( ).
      lv_string = lo_row_1->get_registeredby( ).
      lv_timestamp = lo_row_1->get_deleterequestedat( ).
      lv_daemontaskdefinitionsta = lo_row_1->get_status( ).
    ENDIF.
  ENDLOOP.
  lv_string = lo_result->get_nexttoken( ).
ENDIF.

To list daemon task definitions

This example lists all daemon task definitions in your account that start with the monitoring prefix.

DATA(lo_result) = lo_client->listdaemontaskdefinitions( iv_familyprefix = |monitoring| ) .