/AWS1/IF_IMG=>STARTRESOURCESTATEUPDATE()¶
About StartResourceStateUpdate¶
Begin asynchronous resource state update for lifecycle changes to the specified image resources.
Method Signature¶
METHODS /AWS1/IF_IMG~STARTRESOURCESTATEUPDATE
IMPORTING
!IV_RESOURCEARN TYPE /AWS1/IMGIMAGEBUILDVERSIONARN OPTIONAL
!IO_STATE TYPE REF TO /AWS1/CL_IMGRESOURCESTATE OPTIONAL
!IV_EXECUTIONROLE TYPE /AWS1/IMGROLENAMEORARN OPTIONAL
!IO_INCLUDERESOURCES TYPE REF TO /AWS1/CL_IMGRESRCSTATEUPINCR00 OPTIONAL
!IO_EXCLUSIONRULES TYPE REF TO /AWS1/CL_IMGRESRCSTATEUPEXCL00 OPTIONAL
!IV_UPDATEAT TYPE /AWS1/IMGDATETIMETIMESTAMP OPTIONAL
!IV_CLIENTTOKEN TYPE /AWS1/IMGCLIENTTOKEN OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_imgstrtresrcstateup01
RAISING
/AWS1/CX_IMGCALLRLIMEXCEEDEDEX
/AWS1/CX_IMGCLIENTEXCEPTION
/AWS1/CX_IMGFORBIDDENEXCEPTION
/AWS1/CX_IMGIDEMPOTENTPRMMIS00
/AWS1/CX_IMGINVALIDREQUESTEX
/AWS1/CX_IMGRESOURCEINUSEEX
/AWS1/CX_IMGRESOURCENOTFOUNDEX
/AWS1/CX_IMGSERVICEEXCEPTION
/AWS1/CX_IMGSERVICEUNAVAILEX
/AWS1/CX_IMGCLIENTEXC
/AWS1/CX_IMGSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_resourcearn TYPE /AWS1/IMGIMAGEBUILDVERSIONARN /AWS1/IMGIMAGEBUILDVERSIONARN¶
The Amazon Resource Name (ARN) of the Image Builder resource that is updated. The state update might also impact associated resources.
io_state TYPE REF TO /AWS1/CL_IMGRESOURCESTATE /AWS1/CL_IMGRESOURCESTATE¶
Indicates the lifecycle action to take for this request.
iv_clienttoken TYPE /AWS1/IMGCLIENTTOKEN /AWS1/IMGCLIENTTOKEN¶
Unique, case-sensitive identifier you provide to ensure idempotency of the request. For more information, see Ensuring idempotency in the Amazon EC2 API Reference.
Optional arguments:¶
iv_executionrole TYPE /AWS1/IMGROLENAMEORARN /AWS1/IMGROLENAMEORARN¶
The name or Amazon Resource Name (ARN) of the IAM role that’s used to update image state.
io_includeresources TYPE REF TO /AWS1/CL_IMGRESRCSTATEUPINCR00 /AWS1/CL_IMGRESRCSTATEUPINCR00¶
A list of image resources to update state for.
io_exclusionrules TYPE REF TO /AWS1/CL_IMGRESRCSTATEUPEXCL00 /AWS1/CL_IMGRESRCSTATEUPEXCL00¶
Skip action on the image resource and associated resources if specified exclusion rules are met.
iv_updateat TYPE /AWS1/IMGDATETIMETIMESTAMP /AWS1/IMGDATETIMETIMESTAMP¶
The timestamp that indicates when resources are updated by a lifecycle action.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_imgstrtresrcstateup01 /AWS1/CL_IMGSTRTRESRCSTATEUP01¶
Domain /AWS1/RT_ACCOUNT_ID Primitive Type NUMC
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->startresourcestateupdate(
io_exclusionrules = new /aws1/cl_imgresrcstateupexcl00(
io_amis = new /aws1/cl_imglcplydetexclusio01(
io_lastlaunched = new /aws1/cl_imglcplydetexclusio02(
iv_unit = |string|
iv_value = 123
)
it_regions = VALUE /aws1/cl_imgstringlist_w=>tt_stringlist(
( new /aws1/cl_imgstringlist_w( |string| ) )
)
it_sharedaccounts = VALUE /aws1/cl_imgaccountlist_w=>tt_accountlist(
( new /aws1/cl_imgaccountlist_w( |string| ) )
)
it_tagmap = VALUE /aws1/cl_imgtagmap_w=>tt_tagmap(
(
VALUE /aws1/cl_imgtagmap_w=>ts_tagmap_maprow(
value = new /aws1/cl_imgtagmap_w( |string| )
key = |string|
)
)
)
iv_ispublic = ABAP_TRUE
)
)
io_includeresources = new /aws1/cl_imgresrcstateupincr00(
iv_amis = ABAP_TRUE
iv_containers = ABAP_TRUE
iv_snapshots = ABAP_TRUE
)
io_state = new /aws1/cl_imgresourcestate( |string| )
iv_clienttoken = |string|
iv_executionrole = |string|
iv_resourcearn = |string|
iv_updateat = '20150101000000.0000000'
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_lifecycleexecutionid = lo_result->get_lifecycleexecutionid( ).
lv_imagebuildversionarn = lo_result->get_resourcearn( ).
ENDIF.