cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ejoch <>
Subject CXF Aegis binding problem/ string2string Map
Date Mon, 22 Dec 2008 11:41:44 GMT


I've just moved to using CXF 2.1.3 with Tomcat, having previously been using
2.0.4 inside the Mule ESB.

I'm having a problem with the WSDL produced when a method's input parameter
is a map - specifically, the namespace for the map's 'string2string' type.
Instead of having that type inside the namespace for the service (as
happened with 2.0.4, at least with Mule), CXF is putting the type into the
namespace for whatever service happens to be first in the spring-configured
service list.

String runTest(String id, String tempName, Map<String, String> contents)
throws TempException;

This lives in package:
and is annoted to have namespace
(the annotation works correctly, the DefaultNamespace matches)

The method and parameter names are defined in an aegis mapping file, which
works correctly when the wsdl is rendered.

The WSDL is corrected except for, 'string2string':
<xsd:schema attributeFormDefault="qualified" elementFormDefault="qualified"
<xsd:complexType name="string2stringMap">
<xsd:element name="constructContents" type="tns:constructContents" />
<xsd:complexType name="constructContents">
<xsd:element minOccurs="0" name="siteId" type="xsd:string" />
<xsd:element minOccurs="0" name="templateName" type="xsd:string" />
<xsd:element minOccurs="0" name="contentsMap" type="ns0:string2stringMap" /> is the namespace of the first service in the
list of services we load to CXF. I have tested this by changing other
services to be first in the list, and every time, this WSDL changes so that
'string2string' type belongs to the namespace of the first service.

Everything else in the wsdl is correctly inside the namespace for either the
wsdl's service, or the dto/domain objects: only 'string2string' is in the
wrong namespace.

I have put in the temporary workaround of putting a 'fake' service as first
in the list, with a generic namespace that at least stops the wsdl looking
broken, but this isn't a long term solution- if I were to introduce another
service using maps (or any other type with this issue) any stub-generation
would get a conflict on that package.

does anyone have any ideas please?

View this message in context:
Sent from the cxf-user mailing list archive at

View raw message