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] http://cxf.apache.org/docs/bus-configuration.html
Any help or guidance will really be appreciated.
Paul
--
Sergey Beryozkin
Talend Community Coders
http://coders.talend.com/
Blog: http://sberyozkin.blogspot.com