[camel] branch master updated (13f2f6a -> 4b2580e)

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|

[camel] branch master updated (13f2f6a -> 4b2580e)

acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git.


    from 13f2f6a  CAMEL-14565: Add docs for missing option
     new e06aad5  CAMEL-14552 - Create an AWS-SNS component based on SDK v2
     new 4bac9ea  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, docs
     new 15d565e  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, added component to kit
     new 8abd616  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen
     new 4c38081  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed CS
     new 82d8117  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed descriptions
     new b8d4796  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen docs
     new d6d388a  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed some tests
     new b8c06cd  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Pointing the correct SB starter
     new d4d6457  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Note about OSGi
     new 4b2580e  CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen

The 11 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 apache-camel/src/main/descriptors/common-bin.xml   |   1 +
 bom/camel-bom/pom.xml                              |   5 +
 components/camel-aws2-sns/pom.xml                  |  91 +++++++
 .../aws2/sns/Sns2ComponentConfigurer.java          |  33 +++
 .../component/aws2/sns/Sns2EndpointConfigurer.java |  57 +++++
 .../services/org/apache/camel/component.properties |   7 +
 .../services/org/apache/camel/component/aws2-sns   |   2 +
 .../org/apache/camel/configurer/aws2-sns-component |   2 +
 .../org/apache/camel/configurer/aws2-sns-endpoint  |   2 +
 .../apache/camel/component/aws2/sns/aws2-sns.json  |  51 ++++
 .../src/main/docs/aws2-sns-component.adoc          | 205 ++++++++++++++++
 .../camel/component/aws2/sns/Sns2Component.java    | 132 ++++++++++
 .../aws2/sns/Sns2ComponentVerifierExtension.java   |  84 +++++++
 .../component/aws2/sns/Sns2Configuration.java      | 269 +++++++++++++++++++++
 .../camel/component/aws2/sns/Sns2Constants.java    |  27 +++
 .../camel/component/aws2/sns/Sns2Endpoint.java     | 237 ++++++++++++++++++
 .../aws2/sns/Sns2HeaderFilterStrategy.java         |  30 +++
 .../camel/component/aws2/sns/Sns2Producer.java     | 153 ++++++++++++
 .../component/aws2/sns/AmazonSNSClientMock.java    |  80 ++++++
 .../aws2/sns/SNSComponentClientRegistryTest.java   |  41 ++++
 .../aws2/sns/SnsComponentConfigurationTest.java    | 216 +++++++++++++++++
 .../component/aws2/sns/SnsComponentSpringTest.java |  56 +++++
 .../camel/component/aws2/sns/SnsComponentTest.java |  65 +++++
 .../sns/SnsComponentVerifierExtensionTest.java     |  71 ++++++
 .../camel/component/aws2/sns/SnsProducerTest.java  |  73 ++++++
 .../integration/SnsComponentIntegrationTest.java   |  66 +++++
 .../SnsTopicWithKmsEncryptionIntegrationTest.java  |  65 +++++
 .../src/test/resources/log4j2.properties           |  28 +++
 .../aws2/sns/SnsComponentSpringTest-context.xml    |  34 +++
 components/pom.xml                                 |   1 +
 core/camel-allcomponents/pom.xml                   |   4 +
 .../component/ComponentsBuilderFactory.java        |  12 +
 .../dsl/Aws2SnsComponentBuilderFactory.java        | 160 ++++++++++++
 .../src/generated/resources/metadata.json          |  20 ++
 docs/components/modules/ROOT/nav.adoc              |   1 +
 .../modules/ROOT/pages/aws2-sns-component.adoc     | 206 ++++++++++++++++
 docs/components/modules/ROOT/pages/index.adoc      |   4 +-
 parent/pom.xml                                     |   5 +
 38 files changed, 2595 insertions(+), 1 deletion(-)
 create mode 100644 components/camel-aws2-sns/pom.xml
 create mode 100644 components/camel-aws2-sns/src/generated/java/org/apache/camel/component/aws2/sns/Sns2ComponentConfigurer.java
 create mode 100644 components/camel-aws2-sns/src/generated/java/org/apache/camel/component/aws2/sns/Sns2EndpointConfigurer.java
 create mode 100644 components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/component.properties
 create mode 100644 components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/component/aws2-sns
 create mode 100644 components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/configurer/aws2-sns-component
 create mode 100644 components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/configurer/aws2-sns-endpoint
 create mode 100644 components/camel-aws2-sns/src/generated/resources/org/apache/camel/component/aws2/sns/aws2-sns.json
 create mode 100644 components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
 create mode 100644 components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Component.java
 create mode 100644 components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2ComponentVerifierExtension.java
 create mode 100644 components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
 create mode 100644 components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Constants.java
 create mode 100644 components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
 create mode 100644 components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2HeaderFilterStrategy.java
 create mode 100644 components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Producer.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/AmazonSNSClientMock.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SNSComponentClientRegistryTest.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentSpringTest.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentTest.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentVerifierExtensionTest.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsProducerTest.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsComponentIntegrationTest.java
 create mode 100644 components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsTopicWithKmsEncryptionIntegrationTest.java
 create mode 100644 components/camel-aws2-sns/src/test/resources/log4j2.properties
 create mode 100644 components/camel-aws2-sns/src/test/resources/org/apache/camel/component/aws2/sns/SnsComponentSpringTest-context.xml
 create mode 100644 core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java
 create mode 100644 docs/components/modules/ROOT/pages/aws2-sns-component.adoc

Reply | Threaded
Open this post in threaded view
|

[camel] 01/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2

acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit e06aad5dba95c554edfc3abba21a665edf34cf0b
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 12:40:15 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2
---
 components/camel-aws2-sns/pom.xml                  |  91 +++++++
 .../aws2/sns/Sns2ComponentConfigurer.java          |  33 +++
 .../component/aws2/sns/Sns2EndpointConfigurer.java |  57 +++++
 .../services/org/apache/camel/component.properties |   7 +
 .../services/org/apache/camel/component/aws2-sns   |   2 +
 .../org/apache/camel/configurer/aws2-sns-component |   2 +
 .../org/apache/camel/configurer/aws2-sns-endpoint  |   2 +
 .../apache/camel/component/aws2/sns/aws2-sns.json  |  51 ++++
 .../src/main/docs/aws-sns-component.adoc           | 214 +++++++++++++++++
 .../camel/component/aws2/sns/Sns2Component.java    | 135 +++++++++++
 .../aws2/sns/Sns2ComponentVerifierExtension.java   |  85 +++++++
 .../component/aws2/sns/Sns2Configuration.java      | 267 +++++++++++++++++++++
 .../camel/component/aws2/sns/Sns2Constants.java    |  27 +++
 .../camel/component/aws2/sns/Sns2Endpoint.java     | 236 ++++++++++++++++++
 .../aws2/sns/Sns2HeaderFilterStrategy.java         |  30 +++
 .../camel/component/aws2/sns/Sns2Producer.java     | 153 ++++++++++++
 .../component/aws2/sns/AmazonSNSClientMock.java    |  81 +++++++
 .../aws2/sns/SNSComponentClientRegistryTest.java   |  43 ++++
 .../aws2/sns/SnsComponentConfigurationTest.java    | 216 +++++++++++++++++
 .../component/aws2/sns/SnsComponentSpringTest.java |  57 +++++
 .../camel/component/aws2/sns/SnsComponentTest.java |  67 ++++++
 .../sns/SnsComponentVerifierExtensionTest.java     |  71 ++++++
 .../camel/component/aws2/sns/SnsProducerTest.java  |  77 ++++++
 .../integration/SnsComponentIntegrationTest.java   |  66 +++++
 .../SnsTopicWithKmsEncryptionIntegrationTest.java  |  65 +++++
 .../src/test/resources/log4j2.properties           |  28 +++
 .../aws2/sns/SnsComponentSpringTest-context.xml    |  34 +++
 core/camel-allcomponents/pom.xml                   |   4 +
 .../component/ComponentsBuilderFactory.java        |  12 +
 .../dsl/Aws2SnsComponentBuilderFactory.java        | 160 ++++++++++++
 .../src/generated/resources/metadata.json          |  20 ++
 31 files changed, 2393 insertions(+)

