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/02/13 13:02:13 UTC
[camel] 06/06: CAMEL-19040: Backlog tracer - Capture exception and also first/last to know better what is input and output from Camel.
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
commit 6346f886bad1368bf6bc9e67758747d996a2f4c3
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Mon Feb 13 14:01:20 2023 +0100
CAMEL-19040: Backlog tracer - Capture exception and also first/last to know better what is input and output from Camel.
---
.../modules/ROOT/pages/backlog-tracer.adoc | 22 ++++++++++++++++++++--
1 file changed, 20 insertions(+), 2 deletions(-)
diff --git a/docs/user-manual/modules/ROOT/pages/backlog-tracer.adoc b/docs/user-manual/modules/ROOT/pages/backlog-tracer.adoc
index 5fb3d8e5ed7..7175c7a9def 100644
--- a/docs/user-manual/modules/ROOT/pages/backlog-tracer.adoc
+++ b/docs/user-manual/modules/ROOT/pages/backlog-tracer.adoc
@@ -29,6 +29,7 @@ messages in either a POJO or XML format.
|Option |Default |Description
+|standby | `false` |Whether the tracer is standby. If a tracer is in standby then the tracer is activated during startup and are ready to be enabled manually via JMX or calling the enabled method.
|enabled |`false` |Flag to enable or disable this tracer
|backlogSize |`1000` |Maximum number of total traced messages to keep in the backlog (FIFO
@@ -58,6 +59,11 @@ xref:stream-caching.adoc[Stream Caching].
|bodyIncludeFiles |`true` |Whether to include the message body of file based messages. The overhead
is that the file content has to be read from the file.
+
+|includeExchangeProperties |`true` |Trace messages to include exchange properties.
+
+|includeException |`true` |Trace messages to include exception if the message failed.
+
|===
[[BacklogTracer-Operations]]
@@ -70,17 +76,22 @@ is that the file content has to be read from the file.
|getTraceCounter |`long` |Gets the total number of traced messages.
+|getQueueSize |`long` |Number of traced messages in the backlog.
+
|resetTraceCounter |`void` |To reset the trace counter.
|dumpTracedMessages(nodeOrRouteId) |`List<BacklogTracerEventMessage>` |To dump the traced messages from the give node or route id.
-|dumpTracedMessagesAsXml(nodeOrRouteId) |`String` |To dump the traced messages from the give node or route id in XML
-format.
+|dumpTracedMessagesAsXml(nodeOrRouteId) |`String` |To dump the traced messages from the give node or route id in XML format.
+
+|dumpTracedMessagesAsJSon(nodeOrRouteId) |`String` |To dump the traced messages from the give node or route id in JSon format.
|dumpAllTracedMessages |`List<BacklogTracerEventMessage>` |To dump all the traced messages
|dumpAllTracedMessagesAsXml |`String` |To dump all the traced messages in XML format.
+|dumpAllTracedMessagesAsJSon |`String` |To dump all the traced messages in JSon format.
+
|===
== Enabling
@@ -101,6 +112,13 @@ And in Spring XML
</camelContext>
----
+And in Camel Main you can enable this in the `application.properties` file:
+
+[source,properties]
+----
+camel.main.backlog-tracing = true
+----
+
And in Spring Boot you can enable this in the `application.properties` file:
[source,properties]