...
Option | Default | Description |
---|---|---|
formatter |
| Sets the Trace Formatter to use. Will default use |
enabled | true | Flag to enable or disable this tracer |
logLevel | | The logging level to use: FATAL, ERROR, WARN, INFO, DEBUG, TRACE, OFF |
logName |
| The log name to use. Will default use |
traceFilter | null | An exchange Predicate to filter the tracing. |
traceInterceptors | false | Flag to enable or disable tracing of interceptors |
traceExceptions | true | Flag to enable or disable tracing of thrown exception during processing of the exchange |
traceOutExchanges | false | Flag to enable fine grained tracing with a callback for both IN (before) and OUT (after). Is disabled by default which means there is only one trace callback executed. |
logStackTrace | false | Camel 2.0: When tracing exception you can control whether the stack trace should be logged also. If not then only the exception class and message is logged. |
useJpa | false | Camel 2.0: To use a |
destinationUri | null | Camel 2.0: Optional destination uri to route TraceEventExchange containing TraceEventMessage with details about the trace. Can be used for custom processing to store traces in database using JPA. |
jpaTraceEventMessageClassName | null | Camel 2.3: Fully class name for a custom |
traceHandler | null | Camel 2.3: To use a custom |
traceInterceptorFactory | null | Camel 2.3: To use a custom |
...
This works by Camel creates a new TraceEventExchange containing:
- snapshot of the original traced Exchange as a immutable TraceEventMessage containing String values of the fields, when the interception occurred. This ensures the fields contains the exact data at the given time of interception.
- the original Exchange can be accessed using
getTracedExchange()
Warning |
---|
Beware to access the original Exchange to avoid causing any side effects or alter its state. Prefer to access the information from TraceEventMessage |
Camel routes the TraceEventExchange synchronously from the point of interception. When its completed Camel will continue routing the original Exchange.
...