CXF
  1. CXF
  2. CXF-3846

NullPointerException when requesting ?wsdl using AegisDatabinding and @SchemaValidation

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.4.1
    • Fix Version/s: 2.4.4, 2.3.8
    • Component/s: Aegis Databinding
    • Labels:
      None
    • Environment:

      Debian 6.1 x64, java 1.6.0_18, JBoss 7.0.1

    • Estimated Complexity:
      Novice

      Description

      After getting schema validation to work with aegis databinding, I noticed the ?wsdl is no longer working due to a NullPointerException. The relevant part of the stacktrace:

      unwinding now: java.lang.NullPointerException
      at org.apache.cxf.wstx_msv_validation.Stax2ValidationUtils.setupValidation(Stax2ValidationUtils.java:71) [cxf-wstx-msv-validation-2.4.1.jar:]
      at org.apache.cxf.wstx_msv_validation.WoodstoxValidationImpl.setupValidation(WoodstoxValidationImpl.java:67) [cxf-wstx-msv-validation-2.4.1.jar:]
      at org.apache.cxf.aegis.databinding.AegisSchemaValidationInInterceptor.setSchemaInMessage(AegisSchemaValidationInInterceptor.java:68) [cxf-rt-databinding-aegis-2.4.1.jar:2.4.1]
      at org.apache.cxf.aegis.databinding.AegisSchemaValidationInInterceptor.handleMessage(AegisSchemaValidationInInterceptor.java:56) [cxf-rt-databinding-aegis-2.4.1.jar:2.4.1]
      at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:263) [cxf-api-2.4.1.jar:2.4.1]

      It seems that at AegisSchemaValidationInInterceptor:54 the result of message.getContent(XMLStreamReader.class) is null.

      Obviously, a ?wsdl from a webbrowser is not a valid message, so a validation error could be expectable (a NPE isn't of course). I am wondering though if it is desirable, as it would leave ?wsdl broken.

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            Daniel Kulp
            Reporter:
            Rik van Ballegooijen
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development