Skip to content

/AWS1/CL_DYN=>LISTBACKUPS()

About ListBackups

List DynamoDB backups that are associated with an Amazon Web Services account and weren't made with Amazon Web Services Backup. To list these backups for a given table, specify TableName. ListBackups returns a paginated list of results with at most 1 MB worth of items in a page. You can also specify a maximum number of entries to be returned in a page.

In the request, start time is inclusive, but end time is exclusive. Note that these boundaries are for the time at which the original backup was requested.

You can call ListBackups a maximum of five times per second.

If you want to retrieve the complete list of backups made with Amazon Web Services Backup, use the Amazon Web Services Backup list API.

Method Signature

IMPORTING

Optional arguments:

iv_tablename TYPE /AWS1/DYNTABLEARN /AWS1/DYNTABLEARN

Lists the backups from the table specified in TableName. You can also provide the Amazon Resource Name (ARN) of the table in this parameter.

iv_limit TYPE /AWS1/DYNBACKUPSINPUTLIMIT /AWS1/DYNBACKUPSINPUTLIMIT

Maximum number of backups to return at once.

iv_timerangelowerbound TYPE /AWS1/DYNTIMERANGELOWERBOUND /AWS1/DYNTIMERANGELOWERBOUND

Only backups created after this time are listed. TimeRangeLowerBound is inclusive.

iv_timerangeupperbound TYPE /AWS1/DYNTIMERANGEUPPERBOUND /AWS1/DYNTIMERANGEUPPERBOUND

Only backups created before this time are listed. TimeRangeUpperBound is exclusive.

iv_exclusivestartbackuparn TYPE /AWS1/DYNBACKUPARN /AWS1/DYNBACKUPARN

LastEvaluatedBackupArn is the Amazon Resource Name (ARN) of the backup last evaluated when the current page of results was returned, inclusive of the current page of results. This value may be specified as the ExclusiveStartBackupArn of a new ListBackups operation in order to fetch the next page of results.

iv_backuptype TYPE /AWS1/DYNBACKUPTYPEFILTER /AWS1/DYNBACKUPTYPEFILTER

The backups from the table specified by BackupType are listed.

Where BackupType can be:

  • USER - On-demand backup created by you. (The default setting if no other backup types are specified.)

  • SYSTEM - On-demand backup automatically created by DynamoDB.

  • ALL - All types of on-demand backups (USER and SYSTEM).

RETURNING

oo_output TYPE REF TO /aws1/cl_dynlistbackupsoutput /AWS1/CL_DYNLISTBACKUPSOUTPUT

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_dyn~listbackups(
  iv_backuptype = |string|
  iv_exclusivestartbackuparn = |string|
  iv_limit = 123
  iv_tablename = |string|
  iv_timerangelowerbound = '20150101000000.0000000'
  iv_timerangeupperbound = '20150101000000.0000000'
).

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_backupsummaries( ) into lo_row.
    lo_row_1 = lo_row.
    IF lo_row_1 IS NOT INITIAL.
      lv_tablename = lo_row_1->get_tablename( ).
      lv_tableid = lo_row_1->get_tableid( ).
      lv_tablearn = lo_row_1->get_tablearn( ).
      lv_backuparn = lo_row_1->get_backuparn( ).
      lv_backupname = lo_row_1->get_backupname( ).
      lv_backupcreationdatetime = lo_row_1->get_backupcreationdatetime( ).
      lv_date = lo_row_1->get_backupexpirydatetime( ).
      lv_backupstatus = lo_row_1->get_backupstatus( ).
      lv_backuptype = lo_row_1->get_backuptype( ).
      lv_backupsizebytes = lo_row_1->get_backupsizebytes( ).
    ENDIF.
  ENDLOOP.
  lv_backuparn = lo_result->get_lastevaluatedbackuparn( ).
ENDIF.