Hi,

Here's my xbean.xml file deployed to the bean-se container; it 
attempts to define a pojo with a member named "proxy" that I 
want injected with a CXF proxy to the web service 'PersonService':


<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns:bean="http://servicemix.apache.org/bean/1.0";
       xmlns:person="http://servicemix.apache.org/samples/wsdl-first";
       xmlns:cxfse="http://servicemix.apache.org/cxfse/1.0";>

  <bean:endpoint service="person:PersonService2" 
                 endpoint="person:Person" 
                 bean="#myBean" />

  <bean id="myBean" 
        class="org.apache.servicemix.samples.cxf_wsdl_first.MyBean">

    <property name="proxy">
      <cxfse:proxy service="person:PersonService"
                   context="#context"
                   type="org.apache.servicemix.samples.wsdl_first.Person" />
    </property>

  </bean> 

  <classpath>
    <component>servicemix-bean</component>
    <component>servicemix-cxf-se</component>
  <classpath>
</beans>


My POJO bean is defined like this:

  public class MyBean implements MessageExchangeListener

and contains no annotations of any kind; it's just a pojo.

On deployment to SMX, I get the following error:

  Cannot resolve reference to bean 'context' while setting
  bean property 'context'; nested exception is
  org.springframework.beans.factory.NoSuchBeanDefinitionException:
  No bean named 'context' is defined.


The reference to '#context" does, however, resolve correctly
when made inside an xbean deployed to the cxf-se container.
What do I need to do to get CXF proxy working inside the 
bean container?

Thanks, Garry



Garry wrote:
> 
> Hi,
> 
> I can use the jsr-181 proxy in a bean SU but seem unable to use the
> cxf proxy outside the cxf-se container. When I try, the '#context"
> proxy dependency injection fails with a Spring "can't find referenced 
> bean" error. Works just fine inside the cxf-se container, however. I
> want to confirm that is the case. Is it possible to use cxf proxy in a
> bean SU?  Example?
> 
> Thanks, Garry
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Can-use-cxf-proxy-outside-cxf-se-container--tp15604370s12049p15614266.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Reply via email to