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

Issue with .NET clients - stub method parameters wrapped in a parameter class

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.0.3
    • None
    • None

    Description

      We are trying to upgrade our published services from xfire to cxf. We are using the simple frontend with aegis. Before we push the upgrade to production, we need to make sure the upgrade as transparent as possible to our users. With cxf, we see that the .NET client stubs are different from the ones users are getting now from xfire. A method that appears as doIt(Thing a, Thing b) for example appears as dotIt(DoItRequest request) where DoItRequest contains the a and b parameters.

      I found out that doing a small change to the wsdl makes .NET generate the stubs the way we want them. Changing the method request element from this for example:

      <xsd:element name="findFeaturesByExtent" type="tns:findFeaturesByExtent" />
      <xsd:complexType name="findFeaturesByExtent">
      <xsd:sequence>
      <xsd:element minOccurs="0" name="extent" type="tns:Envelope" />
      <xsd:element minOccurs="0" name="spatialQueryOptions" type="tns:SpatialQueryOptions" />
      <xsd:element minOccurs="0" name="token" type="xsd:string" />
      </xsd:sequence>
      </xsd:complexType>

      to this

      <xsd:element name="findFeaturesByExtent">
      <xsd:complexType name="findFeaturesByExtent">
      <xsd:sequence>
      <xsd:element minOccurs="0" name="extent" type="ns0:Envelope"/>
      <xsd:element minOccurs="0" name="spatialQueryOptions" type="ns0:SpatialQueryOptions"/>
      <xsd:element minOccurs="0" name="token" type="xsd:string"/>
      </xsd:sequence>
      </xsd:complexType>
      </xsd:element>

      fixes the problem.

      Please let me know if you need any additional info.

      Thanks

      Attachments

        Activity

          People

            Unassigned Unassigned
            tawfik Tawfik Lachheb
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: