I think you have two options:

1)  Use the serviceBean child element.  With that, you need to use a spring 
bean child most likely.
<simple:serviceBean>
    <bean ref="myService"/>
</simple:serviceBean>


2)  Use the serviceBean attribute on the simple:server:
<simple:server
        id="server"
        serviceClass="com.mycompany.MyService"
        serviceBean="#myService"
....


Dan



On Friday 25 June 2010 9:59:01 am Sean Patrick Floyd wrote:
> Hello,
> 
> 
> 
> I have a spring config file service.xml in which a service class is defined
> 
> 
> 
> <beans>
> 
>        <bean id="myService" class="com.mycompany.MyServiceImpl">
> 
>        <!-- Many properties here -->
> 
>        </bean>
> 
> 
> 
>        <!-- Many other beans here -->
> 
> </beans>
> 
> 
> 
> And I have a cxf config server.xml with a server definition
> 
> 
> 
> <import location="classpath:service.xml" />
> 
> <simple:server
> 
>        id="server"
> 
>        serviceClass="com.mycompany.MyService"
> 
>        ...
> 
> 
> 
>              <simple:serviceBean ref="myService">
> 
> 
> 
> </simple:serviceBean>
> 
> 
> 
> I would like the server to reference the existing bean, but unfortunately a
> new myService bean is created and all properties are missing.
> 
> serviceClass points to an interface implemented by MyServiceImpl and I
> can't really change that, because otherwise the created wsdl will contain
> all public methods (including setters).
> 
> 
> 
> Is there something I am doing wrong? Or do I have to configure my service
> bean as an inner bean of simple:serviceBean (I hope not)?
> 
> I use interface-based proxying in my service.xml, not cglib. Is that
> perhaps the issue? I see that CGLib is used to create the new bean.
> 
> 
> 
> Can anybody help?
> 
> 
> 
> Thanks Sean

-- 
Daniel Kulp
[email protected]
http://dankulp.com/blog

Reply via email to