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 2019/05/28 13:08:59 UTC

[camel] branch camel-2.22.x updated (a9f3c7f -> 47f4555)

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

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


    from a9f3c7f  [CAMEL-13376]camel-cxf - failure processor for custom exception handling cannot get the original message
     new d65b7d6  Update DefaultInflightRepository.java
     new 47f4555  Update MessageHistory.java

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:
 camel-core/src/main/java/org/apache/camel/MessageHistory.java      | 1 +
 .../main/java/org/apache/camel/impl/DefaultInflightRepository.java | 7 ++++++-
 2 files changed, 7 insertions(+), 1 deletion(-)


[camel] 02/02: Update MessageHistory.java

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

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

commit 47f455564649ec1e700b6da397c02a1f23b0c3cb
Author: bdevido <47...@users.noreply.github.com>
AuthorDate: Tue May 28 14:27:57 2019 +0200

    Update MessageHistory.java
    
    CAMEL-13587: Inflight repository browse should compute elapsed if the message is still inflight at a given node. Thanks to Barbara De Vido for reporting.
---
 camel-core/src/main/java/org/apache/camel/MessageHistory.java | 1 +
 1 file changed, 1 insertion(+)

diff --git a/camel-core/src/main/java/org/apache/camel/MessageHistory.java b/camel-core/src/main/java/org/apache/camel/MessageHistory.java
index 217b9d2..683c7f7 100644
--- a/camel-core/src/main/java/org/apache/camel/MessageHistory.java
+++ b/camel-core/src/main/java/org/apache/camel/MessageHistory.java
@@ -48,6 +48,7 @@ public interface MessageHistory {
 
     /**
      * Gets the elapsed time in millis processing the node took
+     * (this is 0 until the node processing is done)
      */
     long getElapsed();
 


[camel] 01/02: Update DefaultInflightRepository.java

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

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

commit d65b7d62e3ab144cd226f96ba7fee8abf9ce1c30
Author: bdevido <47...@users.noreply.github.com>
AuthorDate: Tue May 28 14:27:17 2019 +0200

    Update DefaultInflightRepository.java
    
    CAMEL-13587: Inflight repository browse should compute elapsed if the message is still inflight at a given node. Thanks to Barbara De Vido for reporting.
---
 .../main/java/org/apache/camel/impl/DefaultInflightRepository.java | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/camel-core/src/main/java/org/apache/camel/impl/DefaultInflightRepository.java b/camel-core/src/main/java/org/apache/camel/impl/DefaultInflightRepository.java
index 7f079ac..9052e65 100644
--- a/camel-core/src/main/java/org/apache/camel/impl/DefaultInflightRepository.java
+++ b/camel-core/src/main/java/org/apache/camel/impl/DefaultInflightRepository.java
@@ -223,7 +223,12 @@ public class DefaultInflightRepository extends ServiceSupport implements Infligh
             // get latest entry
             MessageHistory history = list.getLast();
             if (history != null) {
-                return history.getElapsed();
+                long elapsed = history.getElapsed();
+                if (elapsed == 0 && history.getTime() > 0) {
+                    // still in progress, so lets compute it via the start time
+                    elapsed = System.currentTimeMillis() - history.getTime();
+                }
+                return elapsed;
             } else {
                 return 0;
             }