问题
Is there any Java library allowing to build a simple standalone webservice server without any application server framework?
回答1:
Java 6 contains JAX-WS, which makes it very easy to host a web service in a stand-alone application:
javax.xml.ws.Endpoint.publish("http://localhost:8000/myService/", myServiceImplementation);
回答2:
Axis 2 has a simple standalone server (see http://ws.apache.org/axis2/1_4_1/installationguide.html)
回答3:
Simple is the fastest and lightest NIO web server you will find in the Java world. About twice as fast as Jetty and a quarter the size.
回答4:
Jetty can be run embedded in a java application. Have a look at it.
来源:https://stackoverflow.com/questions/507073/lightweight-webservice-producing-in-java-without-an-application-server