Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Which will construct a String message at runtime using the Simple language. The log message will by logged at INFO level using the route id as the log name. By default a route is named route-1, route-2 etc. But you can use the routeId("myCoolRoute") to set a route name of choice.

Info
titleDifference between log in the DSL and [Log] component

The log DSL is much lighter and meant for logging human logs such as Starting to do ... etc. It can only log a message based on the Simple language. On the other hand Log component is a full fledged component which involves using endpoints and etc. The Log component is meant for logging the Message itself and you have many URI options to control what you would like to be logged.

The log DSL have overloaded methods to set the logging level and/or name as well.

...

Code Block
xml
xml
        <route id="baz">
            <from uri="direct:baz"/>
            <log message="Me Got ${body}" loggingLevel="FATAL" logName="cool"/>
            <to uri="mock:baz"/>
        </route>

See Also

...

Include Page
CAMEL:Using This Pattern
CAMEL:Using This Pattern