cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ian Roberts <i.robe...@dcs.shef.ac.uk>
Subject Re: JAX-WS - multiple services in separate jars
Date Tue, 08 Jul 2008 11:44:54 GMT
splatch wrote:
> Hello CXF users and developers.
> 
> I would like create some module web application with web services. When I
> use Spring's DisplatcherServlet everything works fine, but CXFServlet
> doesn't see jaxws:endpoint defined in imported context.

Rather than having the CXFServlet load its own spring context from 
cxf-servlet.xml, you can just load the whole lot into the root context. 
  Rename your existing cxf-servlet.xml to some other name (e.g. 
cxf-beans.xml) and take out the import of the /module/**-context.xml, 
then change your contextConfigLocation parameter to something like:

     <context-param>
         <param-name>contextConfigLocation</param-name>
         <param-value>
             /WEB-INF/security.xml <!-- spring security configuratio -->
             /WEB-INF/applicationContext.xml <!-- DAOs etc -->
             /WEB-INF/cxf-beans.xml <!-- common CXF definitions -->
             classpath:/module/**-context.xml
         </param-value>
     </context-param>

This should give behaviour equivalent to putting the endpoint config 
directly into applicationContext.xml.

Ian

-- 
Ian Roberts               | Department of Computer Science
i.roberts@dcs.shef.ac.uk  | University of Sheffield, UK

Mime
View raw message