Shutdown embedded Jetty in Spring-Boot Application with Apache CXF -


in spring-boot application register apache-cxf soap service this:

  @bean(destroymethod = "destroy")   org.apache.cxf.endpoint.server server(myservice myservice) {     jaxwsserverfactorybean svrfactory = new jaxwsserverfactorybean();     svrfactory.setserviceclass(myservice.class);     svrfactory.setaddress("http://0.0.0.0:4711/myservice");     svrfactory.setservicebean(myservice);     svrfactory.getininterceptors().add(new loggingininterceptor());     svrfactory.getoutinterceptors().add(new loggingoutinterceptor());     return svrfactory.create();   } 

it may happen @ other places of spring configuration, context can not initialized succesfully (application startup failed) , application shutdown initiated.

unfortunately sever bean, created, stays alive , prevents application shutting down completely. thought destroymethod = "destroy" trick, destroys webapp/soap endpoint (resultig in http error 404) embedded jetty still running.

do have chance configure spring context in way prevents embedded jetty staying alive when spring context initialization failes @ point?


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

jquery - javascript onscroll fade same class but with different div -