/AWS1/IF_KYZ=>GETSTREAM()¶
About GetStream¶
Returns detailed information about a specific data capture stream for an Amazon Keyspaces table. The information includes the stream's Amazon Resource Name (ARN), creation time, current status, retention period, shard composition, and associated table details. This operation helps you monitor and manage the configuration of your Amazon Keyspaces data streams.
Method Signature¶
METHODS /AWS1/IF_KYZ~GETSTREAM
IMPORTING
!IV_STREAMARN TYPE /AWS1/KYZSTREAMARN OPTIONAL
!IV_MAXRESULTS TYPE /AWS1/KYZINTEGER OPTIONAL
!IO_SHARDFILTER TYPE REF TO /AWS1/CL_KYZSHARDFILTER OPTIONAL
!IV_NEXTTOKEN TYPE /AWS1/KYZSHARDIDTOKEN OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_kyzgetstreamoutput
RAISING
/AWS1/CX_KYZACCESSDENIEDEX
/AWS1/CX_KYZINTERNALSERVEREX
/AWS1/CX_KYZRESOURCENOTFOUNDEX
/AWS1/CX_KYZTHROTTLINGEX
/AWS1/CX_KYZVALIDATIONEX
/AWS1/CX_KYZCLIENTEXC
/AWS1/CX_KYZSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_streamarn TYPE /AWS1/KYZSTREAMARN /AWS1/KYZSTREAMARN¶
The Amazon Resource Name (ARN) of the stream for which detailed information is requested. This uniquely identifies the specific stream you want to get information about.
Optional arguments:¶
iv_maxresults TYPE /AWS1/KYZINTEGER /AWS1/KYZINTEGER¶
The maximum number of shard objects to return in a single
GetStreamrequest. The default value is 100. The minimum value is 1 and the maximum value is 100.
io_shardfilter TYPE REF TO /AWS1/CL_KYZSHARDFILTER /AWS1/CL_KYZSHARDFILTER¶
Optional filter criteria to apply when retrieving shards. You can filter shards based on their parent
shardIDto get a list of children shards to narrow down the results returned by theGetStreamoperation.
iv_nexttoken TYPE /AWS1/KYZSHARDIDTOKEN /AWS1/KYZSHARDIDTOKEN¶
An optional pagination token provided by a previous
GetStreamoperation. If this parameter is specified, the response includes only records beyond the token, up to the value specified byMaxResults.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_kyzgetstreamoutput /AWS1/CL_KYZGETSTREAMOUTPUT¶
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->getstream(
io_shardfilter = new /aws1/cl_kyzshardfilter(
iv_shardid = |string|
iv_type = |string|
)
iv_maxresults = 123
iv_nexttoken = |string|
iv_streamarn = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_streamarn = lo_result->get_streamarn( ).
lv_string = lo_result->get_streamlabel( ).
lv_streamstatus = lo_result->get_streamstatus( ).
lv_streamviewtype = lo_result->get_streamviewtype( ).
lv_date = lo_result->get_creationrequestdatetime( ).
lv_keyspacename = lo_result->get_keyspacename( ).
lv_tablename = lo_result->get_tablename( ).
LOOP AT lo_result->get_shards( ) into lo_row.
lo_row_1 = lo_row.
IF lo_row_1 IS NOT INITIAL.
lv_shardid = lo_row_1->get_shardid( ).
lo_sequencenumberrange = lo_row_1->get_sequencenumberrange( ).
IF lo_sequencenumberrange IS NOT INITIAL.
lv_sequencenumber = lo_sequencenumberrange->get_startingsequencenumber( ).
lv_sequencenumber = lo_sequencenumberrange->get_endingsequencenumber( ).
ENDIF.
LOOP AT lo_row_1->get_parentshardids( ) into lo_row_2.
lo_row_3 = lo_row_2.
IF lo_row_3 IS NOT INITIAL.
lv_shardid = lo_row_3->get_value( ).
ENDIF.
ENDLOOP.
ENDIF.
ENDLOOP.
lv_shardidtoken = lo_result->get_nexttoken( ).
ENDIF.