Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8196755

Marshalling with JAX-WS escapes carriage return with entity reference

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Duplicate
    • Affects Version/s: 8u162
    • Fix Version/s: None
    • Component/s: xml
    • Labels:

      Description

      JDK-8172297 caused issues with ApacheCXF JAX-WS deployements. The fix makes use of the XMLStreamWriter.writeEntityRef method, while this is not allowed when using SOAP based web services.
      StackTrace :
          Caused by: java.lang.UnsupportedOperationException: Entity References are not
          allowed in SOAP documents
             at
          com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl.createEntityReference(SOAPDocumentImpl.java:148)
             at
          com.sun.xml.internal.messaging.saaj.soap.SOAPPartImpl.createEntityReference(SOAPPartImpl.java:437)
             at
          org.apache.cxf.staxutils.W3CDOMStreamWriter.writeEntityRef(W3CDOMStreamWriter.java:278)
             at
          com.sun.xml.internal.bind.v2.runtime.output.XMLStreamWriterOutput$XmlStreamOutWriterAdapter.writeEntityRef(XMLStreamWriterOutput.java:277)
             at
          com.sun.xml.internal.bind.v2.runtime.output.XMLStreamWriterOutput$NewLineEscapeHandler.escape(XMLStreamWriterOutput.java:242)
             at
          com.sun.xml.internal.bind.v2.runtime.output.XMLStreamWriterOutput.text(XMLStreamWriterOutput.java:150)

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                aefimov Aleksej Efimov
                Reporter:
                shadowbug Shadow Bug
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: