Spring Web Services
  1. Spring Web Services
  2. SWS-274

Soap headers with whitespace cause java.lang.ClassCastException: com.sun.xml.messaging.saaj.soap.impl.TextImpl - Part II

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.0.2
    • Fix Version/s: 1.5 M2, 1.0.4
    • Component/s: Core
    • Labels:
      None
    • Environment:
      Spring WS 1.0.2, Sun's SAAJ 1.2

      Description

      This bug is related to: http://jira.springframework.org/browse/SWS-244. If white space appears in the header then a class cast exception is thrown. Sun's SAAJ impl returns these whitespace nodes as TextImpl. The class cast happens when the TextImpl's are cast as SOAPHeaderElement. I've verified that this is a problem with Spring WS 1.0.3 as well even though I'm currently using 1.0.2.

      org.springframework.ws.soap.saaj.SaajSoapHeader

      public Object next()

      { SOAPHeaderElement saajHeaderElement = (SOAPHeaderElement) iterator.next(); <-- class cast happens here. return new SaajSoapHeaderElement(saajHeaderElement); }

        Issue Links

          Activity

          Hide
          Arjen Poutsma added a comment -

          Fixed, thanks for spotting this!

          Show
          Arjen Poutsma added a comment - Fixed, thanks for spotting this!
          Hide
          Arjen Poutsma added a comment -

          Reopening issues for 1.0.4

          Show
          Arjen Poutsma added a comment - Reopening issues for 1.0.4
          Hide
          Arjen Poutsma added a comment -

          Fixed in 1.0 branch.

          Show
          Arjen Poutsma added a comment - Fixed in 1.0 branch.
          Hide
          Arjen Poutsma added a comment -

          Closing issues for 1.0.4

          Show
          Arjen Poutsma added a comment - Closing issues for 1.0.4

            People

            • Assignee:
              Arjen Poutsma
              Reporter:
              Mark LaFond
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: