You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Jesse McLaughlin (JIRA)" <ji...@apache.org> on 2007/09/28 10:16:50 UTC

[jira] Created: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

WSDL2Java giving unexpected results when generating client Port interface
-------------------------------------------------------------------------

                 Key: CXF-1078
                 URL: https://issues.apache.org/jira/browse/CXF-1078
             Project: CXF
          Issue Type: Bug
          Components: JAXB Databinding
    Affects Versions: 2.0.2
         Environment: Mac OS/X, JDK5.
            Reporter: Jesse McLaughlin


I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...

I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.

When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:

@WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
public interface TestPort {

    @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
    @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
    @WebMethod
    public void getPerson();
}

This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.

When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:

@WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
public interface TestPort {

    @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
    @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
    @WebResult(targetNamespace = "", name = "return")
    @WebMethod
    public com.test.test.GetPersonRes.Return getPerson(
        @WebParam(targetNamespace = "", name = "personId")
        java.math.BigInteger personId
    );
}

Which looks much more like what I want (and also what XFire gave).

It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.

For reference, here are the jars on my classpath when I run WSDL2Java:

	cxf-2.0.2-incubator.jar
	cxf-manifest-incubator.jar
	jaxb-api-2.0.jar
	jaxb-impl-2.0.5.jar
	jaxb-xjc-2.0.jar
	jaxen-1.1.jar
	jdom-1.0.jar
	neethi-2.0.2.jar
	stax-api-1.0.1.jar
	stax-utils-20060502.jar
	velocity-1.4.jar
	velocity-dep-1.4.jar
	wstx-asl-3.2.1.jar
	xml-resolver-1.2.jar
	XmlSchema-1.2.jar
	jaxws-api-2.0.jar
	wsdl4j-1.6.1.jar
	geronimo-ws-metadata_2.0_spec-1.1.1.jar
	geronimo-activation_1.1_spec-1.0-M1.jar
	geronimo-annotation_1.0_spec-1.1.jar
	commons-logging-1.1.jar
	log4j-1.2.11.jar


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "maomaode (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12530941 ] 

maomaode commented on CXF-1078:
-------------------------------

Prevoious, we don't check if the complexType is abstract or not, I just commit the check last night, and it's for supporting the jaxws2.1 and jaxb2.1, and the generated sei will in the doc-lit bare style, not the wrapped style. and the jaxb artifacts will have the @XmlSeeAlso annotation

> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "Jesse McLaughlin (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12560888#action_12560888 ] 

Jesse McLaughlin commented on CXF-1078:
---------------------------------------

This issue persists in version 2.0.3.  Is there any help on a solution or a workaround for this?

Thx.



> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>            Assignee: maomaode
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "Jesse McLaughlin (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jesse McLaughlin updated CXF-1078:
----------------------------------

    Attachment: types.xsd

the test XSD file

> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "Jesse McLaughlin (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12565900#action_12565900 ] 

Jesse McLaughlin commented on CXF-1078:
---------------------------------------

Re-tried using 2.0.4 and everything works as expected.



> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>            Assignee: maomaode
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "maomaode (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

maomaode reassigned CXF-1078:
-----------------------------

    Assignee: maomaode

> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>            Assignee: maomaode
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "Jesse McLaughlin (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12561121#action_12561121 ] 

Jesse McLaughlin commented on CXF-1078:
---------------------------------------

Thx Daniel.  That looks like it might even be closer to what I actually want.  Look forward to trying it out in 2.0.4.

Cheers,
Jesse.



> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>            Assignee: maomaode
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "Jesse McLaughlin (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jesse McLaughlin updated CXF-1078:
----------------------------------

    Attachment: test.wsdl

the test WSDL file

> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "Daniel Kulp (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12561115#action_12561115 ] 

Daniel Kulp commented on CXF-1078:
----------------------------------


Jesse,

