cAWSSNS - 6.3

Talend ESB Mediation Components Reference Guide

Talend Data Fabric
Talend Data Services Platform
Talend ESB
Talend MDM Platform
Talend Open Studio for ESB
Talend Real-Time Big Data Platform
Design and Development
Installation and Upgrade
Talend Studio

cAWSSNS properties

Component Family

AWS, Connectivity/Messaging


cAWSSNS sends messages to an Amazon's Simple Notification topic.


cAWSSNS is used for sending messages to an Amazon's Simple Notification topic.

 Basic settings


Select an AWS connection component from the list to reuse the connection details you already defined.



Specify the name of the topic on Amazon's Simple Notification Service (SNS) to send message to.



Specify a subject for the message. It can be overriden by the message header CamelAwsSnsSubject.


cAWSSNS can only be an end component in a Route. It has to be used with the cAWSConnection component, which creates a connection to Amazon Web services. For more information about cAWSConnection, see cAWSConnection.



Scenario: Sending messages to Amazon's SNS topic

This scenario will show you how to use the cAWSSNS component to send message to the Amazon's SNS topic.

You must have a valid Amazon Web Services developer account, and be signed up to use Amazon's SNS. For more information, see Amazon SNS.

Dropping and linking the components

  1. From the Palette, drag and drop a cAWSConnection, a cTimer, a cSetBody, and a cAWSSNS component onto the design workspace.

  2. Label the components for better identification of their roles and link them with the Row > Route connection as shown above.

Configuring the components

  1. Double-click the cAWSConnection component to display its Basic settings view in the Component tab.

  2. In the Access Key and Secret Key fields, enter the authentication credentials of your AWS account. For how to get your Access Key and Access Secret, see Access keys (access key ID and secret access key).

  3. Double-click the cTimer component to open its Basic settings view in the Component tab.

  4. In the Repeat field, enter 1 to generate the message exchange one time. Keep the default settings of the other options.

  5. Double-click the cSetBody component to open its Basic settings view in the Component tab.

  6. Select CONSTANT from the Language drop-down list and type in "Hello world" in the Expression field as the message body.

  7. Double-click the cAWSSNS component to open its Basic settings view in the Component tab.

  8. In the Connection list, select the cAWSConnection component that you have just configured to connect to Amazon's SNS service.

    In the Topic field, enter the name of the topic to send message to, "talend-com-tesb-sns" in this use case.

    In the Subject field, give a subject for the message, for example "Talend".

  9. Press Ctrl+S to save your Route.

Viewing the code and executing the Route

  1. Click the Code tab at the bottom of the design workspace to check the generated code.

    As shown above, the message flow from sns_cTimer_1 is given a payload by sns_cSetBody_1 and then sent to sns_cAWSSNS_1.

  2. Press F6 to execute the Route. The logs of the message exchange are printed in the console.

  3. An email address has already subscribed to the SNS topic as shown below. For more information about how to subscribe to a topic, see the site

    An notification of the message is sent to the Email address: