zhfeng commented on code in PR #6130: URL: https://github.com/apache/camel-quarkus/pull/6130#discussion_r1618269439
########## extensions-core/core/runtime/src/main/java/org/apache/camel/quarkus/core/CamelContextRecorder.java: ########## @@ -107,4 +108,34 @@ public void registerManagementEventBridge(RuntimeValue<CamelContext> camelContex .getManagementStrategy() .addEventNotifier(new CamelManagementEventBridge(observedManagementEvents)); } + + public RuntimeValue<CamelContextCustomizer> createBacklogTracerCustomizer(CamelConfig config) { + return new RuntimeValue<>(context -> { + // must enable source location so tracer tooling knows to map breakpoints to source code + context.setSourceLocationEnabled(true); + + // enable tracer on camel + context.setBacklogTracing(config.trace.enabled); + context.setBacklogTracingStandby(config.trace.standby); + context.setBacklogTracingTemplates(config.trace.traceTemplates); + + BacklogTracer tracer = BacklogTracer.createTracer(context); + tracer.setEnabled(config.trace.enabled); + tracer.setStandby(config.trace.standby); + tracer.setBacklogSize(config.trace.backlogSize); + tracer.setRemoveOnDump(config.trace.removeOnDump); + tracer.setBodyMaxChars(config.trace.bodyMaxChars); + tracer.setBodyIncludeStreams(config.trace.bodyIncludeStreams); + tracer.setBodyIncludeFiles(config.trace.bodyIncludeFiles); + tracer.setIncludeExchangeProperties(config.trace.includeExchangeProperties); + tracer.setIncludeExchangeVariables(config.trace.includeExchangeVariables); + tracer.setIncludeException(config.trace.includeException); + tracer.setTraceRests(config.trace.traceRests); + tracer.setTraceTemplates(config.trace.traceTemplates); + tracer.setTracePattern(config.trace.tracePattern.orElse("")); Review Comment: @davsclaus set with `null` on both of them. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@camel.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org