Details
-
Improvement
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
2.23.0
-
None
-
Novice
Description
Add the possibility to disable the invocation of ModelHelper.dumpModelAsXml(). This is particularly disturbing for Camel contexts with a lot of route definitions as this uses a lot of processing time and the information is only used for log output.
Actual use in 2.x in RouteDefinition.java:
RouteDefinition.java
String beforeAsXml = ModelHelper.dumpModelAsXml(camelContext, this); ... String afterAsXml = ModelHelper.dumpModelAsXml(camelContext, merged); log.info("Adviced route before/after as XML:\n{}\n{}", beforeAsXml, afterAsXml);
In 2.X this should be optimized in RouteDefinition.java, in 3.X in RouteReifier.java.
Possible solution: Add log.isInfoEnabled guard.