Uploaded image for project: 'JBoss ESB'
  1. JBoss ESB
  2. JBESB-2922

SchemaValidationActionUnitTest test failure serialising DOM

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 4.6
    • Fix Version/s: 4.7
    • Component/s: Rosetta
    • Labels:
      None

      Description

      The following error is being seen on the CI machines, executing on JDK 1.6

      [java] [junit] java.lang.RuntimeException: Unexpected error. Unable to serialize DOM.
      [java] [junit] at org.jboss.soa.esb.actions.validation.ValidationException.getDomResult(ValidationException.java:59)
      [java] [junit] at org.jboss.soa.esb.actions.validation.SchemaValidationActionUnitTest.processInvalidXml(SchemaValidationActionUnitTest.java:65)
      [java] [junit] Caused by: org.xml.sax.SAXParseException: Premature end of file.
      [java] [junit] at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
      [java] [junit] at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
      [java] [junit] at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:124)
      [java] [junit] at org.jboss.soa.esb.dom.YADOMUtil.parseStream(YADOMUtil.java:148)
      [java] [junit] at org.jboss.soa.esb.dom.YADOMUtil.parseStream(YADOMUtil.java:114)
      [java] [junit] at org.jboss.soa.esb.dom.YADOMUtil.parse(YADOMUtil.java:95)
      [java] [junit] at org.jboss.soa.esb.actions.validation.ValidationException.getDomResult(ValidationException.java:51)

      Tom, are we trying to serialise parser specific classes here? If so this will fail in a mixed environment.

        Gliffy Diagrams

          Activity

          Hide
          kconner Kevin Conner added a comment -

          Unless there is a good reason for including the DOMResult in the exception then I would be inclined to make it null. If we include it, in any fashion, then its content is going to be at the mercy of the transformation engine being used.

          It would be better to make it consistent for all users/engines.

          Show
          kconner Kevin Conner added a comment - Unless there is a good reason for including the DOMResult in the exception then I would be inclined to make it null. If we include it, in any fashion, then its content is going to be at the mercy of the transformation engine being used. It would be better to make it consistent for all users/engines.
          Hide
          kconner Kevin Conner added a comment -

          It doesn't break anything for the community unless they have assumed that the DOMResult is always present. We can keep the API compatibility by returning null.

          Show
          kconner Kevin Conner added a comment - It doesn't break anything for the community unless they have assumed that the DOMResult is always present. We can keep the API compatibility by returning null.
          Hide
          kconner Kevin Conner added a comment -

          This is turning into a forum posting.

          Show
          kconner Kevin Conner added a comment - This is turning into a forum posting.
          Hide
          dward David Ward added a comment -

          LOL. Okay, we can end it here. I will make it always null. It will mean removing some tests. I'll check it in after a clean integration build on both JDK 1.5 and 1.6.

          Show
          dward David Ward added a comment - LOL. Okay, we can end it here. I will make it always null. It will mean removing some tests. I'll check it in after a clean integration build on both JDK 1.5 and 1.6.
          Hide
          dward David Ward added a comment -

          [dward@dwardlinux trunk]$ svn commit
          Sending product/rosetta/src/org/jboss/soa/esb/actions/validation/SchemaValidationAction.java
          Sending product/rosetta/src/org/jboss/soa/esb/actions/validation/ValidationException.java
          Deleting product/rosetta/tests/src/org/jboss/soa/esb/actions/validation/JBESB_2916_UnitTest.java
          Sending product/rosetta/tests/src/org/jboss/soa/esb/actions/validation/SchemaValidationActionUnitTest.java
          Transmitting file data ...
          Committed revision 29936.

          Show
          dward David Ward added a comment - [dward@dwardlinux trunk] $ svn commit Sending product/rosetta/src/org/jboss/soa/esb/actions/validation/SchemaValidationAction.java Sending product/rosetta/src/org/jboss/soa/esb/actions/validation/ValidationException.java Deleting product/rosetta/tests/src/org/jboss/soa/esb/actions/validation/JBESB_2916_UnitTest.java Sending product/rosetta/tests/src/org/jboss/soa/esb/actions/validation/SchemaValidationActionUnitTest.java Transmitting file data ... Committed revision 29936.

            People

            • Assignee:
              dward David Ward
              Reporter:
              kconner Kevin Conner
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development