Hi Willem/Dan,

Is this last change around the serviceBean? Because, I had tried it earlier
and it was not working.

There is one more issue in using the cxf.xml in this fashion. If I do not
refer to a bean using the # and instead give the class directly, it still
does not work.

For example, the following still does not work. The exception says "Could
not find destination factory for transport
http://schemas.xmlsoap.org/soap/http";. This error happens only if you do not
have the dependency cxf-rt-transports-http-jetty. The behavior is different
if you have this dependency.

The only way I have been able to get the service fully functional without
cxf-rt-transports-http-jetty  is by embedding cxf in my spring config after
importing the necessary configs. Hope the information helps.

I would love to see the cxf.xml approach supported. The services.xml in
XFire was a convenient way of keeping the stuff away from my other spring
configs.

Thanks,
Jacob


<beans xmlns="http://www.springframework.org/schema/beans";
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
   xmlns:simple="http://cxf.apache.org/simple";
   xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://cxf.apache.org/simple
http://cxf.apache.org/schemas/simple.xsd";>

   <simple:server id="Test" address="/hello"
       serviceClass="com.ironmountain.digital.erm.irmrap.cl.soap.util.Hello
">
       <simple:serviceBean>
           <bean
               class="
com.ironmountain.digital.erm.irmrap.cl.soap.util.HelloImpl" />
       </simple:serviceBean>

   </simple:server>
</beans>



On 7/18/07, Willem Jiang <[EMAIL PROTECTED]> wrote:

Hi Dan,

I did some clean up of the simple front-end spring parser,
Can you review my last commit (svn commit: r557161)?

Thanks,
Willem.

Dan Diephouse wrote:
> With the simple frontend its called a serviceBean:
>
> <simple:server id="Test" address="/hello"
>     serviceBean="#helloService" serviceClass="com.test.Hello">
> </simple:server>
>
> Cheers,
>
> - Dan
>
> On 7/17/07, Jacob Marcus <[EMAIL PROTECTED]> wrote:
>>
>> Hi Willem,
>>
>> I believe I am using version CXF incubator 2.0. The simple.xsd does not
>> support implementor as an attribute. It does support implementor as an
>> element. But it needs child elements.
>>
>> Should I be using a different version (snapshot) of  CXF?
>>
>> Thanks,
>> Jacob
>>
>> On 7/17/07, Jiang, Ning (Willem) <[EMAIL PROTECTED]> wrote:
>> >
>> >
>> > I think the spring syntext should be
>> >   <simple:server id="Test" address="/hello"
>> >     implementor="#helloService" serviceClass="com.test.Hello">
>> >   </simple:server>
>> >
>> > Because I checked the trunk code, it only deals with the attribute
>> > implementor now.
>> >
>> > Willem.
>> >
>> > -----Original Message-----
>> > From: Jacob Marcus [mailto:[EMAIL PROTECTED]
>> > Sent: Tue 7/17/2007 22:55
>> > To: [email protected]
>> > Subject: Re: How can cxf.xml refer to beans defined in the
application
>> > context? (Xfire to CXF migration)
>> >
>> > I am using the Simple front end approach without annotations.
>> >
>> > <simple:server id="Test" address="/hello"
>> >     serviceBean="#helloService" serviceClass="com.test.Hello">
>> >   </simple:server>
>> >
>> > I think the problem is in the SpringBus. The CXFServlet does not
>> seem to
>> > have access to the ApplicationContext I have loaded using the
>> > ContextLoaderLister in the web.xml
>> >
>> > Is there some additional configuration required?
>> >
>> > Thanks,
>> > Jacob
>> >
>> > On 7/17/07, Jiang, Ning (Willem) <[EMAIL PROTECTED]> wrote:
>> > >
>> > > I think you could try to use the endpoint's attribute implementor.
>> > > It should be workable with the # convention.
>> > > Here is an example for it
>> > > <jaxws:endpoint id="endpoint1"
>> > >               implementor="#HelloService"
>> > >               address="/services/Greeter1"/>
>> > >
>> > > Willem
>> > >
>> > >
>> > > -----Original Message-----
>> > > From: Jacob Marcus [mailto:[EMAIL PROTECTED]
>> > > Sent: Tue 7/17/2007 21:59
>> > > To: [email protected]
>> > > Subject: How can cxf.xml refer to beans defined in the application
>> > > context? (Xfire to CXF migration)
>> > >
>> > > Hi all,
>> > >
>> > > I am an xfire user who is used to the xfire services.xml. I am now
>> > porting
>> > > the services.xml to cxf.xml and have it working for a simple 'Hello
>> > World'
>> > > case.
>> > >
>> > > I have a requirement to refer to beans defined else where in the
>> cxf.xml
>> > .
>> > > XFire used to let me do this using the # convention.
>> > >
>> > > Example : <serviceBean>#ihelloService</serviceBean>.
>> > >
>> > > I tried a similar approach with cxf.  However, it cannot find the
>> bean.
>> > > Has
>> > > anybody tried this? Is this approach supported in cxf?
>> > >
>> > > Thanks,
>> > > Jacob
>> > >
>> > >
>> > >
>> >
>> >
>>
>
>
>

Reply via email to