cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Selibas <>
Subject Re: CXF Config.
Date Wed, 09 May 2012 13:10:44 GMT
Thank your for your response...

I tried what you said and I got it to work. You have no idea how grateful I am.

Can I just confirm with you what I have done because I am not sure its
100% correct...

I defined a bean
    <bean name="myBus"

And then my servlet
    <bean class="org.apache.cxf.transport.servlet.CXFNonSpringServlet">
        <property name="bus" ref="myBus" />

And then my endpoint
    <jaxws:endpoint id="webService" implementor=""
		address="/enpoint" bus="myBus">

And it works. I cant believe there is zero documentation on this.

Thank you again.


On Wed, May 9, 2012 at 1:18 PM, Sergey Beryozkin <> wrote:
> Hi
> On 09/05/12 11:37, Paul Selibas wrote:
>> Hello,
>> Yesterday I asked a question that seems cant be answered. So i will
>> rephrase my question...
>> I am new to CXF so please bear with me:
>> I have created a standalone spring application.
>> I have a spring config file where I have defined a jetty Server
>> instance, as well as a CXFServlet, which is registered to this Server.
>> When I target the URL for that servlet I get the expected "No services
>> have been found.", which is perfect.
>> I then, from the same spring config file, specify the following:
>>     <import resource="classpath:META-INF/cxf/cxf.xml" />
>>     <import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
> This extension import is redundant now...
>>     <import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
>>     <jaxws:endpoint id="webService" implementor="com.xx.EndpointImp"
>>         address="/endpoint">
>>     </jaxws:endpoint>
>> I would then expect the service to be published at the "<servlet
>> url>/endpoint". But its not. Where am I going wrong?
>> I am confused as to what links up the endpoint to the CXFServlet
>> instance I have created. Please note I don't have a
>> web.xml as it is purely configured in spring.
> web.xml will also contains a reference to
> org.springframework.web.context.ContextLoaderListener and CXFServlet reacts
> to it.
> Perhaps you should use CXFNonSpringServlet instead, get an explicit cxf:bus
> [1] bean declared in the context and have a reference to it injected into a
> 'bus' property on the servlet...
> Alternatively, have the 'main' context which only declares CXFServlet with
> its "config-location" init parameter pointing to the 'real' configuration
> containing the endpoint info, not sure if it will work :-)
> Cheers, Sergey
> [1]
>> Any help or guidance will really be appreciated.
>> Paul
> --
> Sergey Beryozkin
> Talend Community Coders
> Blog:

View raw message