/AWS1/CL_EMR=>LISTINSTANCES()
¶
About ListInstances¶
Provides information for all active Amazon EC2 instances and Amazon EC2 instances terminated in the last 30 days, up to a maximum of 2,000. Amazon EC2 instances in any of the following states are considered active: AWAITING_FULFILLMENT, PROVISIONING, BOOTSTRAPPING, RUNNING.
Method Signature¶
IMPORTING¶
Required arguments:¶
iv_clusterid
TYPE /AWS1/EMRCLUSTERID
/AWS1/EMRCLUSTERID
¶
The identifier of the cluster for which to list the instances.
Optional arguments:¶
iv_instancegroupid
TYPE /AWS1/EMRINSTANCEGROUPID
/AWS1/EMRINSTANCEGROUPID
¶
The identifier of the instance group for which to list the instances.
it_instancegrouptypes
TYPE /AWS1/CL_EMRINSTGRPTYPELIST_W=>TT_INSTANCEGROUPTYPELIST
TT_INSTANCEGROUPTYPELIST
¶
The type of instance group for which to list the instances.
iv_instancefleetid
TYPE /AWS1/EMRINSTANCEFLEETID
/AWS1/EMRINSTANCEFLEETID
¶
The unique identifier of the instance fleet.
iv_instancefleettype
TYPE /AWS1/EMRINSTANCEFLEETTYPE
/AWS1/EMRINSTANCEFLEETTYPE
¶
The node type of the instance fleet. For example MASTER, CORE, or TASK.
it_instancestates
TYPE /AWS1/CL_EMRINSTSTATELIST_W=>TT_INSTANCESTATELIST
TT_INSTANCESTATELIST
¶
A list of instance states that will filter the instances returned with this request.
iv_marker
TYPE /AWS1/EMRMARKER
/AWS1/EMRMARKER
¶
The pagination token that indicates the next set of results to retrieve.
RETURNING¶
oo_output
TYPE REF TO /aws1/cl_emrlistinstsoutput
/AWS1/CL_EMRLISTINSTSOUTPUT
¶
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->/aws1/if_emr~listinstances(
it_instancegrouptypes = VALUE /aws1/cl_emrinstgrptypelist_w=>tt_instancegrouptypelist(
( new /aws1/cl_emrinstgrptypelist_w( |string| ) )
)
it_instancestates = VALUE /aws1/cl_emrinststatelist_w=>tt_instancestatelist(
( new /aws1/cl_emrinststatelist_w( |string| ) )
)
iv_clusterid = |string|
iv_instancefleetid = |string|
iv_instancefleettype = |string|
iv_instancegroupid = |string|
iv_marker = |string|
).
This is an example of reading all possible response values
LOOP AT lo_result->get_instances( ) into lo_row.
lv_instanceid = lo_row_1->get_id( ).
lv_instanceid = lo_row_1->get_ec2instanceid( ).
lv_string = lo_row_1->get_publicdnsname( ).
lv_string = lo_row_1->get_publicipaddress( ).
lv_string = lo_row_1->get_privatednsname( ).
lv_string = lo_row_1->get_privateipaddress( ).
lv_instancestate = lo_instancestatus->get_state( ).
lv_instancestatechangereas_1 = lo_instancestatechangereas->get_code( ).
lv_string = lo_instancestatechangereas->get_message( ).
lv_date = lo_instancetimeline->get_creationdatetime( ).
lv_date = lo_instancetimeline->get_readydatetime( ).
lv_date = lo_instancetimeline->get_enddatetime( ).
lv_string = lo_row_1->get_instancegroupid( ).
lv_instancefleetid = lo_row_1->get_instancefleetid( ).
lv_markettype = lo_row_1->get_market( ).
lv_instancetype = lo_row_1->get_instancetype( ).
LOOP AT lo_row_1->get_ebsvolumes( ) into lo_row_2.
lv_string = lo_row_3->get_device( ).
lv_string = lo_row_3->get_volumeid( ).
ENDLOOP.
ENDLOOP.
lv_marker = lo_result->get_marker( ).