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 2023/12/11 08:51:27 UTC
(camel) branch camel-3.20.x updated: CAMEL-19734: fixing the elapsed time to message history (#12387)
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch camel-3.20.x
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/camel-3.20.x by this push:
new abe307c9dea CAMEL-19734: fixing the elapsed time to message history (#12387)
abe307c9dea is described below
commit abe307c9dea4385ca63662a80ce7e1c1922f7998
Author: Rhuan Rocha <rh...@gmail.com>
AuthorDate: Mon Dec 11 05:51:20 2023 -0300
CAMEL-19734: fixing the elapsed time to message history (#12387)
Signed-off-by: Rhuan Rocha <rh...@gmail.com>
---
.../src/main/java/org/apache/camel/support/MessageHelper.java | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/core/camel-support/src/main/java/org/apache/camel/support/MessageHelper.java b/core/camel-support/src/main/java/org/apache/camel/support/MessageHelper.java
index 1cfcc77fe1f..6ec14b82c70 100644
--- a/core/camel-support/src/main/java/org/apache/camel/support/MessageHelper.java
+++ b/core/camel-support/src/main/java/org/apache/camel/support/MessageHelper.java
@@ -38,7 +38,6 @@ import org.apache.camel.spi.DataTypeAware;
import org.apache.camel.spi.ExchangeFormatter;
import org.apache.camel.spi.HeaderFilterStrategy;
import org.apache.camel.util.ObjectHelper;
-import org.apache.camel.util.StopWatch;
import org.apache.camel.util.StringHelper;
import org.apache.camel.util.URISupport;
@@ -636,7 +635,7 @@ public final class MessageHelper {
label = "from[" + URISupport.sanitizeUri(StringHelper.limitLength(exchange.getFromEndpoint().getEndpointUri(), 100))
+ "]";
}
- long elapsed = new StopWatch(exchange.getCreated()).taken();
+ long elapsed = System.currentTimeMillis() - exchange.getCreated();
List<MessageHistory> list = exchange.getProperty(ExchangePropertyKey.MESSAGE_HISTORY, List.class);
boolean enabled = list != null;