Uploaded image for project: 'ServiceMix Components'
  1. ServiceMix Components
  2. SMXCOMP-617

CXF-BCProvider and JbiOutWsdl1Interceptor generate classcast exception in case where JBI messageExchange have newline characters in xml (formatted xml).

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.2.3, servicemix-cxf-bc-2008.01, servicemix-cxf-bc-2009.01
    • Component/s: servicemix-cxf-bc
    • Labels:
      None
    • Environment:

      Any Servicemix getting JBI Exchange from outside component like Camel which adds a formatted SOAP XML message (with newline "\n" characters).

      Description

      CxfBcProvider and JbiOutWsdl1Interceptor when parsing JBI message assume that the next element in the DOM tree would be of type Element when parsing JBI MessageExchange for operationName.
      In some cases (like JBI MessageExchange being populated by servicemix-camel component ) the JBI Message body may contain formatted XML with newline character in which case the both of them fails with java ClassCastException because the firstChild() from the SoapEnv node is TextImpl (represnting "\n") which should be skipped.

      Fix involves changing blind casting to Element type to using DOMUtils from SOAP shared library which makes sure that it would return first Child Element of type Element.

        Attachments

          Activity

            People

            • Assignee:
              ulhasbhole Ulhas Bhole
              Reporter:
              ulhasbhole Ulhas Bhole
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: