Package org.serviceconnector.api.srv

Examples of org.serviceconnector.api.srv.SCSessionServerCallback


    ctrl.stopSC(scCtx);
    scCtx = ctrl.startSC(TestConstants.SC0, TestConstants.log4jSC0Properties, TestConstants.SC0Properties);
   
    Assert.assertEquals("SessionServer is not registered", true, server.isListening());
    sessionServer = server.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk = new SesSrvCallback(sessionServer);
    sessionServer.register(1, 1, cbk);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer.isRegistered());
  }
View Full Code Here


    ctrl.stopSC(scCtx);
    scCtx = ctrl.startSC(TestConstants.SC0, TestConstants.log4jSC0Properties, TestConstants.SC0Properties);
   
    Assert.assertEquals("SessionServer is not registered", true, server.isListening());
    sessionServer = server.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk = new SesSrvCallback(sessionServer);
    sessionServer.register(1, 1, cbk);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer.isRegistered());
  }
View Full Code Here

  public void t205_deregister() throws Exception {
    server = new SCServer(TestConstants.HOST, TestConstants.PORT_SC0_HTTP, TestConstants.PORT_SES_SRV_TCP, ConnectionType.NETTY_HTTP);
    server.startListener();
    Assert.assertEquals("SessionServer is not registered", true, server.isListening());
    sessionServer = server.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk = new SesSrvCallback(sessionServer);
    sessionServer.register(1, 1, cbk);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer.isRegistered());
    ctrl.stopSC(scCtx);
    scCtx = ctrl.startSC(TestConstants.SC0, TestConstants.log4jSC0Properties, TestConstants.SC0Properties);
    sessionServer.deregister();
View Full Code Here

  @Test
  public void t01_checkSessionServer() throws Exception {
    server = new SCServer(TestConstants.HOST, TestConstants.PORT_SC0_TCP, TestConstants.PORT_SES_SRV_TCP, ConnectionType.NETTY_TCP);
    server.startListener();
    sessionServer = server.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk = new SesSrvCallback(sessionServer);
    sessionServer.register(1, 1, cbk);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer.isRegistered());
    sessionServer.checkRegistration();
    Assert.assertEquals("SessionServer is not registered", true, sessionServer.isRegistered());
  }
View Full Code Here

    server1 = new SCServer(TestConstants.HOST, TestConstants.PORT_SC0_TCP, TestConstants.PORT_SES_SRV_TCP,
        ConnectionType.NETTY_TCP);
    server1.startListener();
    Assert.assertEquals("SessionServer is not listening", true, server1.isListening());
    sessionServer1 = server1.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk1 = new SesSrvCallback(sessionServer1);
    sessionServer1.register(1, 1, cbk1);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer1.isRegistered());

    server2 = new SCServer(TestConstants.HOST, TestConstants.PORT_SC0_TCP, TestConstants.PORT_SES_SRV_TCP + 1,
        ConnectionType.NETTY_TCP);
    server2.startListener();
    Assert.assertEquals("SessionServer is not listening", true, server2.isListening());
    sessionServer2 = server2.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk2 = new SesSrvCallback(sessionServer2);
    sessionServer2.register(1, 1, cbk2);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer2.isRegistered());

    sessionServer1.deregister();
    Assert.assertEquals("SessionServer is registered", false, sessionServer1.isRegistered());
View Full Code Here

    server1 = new SCServer(TestConstants.HOST, TestConstants.PORT_SC0_HTTP, TestConstants.PORT_SES_SRV_HTTP,
        ConnectionType.NETTY_HTTP);
    server1.startListener();
    Assert.assertEquals("SessionServer is not listening", true, server1.isListening());
    sessionServer1 = server1.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk1 = new SesSrvCallback(sessionServer1);
    sessionServer1.register(1, 1, cbk1);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer1.isRegistered());

    server2 = new SCServer(TestConstants.HOST, TestConstants.PORT_SC0_HTTP, TestConstants.PORT_SES_SRV_HTTP + 1,
        ConnectionType.NETTY_HTTP);
    server2.startListener();
    Assert.assertEquals("SessionServer is not listening", true, server2.isListening());
    sessionServer2 = server2.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk2 = new SesSrvCallback(sessionServer2);
    sessionServer2.register(1, 1, cbk2);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer2.isRegistered());

    sessionServer1.deregister();
    Assert.assertEquals("SessionServer is registered", false, sessionServer1.isRegistered());
View Full Code Here

    server1 = new SCServer(TestConstants.HOST, TestConstants.PORT_SC0_TCP, TestConstants.PORT_SES_SRV_TCP,
        ConnectionType.NETTY_TCP);
    server1.startListener();
    Assert.assertEquals("SessionServer is not listening", true, server1.isListening());
    sessionServer1 = server1.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk1 = new SesSrvCallback(sessionServer1);
    sessionServer1.register(1, 1, cbk1);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer1.isRegistered());

    server2 = new SCServer(TestConstants.HOST, TestConstants.PORT_SC0_HTTP, TestConstants.PORT_SES_SRV_HTTP,
        ConnectionType.NETTY_HTTP);
    server2.startListener();
    Assert.assertEquals("SessionServer is not listening", true, server2.isListening());
    sessionServer2 = server2.newSessionServer(TestConstants.sesServiceName1);
    SCSessionServerCallback cbk2 = new SesSrvCallback(sessionServer2);
    sessionServer2.register(1, 1, cbk2);
    Assert.assertEquals("SessionServer is not registered", true, sessionServer2.isRegistered());

    sessionServer1.deregister();
    Assert.assertEquals("SessionServer is registered", false, sessionServer1.isRegistered());
View Full Code Here

TOP

Related Classes of org.serviceconnector.api.srv.SCSessionServerCallback

Copyright © 2018 www.massapicom. 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.