title: Can't find the request for URL's Observer
body: <p>i'm building my first SOAP application using Spring Boot + Apache CXF and Maven.</p>
  <p>I've followed this guide:
  <a href="https://www.baeldung.com/apache-cxf-with-spring" rel="nofollow noreferrer">https://www.baeldung.com/apache-cxf-with-spring</a></p>
  <p>Without using XML file, so at the end i have those classes:</p>
  <p><strong>DemoApplication</strong></p>
  <pre><code>@SpringBootApplication
  public class DemoApplication{
  
      public static void main(String[] args) {
          SpringApplication.run(DemoApplication.class, args);
      }
      
  }
  </code></pre>
  <p><strong>ServiceConfiguration</strong>
  @Configuration
  public class ServiceConfiguration {</p>
  <pre><code>    @Bean(name = Bus.DEFAULT_BUS_ID)
      public SpringBus springBus() {
          ServletDestinationFactory destinationFactory = new ServletDestinationFactory();
          SpringBus bus = new SpringBus();
          bus.setExtension(destinationFactory, HttpDestinationFactory.class);
          return bus;
  
      }
  
  
      @Bean
      public Endpoint endpoint() {
          EndpointImpl endpoint = new EndpointImpl(springBus(), new BaeldungImpl());
          endpoint.publish(&quot;http://localhost:8080/demo-0.0.1-SNAPSHOT&quot;);
          return endpoint;
      }
  }
  </code></pre>
  <p><strong>AppInitializer</strong></p>
  <pre><code>public class AppInitializer implements WebApplicationInitializer {
     
      @Override
      public void onStartup(ServletContext container) {
  
          AnnotationConfigWebApplicationContext context = new AnnotationConfigWebApplicationContext();
          context.register(ServiceConfiguration.class);
          
          container.addListener(new ContextLoaderListener(context));
  
          ServletRegistration.Dynamic dispatcher = container.addServlet(&quot;dispatcher&quot;, new CXFServlet());
          dispatcher.addMapping(&quot;/services/*&quot;);
      }
  }
  </code></pre>
  <p><strong>BaeldungImpl</strong></p>
  <pre><code>@WebService(endpointInterface = &quot;com.example.demo.Baeldung&quot;)
  public class BaeldungImpl  implements Baeldung {
      private int counter;
  
      @Override
      public String hello(String name) {
          return &quot;Hello &quot; + name + &quot;!&quot;;
      }
  
      @Override
      public String register(Student student) {
          counter++;
          return student.getName() + &quot; is registered student number &quot; + counter;
      }
  
      @Override
      public String ProvaServizio() {
          return &quot;&quot;;
      }
        
  }
  </code></pre>
  <p><strong>Baeldung</strong></p>
  <pre><code>@WebService
  public interface Baeldung {
      public String hello(String name);
  
      public String register(Student student);
      
      public String ProvaServizio();
  }
  </code></pre>
  <p><strong>Student</strong></p>
  <pre><code>public class Student {
      private String name;
  
      Student() {
      }
  
      public Student(String name) {
          this.name = name;
      }
  
      public String getName() {
          return name;
      }
  
      public void setName(String name) {
          this.name = name;
      }
  }
  </code></pre>
  <p>After buildin and deploying on Tomcat, following this URL i reach this:
  <a href="https://i.stack.imgur.com/d3V7z.png" rel="nofollow noreferrer">Available SOAP services:</a></p>
  <p>If i try to go further (adding /hello,/hegister or /ProvaServizio) i've got this error:</p>
  <p><strong>No service was found.</strong></p>
  <p>And the log says:</p>
  <pre><code>15:48:19.416 [http-nio-8080-exec-127] WARN org.apache.cxf.transport.servlet.ServletController - Can't find the request for http://localhost:8080/demo-0.0.1-SNAPSHOT/services/hello's Observer
  </code></pre>
  <p>Here is my POM</p>
  <pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
  &lt;project xmlns=&quot;http://maven.apache.org/POM/4.0.0&quot;
      xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;
      xsi:schemaLocation=&quot;http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd&quot;&gt;
      &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
      &lt;parent&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-parent&lt;/artifactId&gt;
          &lt;version&gt;2.4.0&lt;/version&gt;
          &lt;relativePath /&gt; &lt;!-- lookup parent from repository --&gt;
      &lt;/parent&gt;
      &lt;groupId&gt;com.example&lt;/groupId&gt;
      &lt;artifactId&gt;demo&lt;/artifactId&gt;
      &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
      &lt;packaging&gt;war&lt;/packaging&gt;
      &lt;name&gt;demo&lt;/name&gt;
      &lt;description&gt;Demo project for Spring Boot&lt;/description&gt;
  
      &lt;properties&gt;
          &lt;java.version&gt;1.8&lt;/java.version&gt;
      &lt;/properties&gt;
  
      &lt;dependencies&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter&lt;/artifactId&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-devtools&lt;/artifactId&gt;
              &lt;scope&gt;runtime&lt;/scope&gt;
              &lt;optional&gt;true&lt;/optional&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-test&lt;/artifactId&gt;
          &lt;scope&gt;test&lt;/scope&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.cxf&lt;/groupId&gt;
              &lt;artifactId&gt;cxf-rt-frontend-jaxws&lt;/artifactId&gt;
              &lt;version&gt;3.4.1&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.cxf&lt;/groupId&gt;
              &lt;artifactId&gt;cxf-rt-transports-http&lt;/artifactId&gt;
              &lt;version&gt;3.4.1&lt;/version&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework&lt;/groupId&gt;
              &lt;artifactId&gt;spring-context&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework&lt;/groupId&gt;
              &lt;artifactId&gt;spring-webmvc&lt;/artifactId&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;javax.servlet&lt;/groupId&gt;
              &lt;artifactId&gt;javax.servlet-api&lt;/artifactId&gt;
          &lt;/dependency&gt;
      &lt;/dependencies&gt;
  
      &lt;build&gt;
          &lt;plugins&gt;
              &lt;plugin&gt;
                  &lt;artifactId&gt;maven-war-plugin&lt;/artifactId&gt;
                  &lt;configuration&gt;
                      &lt;failOnMissingWebXml&gt;false&lt;/failOnMissingWebXml&gt;
                  &lt;/configuration&gt;
              &lt;/plugin&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
                  &lt;artifactId&gt;spring-boot-maven-plugin&lt;/artifactId&gt;
              &lt;/plugin&gt;
          &lt;/plugins&gt;
      &lt;/build&gt;
  
  &lt;/project&gt;
  </code></pre>