This is somewhat fixed in 2.0.4 snapshot (will be doing the release builds shortly if the TCK passes), but possibly not how you expect.    The extension stuff will cause it to be detected as non-unwrappable, so the method will be generated as:

    @SOAPBinding(parameterStyle = SOAPBinding.ParameterStyle.BARE)
    @WebResult(name = "getPersonResponse", targetNamespace = "http://www.test.com/test", partName = "parameters")
    @WebMethod
    public com.test.test.GetPersonRes getPerson(
        @WebParam(partName = "parameters", name = "getPerson", targetNamespace = "http://www.test.com/test")
        com.test.test.GetPersonReq parameters
    );

which will at least work, but won't exactly match what I think you are expecting.


> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>            Assignee: maomaode
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (CXF-1078) WSDL2Java giving unexpected results when generating client Port interface

Posted by "Jesse McLaughlin (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jesse McLaughlin closed CXF-1078.
---------------------------------

       Resolution: Fixed
    Fix Version/s: 2.0.4

> WSDL2Java giving unexpected results when generating client Port interface
> -------------------------------------------------------------------------
>
>                 Key: CXF-1078
>                 URL: https://issues.apache.org/jira/browse/CXF-1078
>             Project: CXF
>          Issue Type: Bug
>          Components: JAXB Databinding
>    Affects Versions: 2.0.2
>         Environment: Mac OS/X, JDK5.
>            Reporter: Jesse McLaughlin
>            Assignee: maomaode
>             Fix For: 2.0.4
>
>         Attachments: test.wsdl, types.xsd
>
>
> I was previously using WSDL2Java for XFire 1.2.6, and with XFire this example works just fine.  When I switched to CXF the results are quite different and don't look right...
> I have two files in this test, the WSDL and one XSD file.  The XSD contains comments indicating where sections can be commented/uncommented in order to show how the results vary unexpectedly.
> When WSDL2Java is run on the attached WSDL file (passing the -client arg), the generated file 'com/test/testservice/TestPort.java' looks like this:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebMethod
>     public void getPerson();
> }
> This is wrong since according to the WSDL the getPerson() operation takes a parameter and also returns a parameter.
> When the XSD is changed to the use the alternative type definitions as indicated in the inline comments, the generated file then becomes:
> @WebService(targetNamespace = "http://www.test.com/TestService/", name = "TestPort")
> public interface TestPort {
>     @ResponseWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonRes", localName = "getPersonResponse")
>     @RequestWrapper(targetNamespace = "http://www.test.com/test", className = "com.test.test.GetPersonReq", localName = "getPerson")
>     @WebResult(targetNamespace = "", name = "return")
>     @WebMethod
>     public com.test.test.GetPersonRes.Return getPerson(
>         @WebParam(targetNamespace = "", name = "personId")
>         java.math.BigInteger personId
>     );
> }
> Which looks much more like what I want (and also what XFire gave).
> It seems that changing the parameter definitions to inherit from an abstract base type somehow causes this issue.
> For reference, here are the jars on my classpath when I run WSDL2Java:
> 	cxf-2.0.2-incubator.jar
> 	cxf-manifest-incubator.jar
> 	jaxb-api-2.0.jar
> 	jaxb-impl-2.0.5.jar
> 	jaxb-xjc-2.0.jar
> 	jaxen-1.1.jar
> 	jdom-1.0.jar
> 	neethi-2.0.2.jar
> 	stax-api-1.0.1.jar
> 	stax-utils-20060502.jar
> 	velocity-1.4.jar
> 	velocity-dep-1.4.jar
> 	wstx-asl-3.2.1.jar
> 	xml-resolver-1.2.jar
> 	XmlSchema-1.2.jar
> 	jaxws-api-2.0.jar
> 	wsdl4j-1.6.1.jar
> 	geronimo-ws-metadata_2.0_spec-1.1.1.jar
> 	geronimo-activation_1.1_spec-1.0-M1.jar
> 	geronimo-annotation_1.0_spec-1.1.jar
> 	commons-logging-1.1.jar
> 	log4j-1.2.11.jar

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.