You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2021/04/30 06:42:12 UTC

[camel] branch main updated (83664aa -> 0407d2e)

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

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


    from 83664aa  CAMEL-16465 - Camel-AWS: Add useDefaultCredentialProvider option to all the components - EC2 Component
     new 135e2dd  CAMEL-16465 - Camel-AWS: Add useDefaultCredentialProvider option to all the components - EC2 Component
     new 0407d2e  CAMEL-16465 - Camel-AWS: Add useDefaultCredentialProvider option to all the components - EC2 Component

The 2 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:
 .../java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java   | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

[camel] 02/02: CAMEL-16465 - Camel-AWS: Add useDefaultCredentialProvider option to all the components - EC2 Component

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 0407d2eadc94a2290877d4e182b90cd5b9b26e90
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Apr 30 08:41:44 2021 +0200

    CAMEL-16465 - Camel-AWS: Add useDefaultCredentialProvider option to all the components - EC2 Component
---
 .../java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java     | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/components/camel-aws/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java b/components/camel-aws/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java
index 9abcb4f..dfad2f6 100644
--- a/components/camel-aws/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java
+++ b/components/camel-aws/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java
@@ -56,7 +56,8 @@ public class AWS2EC2Component extends DefaultComponent {
         setProperties(endpoint, parameters);
         if (!configuration.isUseDefaultCredentialsProvider() && configuration.getAmazonEc2Client() == null
                 && (configuration.getAccessKey() == null || configuration.getSecretKey() == null)) {
-            throw new IllegalArgumentException("useDefaultCredentialsProvider is set to false, amazonEC2Client or accessKey and secretKey must be specified");
+            throw new IllegalArgumentException(
+                    "useDefaultCredentialsProvider is set to false, amazonEC2Client or accessKey and secretKey must be specified");
         }
 
         return endpoint;

[camel] 01/02: CAMEL-16465 - Camel-AWS: Add useDefaultCredentialProvider option to all the components - EC2 Component

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 135e2ddbff754e27e31a12cf19b72b24dd9958a1
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Apr 30 08:39:13 2021 +0200

    CAMEL-16465 - Camel-AWS: Add useDefaultCredentialProvider option to all the components - EC2 Component
---
 .../java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java    | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/components/camel-aws/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java b/components/camel-aws/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java
index 0139af2..9abcb4f 100644
--- a/components/camel-aws/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java
+++ b/components/camel-aws/camel-aws2-ec2/src/main/java/org/apache/camel/component/aws2/ec2/AWS2EC2Component.java
@@ -54,9 +54,9 @@ public class AWS2EC2Component extends DefaultComponent {
                 = this.configuration != null ? this.configuration.copy() : new AWS2EC2Configuration();
         AWS2EC2Endpoint endpoint = new AWS2EC2Endpoint(uri, this, configuration);
         setProperties(endpoint, parameters);
-        if (configuration.getAmazonEc2Client() == null
+        if (!configuration.isUseDefaultCredentialsProvider() && configuration.getAmazonEc2Client() == null
                 && (configuration.getAccessKey() == null || configuration.getSecretKey() == null)) {
-            throw new IllegalArgumentException("amazonEC2Client or accessKey and secretKey must be specified");
+            throw new IllegalArgumentException("useDefaultCredentialsProvider is set to false, amazonEC2Client or accessKey and secretKey must be specified");
         }
 
         return endpoint;