Uploaded image for project: 'CXF'
  1. CXF
  2. CXF-1020

WSDL2Java tool error: failed to generate codes with twoHeadersSameNameDifferentNamespace

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0.1
    • 2.0.5
    • Tooling
    • None
    • windows.

    Description

      I am running WSDL2Java tool to generate codes, and then got the message as follow:

      WSDLToJava Error : Failed to create java parameter for part [stringHeader2] in method [twoHeadersSameNameDiffNS] - this wsdl is invalid, please use the wsdlvalidator tool to validate this wsdl

      I also run wsdlvalidator, it says valid WSDL, and I can get generated codes from JAXWS-RI.

      Attachments

        1. headerDatatype.wsdl
          30 kB
          Jeff Yu

        Issue Links

          Activity

            jeff.yu Jeff Yu added a comment -

            attach the wsdl.

            jeff.yu Jeff Yu added a comment - attach the wsdl.
            dkulp Daniel Kulp added a comment -

            I honestly thing the wsdl is invalid. The "stringHeader2" part definition points to element="StringHeader". However, there is no element defined in the target namespace of the wsdl. Thus, there is not type for it.

            That said, we shouldn't be getting that far. Without "-exsh true", we shouldn't be processing the out of band soap headers. It seems that for some out of band headers on the output side, we are processing them even without the flag set. I'm going to fix that.

            dkulp Daniel Kulp added a comment - I honestly thing the wsdl is invalid. The "stringHeader2" part definition points to element="StringHeader". However, there is no element defined in the target namespace of the wsdl. Thus, there is not type for it. That said, we shouldn't be getting that far. Without "-exsh true", we shouldn't be processing the out of band soap headers. It seems that for some out of band headers on the output side, we are processing them even without the flag set. I'm going to fix that.

            People

              dkulp Daniel Kulp
              jeff.yu Jeff Yu
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: