Search in sources :

Example 6 with ControlService

use of org.apache.cxf.greeter_control.ControlService in project cxf by apache.

the class FailoverTest method startTarget.

protected void startTarget(String address) throws Exception {
    ControlService cs = new ControlService();
    control = cs.getControlPort();
    updateAddressPort(control, PORT_0);
    LOG.info("starting replicated target: " + address);
    assertTrue("Failed to start greeter", control.startGreeter(address));
    targets.add(address);
}
Also used : ControlService(org.apache.cxf.greeter_control.ControlService)

Example 7 with ControlService

use of org.apache.cxf.greeter_control.ControlService in project cxf by apache.

the class ProtocolVariationsTest method initControl.

private void initControl(SpringBusFactory bf, String cfgResource) {
    controlBus = bf.createBus();
    BusFactory.setDefaultBus(controlBus);
    ControlService cs = new ControlService();
    control = cs.getControlPort();
    try {
        updateAddressPort(control, PORT);
    } catch (Exception ex) {
    // ignore
    }
    assertTrue("Failed to start greeter", control.startGreeter(cfgResource));
}
Also used : ControlService(org.apache.cxf.greeter_control.ControlService) RMException(org.apache.cxf.ws.rm.RMException)

Example 8 with ControlService

use of org.apache.cxf.greeter_control.ControlService in project cxf by apache.

the class ServiceInvocationAckBase method setupGreeter.

protected void setupGreeter(String cfgResource) throws NumberFormatException, MalformedURLException {
    SpringBusFactory bf = new SpringBusFactory();
    controlBus = bf.createBus();
    BusFactory.setDefaultBus(controlBus);
    ControlService cs = new ControlService();
    control = cs.getControlPort();
    updateAddressPort(control, getPort());
    assertTrue("Failed to start greeter", control.startGreeter(cfgResource));
    System.setProperty("db.name", getPrefix());
    greeterBus = bf.createBus(cfgResource);
    BusFactory.setDefaultBus(greeterBus);
    System.clearProperty("db.name");
    LOG.fine("Initialised greeter bus with configuration: " + cfgResource);
    GreeterService gs = new GreeterService();
    greeter = gs.getGreeterPort();
    updateAddressPort(greeter, getPort());
    LOG.fine("Created greeter client.");
}
Also used : SpringBusFactory(org.apache.cxf.bus.spring.SpringBusFactory) ControlService(org.apache.cxf.greeter_control.ControlService) GreeterService(org.apache.cxf.greeter_control.GreeterService)

Aggregations

ControlService (org.apache.cxf.greeter_control.ControlService)8 SpringBusFactory (org.apache.cxf.bus.spring.SpringBusFactory)4 GreeterService (org.apache.cxf.greeter_control.GreeterService)4 Client (org.apache.cxf.endpoint.Client)2 Control (org.apache.cxf.greeter_control.Control)2 Greeter (org.apache.cxf.greeter_control.Greeter)2 HTTPConduit (org.apache.cxf.transport.http.HTTPConduit)2 HTTPClientPolicy (org.apache.cxf.transports.http.configuration.HTTPClientPolicy)2 Closeable (java.io.Closeable)1 IOException (java.io.IOException)1 TransformerException (javax.xml.transform.TransformerException)1 Response (javax.xml.ws.Response)1 WebServiceException (javax.xml.ws.WebServiceException)1 AddressingFeature (javax.xml.ws.soap.AddressingFeature)1 SOAPFaultException (javax.xml.ws.soap.SOAPFaultException)1 Bus (org.apache.cxf.Bus)1 LoggingFeature (org.apache.cxf.ext.logging.LoggingFeature)1 GreetMeResponse (org.apache.cxf.greeter_control.types.GreetMeResponse)1 PhaseComparator (org.apache.cxf.phase.PhaseComparator)1 InMessageRecorder (org.apache.cxf.testutil.recorders.InMessageRecorder)1