Uploaded image for project: 'Red Hat Fuse'
  1. Red Hat Fuse
  2. ENTESB-5434

camel-cxf does not populate message body correctly when receiving SOAP from JMS

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • jboss-fuse-6.3
    • jboss-fuse-6.2.1
    • Camel
    • None
    • % %
    • Hide

      1. This problem only reproduces on Windows. On Linux, the test application passes the <xpath> operation fine (although it fails later, but that's probably not relevant.
      2. Install JDK1.8, Maven, and Fuse 6.2.1
      3. Enable the Fuse "admin" user and start Fuse with the 1.8 JDK
      3. Install the hot fix jboss-fuse-6.2.1-103-hf6. This is necessary to make camel-cxf work at all; without it, the message body is null after the <cxf:> endpoint
      4. features:install cxf-transports-jms
      4. Unpack the test case 01624680_spl.zip
      5. Unpack the included CXFService.zip to give the Maven project
      6. Copy the whole contents of CXFService/etc to $FUSE_HOME/etc
      7. Edit the configuration properties file that got copied into $FUSE_HOME/etc so that the line SchemaFilePathRoot points to the full path of $FUSE_HOME/etc (the test cases uses this to locate WSDL files, etc)
      8. Build CXFService.zip (mvn install)
      9. osgi:install -s mvn:com.mycompany/CamelCXF/1.0.0-SNAPSHOT
      10. Use the Hawtio console, or some other means, to post the SOAP message attached as request.xml, to the destination TEST.CREATE_INCIDENT.V1.CS.REQ
      11. See the exception in the log

      Show
      1. This problem only reproduces on Windows. On Linux, the test application passes the <xpath> operation fine (although it fails later, but that's probably not relevant. 2. Install JDK1.8, Maven, and Fuse 6.2.1 3. Enable the Fuse "admin" user and start Fuse with the 1.8 JDK 3. Install the hot fix jboss-fuse-6.2.1-103-hf6. This is necessary to make camel-cxf work at all; without it, the message body is null after the <cxf:> endpoint 4. features:install cxf-transports-jms 4. Unpack the test case 01624680_spl.zip 5. Unpack the included CXFService.zip to give the Maven project 6. Copy the whole contents of CXFService/etc to $FUSE_HOME/etc 7. Edit the configuration properties file that got copied into $FUSE_HOME/etc so that the line SchemaFilePathRoot points to the full path of $FUSE_HOME/etc (the test cases uses this to locate WSDL files, etc) 8. Build CXFService.zip (mvn install) 9. osgi:install -s mvn:com.mycompany/CamelCXF/1.0.0-SNAPSHOT 10. Use the Hawtio console, or some other means, to post the SOAP message attached as request.xml, to the destination TEST.CREATE_INCIDENT.V1.CS.REQ 11. See the exception in the log
    • Sprint 5 - towards ER2

      A camel-cxf endpoint, with datatype MESSAGE or PAYLOAD, fails to populate the Exchange message body correctly, when the endpoint is consuming from a JMS destination, and the SOAP message body is encoded with UTF-8, and the body contains certain multi-byte characters. The problem only arises on Windows, and can only be shown on Fuse 6.2.1 with hot-fix HF6 applied. Without HF6, the message body ends up null.

      The characters that are known to cause problems include the following, but this is probably not an exhaustive list:

      U+00A2 ¢ c2 a2 CENT SIGN
      U+00A3 £ c2 a3 POUND SIGN
      U+00A4 ¤ c2 a4 CURRENCY SIGN
      U+00A5 ¥ c2 a5 YEN SIGN
      U+00A6 ¦ c2 a6 BROKEN BAR
      U+00A7 § c2 a7 SECTION SIGN
      U+00A8 ¨ c2 a8 DIAERESIS

      It might be, in fact, that any multi-byte UTF-8 character is problematic – I have not been able to figure this out yet.

      It seems that, at some point during the processing of the UTF-8 data stream, the initial "C2" byte gets stripped, leaving an invalid, one-byte character.

      The customer's test case fails because it attempts to apply an <xpath> operation to the message body after processing by camel-cxf. However, close inspection of the Fuse log (with a hex editor) shows that the message body logged by camel-cxf contains the invalid character; the problem with <xpath> is simply a consequence of the broken message body.

        1. 01624680_spl.zip
          1.15 MB
        2. camel-cxf-2.15.1.redhat-621084.jar
          219 kB
        3. hf6.zip
          197 kB
        4. request.xml
          5 kB

            yfang@redhat.com Freeman(Yue) Fang
            rhn-support-kboone Kevin Boone
            Viliam Kasala Viliam Kasala
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: