Uploaded image for project: 'FUSE ESB'
  1. FUSE ESB
  2. ESB-1590

Simple Quartz example does not output log message as shown in the readme

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Trivial
    • Resolution: Done
    • Affects Version/s: 4.4.1-fuse-01-06
    • Component/s: None
    • Labels:
      None

      Description

      There was a change introduced with apache-servicemix-4.4.0-fuse-00-61 in which the format of the output changed.

      The readme.txt that accompanies the Quartz example reads as follows:

      "When the quartz.xml file is copied to the deploy directory, it sends
      messages to the log. You can view the log entries by typing the
      following command in the ServiceMix console:

      log:display

      You should see an entry similar to the following:

      14:15:51,202 | INFO | x-camel-thread-4 | test

      rg.apache.camel.processor.Logger 88 Exchange
      [BodyType:javax.xml.transform.dom.DOMSource,
      Body:<timer><name> {http://servicemix.apache.org/examples/camel}

      service:endpoint</name><group>DEFAULT</group><fullname>DEFAULT.

      {http://servicemix.apache.org/examples/camel}

      service:endpoint
      </fullname><description/><fireTime>Mon Mar 23 14:15:51 CST 2009
      </fireTime></timer>]"

      The body of the message is no longer readable as it is a StreamSource. The current output of the example displays as follows:

      12:41:42,765 | INFO | rovider-thread-2 | test | ? ? | 85 - org.apache.camel.camel-core - 2.8.0.fuse-01-06 | Exchange[ExchangePattern:InOnly, BodyType:org.apache.servicemix.nmr.core.util.StringSource, Body:[Body is instance of java.xml.transform.StreamSource]]

      This behavior appears to have changed with org.apache.camel.camel-core - 2.7.3.fuse-00-61

      The example quartz.xml should be updated with either of the below options to produce the output that matches the readme.

      1)

      <camel:camelContext>
      <camel:route streamCache="true">
      <camel:from uri="jbi:endpoint:http://servicemix.apache.org/examples/camel/receiver/endpoint" />
      <camel:to uri="log:test?showStreams=true" />
      </camel:route>
      </camel:camelContext>

      2)

      <camel:camelContext>
      <camel:route>
      <camel:from uri="jbi:endpoint:http://servicemix.apache.org/examples/camel/receiver/endpoint" />
      <camel:convertBodyTo type="String"/>
      <camel:to uri="log:test" />
      </camel:route>
      </camel:camelContext>

      An alternative would be to change the readme to reflect the output with the examples current configuration.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                ffang Freeman(Yue) Fang
                Reporter:
                jsherman Jason Sherman
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: