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

[camel] branch master updated (b088e12 -> 1a55629)

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

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


    from b088e12  Upgrade Localstack image to version 0.12.9.1
     new 2462a38  camel-core - RoutePolicySupport should on stopConsumer only call stop and not shutdown.
     new 1a55629  Polished

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:
 .../org/apache/camel/impl/engine/PrototypeExchangeFactory.java   | 9 +++++++--
 .../main/java/org/apache/camel/support/RoutePolicySupport.java   | 3 +--
 2 files changed, 8 insertions(+), 4 deletions(-)

[camel] 02/02: Polished

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

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

commit 1a55629290f2ed5089f815dcefb9298ef5293cfe
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Tue Apr 13 07:37:34 2021 +0200

    Polished
---
 .../org/apache/camel/impl/engine/PrototypeExchangeFactory.java   | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/PrototypeExchangeFactory.java b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/PrototypeExchangeFactory.java
index 9752f4d..e37be97 100644
--- a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/PrototypeExchangeFactory.java
+++ b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/PrototypeExchangeFactory.java
@@ -145,6 +145,11 @@ public class PrototypeExchangeFactory extends PooledObjectFactorySupport<Exchang
             boolean shouldLog = pooled > 0 || created > 0 || acquired > 0 || released > 0 || discarded > 0;
             if (shouldLog) {
                 String id = getRouteId();
+                if (id == null) {
+                    id = "";
+                } else {
+                    id = " " + id;
+                }
                 String uri = consumer.getEndpoint().getEndpointBaseUri();
                 uri = URISupport.sanitizeUri(uri);
 
@@ -153,10 +158,10 @@ public class PrototypeExchangeFactory extends PooledObjectFactorySupport<Exchang
                 if (leak) {
                     long leaks = (created + acquired) - (released + discarded);
                     log.warn(
-                            "{} {} ({}) usage (leaks detected: {}) [pooled: {}, created: {}, acquired: {} released: {}, discarded: {}]",
+                            "{}{} ({}) usage (leaks detected: {}) [pooled: {}, created: {}, acquired: {} released: {}, discarded: {}]",
                             name, id, uri, leaks, pooled, created, acquired, released, discarded);
                 } else {
-                    log.info("{} {} ({}) usage [pooled: {}, created: {}, acquired: {} released: {}, discarded: {}]",
+                    log.info("{}{} ({}) usage [pooled: {}, created: {}, acquired: {} released: {}, discarded: {}]",
                             name, id, uri, pooled, created, acquired, released, discarded);
                 }
             }

[camel] 01/02: camel-core - RoutePolicySupport should on stopConsumer only call stop and not shutdown.

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

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

commit 2462a3831ba0269d3cb46b351202b0b5f1e690eb
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Tue Apr 13 07:25:06 2021 +0200

    camel-core - RoutePolicySupport should on stopConsumer only call stop and not shutdown.
---
 .../src/main/java/org/apache/camel/support/RoutePolicySupport.java     | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/core/camel-support/src/main/java/org/apache/camel/support/RoutePolicySupport.java b/core/camel-support/src/main/java/org/apache/camel/support/RoutePolicySupport.java
index 010152d..c52e905 100644
--- a/core/camel-support/src/main/java/org/apache/camel/support/RoutePolicySupport.java
+++ b/core/camel-support/src/main/java/org/apache/camel/support/RoutePolicySupport.java
@@ -93,8 +93,7 @@ public abstract class RoutePolicySupport extends ServiceSupport implements Route
      * @see    #suspendOrStopConsumer(Consumer)
      */
     public void stopConsumer(Consumer consumer) throws Exception {
-        // stop and shutdown
-        ServiceHelper.stopAndShutdownServices(consumer);
+        ServiceHelper.stopService(consumer);
     }
 
     /**