cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Benson Margulies (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CXF-1833) Inconsistent Aegis type mapping of List<> with and without @WebParam
Date Wed, 01 Oct 2008 00:51:44 GMT

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

Benson Margulies commented on CXF-1833:
---------------------------------------

This is very likely a side-effect of the artificial separation of generics, non-generics,
and annotations in Aegis. There may be nothing to be done about this except to refactor. Ugh.

> Inconsistent Aegis type mapping of List<> with and without @WebParam
> --------------------------------------------------------------------
>
>                 Key: CXF-1833
>                 URL: https://issues.apache.org/jira/browse/CXF-1833
>             Project: CXF
>          Issue Type: Bug
>          Components: Aegis Databinding
>    Affects Versions: 2.1.2
>         Environment: SimpleFrontend, AegisDatabinding
>            Reporter: Jara Cesnek
>
> When adding @WebParam on List<>, WSDL types and namespaces is changed drastically.

> 1.
>     @WebMethod
>     public void method1(List<String> headers1) {
>     }
> 2.
>     @WebMethod
>     public void method1(String[] headers1) {
>     }
> 3.
>     @WebMethod
>     public void method1( @WebParam(name = "headers1") String[] headers1) {
>     }
> 4.
>     @WebMethod
>     public void method1( @WebParam(name = "headers1") List<String> headers1) {
>     }
> Methods 1,2,3 produces equal WSDL and expected types :
> - <xsd:schema attributeFormDefault="qualified" elementFormDefault="qualified" targetNamespace="http://v1_1_2.mcnav4connector.ws.daisy.marbes.cz"
xmlns:tns="http://v1_1_2.mcnav4connector.ws.daisy.marbes.cz" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> - <xsd:complexType name="ArrayOfString">
> - <xsd:sequence>
>   <xsd:element maxOccurs="unbounded" minOccurs="0" name="string" nillable="true" type="xsd:string"
/> 
>   </xsd:sequence>
>   </xsd:complexType>
> But method 4 produces something unexpexted : 
> - <xsd:schema attributeFormDefault="qualified" elementFormDefault="qualified" targetNamespace="http://util.java"
xmlns:tns="http://util.java" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> - <xsd:complexType name="headers1">
> - <xsd:sequence>
>   <xsd:element maxOccurs="unbounded" minOccurs="0" name="string" nillable="true" type="xsd:string"
/> 
>   </xsd:sequence>
>   </xsd:complexType>
>   </xsd:schema>
> My configuration: 
>         JaxWsServiceFactoryBean aegisServiceFactoryBean = new JaxWsServiceFactoryBean();

>         aegisServiceFactoryBean.setDataBinding(new AegisDatabinding()); 
>         aegisServiceFactoryBean.setServiceConfigurations(Arrays.asList( 
>                 new org.apache.cxf.jaxws.support.JaxWsServiceConfiguration(), 
>                 new org.apache.cxf.service.factory.DefaultServiceConfiguration() 
>         )); 
>         ServerFactoryBean serverFactoryBean = new ServerFactoryBean(); 
>         serverFactoryBean.setServiceClass(AopUtils.getTargetClass(implementor)); 
>         serverFactoryBean.setServiceBean(implementor); 
>         serverFactoryBean.setAddress(url); 
>         serverFactoryBean.setServiceFactory(aegisServiceFactoryBean); 
> Together with bug CXF-1789  there is definitively something nasty in handling @WebParam
in Aegis and SimpleFrontent.

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


Mime
View raw message