Skip to content

/AWS1/IF_RSS=>UPDATENAMESPACE()

About UpdateNamespace

Updates a namespace with the specified settings. Unless required, you can't update multiple parameters in one request. For example, you must specify both adminUsername and adminUserPassword to update either field, but you can't update both kmsKeyId and logExports in a single request.

Similarly, an S3 Tables log-publishing update (a request where logDestinationType is s3table) cannot be combined with any other namespace configuration change and must be submitted as its own request.

Method Signature

METHODS /AWS1/IF_RSS~UPDATENAMESPACE
  IMPORTING
    !IV_NAMESPACENAME TYPE /AWS1/RSSNAMESPACENAME OPTIONAL
    !IV_ADMINUSERPASSWORD TYPE /AWS1/RSSDBPASSWORD OPTIONAL
    !IV_ADMINUSERNAME TYPE /AWS1/RSSDBUSER OPTIONAL
    !IV_KMSKEYID TYPE /AWS1/RSSSTRING OPTIONAL
    !IV_DEFAULTIAMROLEARN TYPE /AWS1/RSSSTRING OPTIONAL
    !IT_IAMROLES TYPE /AWS1/CL_RSSIAMROLEARNLIST_W=>TT_IAMROLEARNLIST OPTIONAL
    !IT_LOGEXPORTS TYPE /AWS1/CL_RSSLOGEXPORTLIST_W=>TT_LOGEXPORTLIST OPTIONAL
    !IV_MANAGEADMINPASSWORD TYPE /AWS1/RSSBOOLEAN OPTIONAL
    !IV_ADMINPASSWORDSECRETKMSK00 TYPE /AWS1/RSSKMSKEYID OPTIONAL
    !IV_LOGDESTINATIONTYPE TYPE /AWS1/RSSLOGDESTINATIONTYPE OPTIONAL
    !IV_S3TABLEACTION TYPE /AWS1/RSSS3TABLEACTION OPTIONAL
    !IT_S3TABLENAMES TYPE /AWS1/CL_RSSS3TABLENAMELIST_W=>TT_S3TABLENAMELIST OPTIONAL
    !IV_S3TABLEKMSKEYID TYPE /AWS1/RSSKMSKEYID OPTIONAL
    !IV_S3TABLEGRANULARITY TYPE /AWS1/RSSS3TABLEGRANULARITY OPTIONAL
  RETURNING
    VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_rssupdatenamespacersp
  RAISING
    /AWS1/CX_RSSCONFLICTEXCEPTION
    /AWS1/CX_RSSINTERNALSERVEREX
    /AWS1/CX_RSSRESOURCENOTFOUNDEX
    /AWS1/CX_RSSVALIDATIONEX
    /AWS1/CX_RSSCLIENTEXC
    /AWS1/CX_RSSSERVEREXC
    /AWS1/CX_RT_TECHNICAL_GENERIC
    /AWS1/CX_RT_SERVICE_GENERIC.

IMPORTING

Required arguments:

iv_namespacename TYPE /AWS1/RSSNAMESPACENAME /AWS1/RSSNAMESPACENAME

The name of the namespace to update. You can't update the name of a namespace once it is created.

Optional arguments:

iv_adminuserpassword TYPE /AWS1/RSSDBPASSWORD /AWS1/RSSDBPASSWORD

The password of the administrator for the first database created in the namespace. This parameter must be updated together with adminUsername.

You can't use adminUserPassword if manageAdminPassword is true.

If your admin user account is locked, this operation also unlocks your account and resets the failed-login counter. This option is available only when account lockout security is enabled for the namespace.

iv_adminusername TYPE /AWS1/RSSDBUSER /AWS1/RSSDBUSER

The username of the administrator for the first database created in the namespace. This parameter must be updated together with adminUserPassword.

iv_kmskeyid TYPE /AWS1/RSSSTRING /AWS1/RSSSTRING

The ID of the Amazon Web Services Key Management Service key used to encrypt your data.

iv_defaultiamrolearn TYPE /AWS1/RSSSTRING /AWS1/RSSSTRING

The Amazon Resource Name (ARN) of the IAM role to set as a default in the namespace. This parameter must be updated together with iamRoles.

it_iamroles TYPE /AWS1/CL_RSSIAMROLEARNLIST_W=>TT_IAMROLEARNLIST TT_IAMROLEARNLIST

A list of IAM roles to associate with the namespace. This parameter must be updated together with defaultIamRoleArn.

it_logexports TYPE /AWS1/CL_RSSLOGEXPORTLIST_W=>TT_LOGEXPORTLIST TT_LOGEXPORTLIST

The types of logs the namespace can export. The export types are userlog, connectionlog, and useractivitylog.

iv_manageadminpassword TYPE /AWS1/RSSBOOLEAN /AWS1/RSSBOOLEAN

If true, Amazon Redshift uses Secrets Manager to manage the namespace's admin credentials. You can't use adminUserPassword if manageAdminPassword is true. If manageAdminPassword is false or not set, Amazon Redshift uses adminUserPassword for the admin user account's password.

iv_adminpasswordsecretkmsk00 TYPE /AWS1/RSSKMSKEYID /AWS1/RSSKMSKEYID

The ID of the Key Management Service (KMS) key used to encrypt and store the namespace's admin credentials secret. You can only use this parameter if manageAdminPassword is true.

iv_logdestinationtype TYPE /AWS1/RSSLOGDESTINATIONTYPE /AWS1/RSSLOGDESTINATIONTYPE

The destination for the log data. Valid values are s3table and cloudwatch.

