Package org.reficio.ws.server.core

Examples of org.reficio.ws.server.core.SoapServer.stop()


    public void createServer() {
        SoapServer server = SoapServer.builder()
                .httpPort(9090)
                .build();
        server.start();
        server.stop();
    }

    @Test
    public void createServer_registerAutoResponder() throws WSDLException {
        SoapServer server = SoapServer.builder()
View Full Code Here


        Wsdl parser = Wsdl.parse(wsdlUrl);
        SoapBuilder builder = parser.binding().localPart("StockQuoteSoapBinding").find();
        AutoResponder responder = new AutoResponder(builder);

        server.registerRequestResponder("/service", responder);
        server.stop();
    }

    @Test
    public void createServer_registerCustomResponder() throws WSDLException {
        SoapServer server = SoapServer.builder()
View Full Code Here

                }
            }
        };

        server.registerRequestResponder("/service", customResponder);
        server.stop();
    }

}
View Full Code Here

        SoapServer server = SoapServer.builder()
                .httpPort(port)
                .build();
        server.start();
        assertFalse(isPortAvailable(port));
        server.stop();
        assertTrue(isPortAvailable(port));
    }

    @Test
    public void startStopDestroy() {
View Full Code Here

    @Test
    public void startStopDestroy() {
        SoapServer server = getServer();
        server.start();
        server.stop();
        server.destroy();
    }

    @Test
    public void startStopDestroyCannotResurrect() {
View Full Code Here

    @Test
    public void startStopDestroyCannotResurrect() {
        SoapServer server = getServer();
        server.start();
        server.stop();
        server.destroy();
        RuntimeException caught = null;
        try {
            server.start();
        } catch (RuntimeException ex) {
View Full Code Here

                .httpsPort(9696)
                .keyStoreUrl(keyStoreUrl)
                .keyStorePassword("")
                .build();
        server.start();
        server.stop();
    }

    @Test(expected = SoapServerException.class)
    public void testServerWithKeyLessKeystore_NullPwd() {
        URL keyStoreUrl = ResourceUtils.getResourceWithAbsolutePackagePath("/keystores", "keyless.keystore");
View Full Code Here

                .httpsPort(9696)
                .keyStoreUrl(keyStoreUrl)
                .keyStorePassword(null)
                .build();
        server.start();
        server.stop();
    }

    @Test(expected = SoapServerException.class)
    public void testServerWithKeyLessKeystore_WrongPwd() {
        URL keyStoreUrl = ResourceUtils.getResourceWithAbsolutePackagePath("/keystores", "keyless.keystore");
View Full Code Here

                .httpsPort(9696)
                .keyStoreUrl(keyStoreUrl)
                .keyStorePassword("wrong_password")
                .build();
        server.start();
        server.stop();
    }

}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.