title: Apache CXF and tomcat
body: <p>I am fairly new to Apache CXF and tomcat. I am trying to build a simple web service and deploy it on tomcat. below is my web.xml
  However when I try to access the 'services' folder using my browser it says No services have been found. I tried creating java web service client but it is not able to locate the service either. What could be wrong in this? </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"&gt;
      &lt;display-name&gt;Sample web service provider&lt;/display-name&gt;
      &lt;listener&gt;
          &lt;!-- For Metro, use this listener-class instead: 
               com.sun.xml.ws.transport.http.servlet.WSServletContextListener --&gt;
          &lt;listener-class&gt;
                org.springframework.web.context.ContextLoaderListener
          &lt;/listener-class&gt;
      &lt;/listener&gt;
      &lt;!-- Remove below context-param element if using Metro --&gt;
      &lt;context-param&gt;
          &lt;param-name&gt;contextConfigLocation&lt;/param-name&gt;
          &lt;param-value&gt;
                classpath:META-INF/cxf/cxf.xml
          &lt;/param-value&gt;
      &lt;/context-param&gt;
      &lt;servlet&gt;
          &lt;servlet-name&gt;WebServicePort&lt;/servlet-name&gt;
          &lt;!-- For Metro, use this servlet-class instead: 
               com.sun.xml.ws.transport.http.servlet.WSServlet  --&gt;
          &lt;servlet-class&gt;org.apache.cxf.transport.servlet.CXFServlet&lt;/servlet-class&gt;
          &lt;load-on-startup&gt;1&lt;/load-on-startup&gt;
      &lt;/servlet&gt;
      &lt;servlet-mapping&gt;
          &lt;servlet-name&gt;WebServicePort&lt;/servlet-name&gt;
          &lt;url-pattern&gt;/services/*&lt;/url-pattern&gt;
      &lt;/servlet-mapping&gt;
      &lt;session-config&gt;
          &lt;session-timeout&gt;60&lt;/session-timeout&gt;
      &lt;/session-config&gt;
  &lt;/web-app&gt;
  </code></pre>