DeleteTopic

DeleteTopic #

Overview #

Deletes a topic and all its subscriptions.

AWS API Reference: https://docs.aws.amazon.com/sns/latest/api/API_DeleteTopic.html

Method #

DELETE_TOPIC

Import Parameters #

This method uses the following import parameters:

  • i_user_name

    The IAM user of AWS account.

  • i_arn

    Value of the Amazon Resource Name (ARN) to be deleted.

  • i_region

    Name of the region.


Export #

This method uses the following export parameters:

  • e_http_status

    HTTP Status code.

  • e_response_headers

    Returns information about the request in format Name/Value pair values.

  • e_response_content

    Response of the method execution.


Example #

DATA: lo_sns_topic   TYPE REF TO /lnkaws/cl_aws_sns_topic,
      lo_cx_aws_s3   TYPE REF TO /lnkaws/cx_aws_s3,
      lv_http_status TYPE i,
      lv_headers     TYPE tihttpnvp,
      lv_content     TYPE string.
TRY.
    CREATE OBJECT lo_sns_topic
      EXPORTING
        i_region    = 'eu-west-1'
        i_user_name = 'userawsconnector'.
    CALL METHOD lo_sns_topic->delete_topic
      EXPORTING
        i_user_name        = 'userawsconnector'
        i_arn              = 'ARN value'
        i_region           = 'eu-west-1'
      IMPORTING
        e_http_status      = lv_http_status
        e_response_headers = lv_headers
        e_response_content = lv_content.

  CATCH /lnkaws/cx_aws_s3 INTO lo_cx_aws_s3.
    RAISE EXCEPTION lo_cx_aws_s3.
ENDTRY.