Tadayoshi Sato created CXF-6608:
-----------------------------------
Summary: java2ws -t (target namespace) option generates invalid
WSDL
Key: CXF-6608
URL: https://issues.apache.org/jira/browse/CXF-6608
Project: CXF
Issue Type: Bug
Components: Tooling
Affects Versions: 3.1.2
Reporter: Tadayoshi Sato
This command:
{code}
java2ws -wsdl -t urn:com.example:ws:1.0 com.example.ws.ExampleService
{code}
generates WSDL that contains two different namespaces for the {{tns}}
({{"urn:com.example:ws:1.0"}}) and the schema types
({{"http://ws.example.com/"}}) as follows:
{code:xml}
<wsdl:definitions name="ExampleService" targetNamespace="urn:com.example:ws:1.0"
xmlns:ns1="http://ws.example.com/" xmlns:tns="urn:com.example:ws:1.0" ...>
<wsdl:types>
<xs:schema xmlns="http://ws.example.com/" ...
targetNamespace="http://ws.example.com/">
<xs:element name="op1" type="op1" />
...
</xs:schema>
</wsdl:types>
<wsdl:message name="op1">
<wsdl:part name="parameters" element="ns1:op1">
</wsdl:part>
</wsdl:message>
...
<wsdl:portType name="ExampleServicePortType">
<wsdl:operation name="op1">
<wsdl:input name="op1" message="ns1:op1">
</wsdl:input>
<wsdl:output name="op1Response" message="ns1:op1Response">
</wsdl:output>
</wsdl:operation>
...
</wsdl:portType>
...
{code}
Therefore, importing the WSDL to Eclipse shows WSDL validation errors.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)