01: package demo.jms_greeter.server;
02:
03: import javax.xml.ws.Endpoint;
04:
05: public class Server {
06:
07: protected Server() throws Exception {
08: System.out.println("Starting Server");
09: Object implementor = new GreeterJMSImpl();
10: String address = "http://celtix.objectweb.org/transports/jms";
11: Endpoint.publish(address, implementor);
12: }
13:
14: public static void main(String args[]) throws Exception {
15: new Server();
16: System.out.println("Server ready...");
17:
18: Thread.sleep(125 * 60 * 1000);
19: System.out.println("Server exiting");
20: System.exit(0);
21: }
22: }
|