Set this to s3table to manage Amazon S3 Tables system-table publishing for the namespace.

iv_s3tableaction TYPE /AWS1/RSSS3TABLEACTION /AWS1/RSSS3TABLEACTION

Whether to enable or disable Amazon S3 Tables publishing. Valid values are Enable and Disable, matched case-insensitively.

When omitted, defaults to Enable. Valid only when logDestinationType is s3table.

it_s3tablenames TYPE /AWS1/CL_RSSS3TABLENAMELIST_W=>TT_S3TABLENAMELIST TT_S3TABLENAMELIST

The system tables to publish (on enable) or to stop publishing (on disable). Each value is either a system table view name that begins with sys_ or the keyword all.

Omitting this parameter, passing an empty list, or including all each select every current and future system table. Each name must be 1-128 characters, and the list can contain up to 256 names.

Valid only when logDestinationType is s3table.

iv_s3tablekmskeyid TYPE /AWS1/RSSKMSKEYID /AWS1/RSSKMSKEYID

The identifier of the Key Management Service key used to encrypt the published Amazon S3 Tables data. When omitted, the data is encrypted with SSE-S3 (Amazon S3 managed keys).

Valid only when logDestinationType is s3table.

iv_s3tablegranularity TYPE /AWS1/RSSS3TABLEGRANULARITY /AWS1/RSSS3TABLEGRANULARITY

The scope of the Amazon S3 Tables destination. Valid values are namespace and account, matched case-insensitively. namespace scopes the published tables to this namespace; account scopes them to the Amazon Web Services account.

Required when enabling. Omitting this parameter or passing a blank value fails with ValidationException. Valid only when logDestinationType is s3table.

RETURNING

oo_output TYPE REF TO /aws1/cl_rssupdatenamespacersp /AWS1/CL_RSSUPDATENAMESPACERSP

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->updatenamespace(
  it_iamroles = VALUE /aws1/cl_rssiamrolearnlist_w=>tt_iamrolearnlist(
    ( new /aws1/cl_rssiamrolearnlist_w( |string| ) )
  )
  it_logexports = VALUE /aws1/cl_rsslogexportlist_w=>tt_logexportlist(
    ( new /aws1/cl_rsslogexportlist_w( |string| ) )
  )
  it_s3tablenames = VALUE /aws1/cl_rsss3tablenamelist_w=>tt_s3tablenamelist(
    ( new /aws1/cl_rsss3tablenamelist_w( |string| ) )
  )
  iv_adminpasswordsecretkmsk00 = |string|
  iv_adminusername = |string|
  iv_adminuserpassword = |string|
  iv_defaultiamrolearn = |string|
  iv_kmskeyid = |string|
  iv_logdestinationtype = |string|
  iv_manageadminpassword = ABAP_TRUE
  iv_namespacename = |string|
  iv_s3tableaction = |string|
  iv_s3tablegranularity = |string|
  iv_s3tablekmskeyid = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  lo_namespace = lo_result->get_namespace( ).
  IF lo_namespace IS NOT INITIAL.
    lv_string = lo_namespace->get_namespacearn( ).
    lv_string = lo_namespace->get_namespaceid( ).
    lv_namespacename = lo_namespace->get_namespacename( ).
    lv_dbuser = lo_namespace->get_adminusername( ).
    lv_string = lo_namespace->get_dbname( ).
    lv_string = lo_namespace->get_kmskeyid( ).
    lv_string = lo_namespace->get_defaultiamrolearn( ).
    LOOP AT lo_namespace->get_iamroles( ) into lo_row.
      lo_row_1 = lo_row.
      IF lo_row_1 IS NOT INITIAL.
        lv_iamrolearn = lo_row_1->get_value( ).
      ENDIF.
    ENDLOOP.
    LOOP AT lo_namespace->get_logexports( ) into lo_row_2.
      lo_row_3 = lo_row_2.
      IF lo_row_3 IS NOT INITIAL.
        lv_logexport = lo_row_3->get_value( ).
      ENDIF.
    ENDLOOP.
    lv_namespacestatus = lo_namespace->get_status( ).
    lv_timestamp = lo_namespace->get_creationdate( ).
    lv_string = lo_namespace->get_adminpasswordsecretarn( ).
    lv_kmskeyid = lo_namespace->get_adminpasswordsecretkms00( ).
    lv_string = lo_namespace->get_lakehouseregstatus( ).
    lv_string = lo_namespace->get_catalogarn( ).
    lo_s3tablepublishstatus = lo_namespace->get_s3tablepublishstatus( ).
    IF lo_s3tablepublishstatus IS NOT INITIAL.
      LOOP AT lo_s3tablepublishstatus->get_s3tables( ) into lo_row_4.
        lo_row_5 = lo_row_4.
        IF lo_row_5 IS NOT INITIAL.
          lv_s3tablename = lo_row_5->get_value( ).
        ENDIF.
      ENDLOOP.
      lv_string = lo_s3tablepublishstatus->get_s3tablenamespace( ).
      lv_s3tablegranularity = lo_s3tablepublishstatus->get_s3tablegranularity( ).
      lv_boolean = lo_s3tablepublishstatus->get_enabledall( ).
      LOOP AT lo_s3tablepublishstatus->get_lastingestiontimes( ) into ls_row_6.
        lv_key = ls_row_6-key.
        lo_value = ls_row_6-value.
        IF lo_value IS NOT INITIAL.
          lv_string = lo_value->get_value( ).
        ENDIF.
      ENDLOOP.
    ENDIF.
  ENDIF.
ENDIF.