diff --git a/components/camel-aws2-sns/pom.xml b/components/camel-aws2-sns/pom.xml
new file mode 100644
index 0000000..6eb92c9
--- /dev/null
+++ b/components/camel-aws2-sns/pom.xml
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+         http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.camel</groupId>
+        <artifactId>components</artifactId>
+        <version>3.1.0-SNAPSHOT</version>
+    </parent>
+
+    <artifactId>camel-aws2-sns</artifactId>
+    <packaging>jar</packaging>
+
+    <name>Camel :: AWS2 SNS</name>
+    <description>A Camel Amazon SNS Web Service Component Version 2</description>
+
+    <properties>
+    </properties>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.camel</groupId>
+            <artifactId>camel-support</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>software.amazon.awssdk</groupId>
+            <artifactId>sns</artifactId>
+            <version>${aws-java-sdk2-version}</version>
+        </dependency>
+        <dependency>
+            <groupId>software.amazon.awssdk</groupId>
+            <artifactId>sqs</artifactId>
+            <version>${aws-java-sdk2-version}</version>
+        </dependency>
+        <dependency>
+            <groupId>software.amazon.awssdk</groupId>
+            <artifactId>apache-client</artifactId>
+            <version>${aws-java-sdk2-version}</version>
+        </dependency>
+
+        <!-- for testing -->
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.camel</groupId>
+            <artifactId>camel-test-spring</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.logging.log4j</groupId>
+            <artifactId>log4j-api</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.logging.log4j</groupId>
+            <artifactId>log4j-core</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.logging.log4j</groupId>
+            <artifactId>log4j-slf4j-impl</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.mockito</groupId>
+            <artifactId>mockito-core</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+</project>
diff --git a/components/camel-aws2-sns/src/generated/java/org/apache/camel/component/aws2/sns/Sns2ComponentConfigurer.java b/components/camel-aws2-sns/src/generated/java/org/apache/camel/component/aws2/sns/Sns2ComponentConfigurer.java
new file mode 100644
index 0000000..614f492
--- /dev/null
+++ b/components/camel-aws2-sns/src/generated/java/org/apache/camel/component/aws2/sns/Sns2ComponentConfigurer.java
@@ -0,0 +1,33 @@
+/* Generated by camel build tools - do NOT edit this file! */
+package org.apache.camel.component.aws2.sns;
+
+import org.apache.camel.CamelContext;
+import org.apache.camel.spi.GeneratedPropertyConfigurer;
+import org.apache.camel.support.component.PropertyConfigurerSupport;
+
+/**
+ * Generated by camel build tools - do NOT edit this file!
+ */
+@SuppressWarnings("unchecked")
+public class Sns2ComponentConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer {
+
+    @Override
+    public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) {
+        Sns2Component target = (Sns2Component) obj;
+        switch (ignoreCase ? name.toLowerCase() : name) {
+        case "accesskey":
+        case "accessKey": target.setAccessKey(property(camelContext, java.lang.String.class, value)); return true;
+        case "lazystartproducer":
+        case "lazyStartProducer": target.setLazyStartProducer(property(camelContext, boolean.class, value)); return true;
+        case "region": target.setRegion(property(camelContext, java.lang.String.class, value)); return true;
+        case "secretkey":
+        case "secretKey": target.setSecretKey(property(camelContext, java.lang.String.class, value)); return true;
+        case "basicpropertybinding":
+        case "basicPropertyBinding": target.setBasicPropertyBinding(property(camelContext, boolean.class, value)); return true;
+        case "configuration": target.setConfiguration(property(camelContext, org.apache.camel.component.aws2.sns.Sns2Configuration.class, value)); return true;
+        default: return false;
+        }
+    }
+
+}
+
diff --git a/components/camel-aws2-sns/src/generated/java/org/apache/camel/component/aws2/sns/Sns2EndpointConfigurer.java b/components/camel-aws2-sns/src/generated/java/org/apache/camel/component/aws2/sns/Sns2EndpointConfigurer.java
new file mode 100644
index 0000000..3e6b469
--- /dev/null
+++ b/components/camel-aws2-sns/src/generated/java/org/apache/camel/component/aws2/sns/Sns2EndpointConfigurer.java
@@ -0,0 +1,57 @@
+/* Generated by camel build tools - do NOT edit this file! */
+package org.apache.camel.component.aws2.sns;
+
+import org.apache.camel.CamelContext;
+import org.apache.camel.spi.GeneratedPropertyConfigurer;
+import org.apache.camel.support.component.PropertyConfigurerSupport;
+
+/**
+ * Generated by camel build tools - do NOT edit this file!
+ */
+@SuppressWarnings("unchecked")
+public class Sns2EndpointConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer {
+
+    @Override
+    public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) {
+        Sns2Endpoint target = (Sns2Endpoint) obj;
+        switch (ignoreCase ? name.toLowerCase() : name) {
+        case "amazonsnsclient":
+        case "amazonSNSClient": target.getConfiguration().setAmazonSNSClient(property(camelContext, software.amazon.awssdk.services.sns.SnsClient.class, value)); return true;
+        case "autocreatetopic":
+        case "autoCreateTopic": target.getConfiguration().setAutoCreateTopic(property(camelContext, boolean.class, value)); return true;
+        case "headerfilterstrategy":
+        case "headerFilterStrategy": target.setHeaderFilterStrategy(property(camelContext, org.apache.camel.spi.HeaderFilterStrategy.class, value)); return true;
+        case "kmsmasterkeyid":
+        case "kmsMasterKeyId": target.getConfiguration().setKmsMasterKeyId(property(camelContext, java.lang.String.class, value)); return true;
+        case "lazystartproducer":
+        case "lazyStartProducer": target.setLazyStartProducer(property(camelContext, boolean.class, value)); return true;
+        case "messagestructure":
+        case "messageStructure": target.getConfiguration().setMessageStructure(property(camelContext, java.lang.String.class, value)); return true;
+        case "policy": target.getConfiguration().setPolicy(property(camelContext, java.lang.String.class, value)); return true;
+        case "proxyhost":
+        case "proxyHost": target.getConfiguration().setProxyHost(property(camelContext, java.lang.String.class, value)); return true;
+        case "proxyport":
+        case "proxyPort": target.getConfiguration().setProxyPort(property(camelContext, java.lang.Integer.class, value)); return true;
+        case "proxyprotocol":
+        case "proxyProtocol": target.getConfiguration().setProxyProtocol(property(camelContext, software.amazon.awssdk.core.Protocol.class, value)); return true;
+        case "queueurl":
+        case "queueUrl": target.getConfiguration().setQueueUrl(property(camelContext, java.lang.String.class, value)); return true;
+        case "region": target.getConfiguration().setRegion(property(camelContext, java.lang.String.class, value)); return true;
+        case "serversideencryptionenabled":
+        case "serverSideEncryptionEnabled": target.getConfiguration().setServerSideEncryptionEnabled(property(camelContext, boolean.class, value)); return true;
+        case "subject": target.getConfiguration().setSubject(property(camelContext, java.lang.String.class, value)); return true;
+        case "subscribesnstosqs":
+        case "subscribeSNStoSQS": target.getConfiguration().setSubscribeSNStoSQS(property(camelContext, boolean.class, value)); return true;
+        case "basicpropertybinding":
+        case "basicPropertyBinding": target.setBasicPropertyBinding(property(camelContext, boolean.class, value)); return true;
+        case "synchronous": target.setSynchronous(property(camelContext, boolean.class, value)); return true;
+        case "accesskey":
+        case "accessKey": target.getConfiguration().setAccessKey(property(camelContext, java.lang.String.class, value)); return true;
+        case "secretkey":
+        case "secretKey": target.getConfiguration().setSecretKey(property(camelContext, java.lang.String.class, value)); return true;
+        default: return false;
+        }
+    }
+
+}
+
diff --git a/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/component.properties b/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/component.properties
new file mode 100644
index 0000000..6b68fd2
--- /dev/null
+++ b/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/component.properties
@@ -0,0 +1,7 @@
+# Generated by camel build tools - do NOT edit this file!
+components=aws2-sns
+groupId=org.apache.camel
+artifactId=camel-aws2-sns
+version=3.1.0-SNAPSHOT
+projectName=Camel :: AWS2 SNS
+projectDescription=A Camel Amazon SNS Web Service Component Version 2
diff --git a/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/component/aws2-sns b/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/component/aws2-sns
new file mode 100644
index 0000000..72f667e
--- /dev/null
+++ b/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/component/aws2-sns
@@ -0,0 +1,2 @@
+# Generated by camel build tools - do NOT edit this file!
+class=org.apache.camel.component.aws2.sns.Sns2Component
diff --git a/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/configurer/aws2-sns-component b/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/configurer/aws2-sns-component
new file mode 100644
index 0000000..c0e6715
--- /dev/null
+++ b/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/configurer/aws2-sns-component
@@ -0,0 +1,2 @@
+# Generated by camel build tools - do NOT edit this file!
+class=org.apache.camel.component.aws2.sns.Sns2ComponentConfigurer
diff --git a/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/configurer/aws2-sns-endpoint b/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/configurer/aws2-sns-endpoint
new file mode 100644
index 0000000..1cbbd1d
--- /dev/null
+++ b/components/camel-aws2-sns/src/generated/resources/META-INF/services/org/apache/camel/configurer/aws2-sns-endpoint
@@ -0,0 +1,2 @@
+# Generated by camel build tools - do NOT edit this file!
+class=org.apache.camel.component.aws2.sns.Sns2EndpointConfigurer
diff --git a/components/camel-aws2-sns/src/generated/resources/org/apache/camel/component/aws2/sns/aws2-sns.json b/components/camel-aws2-sns/src/generated/resources/org/apache/camel/component/aws2/sns/aws2-sns.json
new file mode 100644
index 0000000..205e6be
--- /dev/null
+++ b/components/camel-aws2-sns/src/generated/resources/org/apache/camel/component/aws2/sns/aws2-sns.json
@@ -0,0 +1,51 @@
+{
+  "component": {
+    "kind": "component",
+    "scheme": "aws2-sns",
+    "extendsScheme": "",
+    "syntax": "aws2-sns:topicNameOrArn",
+    "title": "AWS 2 Simple Notification System",
+    "description": "The aws-sns component is used for sending messages to an Amazon Simple Notification Topic.",
+    "label": "cloud,mobile,messaging",
+    "deprecated": false,
+    "async": false,
+    "consumerOnly": false,
+    "producerOnly": true,
+    "lenientProperties": false,
+    "javaType": "org.apache.camel.component.aws2.sns.Sns2Component",
+    "firstVersion": "3.1.0",
+    "groupId": "org.apache.camel",
+    "artifactId": "camel-aws2-sns",
+    "version": "3.1.0-SNAPSHOT"
+  },
+  "componentProperties": {
+    "accessKey": { "kind": "property", "displayName": "Access Key", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "Amazon AWS Access Key" },
+    "lazyStartProducer": { "kind": "property", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the r [...]
+    "region": { "kind": "property", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "The region in which SNS client needs to work" },
+    "secretKey": { "kind": "property", "displayName": "Secret Key", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "Amazon AWS Secret Key" },
+    "basicPropertyBinding": { "kind": "property", "displayName": "Basic Property Binding", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities" },
+    "configuration": { "kind": "property", "displayName": "Configuration", "group": "advanced", "label": "advanced", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws2.sns.Sns2Configuration", "deprecated": false, "secret": false, "description": "The AWS SNS default configuration" }
+  },
+  "properties": {
+    "topicNameOrArn": { "kind": "path", "displayName": "Topic Name Or Arn", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "secret": false, "description": "Topic name or ARN" },
+    "amazonSNSClient": { "kind": "parameter", "displayName": "Amazon SNSClient", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.services.sns.SnsClient", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "To use the AmazonSNS as the client" },
+    "autoCreateTopic": { "kind": "parameter", "displayName": "Auto Create Topic", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": "true", "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "Setting the autocreation of the topic" },
+    "headerFilterStrategy": { "kind": "parameter", "displayName": "Header Filter Strategy", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.spi.HeaderFilterStrategy", "deprecated": false, "secret": false, "description": "To use a custom HeaderFilterStrategy to map headers to\/from Camel." },
+    "kmsMasterKeyId": { "kind": "parameter", "displayName": "Kms Master Key Id", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The ID of an AWS-managed customer master key (CMK) for Amazon SNS or a custom CMK." },
+    "lazyStartProducer": { "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the  [...]
+    "messageStructure": { "kind": "parameter", "displayName": "Message Structure", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The message structure to use such as json" },
+    "policy": { "kind": "parameter", "displayName": "Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The policy for this queue" },
+    "proxyHost": { "kind": "parameter", "displayName": "Proxy Host", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "To define a proxy host when instantiating the SNS client" },
+    "proxyPort": { "kind": "parameter", "displayName": "Proxy Port", "group": "producer", "label": "", "required": false, "type": "integer", "javaType": "java.lang.Integer", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "To define a proxy port when instantiating the SNS client" },
+    "proxyProtocol": { "kind": "parameter", "displayName": "Proxy Protocol", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.core.Protocol", "enum": [ "HTTP", "HTTPS" ], "deprecated": false, "secret": false, "defaultValue": "HTTPS", "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "To define a proxy protocol when instantiating the SNS client" },
+    "queueUrl": { "kind": "parameter", "displayName": "Queue Url", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The queueUrl to subscribe to" },
+    "region": { "kind": "parameter", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The region in which SNS client needs to work. When using this parameter, the configuration will expect the capitalized name of the region (for example AP_E [...]
+    "serverSideEncryptionEnabled": { "kind": "parameter", "displayName": "Server Side Encryption Enabled", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "Define if Server Side Encryption is enabled or not on the topic" },
+    "subject": { "kind": "parameter", "displayName": "Subject", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The subject which is used if the message header 'CamelAwsSnsSubject' is not present." },
+    "subscribeSNStoSQS": { "kind": "parameter", "displayName": "Subscribe SNSto SQS", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "Define if the subscription between SNS Topic and SQS must be done or not" },
+    "basicPropertyBinding": { "kind": "parameter", "displayName": "Basic Property Binding", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the endpoint should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities" },
+    "synchronous": { "kind": "parameter", "displayName": "Synchronous", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": "false", "description": "Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported)." },
+    "accessKey": { "kind": "parameter", "displayName": "Access Key", "group": "security", "label": "security", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": true, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "Amazon AWS Access Key" },
+    "secretKey": { "kind": "parameter", "displayName": "Secret Key", "group": "security", "label": "security", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": true, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "Amazon AWS Secret Key" }
+  }
+}
diff --git a/components/camel-aws2-sns/src/main/docs/aws-sns-component.adoc b/components/camel-aws2-sns/src/main/docs/aws-sns-component.adoc
new file mode 100644
index 0000000..4ffbf31
--- /dev/null
+++ b/components/camel-aws2-sns/src/main/docs/aws-sns-component.adoc
@@ -0,0 +1,214 @@
+[[aws-sns-component]]
+= AWS Simple Notification System Component
+
+*Since Camel 2.8*
+
+// HEADER START
+*Only producer is supported*
+// HEADER END
+
+The SNS component allows messages to be sent to an
+https://aws.amazon.com/sns[Amazon Simple Notification] Topic. The
+implementation of the Amazon API is provided by
+the https://aws.amazon.com/sdkforjava/[AWS SDK].
+
+Prerequisites
+
+You must have a valid Amazon Web Services developer account, and be
+signed up to use Amazon SNS. More information is available at
+https://aws.amazon.com/sns[Amazon SNS].
+
+== URI Format
+
+[source,java]
+-----------------------------
+aws-sns://topicNameOrArn[?options]
+-----------------------------
+
+The topic will be created if they don't already exists. +
+ You can append query options to the URI in the following format,
+`?options=value&option2=value&...`
+
+== URI Options
+
+
+// component options: START
+The AWS Simple Notification System component supports 6 options, which are listed below.
+
+
+
+[width="100%",cols="2,5,^1,2",options="header"]
+|===
+| Name | Description | Default | Type
+| *accessKey* (producer) | Amazon AWS Access Key |  | String
+| *lazyStartProducer* (producer) | Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and [...]
+| *region* (producer) | The region in which SNS client needs to work |  | String
+| *secretKey* (producer) | Amazon AWS Secret Key |  | String
+| *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean
+| *configuration* (advanced) | The AWS SNS default configuration |  | SnsConfiguration
+|===
+// component options: END
+
+
+
+
+
+// endpoint options: START
+The AWS Simple Notification System endpoint is configured using URI syntax:
+
+----
+aws-sns:topicNameOrArn
+----
+
+with the following path and query parameters:
+
+=== Path Parameters (1 parameters):
+
+
+[width="100%",cols="2,5,^1,2",options="header"]
+|===
+| Name | Description | Default | Type
+| *topicNameOrArn* | *Required* Topic name or ARN |  | String
+|===
+
+
+=== Query Parameters (20 parameters):
+
+
+[width="100%",cols="2,5,^1,2",options="header"]
+|===
+| Name | Description | Default | Type
+| *amazonSNSClient* (producer) | To use the AmazonSNS as the client |  | AmazonSNS
+| *amazonSQSClient* (producer) | An SQS Client to use as bridge between SNS and SQS |  | AmazonSQS
+| *autoCreateTopic* (producer) | Setting the autocreation of the topic | true | boolean
+| *headerFilterStrategy* (producer) | To use a custom HeaderFilterStrategy to map headers to/from Camel. |  | HeaderFilterStrategy
+| *kmsMasterKeyId* (producer) | The ID of an AWS-managed customer master key (CMK) for Amazon SNS or a custom CMK. |  | String
+| *lazyStartProducer* (producer) | Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and [...]
+| *messageStructure* (producer) | The message structure to use such as json |  | String
+| *policy* (producer) | The policy for this queue |  | String
+| *proxyHost* (producer) | To define a proxy host when instantiating the SNS client |  | String
+| *proxyPort* (producer) | To define a proxy port when instantiating the SNS client |  | Integer
+| *proxyProtocol* (producer) | To define a proxy protocol when instantiating the SNS client. The value can be one of: HTTP, HTTPS | HTTPS | Protocol
+| *queueUrl* (producer) | The queueUrl to subscribe to |  | String
+| *region* (producer) | The region in which SNS client needs to work. When using this parameter, the configuration will expect the capitalized name of the region (for example AP_EAST_1) You'll need to use the name Regions.EU_WEST_1.name() |  | String
+| *serverSideEncryptionEnabled* (producer) | Define if Server Side Encryption is enabled or not on the topic | false | boolean
+| *subject* (producer) | The subject which is used if the message header 'CamelAwsSnsSubject' is not present. |  | String
+| *subscribeSNStoSQS* (producer) | Define if the subscription between SNS Topic and SQS must be done or not | false | boolean
+| *basicPropertyBinding* (advanced) | Whether the endpoint should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean
+| *synchronous* (advanced) | Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported). | false | boolean
+| *accessKey* (security) | Amazon AWS Access Key |  | String
+| *secretKey* (security) | Amazon AWS Secret Key |  | String
+|===
+// endpoint options: END
+
+
+
+
+
+Required SNS component options
+
+You have to provide the amazonSNSClient in the
+Registry or your accessKey and secretKey to access
+the https://aws.amazon.com/sns[Amazon's SNS].
+
+== Usage
+
+=== Message headers evaluated by the SNS producer
+
+[width="100%",cols="10%,10%,80%",options="header",]
+|=======================================================================
+|Header |Type |Description
+
+|`CamelAwsSnsSubject` |`String` |The Amazon SNS message subject. If not set, the subject from the
+`SnsConfiguration` is used.
+|=======================================================================
+
+=== Message headers set by the SNS producer
+
+[width="100%",cols="10%,10%,80%",options="header",]
+|=======================================================================
+|Header |Type |Description
+
+|`CamelAwsSnsMessageId` |`String` |The Amazon SNS message ID.
+|=======================================================================
+
+=== Advanced AmazonSNS configuration
+
+If you need more control over the `AmazonSNS` instance configuration you
+can create your own instance and refer to it from the URI:
+
+[source,java]
+-------------------------------------------------
+from("direct:start")
+.to("aws-sns://MyTopic?amazonSNSClient=#client");
+-------------------------------------------------
+
+The `#client` refers to a `AmazonSNS` in the
+Registry.
+
+For example if your Camel Application is running behind a firewall:
+
+[source,java]
+--------------------------------------------------------------------------------------
+AWSCredentials awsCredentials = new BasicAWSCredentials("myAccessKey", "mySecretKey");
+ClientConfiguration clientConfiguration = new ClientConfiguration();
+clientConfiguration.setProxyHost("http://myProxyHost");
+clientConfiguration.setProxyPort(8080);
+AmazonSNS client = new AmazonSNSClient(awsCredentials, clientConfiguration);
+
+registry.bind("client", client);
+--------------------------------------------------------------------------------------
+
+=== Create a subscription between an AWS SNS Topic and an AWS SQS Queue
+
+You can create a subscription of an SQS Queue to an SNS Topic in this way:
+
+[source,java]
+-------------------------------------------------
+from("direct:start")
+.to("aws-sns://test-camel-sns1?amazonSNSClient=#amazonSNSClient&amazonSQSClient=#amazonSQSClient&subscribeSNStoSQS=true&queueUrl=https://sqs.eu-central-1.amazonaws.com/780410022472/test-camel");
+-------------------------------------------------
+
+The `#amazonSNSClient` refers to a `AmazonSNS` in the
+Registry, while the `#amazonSQSClient` refers to an `AmazonSQS` client.
+By specifying `subscribeSNStoSQS` to true and a `queueUrl` of an existing SQS Queue,
+you'll be able to subscribe your SQS Queue to your SNS Topic.
+
+At this point you can consume messages coming from SNS Topic through your SQS Queue
+
+[source,java]
+-------------------------------------------------
+from("aws-sqs://test-camel?amazonSQSClient=#amazonSQSClient&delay=50&maxMessagesPerPoll=5")
+    .to(...);
+-------------------------------------------------
+
+== Topic Autocreation
+
+With the option `autoCreateTopic` users are able to avoid the autocreation of an SNS Topic in case it doesn't exist. The default for this option is `true`.
+If set to false any operation on a not-existent topic in AWS won't be successful and an error will be returned.
+
+== Automatic detection of AmazonSNS client in registry
+
+The component is capable of detecting the presence of an AmazonSNS bean into the registry.
+If it's the only instance of that type it will be used as client and you won't have to define it as uri parameter.
+This may be really useful for smarter configuration of the endpoint.
+
+== Dependencies
+
+Maven users will need to add the following dependency to their pom.xml.
+
+*pom.xml*
+
+[source,xml]
+---------------------------------------
+<dependency>
+    <groupId>org.apache.camel</groupId>
+    <artifactId>camel-aws-sns</artifactId>
+    <version>${camel-version}</version>
+</dependency>
+---------------------------------------
+
+where `$\{camel-version\}` must be replaced by the actual version of Camel.
+
+
+include::camel-spring-boot::page$aws-sns-starter.adoc[]
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Component.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Component.java
new file mode 100644
index 0000000..84143d0
--- /dev/null
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Component.java
@@ -0,0 +1,135 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import java.util.Map;
+import java.util.Set;
+
+
+import org.apache.camel.CamelContext;
+import org.apache.camel.Endpoint;
+import org.apache.camel.spi.Metadata;
+import org.apache.camel.spi.annotations.Component;
+import org.apache.camel.support.DefaultComponent;
+import org.apache.camel.util.ObjectHelper;
+
+import software.amazon.awssdk.regions.Region;
+import software.amazon.awssdk.services.sns.SnsClient;
+
+@Component("aws2-sns")
+public class Sns2Component extends DefaultComponent {
+    
+    @Metadata
+    private String accessKey;
+    @Metadata
+    private String secretKey;
+    @Metadata
+    private String region;
+    @Metadata(label = "advanced")    
+    private Sns2Configuration configuration;
+    
+    public Sns2Component() {
+        this(null);
+    }
+
+    public Sns2Component(CamelContext context) {
+        super(context);
+        
+        registerExtension(new Sns2ComponentVerifierExtension());
+    }
+
+    @Override
+    protected Endpoint createEndpoint(String uri, String remaining, Map<String, Object> parameters) throws Exception {
+
+        if (remaining == null || remaining.trim().length() == 0) {
+            throw new IllegalArgumentException("Topic name must be specified.");
+        }
+        Sns2Configuration configuration =  this.configuration != null ? this.configuration.copy() : new Sns2Configuration();
+        if (remaining.startsWith("arn:")) {
+            String[] parts = remaining.split(":");
+            if (parts.length != 6 || !parts[2].equals("sns")) {
+                throw new IllegalArgumentException("Topic arn must be in format arn:aws:sns:region:account:name.");
+            }
+            configuration.setTopicArn(remaining);
+            configuration.setRegion(Region.of(parts[3]).toString());
+        } else {
+            configuration.setTopicName(remaining);
+        }
+        Sns2Endpoint endpoint = new Sns2Endpoint(uri, this, configuration);
+        endpoint.getConfiguration().setAccessKey(accessKey);
+        endpoint.getConfiguration().setSecretKey(secretKey);
+        endpoint.getConfiguration().setRegion(region);
+        setProperties(endpoint, parameters);
+        checkAndSetRegistryClient(configuration);
+        if (configuration.getAmazonSNSClient() == null && (configuration.getAccessKey() == null || configuration.getSecretKey() == null)) {
+            throw new IllegalArgumentException("AmazonSNSClient or accessKey and secretKey must be specified");
+        }
+
+        return endpoint;
+    }
+    
+    public Sns2Configuration getConfiguration() {
+        return configuration;
+    }
+
+    /**
+     * The AWS SNS default configuration
+     */
+    public void setConfiguration(Sns2Configuration configuration) {
+        this.configuration = configuration;
+    }
+
+    public String getAccessKey() {
+        return accessKey;
+    }
+
+    /**
+     * Amazon AWS Access Key
+     */
+    public void setAccessKey(String accessKey) {
+        this.accessKey = accessKey;
+    }
+
+    public String getSecretKey() {
+        return secretKey;
+    }
+
+    /**
+     * Amazon AWS Secret Key
+     */
+    public void setSecretKey(String secretKey) {
+        this.secretKey = secretKey;
+    }
+    
+    /**
+     * The region in which SNS client needs to work
+     */
+    public String getRegion() {
+        return region;
+    }
+
+    public void setRegion(String region) {
+        this.region = region;
+    }
+    
+    private void checkAndSetRegistryClient(Sns2Configuration configuration) {
+        Set<SnsClient> clients = getCamelContext().getRegistry().findByType(SnsClient.class);
+        if (clients.size() == 1) {
+            configuration.setAmazonSNSClient(clients.stream().findFirst().get());
+        }
+    }
+}
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2ComponentVerifierExtension.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2ComponentVerifierExtension.java
new file mode 100644
index 0000000..46c3d45
--- /dev/null
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2ComponentVerifierExtension.java
@@ -0,0 +1,85 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import java.util.Map;
+
+import org.apache.camel.component.extension.verifier.DefaultComponentVerifierExtension;
+import org.apache.camel.component.extension.verifier.ResultBuilder;
+import org.apache.camel.component.extension.verifier.ResultErrorBuilder;
+import org.apache.camel.component.extension.verifier.ResultErrorHelper;
+
+import software.amazon.awssdk.auth.credentials.AwsBasicCredentials;
+import software.amazon.awssdk.auth.credentials.StaticCredentialsProvider;
+import software.amazon.awssdk.core.exception.SdkClientException;
+import software.amazon.awssdk.regions.Region;
+import software.amazon.awssdk.services.sns.SnsClient;
+import software.amazon.awssdk.services.sns.SnsClientBuilder;
+
+public class Sns2ComponentVerifierExtension extends DefaultComponentVerifierExtension {
+
+    public Sns2ComponentVerifierExtension() {
+        this("aws2-sns");
+    }
+
+    public Sns2ComponentVerifierExtension(String scheme) {
+        super(scheme);
+    }
+
+    // *********************************
+    // Parameters validation
+    // *********************************
+
+    @Override
+    protected Result verifyParameters(Map<String, Object> parameters) {
+
+        ResultBuilder builder = ResultBuilder.withStatusAndScope(Result.Status.OK, Scope.PARAMETERS).error(ResultErrorHelper.requiresOption("accessKey", parameters))
+            .error(ResultErrorHelper.requiresOption("secretKey", parameters)).error(ResultErrorHelper.requiresOption("region", parameters));
+
+        // Validate using the catalog
+
+        super.verifyParametersAgainstCatalog(builder, parameters);
+
+        return builder.build();
+    }
+
+    // *********************************
+    // Connectivity validation
+    // *********************************
+
+    @Override
+    protected Result verifyConnectivity(Map<String, Object> parameters) {
+        ResultBuilder builder = ResultBuilder.withStatusAndScope(Result.Status.OK, Scope.CONNECTIVITY);
+
+        try {
+            Sns2Configuration configuration = setProperties(new Sns2Configuration(), parameters);
+            AwsBasicCredentials cred = AwsBasicCredentials.create(configuration.getAccessKey(), configuration.getSecretKey());
+            SnsClientBuilder clientBuilder = SnsClient.builder();
+            SnsClient client = clientBuilder.credentialsProvider(StaticCredentialsProvider.create(cred)).region(Region.of(configuration.getRegion())).build();
+            client.listSubscriptions();
+        } catch (SdkClientException e) {
+            ResultErrorBuilder errorBuilder = ResultErrorBuilder.withCodeAndDescription(VerificationError.StandardCode.AUTHENTICATION, e.getMessage())
+                .detail("aws_sns_exception_message", e.getMessage()).detail(VerificationError.ExceptionAttribute.EXCEPTION_CLASS, e.getClass().getName())
+                .detail(VerificationError.ExceptionAttribute.EXCEPTION_INSTANCE, e);
+
+            builder.error(errorBuilder.build());
+        } catch (Exception e) {
+            builder.error(ResultErrorBuilder.withException(e).build());
+        }
+        return builder.build();
+    }
+}
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
new file mode 100644
index 0000000..205e831
--- /dev/null
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
@@ -0,0 +1,267 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import org.apache.camel.RuntimeCamelException;
+import org.apache.camel.spi.UriParam;
+import org.apache.camel.spi.UriParams;
+
+import software.amazon.awssdk.core.Protocol;
+import software.amazon.awssdk.services.sns.SnsClient;
+
+@UriParams
+public class Sns2Configuration implements Cloneable {
+
+    private String topicArn;
+
+    // Common properties
+    private String topicName;
+    @UriParam
+    private SnsClient amazonSNSClient;
+    @UriParam(label = "security", secret = true)
+    private String accessKey;
+    @UriParam(label = "security", secret = true)
+    private String secretKey;
+    @UriParam(enums = "HTTP,HTTPS", defaultValue = "HTTPS")
+    private Protocol proxyProtocol = Protocol.HTTPS;
+    @UriParam
+    private String proxyHost;
+    @UriParam
+    private Integer proxyPort;
+    @UriParam
+    private String queueUrl;
+    @UriParam
+    private boolean subscribeSNStoSQS;
+    @UriParam
+    private String kmsMasterKeyId;
+    @UriParam
+    private boolean serverSideEncryptionEnabled;
+    @UriParam(defaultValue = "true")
+    private boolean autoCreateTopic = true;
+
+    // Producer only properties
+    @UriParam
+    private String subject;
+    @UriParam
+    private String policy;
+    @UriParam
+    private String messageStructure;
+    @UriParam
+    private String region;
+
+    public String getSubject() {
+        return subject;
+    }
+
+    /**
+     * The subject which is used if the message header 'CamelAwsSnsSubject' is
+     * not present.
+     */
+    public void setSubject(String subject) {
+        this.subject = subject;
+    }
+
+    public String getTopicArn() {
+        return topicArn;
+    }
+
+    /**
+     * The Amazon Resource Name (ARN) assigned to the created topic.
+     */
+    public void setTopicArn(String topicArn) {
+        this.topicArn = topicArn;
+    }
+
+    public String getAccessKey() {
+        return accessKey;
+    }
+
+    /**
+     * Amazon AWS Access Key
+     */
+    public void setAccessKey(String accessKey) {
+        this.accessKey = accessKey;
+    }
+
+    public String getSecretKey() {
+        return secretKey;
+    }
+
+    /**
+     * Amazon AWS Secret Key
+     */
+    public void setSecretKey(String secretKey) {
+        this.secretKey = secretKey;
+    }
+
+    public SnsClient getAmazonSNSClient() {
+        return amazonSNSClient;
+    }
+
+    /**
+     * To use the AmazonSNS as the client
+     */
+    public void setAmazonSNSClient(SnsClient amazonSNSClient) {
+        this.amazonSNSClient = amazonSNSClient;
+    }
+
+    public String getTopicName() {
+        return topicName;
+    }
+
+    /**
+     * The name of the topic
+     */
+    public void setTopicName(String topicName) {
+        this.topicName = topicName;
+    }
+
+    public String getPolicy() {
+        return policy;
+    }
+
+    /**
+     * The policy for this queue
+     */
+    public void setPolicy(String policy) {
+        this.policy = policy;
+    }
+
+    public String getMessageStructure() {
+        return messageStructure;
+    }
+
+    /**
+     * The message structure to use such as json
+     */
+    public void setMessageStructure(String messageStructure) {
+        this.messageStructure = messageStructure;
+    }
+    
+    public Protocol getProxyProtocol() {
+        return proxyProtocol;
+    }
+
+    /**
+     * To define a proxy protocol when instantiating the SNS client
+     */
+    public void setProxyProtocol(Protocol proxyProtocol) {
+        this.proxyProtocol = proxyProtocol;
+    }
+
+    public String getProxyHost() {
+        return proxyHost;
+    }
+
+    /**
+     * To define a proxy host when instantiating the SNS client
+     */
+    public void setProxyHost(String proxyHost) {
+        this.proxyHost = proxyHost;
+    }
+
+    public Integer getProxyPort() {
+        return proxyPort;
+    }
+
+    /**
+     * To define a proxy port when instantiating the SNS client
+     */
+    public void setProxyPort(Integer proxyPort) {
+        this.proxyPort = proxyPort;
+    }
+
+    public String getRegion() {
+        return region;
+    }
+
+    /**
+     * The region in which SNS client needs to work. When using this parameter, the configuration will expect the capitalized name of the region (for example AP_EAST_1)
+     * You'll need to use the name Regions.EU_WEST_1.name()
+     */
+    public void setRegion(String region) {
+        this.region = region;
+    }
+
+    public String getQueueUrl() {
+        return queueUrl;
+    }
+
+    /**
+     * The queueUrl to subscribe to
+     */
+    public void setQueueUrl(String queueUrl) {
+        this.queueUrl = queueUrl;
+    }
+
+    public boolean isSubscribeSNStoSQS() {
+        return subscribeSNStoSQS;
+    }
+
+    /**
+     * Define if the subscription between SNS Topic and SQS must be done or not
+     */
+    public void setSubscribeSNStoSQS(boolean subscribeSNStoSQS) {
+        this.subscribeSNStoSQS = subscribeSNStoSQS;
+    }
+
+    public String getKmsMasterKeyId() {
+        return kmsMasterKeyId;
+    }
+
+    /**
+     * The ID of an AWS-managed customer master key (CMK) for Amazon SNS or a
+     * custom CMK.
+     */
+    public void setKmsMasterKeyId(String kmsMasterKeyId) {
+        this.kmsMasterKeyId = kmsMasterKeyId;
+    }
+
+    public boolean isServerSideEncryptionEnabled() {
+        return serverSideEncryptionEnabled;
+    }
+
+    /**
+     * Define if Server Side Encryption is enabled or not on the topic
+     */
+    public void setServerSideEncryptionEnabled(boolean serverSideEncryptionEnabled) {
+        this.serverSideEncryptionEnabled = serverSideEncryptionEnabled;
+    }
+
+    public boolean isAutoCreateTopic() {
+        return autoCreateTopic;
+    }
+
+    /**
+     * Setting the autocreation of the topic
+     */
+    public void setAutoCreateTopic(boolean autoCreateTopic) {
+        this.autoCreateTopic = autoCreateTopic;
+    }
+
+    // *************************************************
+    //
+    // *************************************************
+
+    public Sns2Configuration copy() {
+        try {
+            return (Sns2Configuration)super.clone();
+        } catch (CloneNotSupportedException e) {
+            throw new RuntimeCamelException(e);
+        }
+    }
+}
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Constants.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Constants.java
new file mode 100644
index 0000000..9ca469e
--- /dev/null
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Constants.java
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+/**
+ * Constants used in Camel AWS SNS module
+ */
+public interface Sns2Constants {
+    
+    String MESSAGE_ID = "CamelAwsSnsMessageId";
+    String SUBJECT = "CamelAwsSnsSubject";
+    String MESSAGE_STRUCTURE = "CamelAwsSnsMessageStructure";
+}
\ No newline at end of file
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
new file mode 100644
index 0000000..c8a39e9
--- /dev/null
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
@@ -0,0 +1,236 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import java.net.URI;
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.camel.Component;
+import org.apache.camel.Consumer;
+import org.apache.camel.Processor;
+import org.apache.camel.Producer;
+import org.apache.camel.spi.HeaderFilterStrategy;
+import org.apache.camel.spi.HeaderFilterStrategyAware;
+import org.apache.camel.spi.Metadata;
+import org.apache.camel.spi.UriEndpoint;
+import org.apache.camel.spi.UriParam;
+import org.apache.camel.spi.UriPath;
+import org.apache.camel.support.DefaultEndpoint;
+import org.apache.camel.util.ObjectHelper;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import software.amazon.awssdk.auth.credentials.AwsBasicCredentials;
+import software.amazon.awssdk.auth.credentials.StaticCredentialsProvider;
+import software.amazon.awssdk.awscore.exception.AwsServiceException;
+import software.amazon.awssdk.http.apache.ApacheHttpClient;
+import software.amazon.awssdk.http.apache.ProxyConfiguration;
+import software.amazon.awssdk.regions.Region;
+import software.amazon.awssdk.services.sns.SnsClient;
+import software.amazon.awssdk.services.sns.SnsClientBuilder;
+import software.amazon.awssdk.services.sns.model.CreateTopicRequest;
+import software.amazon.awssdk.services.sns.model.CreateTopicResponse;
+import software.amazon.awssdk.services.sns.model.ListTopicsRequest;
+import software.amazon.awssdk.services.sns.model.ListTopicsResponse;
+import software.amazon.awssdk.services.sns.model.SetTopicAttributesRequest;
+import software.amazon.awssdk.services.sns.model.SubscribeRequest;
+import software.amazon.awssdk.services.sns.model.SubscribeResponse;
+import software.amazon.awssdk.services.sns.model.Topic;
+
+/**
+ * The aws-sns component is used for sending messages to an Amazon Simple Notification Topic.
+ */
+@UriEndpoint(firstVersion = "3.1.0", scheme = "aws2-sns", title = "AWS 2 Simple Notification System", syntax = "aws2-sns:topicNameOrArn",
+    producerOnly = true, label = "cloud,mobile,messaging")
+public class Sns2Endpoint extends DefaultEndpoint implements HeaderFilterStrategyAware {
+
+    private static final Logger LOG = LoggerFactory.getLogger(Sns2Endpoint.class);
+
+    private SnsClient snsClient;
+
+    @UriPath(description = "Topic name or ARN")
+    @Metadata(required = true)
+    private String topicNameOrArn; // to support component docs
+    @UriParam
+    private Sns2Configuration configuration;
+    @UriParam
+    private HeaderFilterStrategy headerFilterStrategy;
+
+    public Sns2Endpoint(String uri, Component component, Sns2Configuration configuration) {
+        super(uri, component);
+        this.configuration = configuration;
+    }
+
+    @Override
+    public HeaderFilterStrategy getHeaderFilterStrategy() {
+        return headerFilterStrategy;
+    }
+
+    /**
+     * To use a custom HeaderFilterStrategy to map headers to/from Camel.
+     */
+    @Override
+    public void setHeaderFilterStrategy(HeaderFilterStrategy strategy) {
+        this.headerFilterStrategy = strategy;
+    }
+
+    @Override
+    public Consumer createConsumer(Processor processor) throws Exception {
+        throw new UnsupportedOperationException("You cannot receive messages from this endpoint");
+    }
+
+    @Override
+    public Producer createProducer() throws Exception {
+        return new Sns2Producer(this);
+    }
+
+    @Override
+    public void doInit() throws Exception {
+        super.doInit();
+        snsClient = configuration.getAmazonSNSClient() != null
+            ? configuration.getAmazonSNSClient() : createSNSClient();
+
+        // check the setting the headerFilterStrategy
+        if (headerFilterStrategy == null) {
+            headerFilterStrategy = new Sns2HeaderFilterStrategy();
+        }
+        
+        if (configuration.getTopicArn() == null) {
+            try {
+                String nextToken = null;
+                final String arnSuffix = ":" + configuration.getTopicName();
+                do {
+                 ListTopicsRequest request = ListTopicsRequest.builder().nextToken(nextToken).build();
+                    final ListTopicsResponse response = snsClient.listTopics(request);
+                    nextToken = response.nextToken();
+
+                    for (final Topic topic : response.topics()) {
+                        if (topic.topicArn().endsWith(arnSuffix)) {
+                            configuration.setTopicArn(topic.topicArn());
+                            break;
+                        }
+                    }
+                } while (nextToken != null);
+            } catch (final AwsServiceException ase) {
+                LOG.trace("The list topics operation return the following error code {}", ase.awsErrorDetails().errorCode());
+                throw ase;
+            }
+        }
+
+        if (configuration.getTopicArn() == null && configuration.isAutoCreateTopic()) {
+            // creates a new topic, or returns the URL of an existing one
+            CreateTopicRequest.Builder builder = CreateTopicRequest.builder().name(configuration.getTopicName());
+            
+            if (configuration.isServerSideEncryptionEnabled()) {
+                if (ObjectHelper.isNotEmpty(configuration.getKmsMasterKeyId())) {
+                    Map<String, String> attributes = new HashMap<>();
+                    attributes.put("KmsMasterKeyId", configuration.getKmsMasterKeyId());
+                    builder.attributes(attributes);
+                }
+            }
+
+            LOG.trace("Creating topic [{}] with request [{}]...", configuration.getTopicName(), builder);
+
+            CreateTopicResponse result = snsClient.createTopic(builder.build());
+            configuration.setTopicArn(result.topicArn());
+
+            LOG.trace("Topic created with Amazon resource name: {}", configuration.getTopicArn());
+        }
+        
+        if (ObjectHelper.isNotEmpty(configuration.getPolicy())) {
+            LOG.trace("Updating topic [{}] with policy [{}]", configuration.getTopicArn(), configuration.getPolicy());
+            
+            snsClient.setTopicAttributes(SetTopicAttributesRequest.builder().topicArn(configuration.getTopicArn()).attributeName("Policy").attributeValue(configuration.getPolicy()).build());
+            
+            LOG.trace("Topic policy updated");
+        }
+        
+        if (configuration.isSubscribeSNStoSQS()) {
+            if (ObjectHelper.isNotEmpty(ObjectHelper.isNotEmpty(configuration.getQueueUrl()))) {
+                SubscribeResponse resp = snsClient.subscribe(SubscribeRequest.builder().topicArn(configuration.getTopicArn()).protocol("sqs").endpoint(configuration.getQueueUrl()).returnSubscriptionArn(true).build());
+                LOG.trace("Subscription of SQS Queue to SNS Topic done with Amazon resource name: {}", resp.subscriptionArn());
+            } else {
+                throw new IllegalArgumentException("Using the SubscribeSNStoSQS option require both AmazonSQSClient and Queue URL options");
+            }
+        }
+        
+    }
+    
+    @Override
+    public void doStop() throws Exception {
+        if (ObjectHelper.isEmpty(configuration.getAmazonSNSClient())) {
+            if (snsClient != null) {
+                snsClient.close();
+            }
+        }
+        super.doStop();
+    }
+
+    public Sns2Configuration getConfiguration() {
+        return configuration;
+    }
+
+    public void setConfiguration(Sns2Configuration configuration) {
+        this.configuration = configuration;
+    }
+    
+    public void setSNSClient(SnsClient snsClient) {
+        this.snsClient = snsClient;
+    }
+    
+    public SnsClient getSNSClient() {
+        return snsClient;
+    }
+
+    /**
+     * Provide the possibility to override this method for an mock implementation
+     *
+     * @return AmazonSNSClient
+     */
+    SnsClient createSNSClient() {
+        SnsClient client = null;
+        SnsClientBuilder clientBuilder = SnsClient.builder();
+        ProxyConfiguration.Builder proxyConfig = null;
+        ApacheHttpClient.Builder httpClientBuilder = null;
+        boolean isClientConfigFound = false;
+        if (ObjectHelper.isNotEmpty(configuration.getProxyHost()) && ObjectHelper.isNotEmpty(configuration.getProxyPort())) {
+            proxyConfig = ProxyConfiguration.builder();
+            URI proxyEndpoint = URI.create(configuration.getProxyProtocol() + configuration.getProxyHost() + configuration.getProxyPort());
+            proxyConfig.endpoint(proxyEndpoint);
+            httpClientBuilder = ApacheHttpClient.builder().proxyConfiguration(proxyConfig.build());
+            isClientConfigFound = true;
+        }
+        if (configuration.getAccessKey() != null && configuration.getSecretKey() != null) {
+            AwsBasicCredentials cred = AwsBasicCredentials.create(configuration.getAccessKey(), configuration.getSecretKey());
+            if (isClientConfigFound) {
+                clientBuilder = clientBuilder.httpClientBuilder(httpClientBuilder).credentialsProvider(StaticCredentialsProvider.create(cred));
+            } else {
+                clientBuilder = clientBuilder.credentialsProvider(StaticCredentialsProvider.create(cred));
+            }
+        } else {
+            if (!isClientConfigFound) {
+                clientBuilder = clientBuilder.httpClientBuilder(httpClientBuilder);
+            }
+        }
+        if (ObjectHelper.isNotEmpty(configuration.getRegion())) {
+            clientBuilder = clientBuilder.region(Region.of(configuration.getRegion()));
+        }
+        client = clientBuilder.build();
+        return client;
+    }
+}
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2HeaderFilterStrategy.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2HeaderFilterStrategy.java
new file mode 100644
index 0000000..756d5da
--- /dev/null
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2HeaderFilterStrategy.java
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import org.apache.camel.support.DefaultHeaderFilterStrategy;
+
+public class Sns2HeaderFilterStrategy extends DefaultHeaderFilterStrategy {
+    public Sns2HeaderFilterStrategy() {
+        initialize();  
+    }
+
+    protected void initialize() {
+        // filter headers begin with "Camel" or "org.apache.camel"
+        setOutFilterPattern("(breadcrumbId|Camel|org\\.apache\\.camel)[\\.|a-z|A-z|0-9]*");
+    }
+}
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Producer.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Producer.java
new file mode 100644
index 0000000..b6871c0
--- /dev/null
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Producer.java
@@ -0,0 +1,153 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import java.nio.ByteBuffer;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Map.Entry;
+import java.util.Objects;
+import java.util.stream.Collectors;
+
+import org.apache.camel.Endpoint;
+import org.apache.camel.Exchange;
+import org.apache.camel.Message;
+import org.apache.camel.spi.HeaderFilterStrategy;
+import org.apache.camel.support.DefaultProducer;
+import org.apache.camel.util.URISupport;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import software.amazon.awssdk.core.SdkBytes;
+import software.amazon.awssdk.services.sns.model.MessageAttributeValue;
+import software.amazon.awssdk.services.sns.model.PublishRequest;
+import software.amazon.awssdk.services.sns.model.PublishResponse;
+
+/**
+ * A Producer which sends messages to the Amazon Web Service Simple Notification Service
+ * <a href="http://aws.amazon.com/sns/">AWS SNS</a>
+ */
+public class Sns2Producer extends DefaultProducer {
+
+    private static final Logger LOG = LoggerFactory.getLogger(Sns2Producer.class);
+
+    private transient String snsProducerToString;
+
+    public Sns2Producer(Endpoint endpoint) {
+        super(endpoint);
+    }
+
+    @Override
+    public void process(Exchange exchange) throws Exception {
+        PublishRequest.Builder request = PublishRequest.builder();
+
+        request.topicArn(getConfiguration().getTopicArn());
+        request.subject(determineSubject(exchange));
+        request.messageStructure(determineMessageStructure(exchange));
+        request.message(exchange.getIn().getBody(String.class));
+        request.messageAttributes(this.translateAttributes(exchange.getIn().getHeaders(), exchange));
+
+        LOG.trace("Sending request [{}] from exchange [{}]...", request, exchange);
+
+        PublishResponse result = getEndpoint().getSNSClient().publish(request.build());
+
+        LOG.trace("Received result [{}]", result);
+
+        Message message = getMessageForResponse(exchange);
+        message.setHeader(Sns2Constants.MESSAGE_ID, result.messageId());
+    }
+
+    private String determineSubject(Exchange exchange) {
+        String subject = exchange.getIn().getHeader(Sns2Constants.SUBJECT, String.class);
+        if (subject == null) {
+            subject = getConfiguration().getSubject();
+        }
+
+        return subject;
+    }
+
+    private String determineMessageStructure(Exchange exchange) {
+        String structure = exchange.getIn().getHeader(Sns2Constants.MESSAGE_STRUCTURE, String.class);
+        if (structure == null) {
+            structure = getConfiguration().getMessageStructure();
+        }
+
+        return structure;
+    }
+
+    Map<String, MessageAttributeValue> translateAttributes(Map<String, Object> headers, Exchange exchange) {
+        Map<String, MessageAttributeValue> result = new HashMap<>();
+        HeaderFilterStrategy headerFilterStrategy = getEndpoint().getHeaderFilterStrategy();
+        for (Entry<String, Object> entry : headers.entrySet()) {
+            // only put the message header which is not filtered into the message attribute
+            if (!headerFilterStrategy.applyFilterToCamelHeaders(entry.getKey(), entry.getValue(), exchange)) {
+                Object value = entry.getValue();
+                if (value instanceof String && !((String)value).isEmpty()) {
+                    MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
+                    mav.dataType("String");
+                    mav.stringValue((String)value);
+                    result.put(entry.getKey(), mav.build());
+                } else if (value instanceof ByteBuffer) {
+                 MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
+                    mav.dataType("Binary");
+                    mav.binaryValue(SdkBytes.fromByteBuffer((ByteBuffer)value));
+                    result.put(entry.getKey(), mav.build());
+                } else if (value instanceof Date) {
+                 MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
+                    mav.dataType("String");
+                    mav.stringValue(value.toString());
+                    result.put(entry.getKey(), mav.build());
+                } else if (value instanceof List) {
+                    String resultString = ((List<?>) value).stream()
+                            .map(o -> o instanceof String ? String.format("\"%s\"", o) : Objects.toString(o))
+                            .collect(Collectors.joining(", "));
+                    MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
+                    mav.dataType("String.Array");
+                    mav.stringValue("[" + resultString + "]");
+                    result.put(entry.getKey(), mav.build());
+                } else {
+                    // cannot translate the message header to message attribute value
+                    LOG.warn("Cannot put the message header key={}, value={} into Sns MessageAttribute", entry.getKey(), entry.getValue());
+                }
+            }
+        }
+        return result;
+    }
+
+    protected Sns2Configuration getConfiguration() {
+        return getEndpoint().getConfiguration();
+    }
+
+    @Override
+    public String toString() {
+        if (snsProducerToString == null) {
+            snsProducerToString = "SnsProducer[" + URISupport.sanitizeUri(getEndpoint().getEndpointUri()) + "]";
+        }
+        return snsProducerToString;
+    }
+
+    @Override
+    public Sns2Endpoint getEndpoint() {
+        return (Sns2Endpoint) super.getEndpoint();
+    }
+
+    public static Message getMessageForResponse(final Exchange exchange) {
+        return exchange.getMessage();
+    }
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/AmazonSNSClientMock.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/AmazonSNSClientMock.java
new file mode 100644
index 0000000..f442786
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/AmazonSNSClientMock.java
@@ -0,0 +1,81 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import software.amazon.awssdk.services.sns.SnsClient;
+import software.amazon.awssdk.services.sns.model.CreateTopicRequest;
+import software.amazon.awssdk.services.sns.model.CreateTopicResponse;
+import software.amazon.awssdk.services.sns.model.ListTopicsRequest;
+import software.amazon.awssdk.services.sns.model.ListTopicsResponse;
+import software.amazon.awssdk.services.sns.model.PublishRequest;
+import software.amazon.awssdk.services.sns.model.PublishResponse;
+import software.amazon.awssdk.services.sns.model.SetTopicAttributesRequest;
+import software.amazon.awssdk.services.sns.model.SetTopicAttributesResponse;
+import software.amazon.awssdk.services.sns.model.Topic;
+
+import org.junit.Assert;
+
+public class AmazonSNSClientMock implements SnsClient {
+    
+    private static final String DEFAULT_TOPIC_ARN = "arn:aws:sns:us-east-1:541925086079:MyTopic";
+    
+    public AmazonSNSClientMock() {
+    }
+
+    @Override
+    public SetTopicAttributesResponse setTopicAttributes(SetTopicAttributesRequest setTopicAttributesRequest) {
+        Assert.assertEquals(DEFAULT_TOPIC_ARN, setTopicAttributesRequest.topicArn());
+        Assert.assertEquals("Policy", setTopicAttributesRequest.attributeName());
+        Assert.assertEquals("XXX", setTopicAttributesRequest.attributeValue());
+        return SetTopicAttributesResponse.builder().build();
+    }
+
+    @Override
+    public CreateTopicResponse createTopic(CreateTopicRequest createTopicRequest) {
+        return CreateTopicResponse.builder().topicArn(DEFAULT_TOPIC_ARN).build();
+    }
+
+    @Override
+    public PublishResponse publish(PublishRequest publishRequest) {
+        return PublishResponse.builder().messageId("dcc8ce7a-7f18-4385-bedd-b97984b4363c").build();
+    }
+    
+    @Override
+    public ListTopicsResponse listTopics(ListTopicsRequest listTopicRequest) {
+     ListTopicsResponse.Builder res = ListTopicsResponse.builder();
+        Topic topic = Topic.builder().topicArn(DEFAULT_TOPIC_ARN).build();
+        List<Topic> list = new ArrayList<>();
+        list.add(topic);
+        res.topics(list);
+        return res.build();
+    }
+
+ @Override
+ public String serviceName() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public void close() {
+ // TODO Auto-generated method stub
+
+ }
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SNSComponentClientRegistryTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SNSComponentClientRegistryTest.java
new file mode 100644
index 0000000..cf6ce6e
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SNSComponentClientRegistryTest.java
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import org.apache.camel.component.aws2.sns.Sns2Component;
+import org.apache.camel.component.aws2.sns.Sns2Endpoint;
+import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Test;
+
+public class SNSComponentClientRegistryTest extends CamelTestSupport {
+
+    @Test
+    public void createEndpointWithMinimalSNSClientConfiguration() throws Exception {
+
+        AmazonSNSClientMock awsSNSClient = new AmazonSNSClientMock();
+        context.getRegistry().bind("awsSNSClient", awsSNSClient);
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic");
+
+        assertNotNull(endpoint.getConfiguration().getAmazonSNSClient());
+    }
+    
+    @Test(expected = IllegalArgumentException.class)
+    public void createEndpointWithMinimalSNSClientMisconfiguration() throws Exception {
+
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic");
+    }
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
new file mode 100644
index 0000000..ea9064f
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
@@ -0,0 +1,216 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import org.apache.camel.component.aws2.sns.Sns2Component;
+import org.apache.camel.component.aws2.sns.Sns2Endpoint;
+import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Test;
+
+import software.amazon.awssdk.core.Protocol;
+import software.amazon.awssdk.regions.Region;
+
+public class SnsComponentConfigurationTest extends CamelTestSupport {
+    
+    @Test
+    public void createEndpointWithMinimalConfiguration() throws Exception {
+        AmazonSNSClientMock mock = new AmazonSNSClientMock();
+        
+        context.getRegistry().bind("amazonSNSClient", mock);
+
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy");
+        
+        assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
+        assertEquals("xxx", endpoint.getConfiguration().getAccessKey());
+        assertEquals("yyy", endpoint.getConfiguration().getSecretKey());
+        assertNotNull(endpoint.getConfiguration().getAmazonSNSClient());
+        assertNull(endpoint.getConfiguration().getTopicArn());
+        assertNull(endpoint.getConfiguration().getSubject());
+        assertNull(endpoint.getConfiguration().getPolicy());
+    }
+    
+    @Test
+    public void createEndpointWithOnlyAccessKeyAndSecretKey() throws Exception {
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?accessKey=xxx&secretKey=yyy");
+
+        assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
+        assertEquals("xxx", endpoint.getConfiguration().getAccessKey());
+        assertEquals("yyy", endpoint.getConfiguration().getSecretKey());
+        assertNull(endpoint.getConfiguration().getAmazonSNSClient());
+        assertNull(endpoint.getConfiguration().getTopicArn());
+        assertNull(endpoint.getConfiguration().getSubject());
+        assertNull(endpoint.getConfiguration().getPolicy());
+    }
+
+    @Test
+    public void createEndpointWithMinimalArnConfiguration() throws Exception {
+        AmazonSNSClientMock mock = new AmazonSNSClientMock();
+        
+        context.getRegistry().bind("amazonSNSClient", mock);
+
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://arn:aws:sns:us-east-1:account:MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy");
+
+        assertNull(endpoint.getConfiguration().getTopicName());
+        assertEquals("arn:aws:sns:us-east-1:account:MyTopic", endpoint.getConfiguration().getTopicArn());
+    }
+
+    @Test
+    public void createEndpointWithMinimalConfigurationAndProvidedClient() throws Exception {
+        AmazonSNSClientMock mock = new AmazonSNSClientMock();
+        
+        context.getRegistry().bind("amazonSNSClient", mock);
+        
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient");
+        
+        assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
+        assertNull(endpoint.getConfiguration().getAccessKey());
+        assertNull(endpoint.getConfiguration().getSecretKey());
+        assertNull(endpoint.getConfiguration().getTopicArn());
+        assertNull(endpoint.getConfiguration().getSubject());
+        assertNull(endpoint.getConfiguration().getPolicy());
+        endpoint.start();
+        
+        assertEquals("arn:aws:sns:us-east-1:541925086079:MyTopic", endpoint.getConfiguration().getTopicArn());
+        
+        endpoint.stop();
+    }
+    
+    @Test
+    public void createEndpointWithMaximalConfiguration() throws Exception {
+    
+        AmazonSNSClientMock mock = new AmazonSNSClientMock();
+        
+        context.getRegistry().bind("amazonSNSClient", mock);
+        
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy"
+                + "&policy=%7B%22Version%22%3A%222008-10-17%22,%22Statement%22%3A%5B%7B%22Sid%22%3A%221%22,%22Effect%22%3A%22Allow%22,%22Principal%22%3A%7B%22AWS%22%3A%5B%22*%22%5D%7D,"
+                + "%22Action%22%3A%5B%22sns%3ASubscribe%22%5D%7D%5D%7D&subject=The+subject+message");
+        
+        assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
+        assertEquals("xxx", endpoint.getConfiguration().getAccessKey());
+        assertEquals("yyy", endpoint.getConfiguration().getSecretKey());
+        assertNull(endpoint.getConfiguration().getTopicArn());
+        assertNotNull(endpoint.getConfiguration().getAmazonSNSClient());
+        assertEquals("The subject message", endpoint.getConfiguration().getSubject());
+        assertEquals(
+                "{\"Version\":\"2008-10-17\",\"Statement\":[{\"Sid\":\"1\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":[\"*\"]},\"Action\":[\"sns:Subscribe\"]}]}",
+                endpoint.getConfiguration().getPolicy());
+    }
+    
+    @Test
+    public void createEndpointWithSQSSubscription() throws Exception {
+        AmazonSNSClientMock mock = new AmazonSNSClientMock();
+        
+        context.getRegistry().bind("amazonSNSClient", mock);
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&"
+        + "accessKey=xxx&secretKey=yyy&queueUrl=arn:aws:sqs:us-east-1:541925086079:MyQueue&subscribeSNStoSQS=true");
+        
+        assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
+        assertEquals("xxx", endpoint.getConfiguration().getAccessKey());
+        assertEquals("yyy", endpoint.getConfiguration().getSecretKey());
+        assertEquals("arn:aws:sqs:us-east-1:541925086079:MyQueue", endpoint.getConfiguration().getQueueUrl());
+        assertNotNull(endpoint.getConfiguration().getAmazonSNSClient());
+        assertNull(endpoint.getConfiguration().getTopicArn());
+        assertNull(endpoint.getConfiguration().getSubject());
+        assertNull(endpoint.getConfiguration().getPolicy());
+    }
+    
+    @Test(expected = IllegalArgumentException.class)
+    public void createEndpointWithoutAccessKeyConfiguration() throws Exception {
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        component.createEndpoint("aws-sns://MyTopic?secretKey=yyy");
+    }
+    
+    @Test(expected = IllegalArgumentException.class)
+    public void createEndpointWithoutSecretKeyConfiguration() throws Exception {
+        Sns2Component component = new Sns2Component(context);
+        component.createEndpoint("aws2-sns://MyTopic?accessKey=xxx");
+    }
+    
+    @Test
+    public void createEndpointWithComponentElements() throws Exception {
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        component.setAccessKey("XXX");
+        component.setSecretKey("YYY");
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic");
+        
+        assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
+        assertEquals("XXX", endpoint.getConfiguration().getAccessKey());
+        assertEquals("YYY", endpoint.getConfiguration().getSecretKey());
+    }
+    
+    @Test
+    public void createEndpointWithComponentAndEndpointElements() throws Exception {
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        component.setAccessKey("XXX");
+        component.setSecretKey("YYY");
+        component.setRegion(Region.US_WEST_1.toString());
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic?accessKey=xxxxxx&secretKey=yyyyy&region=US_EAST_1");
+        
+        assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
+        assertEquals("xxxxxx", endpoint.getConfiguration().getAccessKey());
+        assertEquals("yyyyy", endpoint.getConfiguration().getSecretKey());
+        assertEquals("US_EAST_1", endpoint.getConfiguration().getRegion());
+    }
+    
+    @Test
+    public void createEndpointWithoutAutocreation() throws Exception {
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        component.setAccessKey("XXX");
+        component.setSecretKey("YYY");
+        component.setRegion(Region.US_WEST_1.toString());
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic?accessKey=xxxxxx&secretKey=yyyyy&region=US_EAST_1&autoCreateTopic=false");
+        
+        assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
+        assertEquals("xxxxxx", endpoint.getConfiguration().getAccessKey());
+        assertEquals("yyyyy", endpoint.getConfiguration().getSecretKey());
+        assertEquals("US_EAST_1", endpoint.getConfiguration().getRegion());
+        assertEquals(false, endpoint.getConfiguration().isAutoCreateTopic());
+    }
+    
+    @Test
+    public void createEndpointWithComponentEndpointElementsAndProxy() throws Exception {
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        component.setAccessKey("XXX");
+        component.setSecretKey("YYY");
+        component.setRegion(Region.US_WEST_1.toString());
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://label?accessKey=xxxxxx&secretKey=yyyyy&region=US_EAST_1&proxyHost=localhost&proxyPort=9000&proxyProtocol=HTTP");
+        
+        assertEquals("xxxxxx", endpoint.getConfiguration().getAccessKey());
+        assertEquals("yyyyy", endpoint.getConfiguration().getSecretKey());
+        assertEquals("US_EAST_1", endpoint.getConfiguration().getRegion());
+        assertEquals(Protocol.HTTP, endpoint.getConfiguration().getProxyProtocol());
+        assertEquals("localhost", endpoint.getConfiguration().getProxyHost());
+        assertEquals(Integer.valueOf(9000), endpoint.getConfiguration().getProxyPort());
+    }
+    
+    @Test
+    public void createEndpointWithoutSecretKeyAndAccessKeyConfiguration() throws Exception {
+        AmazonSNSClientMock mock = new AmazonSNSClientMock();
+        
+        context.getRegistry().bind("amazonSNSClient", mock);
+
+        Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
+        component.createEndpoint("aws-sns://MyTopic?amazonSNSClient=#amazonSNSClient");
+    }
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentSpringTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentSpringTest.java
new file mode 100644
index 0000000..822960c
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentSpringTest.java
@@ -0,0 +1,57 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import org.apache.camel.Exchange;
+import org.apache.camel.ExchangePattern;
+import org.apache.camel.Processor;
+import org.apache.camel.component.aws2.sns.Sns2Constants;
+import org.apache.camel.test.spring.CamelSpringTestSupport;
+import org.junit.Test;
+import org.springframework.context.support.ClassPathXmlApplicationContext;
+
+public class SnsComponentSpringTest extends CamelSpringTestSupport {
+    
+    @Test
+    public void sendInOnly() throws Exception {
+        Exchange exchange = template.send("direct:start", ExchangePattern.InOnly, new Processor() {
+            public void process(Exchange exchange) throws Exception {
+                exchange.getIn().setHeader(Sns2Constants.SUBJECT, "This is my subject text.");
+                exchange.getIn().setBody("This is my message text.");
+            }
+        });
+        
+        assertEquals("dcc8ce7a-7f18-4385-bedd-b97984b4363c", exchange.getIn().getHeader(Sns2Constants.MESSAGE_ID));
+    }
+    
+    @Test
+    public void sendInOut() throws Exception {
+        Exchange exchange = template.send("direct:start", ExchangePattern.InOut, new Processor() {
+            public void process(Exchange exchange) throws Exception {
+                exchange.getIn().setHeader(Sns2Constants.SUBJECT, "This is my subject text.");
+                exchange.getIn().setBody("This is my message text.");
+            }
+        });
+        
+        assertEquals("dcc8ce7a-7f18-4385-bedd-b97984b4363c", exchange.getMessage().getHeader(Sns2Constants.MESSAGE_ID));
+    }
+
+    @Override
+    protected ClassPathXmlApplicationContext createApplicationContext() {
+        return new ClassPathXmlApplicationContext("org/apache/camel/component/aws2/sns/SnsComponentSpringTest-context.xml");
+    }
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentTest.java
new file mode 100644
index 0000000..d9e6462
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentTest.java
@@ -0,0 +1,67 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import org.apache.camel.BindToRegistry;
+import org.apache.camel.Exchange;
+import org.apache.camel.ExchangePattern;
+import org.apache.camel.Processor;
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.aws2.sns.Sns2Constants;
+import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Test;
+
+public class SnsComponentTest extends CamelTestSupport {
+
+    @BindToRegistry("amazonSNSClient")
+    AmazonSNSClientMock client = new AmazonSNSClientMock();
+    
+    @Test
+    public void sendInOnly() throws Exception {
+        Exchange exchange = template.send("direct:start", ExchangePattern.InOnly, new Processor() {
+            public void process(Exchange exchange) throws Exception {
+                exchange.getIn().setHeader(Sns2Constants.SUBJECT, "This is my subject text.");
+                exchange.getIn().setBody("This is my message text.");
+            }
+        });
+        
+        assertEquals("dcc8ce7a-7f18-4385-bedd-b97984b4363c", exchange.getIn().getHeader(Sns2Constants.MESSAGE_ID));
+    }
+    
+    @Test
+    public void sendInOut() throws Exception {
+        Exchange exchange = template.send("direct:start", ExchangePattern.InOut, new Processor() {
+            public void process(Exchange exchange) throws Exception {
+                exchange.getIn().setHeader(Sns2Constants.SUBJECT, "This is my subject text.");
+                exchange.getIn().setBody("This is my message text.");
+            }
+        });
+        
+        assertEquals("dcc8ce7a-7f18-4385-bedd-b97984b4363c", exchange.getMessage().getHeader(Sns2Constants.MESSAGE_ID));
+    }
+
+    @Override
+    protected RouteBuilder createRouteBuilder() throws Exception {
+        return new RouteBuilder() {
+            @Override
+            public void configure() throws Exception {
+                from("direct:start")
+                    .to("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&policy=XXX");
+            }
+        };
+    }
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentVerifierExtensionTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentVerifierExtensionTest.java
new file mode 100644
index 0000000..9df1ad4
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentVerifierExtensionTest.java
@@ -0,0 +1,71 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.camel.Component;
+import org.apache.camel.component.extension.ComponentVerifierExtension;
+import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Assert;
+import org.junit.Test;
+
+public class SnsComponentVerifierExtensionTest extends CamelTestSupport {
+
+    // *************************************************
+    // Tests (parameters)
+    // *************************************************
+    @Override
+    public boolean isUseRouteBuilder() {
+        return false;
+    }
+
+    @Test
+    public void testParameters() throws Exception {
+        Component component = context().getComponent("aws2-sns");
+
+        ComponentVerifierExtension verifier = component.getExtension(ComponentVerifierExtension.class).orElseThrow(IllegalStateException::new);
+
+        Map<String, Object> parameters = new HashMap<>();
+        parameters.put("secretKey", "l");
+        parameters.put("accessKey", "k");
+        parameters.put("region", "l");
+        parameters.put("topicNameOrArn", "bucket1");
+
+        ComponentVerifierExtension.Result result = verifier.verify(ComponentVerifierExtension.Scope.PARAMETERS, parameters);
+
+        Assert.assertEquals(ComponentVerifierExtension.Result.Status.OK, result.getStatus());
+    }
+
+    @Test
+    public void testConnectivity() throws Exception {
+        Component component = context().getComponent("aws2-sns");
+        ComponentVerifierExtension verifier = component.getExtension(ComponentVerifierExtension.class).orElseThrow(IllegalStateException::new);
+
+        Map<String, Object> parameters = new HashMap<>();
+        parameters.put("secretKey", "l");
+        parameters.put("accessKey", "k");
+        parameters.put("region", "US_EAST_1");
+        parameters.put("topicNameOrArn", "test12");
+
+        ComponentVerifierExtension.Result result = verifier.verify(ComponentVerifierExtension.Scope.CONNECTIVITY, parameters);
+
+        Assert.assertEquals(ComponentVerifierExtension.Result.Status.ERROR, result.getStatus());
+    }
+
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsProducerTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsProducerTest.java
new file mode 100644
index 0000000..6b98100
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsProducerTest.java
@@ -0,0 +1,77 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns;
+
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.camel.Exchange;
+import org.apache.camel.component.aws2.sns.Sns2Endpoint;
+import org.apache.camel.component.aws2.sns.Sns2HeaderFilterStrategy;
+import org.apache.camel.component.aws2.sns.Sns2Producer;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
+
+import software.amazon.awssdk.services.sns.model.MessageAttributeValue;
+
+import static org.hamcrest.CoreMatchers.is;
+import static org.junit.Assert.assertThat;
+import static org.mockito.Mockito.when;
+
+@RunWith(MockitoJUnitRunner.class)
+public class SnsProducerTest {
+
+    @Mock
+    private Exchange exchange;
+    @Mock
+    private Sns2Endpoint endpoint;
+    private Sns2Producer producer;
+
+    @Before
+    public void setUp() {
+        producer = new Sns2Producer(endpoint);
+
+        when(endpoint.getHeaderFilterStrategy()).thenReturn(new Sns2HeaderFilterStrategy());
+    }
+
+    @Test
+    public void translateAttributes() {
+        Map<String, Object> headers = new HashMap<>();
+        headers.put("key1", null);
+        headers.put("key2", "");
+        headers.put("key3", "value3");
+        headers.put("key4", Arrays.asList("Value4", "Value5", "Value6"));
+        headers.put("key5", Arrays.asList("Value7", null, "Value9"));
+        headers.put("key6", Arrays.asList(10, null, 12));
+        headers.put("key7", Arrays.asList(true, null, false));
+
+        Map<String, MessageAttributeValue> translateAttributes = producer.translateAttributes(headers, exchange);
+
+        assertThat(translateAttributes.size(), is(5));
+        assertThat(translateAttributes.get("key3").dataType(), is("String"));
+        assertThat(translateAttributes.get("key3").stringValue(), is("value3"));
+        assertThat(translateAttributes.get("key4").dataType(), is("String.Array"));
+        assertThat(translateAttributes.get("key4").stringValue(), is("[\"Value4\", \"Value5\", \"Value6\"]"));
+        assertThat(translateAttributes.get("key5").stringValue(), is("[\"Value7\", null, \"Value9\"]"));
+        assertThat(translateAttributes.get("key6").stringValue(), is("[10, null, 12]"));
+        assertThat(translateAttributes.get("key7").stringValue(), is("[true, null, false]"));
+    }
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsComponentIntegrationTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsComponentIntegrationTest.java
new file mode 100644
index 0000000..fedc451
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsComponentIntegrationTest.java
@@ -0,0 +1,66 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns.integration;
+
+import org.apache.camel.Exchange;
+import org.apache.camel.ExchangePattern;
+import org.apache.camel.Processor;
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.aws2.sns.Sns2Constants;
+import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Ignore;
+import org.junit.Test;
+
+@Ignore("Must be manually tested. Provide your own accessKey and secretKey!")
+public class SnsComponentIntegrationTest extends CamelTestSupport {
+    
+    @Test
+    public void sendInOnly() throws Exception {
+        Exchange exchange = template.send("direct:start", ExchangePattern.InOnly, new Processor() {
+            public void process(Exchange exchange) throws Exception {
+                exchange.getIn().setHeader(Sns2Constants.SUBJECT, "This is my subject");
+                exchange.getIn().setBody("This is my message text.");
+            }
+        });
+        
+        assertNotNull(exchange.getIn().getHeader(Sns2Constants.MESSAGE_ID));
+    }
+    
+    @Test
+    public void sendInOut() throws Exception {
+        Exchange exchange = template.send("direct:start", ExchangePattern.InOut, new Processor() {
+            public void process(Exchange exchange) throws Exception {
+                exchange.getIn().setHeader(Sns2Constants.SUBJECT, "This is my subject");
+                exchange.getIn().setBody("This is my message text.");
+            }
+        });
+        
+        assertNotNull(exchange.getMessage().getHeader(Sns2Constants.MESSAGE_ID));
+    }
+    
+    @Override
+    protected RouteBuilder createRouteBuilder() throws Exception {
+        return new RouteBuilder() {
+            @Override
+            public void configure() throws Exception {
+                from("direct:start")
+                    .to("aws2-sns://MyNewTopic?accessKey=xxx&secretKey=yyy&policy=%7B%22Version%22%3A%222008-10-17%22,%22Statement%22%3A%5B%7B%22Sid%22%3A%221%22,%22Effect%22%3A%22Allow%22,"
+                            + "%22Principal%22%3A%7B%22AWS%22%3A%5B%22*%22%5D%7D,%22Action%22%3A%5B%22sns%3ASubscribe%22%5D%7D%5D%7D&subject=The+subject+message");
+            }
+        };
+    }
+}
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsTopicWithKmsEncryptionIntegrationTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsTopicWithKmsEncryptionIntegrationTest.java
new file mode 100644
index 0000000..08c95bf
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsTopicWithKmsEncryptionIntegrationTest.java
@@ -0,0 +1,65 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.aws2.sns.integration;
+
+import org.apache.camel.Exchange;
+import org.apache.camel.ExchangePattern;
+import org.apache.camel.Processor;
+import org.apache.camel.builder.RouteBuilder;
+import org.apache.camel.component.aws2.sns.Sns2Constants;
+import org.apache.camel.test.junit4.CamelTestSupport;
+import org.junit.Ignore;
+import org.junit.Test;
+
+@Ignore("Must be manually tested. Provide your own accessKey and secretKey!")
+public class SnsTopicWithKmsEncryptionIntegrationTest extends CamelTestSupport {
+    
+    @Test
+    public void sendInOnly() throws Exception {
+        Exchange exchange = template.send("direct:start", ExchangePattern.InOnly, new Processor() {
+            public void process(Exchange exchange) throws Exception {
+                exchange.getIn().setHeader(Sns2Constants.SUBJECT, "This is my subject");
+                exchange.getIn().setBody("This is my message text.");
+            }
+        });
+        
+        assertNotNull(exchange.getIn().getHeader(Sns2Constants.MESSAGE_ID));
+    }
+    
+    @Test
+    public void sendInOut() throws Exception {
+        Exchange exchange = template.send("direct:start", ExchangePattern.InOut, new Processor() {
+            public void process(Exchange exchange) throws Exception {
+                exchange.getIn().setHeader(Sns2Constants.SUBJECT, "This is my subject");
+                exchange.getIn().setBody("This is my message text.");
+            }
+        });
+        
+        assertNotNull(exchange.getMessage().getHeader(Sns2Constants.MESSAGE_ID));
+    }
+    
+    @Override
+    protected RouteBuilder createRouteBuilder() throws Exception {
+        return new RouteBuilder() {
+            @Override
+            public void configure() throws Exception {
+                from("direct:start")
+                    .to("aws2-sns://MyNewTopic1?accessKey=RAW(xxxx)&secretKey=RAW(xxxx)&region=EU_WEST_1&subject=The+subject+message&serverSideEncryptionEnabled=true&kmsMasterKeyId=RAW(xxx)");
+            }
+        };
+    }
+}
diff --git a/components/camel-aws2-sns/src/test/resources/log4j2.properties b/components/camel-aws2-sns/src/test/resources/log4j2.properties
new file mode 100644
index 0000000..b04fda5
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/resources/log4j2.properties
@@ -0,0 +1,28 @@
+## ---------------------------------------------------------------------------
+## Licensed to the Apache Software Foundation (ASF) under one or more
+## contributor license agreements.  See the NOTICE file distributed with
+## this work for additional information regarding copyright ownership.
+## The ASF licenses this file to You under the Apache License, Version 2.0
+## (the "License"); you may not use this file except in compliance with
+## the License.  You may obtain a copy of the License at
+##
+##      http://www.apache.org/licenses/LICENSE-2.0
+##
+## Unless required by applicable law or agreed to in writing, software
+## distributed under the License is distributed on an "AS IS" BASIS,
+## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+## See the License for the specific language governing permissions and
+## limitations under the License.
+## ---------------------------------------------------------------------------
+
+appender.file.type = File
+appender.file.name = file
+appender.file.fileName = target/camel-aws-sns-test.log
+appender.file.layout.type = PatternLayout
+appender.file.layout.pattern = %d [%-15.15t] %-5p %-30.30c{1} - %m%n
+appender.out.type = Console
+appender.out.name = out
+appender.out.layout.type = PatternLayout
+appender.out.layout.pattern = %d [%-15.15t] %-5p %-30.30c{1} - %m%n
+rootLogger.level = INFO
+rootLogger.appenderRef.file.ref = file
diff --git a/components/camel-aws2-sns/src/test/resources/org/apache/camel/component/aws2/sns/SnsComponentSpringTest-context.xml b/components/camel-aws2-sns/src/test/resources/org/apache/camel/component/aws2/sns/SnsComponentSpringTest-context.xml
new file mode 100644
index 0000000..a9b89f6
--- /dev/null
+++ b/components/camel-aws2-sns/src/test/resources/org/apache/camel/component/aws2/sns/SnsComponentSpringTest-context.xml
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+         http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+
+-->
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="
+    http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
+    http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd">
+
+    <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
+        <route>
+            <from uri="direct:start"/>
+            <to uri="aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient"/>
+        </route>
+    </camelContext>
+
+    <bean id="amazonSNSClient" class="org.apache.camel.component.aws2.sns.AmazonSNSClientMock"/>
+</beans>
\ No newline at end of file
diff --git a/core/camel-allcomponents/pom.xml b/core/camel-allcomponents/pom.xml
index dbec35e..3b23a1d 100644
--- a/core/camel-allcomponents/pom.xml
+++ b/core/camel-allcomponents/pom.xml
@@ -204,6 +204,10 @@
  </dependency>
  <dependency>
  <groupId>org.apache.camel</groupId>
+ <artifactId>camel-aws2-sns</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
  <artifactId>camel-aws2-translate</artifactId>
  </dependency>
  <dependency>
diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
index a0c69a2..529afb0 100644
--- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
+++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
@@ -586,6 +586,18 @@ public interface ComponentsBuilderFactory {
         return org.apache.camel.builder.component.dsl.Aws2SesComponentBuilderFactory.aws2Ses();
     }
     /**
+     * AWS 2 Simple Notification System (camel-aws2-sns)
+     * The aws-sns component is used for sending messages to an Amazon Simple
+     * Notification Topic.
+     *
+     * Category: cloud,mobile,messaging
+     * Since: 3.1
+     * Maven coordinates: org.apache.camel:camel-aws2-sns
+     */
+    static org.apache.camel.builder.component.dsl.Aws2SnsComponentBuilderFactory.Aws2SnsComponentBuilder aws2Sns() {
+        return org.apache.camel.builder.component.dsl.Aws2SnsComponentBuilderFactory.aws2Sns();
+    }
+    /**
      * AWS 2 Translate (camel-aws2-translate)
      * The aws2-translate component is used for managing Amazon Translate
      *
diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java
new file mode 100644
index 0000000..79c61c9
--- /dev/null
+++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java
@@ -0,0 +1,160 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.builder.component.dsl;
+
+import javax.annotation.Generated;
+import org.apache.camel.Component;
+import org.apache.camel.builder.component.AbstractComponentBuilder;
+import org.apache.camel.builder.component.ComponentBuilder;
+import org.apache.camel.component.aws2.sns.Sns2Component;
+
+/**
+ * The aws-sns component is used for sending messages to an Amazon Simple
+ * Notification Topic.
+ *
+ * Generated by camel-package-maven-plugin - do not edit this file!
+ */
+@Generated("org.apache.camel.maven.packaging.ComponentDslMojo")
+public interface Aws2SnsComponentBuilderFactory {
+
+    /**
+     * AWS 2 Simple Notification System (camel-aws2-sns)
+     * The aws-sns component is used for sending messages to an Amazon Simple
+     * Notification Topic.
+     *
+     * Category: cloud,mobile,messaging
+     * Since: 3.1
+     * Maven coordinates: org.apache.camel:camel-aws2-sns
+     */
+    static Aws2SnsComponentBuilder aws2Sns() {
+        return new Aws2SnsComponentBuilderImpl();
+    }
+
+    /**
+     * Builder for the AWS 2 Simple Notification System component.
+     */
+    interface Aws2SnsComponentBuilder extends ComponentBuilder<Sns2Component> {
+        /**
+         * Amazon AWS Access Key.
+         *
+         * The option is a: <code>java.lang.String</code> type.
+         *
+         * Group: producer
+         */
+        default Aws2SnsComponentBuilder accessKey(java.lang.String accessKey) {
+            doSetProperty("accessKey", accessKey);
+            return this;
+        }
+        /**
+         * Whether the producer should be started lazy (on the first message).
+         * By starting lazy you can use this to allow CamelContext and routes to
+         * startup in situations where a producer may otherwise fail during
+         * starting and cause the route to fail being started. By deferring this
+         * startup to be lazy then the startup failure can be handled during
+         * routing messages via Camel's routing error handlers. Beware that when
+         * the first message is processed then creating and starting the
+         * producer may take a little time and prolong the total processing time
+         * of the processing.
+         *
+         * The option is a: <code>boolean</code> type.
+         *
+         * Default: false
+         * Group: producer
+         */
+        default Aws2SnsComponentBuilder lazyStartProducer(
+                boolean lazyStartProducer) {
+            doSetProperty("lazyStartProducer", lazyStartProducer);
+            return this;
+        }
+        /**
+         * The region in which SNS client needs to work.
+         *
+         * The option is a: <code>java.lang.String</code> type.
+         *
+         * Group: producer
+         */
+        default Aws2SnsComponentBuilder region(java.lang.String region) {
+            doSetProperty("region", region);
+            return this;
+        }
+        /**
+         * Amazon AWS Secret Key.
+         *
+         * The option is a: <code>java.lang.String</code> type.
+         *
+         * Group: producer
+         */
+        default Aws2SnsComponentBuilder secretKey(java.lang.String secretKey) {
+            doSetProperty("secretKey", secretKey);
+            return this;
+        }
+        /**
+         * Whether the component should use basic property binding (Camel 2.x)
+         * or the newer property binding with additional capabilities.
+         *
+         * The option is a: <code>boolean</code> type.
+         *
+         * Default: false
+         * Group: advanced
+         */
+        default Aws2SnsComponentBuilder basicPropertyBinding(
+                boolean basicPropertyBinding) {
+            doSetProperty("basicPropertyBinding", basicPropertyBinding);
+            return this;
+        }
+        /**
+         * The AWS SNS default configuration.
+         *
+         * The option is a:
+         * <code>org.apache.camel.component.aws2.sns.Sns2Configuration</code>
+         * type.
+         *
+         * Group: advanced
+         */
+        default Aws2SnsComponentBuilder configuration(
+                org.apache.camel.component.aws2.sns.Sns2Configuration configuration) {
+            doSetProperty("configuration", configuration);
+            return this;
+        }
+    }
+
+    class Aws2SnsComponentBuilderImpl
+            extends
+                AbstractComponentBuilder<Sns2Component>
+            implements
+                Aws2SnsComponentBuilder {
+        @Override
+        protected Sns2Component buildConcreteComponent() {
+            return new Sns2Component();
+        }
+        @Override
+        protected boolean setPropertyOnComponent(
+                Component component,
+                String name,
+                Object value) {
+            switch (name) {
+            case "accessKey": ((Sns2Component) component).setAccessKey((java.lang.String) value); return true;
+            case "lazyStartProducer": ((Sns2Component) component).setLazyStartProducer((boolean) value); return true;
+            case "region": ((Sns2Component) component).setRegion((java.lang.String) value); return true;
+            case "secretKey": ((Sns2Component) component).setSecretKey((java.lang.String) value); return true;
+            case "basicPropertyBinding": ((Sns2Component) component).setBasicPropertyBinding((boolean) value); return true;
+            case "configuration": ((Sns2Component) component).setConfiguration((org.apache.camel.component.aws2.sns.Sns2Configuration) value); return true;
+            default: return false;
+            }
+        }
+    }
+}
\ No newline at end of file
diff --git a/core/camel-componentdsl/src/generated/resources/metadata.json b/core/camel-componentdsl/src/generated/resources/metadata.json
index e6c5d84..52f22b2 100644
--- a/core/camel-componentdsl/src/generated/resources/metadata.json
+++ b/core/camel-componentdsl/src/generated/resources/metadata.json
@@ -581,6 +581,26 @@
     "artifactId": "camel-aws2-ses",
     "version": "3.1.0-SNAPSHOT"
   },
+  "Aws2SnsComponentBuilderFactory": {
+    "kind": "component",
+    "scheme": "aws2-sns",
+    "extendsScheme": "",
+    "syntax": "aws2-sns:topicNameOrArn",
+    "title": "AWS 2 Simple Notification System",
+    "description": "The aws-sns component is used for sending messages to an Amazon Simple Notification Topic.",
+    "label": "cloud,mobile,messaging",
+    "deprecated": false,
+    "deprecationNote": "cloud,mobile,messaging",
+    "async": false,
+    "consumerOnly": false,
+    "producerOnly": true,
+    "lenientProperties": false,
+    "javaType": "org.apache.camel.component.aws2.sns.Sns2Component",
+    "firstVersion": "3.1.0",
+    "groupId": "org.apache.camel",
+    "artifactId": "camel-aws2-sns",
+    "version": "3.1.0-SNAPSHOT"
+  },
   "Aws2TranslateComponentBuilderFactory": {
     "kind": "component",
     "scheme": "aws2-translate",

Reply | Threaded
Open this post in threaded view
|

[camel] 02/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, docs

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 4bac9ea65a9d915ac266fae971c63725f979ba32
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 12:49:17 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, docs
---
 ...-sns-component.adoc => aws2-sns-component.adoc} | 54 ++++++++--------------
 1 file changed, 19 insertions(+), 35 deletions(-)

diff --git a/components/camel-aws2-sns/src/main/docs/aws-sns-component.adoc b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
similarity index 81%
rename from components/camel-aws2-sns/src/main/docs/aws-sns-component.adoc
rename to components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
index 4ffbf31..e25c1af 100644
--- a/components/camel-aws2-sns/src/main/docs/aws-sns-component.adoc
+++ b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
@@ -1,7 +1,8 @@
-[[aws-sns-component]]
-= AWS Simple Notification System Component
+= AWS 2 Simple Notification System Component
 
 *Since Camel 2.8*
+*Since Camel 3.1*
+
 
 // HEADER START
 *Only producer is supported*
@@ -22,7 +23,7 @@ https://aws.amazon.com/sns[Amazon SNS].
 
 [source,java]
 -----------------------------
-aws-sns://topicNameOrArn[?options]
+aws2-sns://topicNameOrArn[?options]
 -----------------------------
 
 The topic will be created if they don't already exists. +
@@ -33,7 +34,7 @@ The topic will be created if they don't already exists. +
 
 
 // component options: START
-The AWS Simple Notification System component supports 6 options, which are listed below.
+The AWS 2 Simple Notification System component supports 6 options, which are listed below.
 
 
 
@@ -45,7 +46,7 @@ The AWS Simple Notification System component supports 6 options, which are liste
 | *region* (producer) | The region in which SNS client needs to work |  | String
 | *secretKey* (producer) | Amazon AWS Secret Key |  | String
 | *basicPropertyBinding* (advanced) | Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean
-| *configuration* (advanced) | The AWS SNS default configuration |  | SnsConfiguration
+| *configuration* (advanced) | The AWS SNS default configuration |  | Sns2Configuration
 |===
 // component options: END
 
@@ -54,10 +55,10 @@ The AWS Simple Notification System component supports 6 options, which are liste
 
 
 // endpoint options: START
-The AWS Simple Notification System endpoint is configured using URI syntax:
+The AWS 2 Simple Notification System endpoint is configured using URI syntax:
 
 ----
-aws-sns:topicNameOrArn
+aws2-sns:topicNameOrArn
 ----
 
 with the following path and query parameters:
@@ -72,14 +73,13 @@ with the following path and query parameters:
 |===
 
 
-=== Query Parameters (20 parameters):
+=== Query Parameters (19 parameters):
 
 
 [width="100%",cols="2,5,^1,2",options="header"]
 |===
 | Name | Description | Default | Type
-| *amazonSNSClient* (producer) | To use the AmazonSNS as the client |  | AmazonSNS
-| *amazonSQSClient* (producer) | An SQS Client to use as bridge between SNS and SQS |  | AmazonSQS
+| *amazonSNSClient* (producer) | To use the AmazonSNS as the client |  | SnsClient
 | *autoCreateTopic* (producer) | Setting the autocreation of the topic | true | boolean
 | *headerFilterStrategy* (producer) | To use a custom HeaderFilterStrategy to map headers to/from Camel. |  | HeaderFilterStrategy
 | *kmsMasterKeyId* (producer) | The ID of an AWS-managed customer master key (CMK) for Amazon SNS or a custom CMK. |  | String
@@ -102,9 +102,6 @@ with the following path and query parameters:
 // endpoint options: END
 
 
-
-
-
 Required SNS component options
 
 You have to provide the amazonSNSClient in the
@@ -134,31 +131,18 @@ the https://aws.amazon.com/sns[Amazon's SNS].
 
 === Advanced AmazonSNS configuration
 
-If you need more control over the `AmazonSNS` instance configuration you
+If you need more control over the `SnsClient` instance configuration you
 can create your own instance and refer to it from the URI:
 
 [source,java]
 -------------------------------------------------
 from("direct:start")
-.to("aws-sns://MyTopic?amazonSNSClient=#client");
+.to("aws2-sns://MyTopic?amazonSNSClient=#client");
 -------------------------------------------------
 
 The `#client` refers to a `AmazonSNS` in the
 Registry.
 
-For example if your Camel Application is running behind a firewall:
-
-[source,java]
---------------------------------------------------------------------------------------
-AWSCredentials awsCredentials = new BasicAWSCredentials("myAccessKey", "mySecretKey");
-ClientConfiguration clientConfiguration = new ClientConfiguration();
-clientConfiguration.setProxyHost("http://myProxyHost");
-clientConfiguration.setProxyPort(8080);
-AmazonSNS client = new AmazonSNSClient(awsCredentials, clientConfiguration);
-
-registry.bind("client", client);
---------------------------------------------------------------------------------------
-
 === Create a subscription between an AWS SNS Topic and an AWS SQS Queue
 
 You can create a subscription of an SQS Queue to an SNS Topic in this way:
@@ -166,11 +150,11 @@ You can create a subscription of an SQS Queue to an SNS Topic in this way:
 [source,java]
 -------------------------------------------------
 from("direct:start")
-.to("aws-sns://test-camel-sns1?amazonSNSClient=#amazonSNSClient&amazonSQSClient=#amazonSQSClient&subscribeSNStoSQS=true&queueUrl=https://sqs.eu-central-1.amazonaws.com/780410022472/test-camel");
+.to("aws2-sns://test-camel-sns1?amazonSNSClient=#amazonSNSClient&subscribeSNStoSQS=true&queueUrl=https://sqs.eu-central-1.amazonaws.com/780410022472/test-camel");
 -------------------------------------------------
 
-The `#amazonSNSClient` refers to a `AmazonSNS` in the
-Registry, while the `#amazonSQSClient` refers to an `AmazonSQS` client.
+The `#amazonSNSClient` refers to a `SnsClient` in the
+Registry.
 By specifying `subscribeSNStoSQS` to true and a `queueUrl` of an existing SQS Queue,
 you'll be able to subscribe your SQS Queue to your SNS Topic.
 
@@ -178,7 +162,7 @@ At this point you can consume messages coming from SNS Topic through your SQS Qu
 
 [source,java]
 -------------------------------------------------
-from("aws-sqs://test-camel?amazonSQSClient=#amazonSQSClient&delay=50&maxMessagesPerPoll=5")
+from("aws2-sqs://test-camel?amazonSQSClient=#amazonSQSClient&delay=50&maxMessagesPerPoll=5")
     .to(...);
 -------------------------------------------------
 
@@ -187,9 +171,9 @@ from("aws-sqs://test-camel?amazonSQSClient=#amazonSQSClient&delay=50&maxMessages
 With the option `autoCreateTopic` users are able to avoid the autocreation of an SNS Topic in case it doesn't exist. The default for this option is `true`.
 If set to false any operation on a not-existent topic in AWS won't be successful and an error will be returned.
 
-== Automatic detection of AmazonSNS client in registry
+== Automatic detection of SnsClient client in registry
 
-The component is capable of detecting the presence of an AmazonSNS bean into the registry.
+The component is capable of detecting the presence of an SnsClient bean into the registry.
 If it's the only instance of that type it will be used as client and you won't have to define it as uri parameter.
 This may be really useful for smarter configuration of the endpoint.
 
@@ -203,7 +187,7 @@ Maven users will need to add the following dependency to their pom.xml.
 ---------------------------------------
 <dependency>
     <groupId>org.apache.camel</groupId>
-    <artifactId>camel-aws-sns</artifactId>
+    <artifactId>camel-aws2-sns</artifactId>
     <version>${camel-version}</version>
 </dependency>
 ---------------------------------------

Reply | Threaded
Open this post in threaded view
|

[camel] 03/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, added component to kit

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 15d565e438cc8ee9ddd9685a4abda45d83fcbc50
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 13:10:00 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, added component to kit
---
 apache-camel/src/main/descriptors/common-bin.xml | 1 +
 bom/camel-bom/pom.xml                            | 5 +++++
 components/pom.xml                               | 1 +
 parent/pom.xml                                   | 5 +++++
 4 files changed, 12 insertions(+)

diff --git a/apache-camel/src/main/descriptors/common-bin.xml b/apache-camel/src/main/descriptors/common-bin.xml
index badb2ac..10673fa 100644
--- a/apache-camel/src/main/descriptors/common-bin.xml
+++ b/apache-camel/src/main/descriptors/common-bin.xml
@@ -95,6 +95,7 @@
         <include>org.apache.camel:camel-aws2-mq</include>
         <include>org.apache.camel:camel-aws2-msk</include>
         <include>org.apache.camel:camel-aws2-ses</include>
+        <include>org.apache.camel:camel-aws2-sns</include>
         <include>org.apache.camel:camel-aws2-translate</include>
         <include>org.apache.camel:camel-azure</include>
         <include>org.apache.camel:camel-barcode</include>
diff --git a/bom/camel-bom/pom.xml b/bom/camel-bom/pom.xml
index df6f9e6..c290e94 100644
--- a/bom/camel-bom/pom.xml
+++ b/bom/camel-bom/pom.xml
@@ -268,6 +268,11 @@
       </dependency>
       <dependency>
         <groupId>org.apache.camel</groupId>
+        <artifactId>camel-aws2-sns</artifactId>
+        <version>${project.version}</version>
+      </dependency>
+      <dependency>
+        <groupId>org.apache.camel</groupId>
         <artifactId>camel-aws2-translate</artifactId>
         <version>${project.version}</version>
       </dependency>
diff --git a/components/pom.xml b/components/pom.xml
index 3b878de..a0edbc2 100644
--- a/components/pom.xml
+++ b/components/pom.xml
@@ -133,6 +133,7 @@
         <module>camel-aws2-msk</module>
         <module>camel-aws2-mq</module>
         <module>camel-aws2-ses</module>
+        <module>camel-aws2-sns</module>
         <module>camel-aws2-translate</module>
         <module>camel-aws-xray</module>
         <module>camel-azure</module>
diff --git a/parent/pom.xml b/parent/pom.xml
index cb5674e..823cd03 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -1081,6 +1081,11 @@
       </dependency>
       <dependency>
         <groupId>org.apache.camel</groupId>
+        <artifactId>camel-aws2-sns</artifactId>
+        <version>${project.version}</version>
+      </dependency>
+      <dependency>
+        <groupId>org.apache.camel</groupId>
         <artifactId>camel-aws2-translate</artifactId>
         <version>${project.version}</version>
       </dependency>

Reply | Threaded
Open this post in threaded view
|

[camel] 04/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 8abd61677bf97f467adf207460a40085743abea5
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 14:34:11 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen
---
 components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc    | 6 ++++--
 docs/components/modules/ROOT/nav.adoc                              | 1 +
 .../components/modules/ROOT/pages}/aws2-sns-component.adoc         | 7 +++++--
 docs/components/modules/ROOT/pages/index.adoc                      | 4 +++-
 4 files changed, 13 insertions(+), 5 deletions(-)

diff --git a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
index e25c1af..ac904c3 100644
--- a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
+++ b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
@@ -1,6 +1,8 @@
+[[aws2-sns-component]]
 = AWS 2 Simple Notification System Component
 
-*Since Camel 2.8*
+*Since Camel 3.1*
+
 *Since Camel 3.1*
 
 
@@ -195,4 +197,4 @@ Maven users will need to add the following dependency to their pom.xml.
 where `$\{camel-version\}` must be replaced by the actual version of Camel.
 
 
-include::camel-spring-boot::page$aws-sns-starter.adoc[]
+include::camel-spring-boot::page$aws-sns-starter.adoc[]
\ No newline at end of file
diff --git a/docs/components/modules/ROOT/nav.adoc b/docs/components/modules/ROOT/nav.adoc
index dcd6a2c..2338cd9 100644
--- a/docs/components/modules/ROOT/nav.adoc
+++ b/docs/components/modules/ROOT/nav.adoc
@@ -54,6 +54,7 @@
 * xref:aws2-mq-component.adoc[AWS 2 MQ Component]
 * xref:aws2-msk-component.adoc[AWS 2 MSK Component]
 * xref:aws2-ses-component.adoc[AWS 2 Simple Email Service Component]
+* xref:aws2-sns-component.adoc[AWS 2 Simple Notification System Component]
 * xref:aws2-translate-component.adoc[AWS 2 Translate Component]
 * xref:azure-blob-component.adoc[Azure Storage Blob Service Component]
 * xref:azure-queue-component.adoc[Azure Storage Queue Service Component]
diff --git a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc b/docs/components/modules/ROOT/pages/aws2-sns-component.adoc
similarity index 98%
copy from components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
copy to docs/components/modules/ROOT/pages/aws2-sns-component.adoc
index e25c1af..6e7c08d 100644
--- a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
+++ b/docs/components/modules/ROOT/pages/aws2-sns-component.adoc
@@ -1,6 +1,9 @@
+[[aws2-sns-component]]
 = AWS 2 Simple Notification System Component
+:page-source: components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
+
+*Since Camel 3.1*
 
-*Since Camel 2.8*
 *Since Camel 3.1*
 
 
@@ -195,4 +198,4 @@ Maven users will need to add the following dependency to their pom.xml.
 where `$\{camel-version\}` must be replaced by the actual version of Camel.
 
 
-include::camel-spring-boot::page$aws-sns-starter.adoc[]
+include::camel-spring-boot::page$aws-sns-starter.adoc[]
\ No newline at end of file
diff --git a/docs/components/modules/ROOT/pages/index.adoc b/docs/components/modules/ROOT/pages/index.adoc
index 6380cd0..a2c6fe3 100644
--- a/docs/components/modules/ROOT/pages/index.adoc
+++ b/docs/components/modules/ROOT/pages/index.adoc
@@ -6,7 +6,7 @@ The following Apache Camel artifacts are provided:
 == Components
 
 // components: START
-Number of Components: 326 in 260 JAR artifacts (1 deprecated)
+Number of Components: 327 in 261 JAR artifacts (1 deprecated)
 
 [width="100%",cols="4,1,5",options="header"]
 |===
@@ -68,6 +68,8 @@ Number of Components: 326 in 260 JAR artifacts (1 deprecated)
 
 | xref:aws2-ses-component.adoc[AWS 2 Simple Email Service] (camel-aws2-ses) | 3.1 | The aws2-ses component is used for sending emails with Amazon's SES service.
 
+| xref:aws2-sns-component.adoc[AWS 2 Simple Notification System] (camel-aws2-sns) | 3.1 | The aws-sns component is used for sending messages to an Amazon Simple Notification Topic.
+
 | xref:aws2-translate-component.adoc[AWS 2 Translate] (camel-aws2-translate) | 3.1 | The aws2-translate component is used for managing Amazon Translate
 
 | xref:aws-cw-component.adoc[AWS CloudWatch] (camel-aws-cw) | 2.11 | The aws-cw component is used for sending metrics to an Amazon CloudWatch.

Reply | Threaded
Open this post in threaded view
|

[camel] 05/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed CS

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 4c380814bfc55c36c91adf2260cec62cd94fe8e3
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 14:45:21 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed CS
---
 .../camel/component/aws2/sns/Sns2Component.java    | 19 ++---
 .../aws2/sns/Sns2ComponentVerifierExtension.java   |  1 -
 .../component/aws2/sns/Sns2Configuration.java      |  8 +-
 .../camel/component/aws2/sns/Sns2Constants.java    |  4 +-
 .../camel/component/aws2/sns/Sns2Endpoint.java     | 41 +++++-----
 .../aws2/sns/Sns2HeaderFilterStrategy.java         |  4 +-
 .../camel/component/aws2/sns/Sns2Producer.java     | 22 +++---
 .../component/aws2/sns/AmazonSNSClientMock.java    | 33 ++++----
 .../aws2/sns/SNSComponentClientRegistryTest.java   |  8 +-
 .../aws2/sns/SnsComponentConfigurationTest.java    | 92 +++++++++++-----------
 .../component/aws2/sns/SnsComponentSpringTest.java |  9 +--
 .../camel/component/aws2/sns/SnsComponentTest.java | 12 ++-
 .../camel/component/aws2/sns/SnsProducerTest.java  |  4 -
 .../integration/SnsComponentIntegrationTest.java   | 12 +--
 .../SnsTopicWithKmsEncryptionIntegrationTest.java  | 10 +--
 15 files changed, 133 insertions(+), 146 deletions(-)

diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Component.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Component.java
index 84143d0..059a2d9 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Component.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Component.java
@@ -19,36 +19,33 @@ package org.apache.camel.component.aws2.sns;
 import java.util.Map;
 import java.util.Set;
 
-
 import org.apache.camel.CamelContext;
 import org.apache.camel.Endpoint;
 import org.apache.camel.spi.Metadata;
 import org.apache.camel.spi.annotations.Component;
 import org.apache.camel.support.DefaultComponent;
-import org.apache.camel.util.ObjectHelper;
-
 import software.amazon.awssdk.regions.Region;
 import software.amazon.awssdk.services.sns.SnsClient;
 
 @Component("aws2-sns")
 public class Sns2Component extends DefaultComponent {
-    
+
     @Metadata
     private String accessKey;
     @Metadata
     private String secretKey;
     @Metadata
     private String region;
-    @Metadata(label = "advanced")    
+    @Metadata(label = "advanced")
     private Sns2Configuration configuration;
-    
+
     public Sns2Component() {
         this(null);
     }
 
     public Sns2Component(CamelContext context) {
         super(context);
-        
+
         registerExtension(new Sns2ComponentVerifierExtension());
     }
 
@@ -58,7 +55,7 @@ public class Sns2Component extends DefaultComponent {
         if (remaining == null || remaining.trim().length() == 0) {
             throw new IllegalArgumentException("Topic name must be specified.");
         }
-        Sns2Configuration configuration =  this.configuration != null ? this.configuration.copy() : new Sns2Configuration();
+        Sns2Configuration configuration = this.configuration != null ? this.configuration.copy() : new Sns2Configuration();
         if (remaining.startsWith("arn:")) {
             String[] parts = remaining.split(":");
             if (parts.length != 6 || !parts[2].equals("sns")) {
@@ -81,7 +78,7 @@ public class Sns2Component extends DefaultComponent {
 
         return endpoint;
     }
-    
+
     public Sns2Configuration getConfiguration() {
         return configuration;
     }
@@ -114,7 +111,7 @@ public class Sns2Component extends DefaultComponent {
     public void setSecretKey(String secretKey) {
         this.secretKey = secretKey;
     }
-    
+
     /**
      * The region in which SNS client needs to work
      */
@@ -125,7 +122,7 @@ public class Sns2Component extends DefaultComponent {
     public void setRegion(String region) {
         this.region = region;
     }
-    
+
     private void checkAndSetRegistryClient(Sns2Configuration configuration) {
         Set<SnsClient> clients = getCamelContext().getRegistry().findByType(SnsClient.class);
         if (clients.size() == 1) {
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2ComponentVerifierExtension.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2ComponentVerifierExtension.java
index 46c3d45..0af6085 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2ComponentVerifierExtension.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2ComponentVerifierExtension.java
@@ -22,7 +22,6 @@ import org.apache.camel.component.extension.verifier.DefaultComponentVerifierExt
 import org.apache.camel.component.extension.verifier.ResultBuilder;
 import org.apache.camel.component.extension.verifier.ResultErrorBuilder;
 import org.apache.camel.component.extension.verifier.ResultErrorHelper;
-
 import software.amazon.awssdk.auth.credentials.AwsBasicCredentials;
 import software.amazon.awssdk.auth.credentials.StaticCredentialsProvider;
 import software.amazon.awssdk.core.exception.SdkClientException;
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
index 205e831..19785a3 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
@@ -19,7 +19,6 @@ package org.apache.camel.component.aws2.sns;
 import org.apache.camel.RuntimeCamelException;
 import org.apache.camel.spi.UriParam;
 import org.apache.camel.spi.UriParams;
-
 import software.amazon.awssdk.core.Protocol;
 import software.amazon.awssdk.services.sns.SnsClient;
 
@@ -151,7 +150,7 @@ public class Sns2Configuration implements Cloneable {
     public void setMessageStructure(String messageStructure) {
         this.messageStructure = messageStructure;
     }
-    
+
     public Protocol getProxyProtocol() {
         return proxyProtocol;
     }
@@ -190,8 +189,9 @@ public class Sns2Configuration implements Cloneable {
     }
 
     /**
-     * The region in which SNS client needs to work. When using this parameter, the configuration will expect the capitalized name of the region (for example AP_EAST_1)
-     * You'll need to use the name Regions.EU_WEST_1.name()
+     * The region in which SNS client needs to work. When using this parameter,
+     * the configuration will expect the capitalized name of the region (for
+     * example AP_EAST_1) You'll need to use the name Regions.EU_WEST_1.name()
      */
     public void setRegion(String region) {
         this.region = region;
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Constants.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Constants.java
index 9ca469e..8a7cb30 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Constants.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Constants.java
@@ -20,8 +20,8 @@ package org.apache.camel.component.aws2.sns;
  * Constants used in Camel AWS SNS module
  */
 public interface Sns2Constants {
-    
+
     String MESSAGE_ID = "CamelAwsSnsMessageId";
     String SUBJECT = "CamelAwsSnsSubject";
     String MESSAGE_STRUCTURE = "CamelAwsSnsMessageStructure";
-}
\ No newline at end of file
+}
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
index c8a39e9..410b778 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
@@ -34,7 +34,6 @@ import org.apache.camel.support.DefaultEndpoint;
 import org.apache.camel.util.ObjectHelper;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
-
 import software.amazon.awssdk.auth.credentials.AwsBasicCredentials;
 import software.amazon.awssdk.auth.credentials.StaticCredentialsProvider;
 import software.amazon.awssdk.awscore.exception.AwsServiceException;
@@ -53,10 +52,10 @@ import software.amazon.awssdk.services.sns.model.SubscribeResponse;
 import software.amazon.awssdk.services.sns.model.Topic;
 
 /**
- * The aws-sns component is used for sending messages to an Amazon Simple Notification Topic.
+ * The aws-sns component is used for sending messages to an Amazon Simple
+ * Notification Topic.
  */
-@UriEndpoint(firstVersion = "3.1.0", scheme = "aws2-sns", title = "AWS 2 Simple Notification System", syntax = "aws2-sns:topicNameOrArn",
-    producerOnly = true, label = "cloud,mobile,messaging")
+@UriEndpoint(firstVersion = "3.1.0", scheme = "aws2-sns", title = "AWS 2 Simple Notification System", syntax = "aws2-sns:topicNameOrArn", producerOnly = true, label = "cloud,mobile,messaging")
 public class Sns2Endpoint extends DefaultEndpoint implements HeaderFilterStrategyAware {
 
     private static final Logger LOG = LoggerFactory.getLogger(Sns2Endpoint.class);
@@ -102,20 +101,19 @@ public class Sns2Endpoint extends DefaultEndpoint implements HeaderFilterStrateg
     @Override
     public void doInit() throws Exception {
         super.doInit();
-        snsClient = configuration.getAmazonSNSClient() != null
-            ? configuration.getAmazonSNSClient() : createSNSClient();
+        snsClient = configuration.getAmazonSNSClient() != null ? configuration.getAmazonSNSClient() : createSNSClient();
 
         // check the setting the headerFilterStrategy
         if (headerFilterStrategy == null) {
             headerFilterStrategy = new Sns2HeaderFilterStrategy();
         }
-        
+
         if (configuration.getTopicArn() == null) {
             try {
                 String nextToken = null;
                 final String arnSuffix = ":" + configuration.getTopicName();
                 do {
-                 ListTopicsRequest request = ListTopicsRequest.builder().nextToken(nextToken).build();
+                    ListTopicsRequest request = ListTopicsRequest.builder().nextToken(nextToken).build();
                     final ListTopicsResponse response = snsClient.listTopics(request);
                     nextToken = response.nextToken();
 
@@ -135,7 +133,7 @@ public class Sns2Endpoint extends DefaultEndpoint implements HeaderFilterStrateg
         if (configuration.getTopicArn() == null && configuration.isAutoCreateTopic()) {
             // creates a new topic, or returns the URL of an existing one
             CreateTopicRequest.Builder builder = CreateTopicRequest.builder().name(configuration.getTopicName());
-            
+
             if (configuration.isServerSideEncryptionEnabled()) {
                 if (ObjectHelper.isNotEmpty(configuration.getKmsMasterKeyId())) {
                     Map<String, String> attributes = new HashMap<>();
@@ -151,26 +149,28 @@ public class Sns2Endpoint extends DefaultEndpoint implements HeaderFilterStrateg
 
             LOG.trace("Topic created with Amazon resource name: {}", configuration.getTopicArn());
         }
-        
+
         if (ObjectHelper.isNotEmpty(configuration.getPolicy())) {
             LOG.trace("Updating topic [{}] with policy [{}]", configuration.getTopicArn(), configuration.getPolicy());
-            
-            snsClient.setTopicAttributes(SetTopicAttributesRequest.builder().topicArn(configuration.getTopicArn()).attributeName("Policy").attributeValue(configuration.getPolicy()).build());
-            
+
+            snsClient.setTopicAttributes(SetTopicAttributesRequest.builder().topicArn(configuration.getTopicArn()).attributeName("Policy").attributeValue(configuration.getPolicy())
+                .build());
+
             LOG.trace("Topic policy updated");
         }
-        
+
         if (configuration.isSubscribeSNStoSQS()) {
             if (ObjectHelper.isNotEmpty(ObjectHelper.isNotEmpty(configuration.getQueueUrl()))) {
-                SubscribeResponse resp = snsClient.subscribe(SubscribeRequest.builder().topicArn(configuration.getTopicArn()).protocol("sqs").endpoint(configuration.getQueueUrl()).returnSubscriptionArn(true).build());
+                SubscribeResponse resp = snsClient.subscribe(SubscribeRequest.builder().topicArn(configuration.getTopicArn()).protocol("sqs").endpoint(configuration.getQueueUrl())
+                    .returnSubscriptionArn(true).build());
                 LOG.trace("Subscription of SQS Queue to SNS Topic done with Amazon resource name: {}", resp.subscriptionArn());
             } else {
                 throw new IllegalArgumentException("Using the SubscribeSNStoSQS option require both AmazonSQSClient and Queue URL options");
             }
         }
-        
+
     }
-    
+
     @Override
     public void doStop() throws Exception {
         if (ObjectHelper.isEmpty(configuration.getAmazonSNSClient())) {
@@ -188,17 +188,18 @@ public class Sns2Endpoint extends DefaultEndpoint implements HeaderFilterStrateg
     public void setConfiguration(Sns2Configuration configuration) {
         this.configuration = configuration;
     }
-    
+
     public void setSNSClient(SnsClient snsClient) {
         this.snsClient = snsClient;
     }
-    
+
     public SnsClient getSNSClient() {
         return snsClient;
     }
 
     /**
-     * Provide the possibility to override this method for an mock implementation
+     * Provide the possibility to override this method for an mock
+     * implementation
      *
      * @return AmazonSNSClient
      */
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2HeaderFilterStrategy.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2HeaderFilterStrategy.java
index 756d5da..5ecf688 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2HeaderFilterStrategy.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2HeaderFilterStrategy.java
@@ -20,11 +20,11 @@ import org.apache.camel.support.DefaultHeaderFilterStrategy;
 
 public class Sns2HeaderFilterStrategy extends DefaultHeaderFilterStrategy {
     public Sns2HeaderFilterStrategy() {
-        initialize();  
+        initialize();
     }
 
     protected void initialize() {
         // filter headers begin with "Camel" or "org.apache.camel"
-        setOutFilterPattern("(breadcrumbId|Camel|org\\.apache\\.camel)[\\.|a-z|A-z|0-9]*");
+        setOutFilterPattern("(breadcrumbId|Camel|org\\.apache\\.camel)[\\.|a-z|A-z|0-9]*");
     }
 }
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Producer.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Producer.java
index b6871c0..4bc2499 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Producer.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Producer.java
@@ -33,15 +33,14 @@ import org.apache.camel.support.DefaultProducer;
 import org.apache.camel.util.URISupport;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
-
 import software.amazon.awssdk.core.SdkBytes;
 import software.amazon.awssdk.services.sns.model.MessageAttributeValue;
 import software.amazon.awssdk.services.sns.model.PublishRequest;
 import software.amazon.awssdk.services.sns.model.PublishResponse;
 
 /**
- * A Producer which sends messages to the Amazon Web Service Simple Notification Service
- * <a href="http://aws.amazon.com/sns/">AWS SNS</a>
+ * A Producer which sends messages to the Amazon Web Service Simple Notification
+ * Service <a href="http://aws.amazon.com/sns/">AWS SNS</a>
  */
 public class Sns2Producer extends DefaultProducer {
 
@@ -95,7 +94,8 @@ public class Sns2Producer extends DefaultProducer {
         Map<String, MessageAttributeValue> result = new HashMap<>();
         HeaderFilterStrategy headerFilterStrategy = getEndpoint().getHeaderFilterStrategy();
         for (Entry<String, Object> entry : headers.entrySet()) {
-            // only put the message header which is not filtered into the message attribute
+            // only put the message header which is not filtered into the
+            // message attribute
             if (!headerFilterStrategy.applyFilterToCamelHeaders(entry.getKey(), entry.getValue(), exchange)) {
                 Object value = entry.getValue();
                 if (value instanceof String && !((String)value).isEmpty()) {
@@ -104,25 +104,25 @@ public class Sns2Producer extends DefaultProducer {
                     mav.stringValue((String)value);
                     result.put(entry.getKey(), mav.build());
                 } else if (value instanceof ByteBuffer) {
-                 MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
+                    MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
                     mav.dataType("Binary");
                     mav.binaryValue(SdkBytes.fromByteBuffer((ByteBuffer)value));
                     result.put(entry.getKey(), mav.build());
                 } else if (value instanceof Date) {
-                 MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
+                    MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
                     mav.dataType("String");
                     mav.stringValue(value.toString());
                     result.put(entry.getKey(), mav.build());
                 } else if (value instanceof List) {
-                    String resultString = ((List<?>) value).stream()
-                            .map(o -> o instanceof String ? String.format("\"%s\"", o) : Objects.toString(o))
-                            .collect(Collectors.joining(", "));
+                    String resultString = ((List<?>)value).stream().map(o -> o instanceof String ? String.format("\"%s\"", o) : Objects.toString(o))
+                        .collect(Collectors.joining(", "));
                     MessageAttributeValue.Builder mav = MessageAttributeValue.builder();
                     mav.dataType("String.Array");
                     mav.stringValue("[" + resultString + "]");
                     result.put(entry.getKey(), mav.build());
                 } else {
-                    // cannot translate the message header to message attribute value
+                    // cannot translate the message header to message attribute
+                    // value
                     LOG.warn("Cannot put the message header key={}, value={} into Sns MessageAttribute", entry.getKey(), entry.getValue());
                 }
             }
@@ -144,7 +144,7 @@ public class Sns2Producer extends DefaultProducer {
 
     @Override
     public Sns2Endpoint getEndpoint() {
-        return (Sns2Endpoint) super.getEndpoint();
+        return (Sns2Endpoint)super.getEndpoint();
     }
 
     public static Message getMessageForResponse(final Exchange exchange) {
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/AmazonSNSClientMock.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/AmazonSNSClientMock.java
index f442786..48142ec 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/AmazonSNSClientMock.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/AmazonSNSClientMock.java
@@ -19,6 +19,7 @@ package org.apache.camel.component.aws2.sns;
 import java.util.ArrayList;
 import java.util.List;
 
+import org.junit.Assert;
 import software.amazon.awssdk.services.sns.SnsClient;
 import software.amazon.awssdk.services.sns.model.CreateTopicRequest;
 import software.amazon.awssdk.services.sns.model.CreateTopicResponse;
@@ -30,12 +31,10 @@ import software.amazon.awssdk.services.sns.model.SetTopicAttributesRequest;
 import software.amazon.awssdk.services.sns.model.SetTopicAttributesResponse;
 import software.amazon.awssdk.services.sns.model.Topic;
 
-import org.junit.Assert;
-
 public class AmazonSNSClientMock implements SnsClient {
-    
+
     private static final String DEFAULT_TOPIC_ARN = "arn:aws:sns:us-east-1:541925086079:MyTopic";
-    
+
     public AmazonSNSClientMock() {
     }
 
@@ -56,26 +55,26 @@ public class AmazonSNSClientMock implements SnsClient {
     public PublishResponse publish(PublishRequest publishRequest) {
         return PublishResponse.builder().messageId("dcc8ce7a-7f18-4385-bedd-b97984b4363c").build();
     }
-    
+
     @Override
     public ListTopicsResponse listTopics(ListTopicsRequest listTopicRequest) {
-     ListTopicsResponse.Builder res = ListTopicsResponse.builder();
-        Topic topic = Topic.builder().topicArn(DEFAULT_TOPIC_ARN).build();
+        ListTopicsResponse.Builder res = ListTopicsResponse.builder();
+        Topic topic = Topic.builder().topicArn(DEFAULT_TOPIC_ARN).build();
         List<Topic> list = new ArrayList<>();
         list.add(topic);
         res.topics(list);
         return res.build();
     }
 
- @Override
- public String serviceName() {
- // TODO Auto-generated method stub
- return null;
- }
+    @Override
+    public String serviceName() {
+        // TODO Auto-generated method stub
+        return null;
+    }
 
- @Override
- public void close() {
- // TODO Auto-generated method stub
-
- }
+    @Override
+    public void close() {
+        // TODO Auto-generated method stub
+
+    }
 }
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SNSComponentClientRegistryTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SNSComponentClientRegistryTest.java
index cf6ce6e..f4c19e4 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SNSComponentClientRegistryTest.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SNSComponentClientRegistryTest.java
@@ -16,8 +16,6 @@
  */
 package org.apache.camel.component.aws2.sns;
 
-import org.apache.camel.component.aws2.sns.Sns2Component;
-import org.apache.camel.component.aws2.sns.Sns2Endpoint;
 import org.apache.camel.test.junit4.CamelTestSupport;
 import org.junit.Test;
 
@@ -29,15 +27,15 @@ public class SNSComponentClientRegistryTest extends CamelTestSupport {
         AmazonSNSClientMock awsSNSClient = new AmazonSNSClientMock();
         context.getRegistry().bind("awsSNSClient", awsSNSClient);
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic");
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic");
 
         assertNotNull(endpoint.getConfiguration().getAmazonSNSClient());
     }
-    
+
     @Test(expected = IllegalArgumentException.class)
     public void createEndpointWithMinimalSNSClientMisconfiguration() throws Exception {
 
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic");
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic");
     }
 }
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
index ea9064f..7ed0b0f 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
@@ -16,25 +16,23 @@
  */
 package org.apache.camel.component.aws2.sns;
 
-import org.apache.camel.component.aws2.sns.Sns2Component;
-import org.apache.camel.component.aws2.sns.Sns2Endpoint;
+
 import org.apache.camel.test.junit4.CamelTestSupport;
 import org.junit.Test;
-
 import software.amazon.awssdk.core.Protocol;
 import software.amazon.awssdk.regions.Region;
 
 public class SnsComponentConfigurationTest extends CamelTestSupport {
-    
+
     @Test
     public void createEndpointWithMinimalConfiguration() throws Exception {
         AmazonSNSClientMock mock = new AmazonSNSClientMock();
-        
+
         context.getRegistry().bind("amazonSNSClient", mock);
 
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy");
-        
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy");
+
         assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
         assertEquals("xxx", endpoint.getConfiguration().getAccessKey());
         assertEquals("yyy", endpoint.getConfiguration().getSecretKey());
@@ -43,11 +41,11 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
         assertNull(endpoint.getConfiguration().getSubject());
         assertNull(endpoint.getConfiguration().getPolicy());
     }
-    
+
     @Test
     public void createEndpointWithOnlyAccessKeyAndSecretKey() throws Exception {
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?accessKey=xxx&secretKey=yyy");
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic?accessKey=xxx&secretKey=yyy");
 
         assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
         assertEquals("xxx", endpoint.getConfiguration().getAccessKey());
@@ -61,11 +59,12 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
     @Test
     public void createEndpointWithMinimalArnConfiguration() throws Exception {
         AmazonSNSClientMock mock = new AmazonSNSClientMock();
-        
+
         context.getRegistry().bind("amazonSNSClient", mock);
 
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://arn:aws:sns:us-east-1:account:MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy");
+        Sns2Endpoint endpoint = (Sns2Endpoint)component
+            .createEndpoint("aws2-sns://arn:aws:sns:us-east-1:account:MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy");
 
         assertNull(endpoint.getConfiguration().getTopicName());
         assertEquals("arn:aws:sns:us-east-1:account:MyTopic", endpoint.getConfiguration().getTopicArn());
@@ -74,12 +73,12 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
     @Test
     public void createEndpointWithMinimalConfigurationAndProvidedClient() throws Exception {
         AmazonSNSClientMock mock = new AmazonSNSClientMock();
-        
+
         context.getRegistry().bind("amazonSNSClient", mock);
-        
+
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient");
-        
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient");
+
         assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
         assertNull(endpoint.getConfiguration().getAccessKey());
         assertNull(endpoint.getConfiguration().getSecretKey());
@@ -87,44 +86,44 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
         assertNull(endpoint.getConfiguration().getSubject());
         assertNull(endpoint.getConfiguration().getPolicy());
         endpoint.start();
-        
+
         assertEquals("arn:aws:sns:us-east-1:541925086079:MyTopic", endpoint.getConfiguration().getTopicArn());
-        
+
         endpoint.stop();
     }
-    
+
     @Test
     public void createEndpointWithMaximalConfiguration() throws Exception {
-    
+
         AmazonSNSClientMock mock = new AmazonSNSClientMock();
-        
+
         context.getRegistry().bind("amazonSNSClient", mock);
-        
+
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy"
-                + "&policy=%7B%22Version%22%3A%222008-10-17%22,%22Statement%22%3A%5B%7B%22Sid%22%3A%221%22,%22Effect%22%3A%22Allow%22,%22Principal%22%3A%7B%22AWS%22%3A%5B%22*%22%5D%7D,"
-                + "%22Action%22%3A%5B%22sns%3ASubscribe%22%5D%7D%5D%7D&subject=The+subject+message");
-        
+        Sns2Endpoint endpoint = (Sns2Endpoint)component
+            .createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&accessKey=xxx&secretKey=yyy"
+                            + "&policy=%7B%22Version%22%3A%222008-10-17%22,%22Statement%22%3A%5B%7B%22Sid%22%3A%221%22,%22Effect%22%3A%22Allow%22,%22Principal%22%3A%7B%22AWS%22%3A%5B%22*%22%5D%7D,"
+                            + "%22Action%22%3A%5B%22sns%3ASubscribe%22%5D%7D%5D%7D&subject=The+subject+message");
+
         assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
         assertEquals("xxx", endpoint.getConfiguration().getAccessKey());
         assertEquals("yyy", endpoint.getConfiguration().getSecretKey());
         assertNull(endpoint.getConfiguration().getTopicArn());
         assertNotNull(endpoint.getConfiguration().getAmazonSNSClient());
         assertEquals("The subject message", endpoint.getConfiguration().getSubject());
-        assertEquals(
-                "{\"Version\":\"2008-10-17\",\"Statement\":[{\"Sid\":\"1\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":[\"*\"]},\"Action\":[\"sns:Subscribe\"]}]}",
-                endpoint.getConfiguration().getPolicy());
+        assertEquals("{\"Version\":\"2008-10-17\",\"Statement\":[{\"Sid\":\"1\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":[\"*\"]},\"Action\":[\"sns:Subscribe\"]}]}",
+                     endpoint.getConfiguration().getPolicy());
     }
-    
+
     @Test
     public void createEndpointWithSQSSubscription() throws Exception {
         AmazonSNSClientMock mock = new AmazonSNSClientMock();
-        
+
         context.getRegistry().bind("amazonSNSClient", mock);
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        Sns2Endpoint endpoint = (Sns2Endpoint) component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&"
-        + "accessKey=xxx&secretKey=yyy&queueUrl=arn:aws:sqs:us-east-1:541925086079:MyQueue&subscribeSNStoSQS=true");
-        
+        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&"
+                                                                       + "accessKey=xxx&secretKey=yyy&queueUrl=arn:aws:sqs:us-east-1:541925086079:MyQueue&subscribeSNStoSQS=true");
+
         assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
         assertEquals("xxx", endpoint.getConfiguration().getAccessKey());
         assertEquals("yyy", endpoint.getConfiguration().getSecretKey());
@@ -134,31 +133,31 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
         assertNull(endpoint.getConfiguration().getSubject());
         assertNull(endpoint.getConfiguration().getPolicy());
     }
-    
+
     @Test(expected = IllegalArgumentException.class)
     public void createEndpointWithoutAccessKeyConfiguration() throws Exception {
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
         component.createEndpoint("aws-sns://MyTopic?secretKey=yyy");
     }
-    
+
     @Test(expected = IllegalArgumentException.class)
     public void createEndpointWithoutSecretKeyConfiguration() throws Exception {
         Sns2Component component = new Sns2Component(context);
         component.createEndpoint("aws2-sns://MyTopic?accessKey=xxx");
     }
-    
+
     @Test
     public void createEndpointWithComponentElements() throws Exception {
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
         component.setAccessKey("XXX");
         component.setSecretKey("YYY");
         Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic");
-        
+
         assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
         assertEquals("XXX", endpoint.getConfiguration().getAccessKey());
         assertEquals("YYY", endpoint.getConfiguration().getSecretKey());
     }
-    
+
     @Test
     public void createEndpointWithComponentAndEndpointElements() throws Exception {
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
@@ -166,13 +165,13 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
         component.setSecretKey("YYY");
         component.setRegion(Region.US_WEST_1.toString());
         Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic?accessKey=xxxxxx&secretKey=yyyyy&region=US_EAST_1");
-        
+
         assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
         assertEquals("xxxxxx", endpoint.getConfiguration().getAccessKey());
         assertEquals("yyyyy", endpoint.getConfiguration().getSecretKey());
         assertEquals("US_EAST_1", endpoint.getConfiguration().getRegion());
     }
-    
+
     @Test
     public void createEndpointWithoutAutocreation() throws Exception {
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
@@ -180,22 +179,23 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
         component.setSecretKey("YYY");
         component.setRegion(Region.US_WEST_1.toString());
         Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://MyTopic?accessKey=xxxxxx&secretKey=yyyyy&region=US_EAST_1&autoCreateTopic=false");
-        
+
         assertEquals("MyTopic", endpoint.getConfiguration().getTopicName());
         assertEquals("xxxxxx", endpoint.getConfiguration().getAccessKey());
         assertEquals("yyyyy", endpoint.getConfiguration().getSecretKey());
         assertEquals("US_EAST_1", endpoint.getConfiguration().getRegion());
         assertEquals(false, endpoint.getConfiguration().isAutoCreateTopic());
     }
-    
+
     @Test
     public void createEndpointWithComponentEndpointElementsAndProxy() throws Exception {
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
         component.setAccessKey("XXX");
         component.setSecretKey("YYY");
         component.setRegion(Region.US_WEST_1.toString());
-        Sns2Endpoint endpoint = (Sns2Endpoint)component.createEndpoint("aws2-sns://label?accessKey=xxxxxx&secretKey=yyyyy&region=US_EAST_1&proxyHost=localhost&proxyPort=9000&proxyProtocol=HTTP");
-        
+        Sns2Endpoint endpoint = (Sns2Endpoint)component
+            .createEndpoint("aws2-sns://label?accessKey=xxxxxx&secretKey=yyyyy&region=US_EAST_1&proxyHost=localhost&proxyPort=9000&proxyProtocol=HTTP");
+
         assertEquals("xxxxxx", endpoint.getConfiguration().getAccessKey());
         assertEquals("yyyyy", endpoint.getConfiguration().getSecretKey());
         assertEquals("US_EAST_1", endpoint.getConfiguration().getRegion());
@@ -203,11 +203,11 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
         assertEquals("localhost", endpoint.getConfiguration().getProxyHost());
         assertEquals(Integer.valueOf(9000), endpoint.getConfiguration().getProxyPort());
     }
-    
+
     @Test
     public void createEndpointWithoutSecretKeyAndAccessKeyConfiguration() throws Exception {
         AmazonSNSClientMock mock = new AmazonSNSClientMock();
-        
+
         context.getRegistry().bind("amazonSNSClient", mock);
 
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentSpringTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentSpringTest.java
index 822960c..eb17fe5 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentSpringTest.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentSpringTest.java
@@ -19,13 +19,12 @@ package org.apache.camel.component.aws2.sns;
 import org.apache.camel.Exchange;
 import org.apache.camel.ExchangePattern;
 import org.apache.camel.Processor;
-import org.apache.camel.component.aws2.sns.Sns2Constants;
 import org.apache.camel.test.spring.CamelSpringTestSupport;
 import org.junit.Test;
 import org.springframework.context.support.ClassPathXmlApplicationContext;
 
 public class SnsComponentSpringTest extends CamelSpringTestSupport {
-    
+
     @Test
     public void sendInOnly() throws Exception {
         Exchange exchange = template.send("direct:start", ExchangePattern.InOnly, new Processor() {
@@ -34,10 +33,10 @@ public class SnsComponentSpringTest extends CamelSpringTestSupport {
                 exchange.getIn().setBody("This is my message text.");
             }
         });
-        
+
         assertEquals("dcc8ce7a-7f18-4385-bedd-b97984b4363c", exchange.getIn().getHeader(Sns2Constants.MESSAGE_ID));
     }
-    
+
     @Test
     public void sendInOut() throws Exception {
         Exchange exchange = template.send("direct:start", ExchangePattern.InOut, new Processor() {
@@ -46,7 +45,7 @@ public class SnsComponentSpringTest extends CamelSpringTestSupport {
                 exchange.getIn().setBody("This is my message text.");
             }
         });
-        
+
         assertEquals("dcc8ce7a-7f18-4385-bedd-b97984b4363c", exchange.getMessage().getHeader(Sns2Constants.MESSAGE_ID));
     }
 
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentTest.java
index d9e6462..ebf1fdb 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentTest.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentTest.java
@@ -21,7 +21,6 @@ import org.apache.camel.Exchange;
 import org.apache.camel.ExchangePattern;
 import org.apache.camel.Processor;
 import org.apache.camel.builder.RouteBuilder;
-import org.apache.camel.component.aws2.sns.Sns2Constants;
 import org.apache.camel.test.junit4.CamelTestSupport;
 import org.junit.Test;
 
@@ -29,7 +28,7 @@ public class SnsComponentTest extends CamelTestSupport {
 
     @BindToRegistry("amazonSNSClient")
     AmazonSNSClientMock client = new AmazonSNSClientMock();
-    
+
     @Test
     public void sendInOnly() throws Exception {
         Exchange exchange = template.send("direct:start", ExchangePattern.InOnly, new Processor() {
@@ -38,10 +37,10 @@ public class SnsComponentTest extends CamelTestSupport {
                 exchange.getIn().setBody("This is my message text.");
             }
         });
-        
+
         assertEquals("dcc8ce7a-7f18-4385-bedd-b97984b4363c", exchange.getIn().getHeader(Sns2Constants.MESSAGE_ID));
     }
-    
+
     @Test
     public void sendInOut() throws Exception {
         Exchange exchange = template.send("direct:start", ExchangePattern.InOut, new Processor() {
@@ -50,7 +49,7 @@ public class SnsComponentTest extends CamelTestSupport {
                 exchange.getIn().setBody("This is my message text.");
             }
         });
-        
+
         assertEquals("dcc8ce7a-7f18-4385-bedd-b97984b4363c", exchange.getMessage().getHeader(Sns2Constants.MESSAGE_ID));
     }
 
@@ -59,8 +58,7 @@ public class SnsComponentTest extends CamelTestSupport {
         return new RouteBuilder() {
             @Override
             public void configure() throws Exception {
-                from("direct:start")
-                    .to("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&policy=XXX");
+                from("direct:start").to("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient&policy=XXX");
             }
         };
     }
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsProducerTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsProducerTest.java
index 6b98100..c268c01 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsProducerTest.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsProducerTest.java
@@ -21,15 +21,11 @@ import java.util.HashMap;
 import java.util.Map;
 
 import org.apache.camel.Exchange;
-import org.apache.camel.component.aws2.sns.Sns2Endpoint;
-import org.apache.camel.component.aws2.sns.Sns2HeaderFilterStrategy;
-import org.apache.camel.component.aws2.sns.Sns2Producer;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.mockito.Mock;
 import org.mockito.junit.MockitoJUnitRunner;
-
 import software.amazon.awssdk.services.sns.model.MessageAttributeValue;
 
 import static org.hamcrest.CoreMatchers.is;
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsComponentIntegrationTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsComponentIntegrationTest.java
index fedc451..f43f942 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsComponentIntegrationTest.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsComponentIntegrationTest.java
@@ -27,7 +27,7 @@ import org.junit.Test;
 
 @Ignore("Must be manually tested. Provide your own accessKey and secretKey!")
 public class SnsComponentIntegrationTest extends CamelTestSupport {
-    
+
     @Test
     public void sendInOnly() throws Exception {
         Exchange exchange = template.send("direct:start", ExchangePattern.InOnly, new Processor() {
@@ -36,10 +36,10 @@ public class SnsComponentIntegrationTest extends CamelTestSupport {
                 exchange.getIn().setBody("This is my message text.");
             }
         });
-        
+
         assertNotNull(exchange.getIn().getHeader(Sns2Constants.MESSAGE_ID));
     }
-    
+
     @Test
     public void sendInOut() throws Exception {
         Exchange exchange = template.send("direct:start", ExchangePattern.InOut, new Processor() {
@@ -48,10 +48,10 @@ public class SnsComponentIntegrationTest extends CamelTestSupport {
                 exchange.getIn().setBody("This is my message text.");
             }
         });
-        
+
         assertNotNull(exchange.getMessage().getHeader(Sns2Constants.MESSAGE_ID));
     }
-    
+
     @Override
     protected RouteBuilder createRouteBuilder() throws Exception {
         return new RouteBuilder() {
@@ -59,7 +59,7 @@ public class SnsComponentIntegrationTest extends CamelTestSupport {
             public void configure() throws Exception {
                 from("direct:start")
                     .to("aws2-sns://MyNewTopic?accessKey=xxx&secretKey=yyy&policy=%7B%22Version%22%3A%222008-10-17%22,%22Statement%22%3A%5B%7B%22Sid%22%3A%221%22,%22Effect%22%3A%22Allow%22,"
-                            + "%22Principal%22%3A%7B%22AWS%22%3A%5B%22*%22%5D%7D,%22Action%22%3A%5B%22sns%3ASubscribe%22%5D%7D%5D%7D&subject=The+subject+message");
+                        + "%22Principal%22%3A%7B%22AWS%22%3A%5B%22*%22%5D%7D,%22Action%22%3A%5B%22sns%3ASubscribe%22%5D%7D%5D%7D&subject=The+subject+message");
             }
         };
     }
diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsTopicWithKmsEncryptionIntegrationTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsTopicWithKmsEncryptionIntegrationTest.java
index 08c95bf..6388684 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsTopicWithKmsEncryptionIntegrationTest.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/integration/SnsTopicWithKmsEncryptionIntegrationTest.java
@@ -27,7 +27,7 @@ import org.junit.Test;
 
 @Ignore("Must be manually tested. Provide your own accessKey and secretKey!")
 public class SnsTopicWithKmsEncryptionIntegrationTest extends CamelTestSupport {
-    
+
     @Test
     public void sendInOnly() throws Exception {
         Exchange exchange = template.send("direct:start", ExchangePattern.InOnly, new Processor() {
@@ -36,10 +36,10 @@ public class SnsTopicWithKmsEncryptionIntegrationTest extends CamelTestSupport {
                 exchange.getIn().setBody("This is my message text.");
             }
         });
-        
+
         assertNotNull(exchange.getIn().getHeader(Sns2Constants.MESSAGE_ID));
     }
-    
+
     @Test
     public void sendInOut() throws Exception {
         Exchange exchange = template.send("direct:start", ExchangePattern.InOut, new Processor() {
@@ -48,10 +48,10 @@ public class SnsTopicWithKmsEncryptionIntegrationTest extends CamelTestSupport {
                 exchange.getIn().setBody("This is my message text.");
             }
         });
-        
+
         assertNotNull(exchange.getMessage().getHeader(Sns2Constants.MESSAGE_ID));
     }
-    
+
     @Override
     protected RouteBuilder createRouteBuilder() throws Exception {
         return new RouteBuilder() {

Reply | Threaded
Open this post in threaded view
|

[camel] 06/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed descriptions

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 82d8117b98982ff862b699a5a176751bf5c23209
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 14:48:00 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed descriptions
---
 .../org/apache/camel/component/aws2/sns/Sns2Configuration.java | 10 ++++++----
 .../java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java |  2 +-
 2 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
index 19785a3..a0511d6 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Configuration.java
@@ -19,6 +19,7 @@ package org.apache.camel.component.aws2.sns;
 import org.apache.camel.RuntimeCamelException;
 import org.apache.camel.spi.UriParam;
 import org.apache.camel.spi.UriParams;
+
 import software.amazon.awssdk.core.Protocol;
 import software.amazon.awssdk.services.sns.SnsClient;
 
@@ -150,7 +151,7 @@ public class Sns2Configuration implements Cloneable {
     public void setMessageStructure(String messageStructure) {
         this.messageStructure = messageStructure;
     }
-
+    
     public Protocol getProxyProtocol() {
         return proxyProtocol;
     }
@@ -189,9 +190,10 @@ public class Sns2Configuration implements Cloneable {
     }
 
     /**
-     * The region in which SNS client needs to work. When using this parameter,
-     * the configuration will expect the capitalized name of the region (for
-     * example AP_EAST_1) You'll need to use the name Regions.EU_WEST_1.name()
+     * The region in which SNS client needs to work. When using this
+     * parameter, the configuration will expect the lowercase name of the
+     * region (for example ap-east-1) You'll need to use the name
+     * Region.EU_WEST_1.id()
      */
     public void setRegion(String region) {
         this.region = region;
diff --git a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
index 410b778..9aa94d1 100644
--- a/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
+++ b/components/camel-aws2-sns/src/main/java/org/apache/camel/component/aws2/sns/Sns2Endpoint.java
@@ -52,7 +52,7 @@ import software.amazon.awssdk.services.sns.model.SubscribeResponse;
 import software.amazon.awssdk.services.sns.model.Topic;
 
 /**
- * The aws-sns component is used for sending messages to an Amazon Simple
+ * The aws2-sns component is used for sending messages to an Amazon Simple
  * Notification Topic.
  */
 @UriEndpoint(firstVersion = "3.1.0", scheme = "aws2-sns", title = "AWS 2 Simple Notification System", syntax = "aws2-sns:topicNameOrArn", producerOnly = true, label = "cloud,mobile,messaging")

Reply | Threaded
Open this post in threaded view
|

[camel] 07/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen docs

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit b8d479681a263ee83fb9c2f738e6eff827bd7a4b
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 14:48:39 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen docs
---
 .../resources/org/apache/camel/component/aws2/sns/aws2-sns.json       | 4 ++--
 components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc       | 4 ++--
 .../org/apache/camel/builder/component/ComponentsBuilderFactory.java  | 2 +-
 .../camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java   | 4 ++--
 core/camel-componentdsl/src/generated/resources/metadata.json         | 2 +-
 5 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/components/camel-aws2-sns/src/generated/resources/org/apache/camel/component/aws2/sns/aws2-sns.json b/components/camel-aws2-sns/src/generated/resources/org/apache/camel/component/aws2/sns/aws2-sns.json
index 205e6be..416c827 100644
--- a/components/camel-aws2-sns/src/generated/resources/org/apache/camel/component/aws2/sns/aws2-sns.json
+++ b/components/camel-aws2-sns/src/generated/resources/org/apache/camel/component/aws2/sns/aws2-sns.json
@@ -5,7 +5,7 @@
     "extendsScheme": "",
     "syntax": "aws2-sns:topicNameOrArn",
     "title": "AWS 2 Simple Notification System",
-    "description": "The aws-sns component is used for sending messages to an Amazon Simple Notification Topic.",
+    "description": "The aws2-sns component is used for sending messages to an Amazon Simple Notification Topic.",
     "label": "cloud,mobile,messaging",
     "deprecated": false,
     "async": false,
@@ -39,7 +39,7 @@
     "proxyPort": { "kind": "parameter", "displayName": "Proxy Port", "group": "producer", "label": "", "required": false, "type": "integer", "javaType": "java.lang.Integer", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "To define a proxy port when instantiating the SNS client" },
     "proxyProtocol": { "kind": "parameter", "displayName": "Proxy Protocol", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "software.amazon.awssdk.core.Protocol", "enum": [ "HTTP", "HTTPS" ], "deprecated": false, "secret": false, "defaultValue": "HTTPS", "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "To define a proxy protocol when instantiating the SNS client" },
     "queueUrl": { "kind": "parameter", "displayName": "Queue Url", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The queueUrl to subscribe to" },
-    "region": { "kind": "parameter", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The region in which SNS client needs to work. When using this parameter, the configuration will expect the capitalized name of the region (for example AP_E [...]
+    "region": { "kind": "parameter", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The region in which SNS client needs to work. When using this parameter, the configuration will expect the lowercase name of the region (for example ap-eas [...]
     "serverSideEncryptionEnabled": { "kind": "parameter", "displayName": "Server Side Encryption Enabled", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "Define if Server Side Encryption is enabled or not on the topic" },
     "subject": { "kind": "parameter", "displayName": "Subject", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "The subject which is used if the message header 'CamelAwsSnsSubject' is not present." },
     "subscribeSNStoSQS": { "kind": "parameter", "displayName": "Subscribe SNSto SQS", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws2.sns.Sns2Configuration", "configurationField": "configuration", "description": "Define if the subscription between SNS Topic and SQS must be done or not" },
diff --git a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
index ac904c3..6b83fa5 100644
--- a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
+++ b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
@@ -92,7 +92,7 @@ with the following path and query parameters:
 | *proxyPort* (producer) | To define a proxy port when instantiating the SNS client |  | Integer
 | *proxyProtocol* (producer) | To define a proxy protocol when instantiating the SNS client. The value can be one of: HTTP, HTTPS | HTTPS | Protocol
 | *queueUrl* (producer) | The queueUrl to subscribe to |  | String
-| *region* (producer) | The region in which SNS client needs to work. When using this parameter, the configuration will expect the capitalized name of the region (for example AP_EAST_1) You'll need to use the name Regions.EU_WEST_1.name() |  | String
+| *region* (producer) | The region in which SNS client needs to work. When using this parameter, the configuration will expect the lowercase name of the region (for example ap-east-1) You'll need to use the name Region.EU_WEST_1.id() |  | String
 | *serverSideEncryptionEnabled* (producer) | Define if Server Side Encryption is enabled or not on the topic | false | boolean
 | *subject* (producer) | The subject which is used if the message header 'CamelAwsSnsSubject' is not present. |  | String
 | *subscribeSNStoSQS* (producer) | Define if the subscription between SNS Topic and SQS must be done or not | false | boolean
@@ -197,4 +197,4 @@ Maven users will need to add the following dependency to their pom.xml.
 where `$\{camel-version\}` must be replaced by the actual version of Camel.
 
 
-include::camel-spring-boot::page$aws-sns-starter.adoc[]
\ No newline at end of file
+include::camel-spring-boot::page$aws-sns-starter.adoc[]
diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
index 529afb0..911cdc8 100644
--- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
+++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
@@ -587,7 +587,7 @@ public interface ComponentsBuilderFactory {
     }
     /**
      * AWS 2 Simple Notification System (camel-aws2-sns)
-     * The aws-sns component is used for sending messages to an Amazon Simple
+     * The aws2-sns component is used for sending messages to an Amazon Simple
      * Notification Topic.
      *
      * Category: cloud,mobile,messaging
diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java
index 79c61c9..ad36bc4 100644
--- a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java
+++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/Aws2SnsComponentBuilderFactory.java
@@ -23,7 +23,7 @@ import org.apache.camel.builder.component.ComponentBuilder;
 import org.apache.camel.component.aws2.sns.Sns2Component;
 
 /**
- * The aws-sns component is used for sending messages to an Amazon Simple
+ * The aws2-sns component is used for sending messages to an Amazon Simple
  * Notification Topic.
  *
  * Generated by camel-package-maven-plugin - do not edit this file!
@@ -33,7 +33,7 @@ public interface Aws2SnsComponentBuilderFactory {
 
     /**
      * AWS 2 Simple Notification System (camel-aws2-sns)
-     * The aws-sns component is used for sending messages to an Amazon Simple
+     * The aws2-sns component is used for sending messages to an Amazon Simple
      * Notification Topic.
      *
      * Category: cloud,mobile,messaging
diff --git a/core/camel-componentdsl/src/generated/resources/metadata.json b/core/camel-componentdsl/src/generated/resources/metadata.json
index 52f22b2..f1edc81 100644
--- a/core/camel-componentdsl/src/generated/resources/metadata.json
+++ b/core/camel-componentdsl/src/generated/resources/metadata.json
@@ -587,7 +587,7 @@
     "extendsScheme": "",
     "syntax": "aws2-sns:topicNameOrArn",
     "title": "AWS 2 Simple Notification System",
-    "description": "The aws-sns component is used for sending messages to an Amazon Simple Notification Topic.",
+    "description": "The aws2-sns component is used for sending messages to an Amazon Simple Notification Topic.",
     "label": "cloud,mobile,messaging",
     "deprecated": false,
     "deprecationNote": "cloud,mobile,messaging",

Reply | Threaded
Open this post in threaded view
|

[camel] 08/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed some tests

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit d6d388ab71119ab9d4d2dc4dabf6759c4cb42966
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 14:51:20 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Fixed some tests
---
 .../camel/component/aws2/sns/SnsComponentConfigurationTest.java       | 4 ++--
 components/camel-aws2-sns/src/test/resources/log4j2.properties        | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
index 7ed0b0f..974ff0f 100644
--- a/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
+++ b/components/camel-aws2-sns/src/test/java/org/apache/camel/component/aws2/sns/SnsComponentConfigurationTest.java
@@ -137,7 +137,7 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
     @Test(expected = IllegalArgumentException.class)
     public void createEndpointWithoutAccessKeyConfiguration() throws Exception {
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        component.createEndpoint("aws-sns://MyTopic?secretKey=yyy");
+        component.createEndpoint("aws2-sns://MyTopic?secretKey=yyy");
     }
 
     @Test(expected = IllegalArgumentException.class)
@@ -211,6 +211,6 @@ public class SnsComponentConfigurationTest extends CamelTestSupport {
         context.getRegistry().bind("amazonSNSClient", mock);
 
         Sns2Component component = context.getComponent("aws2-sns", Sns2Component.class);
-        component.createEndpoint("aws-sns://MyTopic?amazonSNSClient=#amazonSNSClient");
+        component.createEndpoint("aws2-sns://MyTopic?amazonSNSClient=#amazonSNSClient");
     }
 }
diff --git a/components/camel-aws2-sns/src/test/resources/log4j2.properties b/components/camel-aws2-sns/src/test/resources/log4j2.properties
index b04fda5..c7b091c 100644
--- a/components/camel-aws2-sns/src/test/resources/log4j2.properties
+++ b/components/camel-aws2-sns/src/test/resources/log4j2.properties
@@ -17,7 +17,7 @@
 
 appender.file.type = File
 appender.file.name = file
-appender.file.fileName = target/camel-aws-sns-test.log
+appender.file.fileName = target/camel-aws2-sns-test.log
 appender.file.layout.type = PatternLayout
 appender.file.layout.pattern = %d [%-15.15t] %-5p %-30.30c{1} - %m%n
 appender.out.type = Console

Reply | Threaded
Open this post in threaded view
|

[camel] 09/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Pointing the correct SB starter

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit b8c06cd2d0b44e6f51c4281a92f7c6b056522dc6
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 14:52:12 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Pointing the correct SB starter
---
 components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
index 6b83fa5..08ab60c 100644
--- a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
+++ b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
@@ -197,4 +197,4 @@ Maven users will need to add the following dependency to their pom.xml.
 where `$\{camel-version\}` must be replaced by the actual version of Camel.
 
 
-include::camel-spring-boot::page$aws-sns-starter.adoc[]
+include::camel-spring-boot::page$aws2-sns-starter.adoc[]

Reply | Threaded
Open this post in threaded view
|

[camel] 10/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Note about OSGi

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit d4d6457110035e2b894f431503e74aa1f0fe1614
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 15:00:21 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Note about OSGi
---
 components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
index 08ab60c..439cdb1 100644
--- a/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
+++ b/components/camel-aws2-sns/src/main/docs/aws2-sns-component.adoc
@@ -21,6 +21,11 @@ You must have a valid Amazon Web Services developer account, and be
 signed up to use Amazon SNS. More information is available at
 https://aws.amazon.com/sns[Amazon SNS].
 
+[NOTE]
+====
+The AWS2 SNS component is not supported in OSGI
+====
+
 == URI Format
 
 [source,java]

Reply | Threaded
Open this post in threaded view
|

[camel] 11/11: CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen

acosentino
In reply to this post by acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 4b2580ecf9d34bf8c69ddc1ba12c9ae9dbfb2edd
Author: Andrea Cosentino <[hidden email]>
AuthorDate: Fri Feb 14 15:08:53 2020 +0100

    CAMEL-14552 - Create an AWS-SNS component based on SDK v2, Regen
---
 docs/components/modules/ROOT/pages/aws2-sns-component.adoc | 9 +++++++--
 docs/components/modules/ROOT/pages/index.adoc              | 2 +-
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/docs/components/modules/ROOT/pages/aws2-sns-component.adoc b/docs/components/modules/ROOT/pages/aws2-sns-component.adoc
index 6e7c08d..e00f1bb 100644
--- a/docs/components/modules/ROOT/pages/aws2-sns-component.adoc
+++ b/docs/components/modules/ROOT/pages/aws2-sns-component.adoc
@@ -22,6 +22,11 @@ You must have a valid Amazon Web Services developer account, and be
 signed up to use Amazon SNS. More information is available at
 https://aws.amazon.com/sns[Amazon SNS].
 
+[NOTE]
+====
+The AWS2 SNS component is not supported in OSGI
+====
+
 == URI Format
 
 [source,java]
@@ -93,7 +98,7 @@ with the following path and query parameters:
 | *proxyPort* (producer) | To define a proxy port when instantiating the SNS client |  | Integer
 | *proxyProtocol* (producer) | To define a proxy protocol when instantiating the SNS client. The value can be one of: HTTP, HTTPS | HTTPS | Protocol
 | *queueUrl* (producer) | The queueUrl to subscribe to |  | String
-| *region* (producer) | The region in which SNS client needs to work. When using this parameter, the configuration will expect the capitalized name of the region (for example AP_EAST_1) You'll need to use the name Regions.EU_WEST_1.name() |  | String
+| *region* (producer) | The region in which SNS client needs to work. When using this parameter, the configuration will expect the lowercase name of the region (for example ap-east-1) You'll need to use the name Region.EU_WEST_1.id() |  | String
 | *serverSideEncryptionEnabled* (producer) | Define if Server Side Encryption is enabled or not on the topic | false | boolean
 | *subject* (producer) | The subject which is used if the message header 'CamelAwsSnsSubject' is not present. |  | String
 | *subscribeSNStoSQS* (producer) | Define if the subscription between SNS Topic and SQS must be done or not | false | boolean
@@ -198,4 +203,4 @@ Maven users will need to add the following dependency to their pom.xml.
 where `$\{camel-version\}` must be replaced by the actual version of Camel.
 
 
-include::camel-spring-boot::page$aws-sns-starter.adoc[]
\ No newline at end of file
+include::camel-spring-boot::page$aws2-sns-starter.adoc[]
diff --git a/docs/components/modules/ROOT/pages/index.adoc b/docs/components/modules/ROOT/pages/index.adoc
index a2c6fe3..aec4dd5 100644
--- a/docs/components/modules/ROOT/pages/index.adoc
+++ b/docs/components/modules/ROOT/pages/index.adoc
@@ -68,7 +68,7 @@ Number of Components: 327 in 261 JAR artifacts (1 deprecated)
 
 | xref:aws2-ses-component.adoc[AWS 2 Simple Email Service] (camel-aws2-ses) | 3.1 | The aws2-ses component is used for sending emails with Amazon's SES service.
 
-| xref:aws2-sns-component.adoc[AWS 2 Simple Notification System] (camel-aws2-sns) | 3.1 | The aws-sns component is used for sending messages to an Amazon Simple Notification Topic.
+| xref:aws2-sns-component.adoc[AWS 2 Simple Notification System] (camel-aws2-sns) | 3.1 | The aws2-sns component is used for sending messages to an Amazon Simple Notification Topic.
 
 | xref:aws2-translate-component.adoc[AWS 2 Translate] (camel-aws2-translate) | 3.1 | The aws2-translate component is used for managing Amazon Translate