cxf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrea Smyth <andrea.sm...@iona.com>
Subject wildcard bean definitions
Date Fri, 01 Jun 2007 18:11:27 GMT
Hi all,

The support for wildcard beans that was introduced a while ago only 
seems to apply to standard beans, i.e. 
{http://www.springframework.org/schema/beans}bean elements, but not to 
custom beans such as  
{http://cxf.apache.org/transports/http/configuration}conduit elements.  
With more and more use of Spring's support for custom schema it would be 
good to support this for custom beans also:

<h:conduit name="*.http-conduit">
      <h:client ConnectionTimeout="79"/>
 </h:conduit>

The problem seems to be that the wildcard definitions map uses the 
simple class name as the key. If  line 152 in ConfigurerImpl:
String className = beanInstance.getClass().getSimpleName();
is changed to use the qualified name, the above works as expected.

What was the rationale for choosing the simple name as a key?  Are there 
any objections to changing this to using the qualified class name?
Note that for custom beans that class name never needs to be specified  
- the bean definition parser provides it (and it would result in invalid 
xml unless a "class" attribute was actually defined for a custom bean).

Cheers,
Andrea.


Mime
View raw message