August 15, 2023

Listing all Amazon SQS queues in an AWS region – Docs for ESB 6.x

Listing all Amazon SQS queues in an AWS region

Configure the tSQSQueueList
component, the tIterateToFlow component, the tLogRow component, and the tJava component to list the URLs of all Amazon SQS queues in an AWS
region and display the total number of the queues in the region on the console of

Talend Studio
.

  1. Double-click the tSQSQueueList
    component to open its Basic settings view.

    amazon_sqs_tsqsqueuelist_basic.png

  2. Specify the connection details required to access Amazon SQS. In this
    example, select the Use an existing connection
    check box and from the Component List drop-down
    list displayed, select the connection component to reuse its connection details you
    have already defined.
  3. Double-click the tIterateToFlow
    component to open its Basic settings view.

    amazon_sqs_titeratetoflow_basic.png

  4. Click the

    components-button_three_dot.png

    button next to Edit schema to
    open the schema dialog box.

    amazon_sqs_titeratetoflow_schema.png

  5. Click the

    plus_button.png

    button to add one String type column
    CurrentQueueURL that will hold the URLs of the queues to be
    listed. When done, click OK to close the dialog
    box.

  6. In the Mapping table, set the value
    for the CurrentQueueURL column. In this example, the value is
    set to
    ((String)globalMap.get(“tSQSQueueList_1_CURRENT_QUEUE_NAME”)),
    which is the value of the global variable CURRENT_QUEUE_NAME
    for the tSQSQueueList component.

    Note that you can fill the value by pressing Ctrl + Space to access the global variables list and then selecting
    tSQSQueueList_1_CURRENT_QUEUE_NAME from the list.
  7. Double-click the tLogRow component to
    open its Basic settings view, and then select
    Table (print values in cells of a table) in the
    Mode area for better readability of the
    result.

    amazon_sqs_tlogrow_basic.png

  8. Double-click the tJava component to open its
    Basic settings view.

    amazon_sqs_tjava_basic.png

  9. In the Code field, enter the following
    code to display the total number of the queues in the region.


Document get from Talend https://help.talend.com
Thank you for watching.
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x