title: CXF-WS integration with spring boot (jhipster stack)
body: <p>I try to integrate CXF WS to jhipster stack, so avoid xml configuration.</p>
  
  <p>The first class to config service</p>
  
  <pre><code>@EnableWs
  @Configuration
  @AutoConfigureAfter(WebConfigurer.class)
  public class WebServiceConfig extends WsConfigurerAdapter {
  
      @Bean
      public ServletRegistrationBean dispatcherServlet() {
          CXFServlet cxfServlet = new CXFServlet();
          return new ServletRegistrationBean(cxfServlet, "/soap/*");
      }
  
      @Bean(name = "cxf")
      public SpringBus springBus() {
          return new SpringBus();
      }
  
      @Bean
      public Hello hello() {
          return new HelloPortImpl();
      }
  
      @Bean
      public Endpoint endpoint() {
          EndpointImpl endpoint = new EndpointImpl(springBus(), hello());
          endpoint.publish("/hello");
          return endpoint;
      }
  }
  </code></pre>
  
  <p>The second file :</p>
  
  <pre><code>@WebService(targetNamespace = "http://service.ws.sample/", name = "Hello")
  public interface Hello {
  
  
      @WebResult(name = "return", targetNamespace = "")
      @RequestWrapper(localName = "sayHello", targetNamespace = "http://service.ws.sample/", className = "com.orange.api.rfid.tacites.proxyauth.web.restWS.SayHello")
      @WebMethod(action = "urn:SayHello")
      @ResponseWrapper(localName = "sayHelloResponse", targetNamespace = "http://service.ws.sample/", className = "com.orange.api.rfid.tacites.proxyauth.web.restWS.SayHelloResponse")
      public java.lang.String sayHello(
          @WebParam(name = "myname", targetNamespace = "")
          java.lang.String myname
      );
  }
  </code></pre>
  
  <p>The third file</p>
  
  <pre><code>@javax.jws.WebService(
      serviceName = "HelloService",
      portName = "HelloPort",
      targetNamespace = "http://service.ws.sample/",
      endpointInterface = "com.orange.api.rfid.tacites.proxyauth.web.restWS.Hello")
  
  
  public class HelloPortImpl implements Hello {
  
      private static final Logger LOG = Logger.getLogger(HelloPortImpl.class.getName());
  
      public java.lang.String sayHello(java.lang.String myname) {
          LOG.info("Executing operation sayHello" + myname);
          try {
              return "Welcome to CXF Spring boot " + myname + "!!!";
          } catch (java.lang.Exception ex) {
              ex.printStackTrace();
              throw new RuntimeException(ex);
          }
      }
  }
  </code></pre>
  
  <p>In my logs when start spring boot, i have this line:</p>
  
  <pre><code>[DEBUG] com.sun.xml.bind.v2.schemagen.XmlSchemaGenerator - Wrigin XML Schema for com.sun.xml.bind.v2.schemagen.XmlSchemaGenerator@6a08fd54[http://service.ws.sample/=com.sun.xml.bind.v2.schemagen.XmlSchemaGenerator$Namespace@76617add]
  com.sun.xml.bind.v2.util.StackRecorder: null
      at com.sun.xml.bind.v2.schemagen.XmlSchemaGenerator.write(XmlSchemaGenerator.java:441) [jaxb-impl-2.2.jar:2.2]
  </code></pre>
  
  <p>The problem is Jhipster index.html is not found and in <a href="http://localhost:8080/soap/hello" rel="nofollow">http://localhost:8080/soap/hello</a> i have No binding operation info while invoking unknown method with params unknown</p>
  
  <p>I think the cxf servlet kill first one servlet, how to configure to coexist both?</p>
  
  <p>Regards</p>