You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Andreas Gudian (JIRA)" <ji...@apache.org> on 2012/05/09 16:55:48 UTC

[jira] [Issue Comment Edited] (CXF-4301) Problem with Implicit Soap Headers and @ResponseWrapper in methods with multiple response attributes: NullPointerException in ReflectionServiceFactoryBean or Response-Marshalling Error

    [ https://issues.apache.org/jira/browse/CXF-4301?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13271467#comment-13271467 ] 

Andreas Gudian edited comment on CXF-4301 at 5/9/12 2:54 PM:
-------------------------------------------------------------

Attached an example of the error. 

The two WSDL files are 100% equal. Creating a copy was just my workaround to perform the source generation twice within one pom: once with ext. soap headers = true, once with false.

call {{mvn clean test}} to execute all four test cases. Three of them will fail due to the problem described here.
                
      was (Author: agudian):
    Example of the error. 

The two WSDL files are 100% equal. Creating a copy was just my workaround to perform the source generation twice within one pom: once with ext. soap headers = true, once with false.

call {{mvn clean test}} to execute all four test cases. Three of them will fail due to the problem described here.
                  
> Problem with Implicit Soap Headers and @ResponseWrapper in methods with multiple response attributes: NullPointerException in ReflectionServiceFactoryBean or Response-Marshalling Error
> ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CXF-4301
>                 URL: https://issues.apache.org/jira/browse/CXF-4301
>             Project: CXF
>          Issue Type: Bug
>            Reporter: Andreas Gudian
>         Attachments: implicit-header-showcase.zip
>
>
> (Extended version of the problem described and fixed in CXF-4117)
> I have a WSDL that defines an implicit Soap Header for requests and responses. One of the response messages consists of multiple elements with types that map to the same type in Java (String, in that case).
> Problem #1: When I generate my Code using the flag {{ExtendedSoapHeaders=true}}, the service can not be published due to the following exception:
> {code}
> java.lang.NullPointerException
> 	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeParameter(ReflectionServiceFactoryBean.java:827)
> 	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeClassInfo(ReflectionServiceFactoryBean.java:748)
> 	at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.initializeWSDLOperation(JaxWsServiceFactoryBean.java:254)
> 	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeWSDLOperations(ReflectionServiceFactoryBean.java:652)
> 	at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.initializeWSDLOperations(JaxWsServiceFactoryBean.java:292)
> 	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromWSDL(ReflectionServiceFactoryBean.java:393)
> 	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServiceModel(ReflectionServiceFactoryBean.java:506)
> 	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(ReflectionServiceFactoryBean.java:242)
> 	at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFactoryBean.java:205)
> 	at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:101)
> 	at org.apache.cxf.frontend.ServerFactoryBean.create(ServerFactoryBean.java:159)
> 	at org.apache.cxf.jaxws.JaxWsServerFactoryBean.create(JaxWsServerFactoryBean.java:207)
> {code}
> Problem #2: When I generate my Code using the flag {{ExtendedSoapHeaders=false}}, the response message is not marshaled correctly and the schema validation fails (the element from the Soap header is placed in the response body, filled with the value of one of the regular response elements, which then was missing the response).
> I will attach an example for both cases.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira