Я пишу веб-сервис, начиная с написания WSDL. Я генерировал скелетный код на стороне сервера, используя wsimport, а затем написал свой собственный класс реализации. Я запускаю веб-сервис на сервере Axis2. При использовании soapUI сообщения SOAP, поступающие в службу и из нее, выглядят хорошо, но при использовании клиента веб-службы в заглушках на стороне клиента я получаю нулевое значение. Я слышал, что это может быть проблема с пространством имен, но я вижу что-то не так. Вот моя копия WSDL. Любая помощь будет оценена.
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:ns1="http://org.apache.axis2/xsd" xmlns:ns="http://test.sa.lmco.com" xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" targetNamespace="http://test.sa.lmco.com">
<!-- **************** -->
<!-- ** Types ** -->
<!-- **************** -->
<wsdl:types>
<xs:schema attributeFormDefault="qualified" elementFormDefault="qualified" targetNamespace="http://test.sa.lmco.com">
<xs:element name="sayHello">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="s" nillable="true" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="sayHelloResponse">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="getTaxonomyNode">
<xs:complexType>
<xs:sequence>
<xs:element name="taxonomyId" minOccurs="1" maxOccurs="1" type="xs:int" />
<xs:element name="nodeId" type="xs:int" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="getTaxonomyNodeResponse">
<xs:complexType>
<xs:sequence>
<xs:element name="resultNode" type="ns:TaxonomyNode" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="getChildren">
<xs:complexType>
<xs:sequence>
<xs:element name="taxonomyId" minOccurs="1" maxOccurs="1" type="xs:int" />
<xs:element name="parentNodeId" minOccurs="1" maxOccurs="1" type="xs:int" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="getChildrenResponse">
<xs:complexType>
<xs:sequence>
<xs:element name="childNodes" minOccurs="0" maxOccurs="unbounded" type="ns:TaxonomyNode" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:complexType name="TaxonomyNode">
<xs:sequence>
<xs:element name="taxonomyId" type="xs:int" />
<xs:element name="nodeId" type="xs:int" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="LCD">
<xs:sequence>
<xs:element name="language" type="xs:string" />
<xs:element name="content" type="xs:string" />
<xs:element name="description" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:schema>
</wsdl:types>
<!-- ***************** -->
<!-- ** Messages ** -->
<!-- ***************** -->
<wsdl:message name="sayHelloRequest">
<wsdl:part name="parameters" element="ns:sayHello"/>
</wsdl:message>
<wsdl:message name="sayHelloResponse">
<wsdl:part name="parameters" element="ns:sayHelloResponse"/>
</wsdl:message>
<wsdl:message name="getTaxonomyNodeRequest">
<wsdl:part name="parameters" element="ns:getTaxonomyNode" />
</wsdl:message>
<wsdl:message name="getTaxonomyNodeResponse">
<wsdl:part name="parameters" element="ns:getTaxonomyNodeResponse" />
</wsdl:message>
<wsdl:message name="getChildrenRequest">
<wsdl:part name="parameters" element="ns:getChildren" />
</wsdl:message>
<wsdl:message name="getChildrenResponse">
<wsdl:part name="parameters" element="ns:getChildrenResponse" />
</wsdl:message>
<!-- ******************* -->
<!-- ** PortTypes ** -->
<!-- ******************* -->
<wsdl:portType name="HelloWSPortType">
<wsdl:operation name="sayHello">
<wsdl:input message="ns:sayHelloRequest" wsaw:Action="urn:sayHello"/>
<wsdl:output message="ns:sayHelloResponse" wsaw:Action="urn:sayHelloResponse"/>
</wsdl:operation>
<wsdl:operation name="getTaxonomyNode">
<wsdl:input message="ns:getTaxonomyNodeRequest" wsaw:Action="urn:getTaxonomyNode" />
<wsdl:output message="ns:getTaxonomyNodeResponse" wsaw:Action="urn:getTaxonomyNodeResponse" />
</wsdl:operation>
<wsdl:operation name="getChildren">
<wsdl:input message="ns:getChildrenRequest" wsaw:Action="urn:getChildren" />
<wsdl:output message="ns:getChildrenResponse" wsaw:Action="urn:getChildrenResponse" />
</wsdl:operation>
</wsdl:portType>
<!-- ****************** -->
<!-- ** Bindings ** -->
<!-- ****************** -->
<wsdl:binding name="HelloWSServiceSoap11Binding" type="ns:HelloWSPortType">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
<wsdl:operation name="sayHello">
<soap:operation soapAction="urn:sayHello" style="document"/>
<wsdl:input>
<soap:body use="literal"/>
</wsdl:input>
<wsdl:output>
<soap:body use="literal"/>
</wsdl:output>
</wsdl:operation>
<wsdl:operation name="getTaxonomyNode">
<soap:operation soapAction="urn:getTaxonomyNode" style="document" />
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
<wsdl:operation name="getChildren">
<soap:operation soapAction="urn:getChildren" style="document" />
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<!-- **************** -->
<!-- ** Service ** -->
<!-- **************** -->
<wsdl:service name="HelloWS">
<wsdl:port name="HelloWSServiceHttpSoap11Endpoint" binding="ns:HelloWSServiceSoap11Binding">
<soap:address location="http://162.16.129.25:9090/axis2/services/HelloWS"/>
</wsdl:port>
</wsdl:service>