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 97acbb5ecd8680ac02181912756f2a01175c194a
Author: Andrea Cosentino <[email protected]>
AuthorDate: Tue Mar 20 08:11:58 2018 +0100

    CAMEL-12379 - Shutdown only AWS clients owned by the context - AWS SW
---
 .../main/java/org/apache/camel/component/aws/swf/SWFEndpoint.java | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git 
a/components/camel-aws/src/main/java/org/apache/camel/component/aws/swf/SWFEndpoint.java
 
b/components/camel-aws/src/main/java/org/apache/camel/component/aws/swf/SWFEndpoint.java
index 238adfe..8be1908 100644
--- 
a/components/camel-aws/src/main/java/org/apache/camel/component/aws/swf/SWFEndpoint.java
+++ 
b/components/camel-aws/src/main/java/org/apache/camel/component/aws/swf/SWFEndpoint.java
@@ -84,9 +84,11 @@ public class SWFEndpoint extends DefaultEndpoint {
 
     @Override
     protected void doStop() throws Exception {
-        if (amazonSWClient != null) {
-            amazonSWClient.shutdown();
-            amazonSWClient = null;
+        if (ObjectHelper.isEmpty(configuration.getAmazonSWClient())) {
+            if (amazonSWClient != null) {
+                amazonSWClient.shutdown();
+                amazonSWClient = null;
+            }
         }
         super.doStop();
     }

-- 
To stop receiving notification emails like this one, please contact
[email protected].

Reply via email to