Package org.serviceconnector.api.cln

Examples of org.serviceconnector.api.cln.SCClient.attach()


   * Expectation: clients get a not found error, passes
   */
  @Test
  public void t95_TwoSubscribersServerGetsDestroyed() throws Exception {
    SCClient client2 = new SCClient(TestConstants.HOST, TestConstants.PORT_SC1_TCP, ConnectionType.NETTY_TCP);
    client2.attach();
    SCPublishService service1 = client.newPublishService(TestConstants.pubServiceName1);
    SCPublishService service2 = client2.newPublishService(TestConstants.pubServiceName1);

    SCSubscribeMessage subMsgRequest = new SCSubscribeMessage(TestConstants.pangram);
    subMsgRequest.setDataLength(TestConstants.pangram.length());
View Full Code Here


   */
  @Test
  public void t30_cc_2Clients1Cache() throws Exception {
    // 1: connect new client2 to top level (cascaded) SC
    SCClient client2 = new SCClient(TestConstants.HOST, sessionClient.getPort(), ConnectionType.NETTY_TCP);
    client2.attach();
    SCSessionService sessionService2 = client2.newSessionService(TestConstants.sesServiceName1);
    sessionService2.createSession(new SCMessage(), new SessionMsgCallback(sessionService2));

    // 2: load data to cache (cid=700) by client1
    SCMessage request = new SCMessage();
View Full Code Here

   */
  @Test
  public void t31_cc_2Clients1Cache() throws Exception {
    // 1: connect new client2 to top level (cascaded) SC
    SCClient client2 = new SCClient(TestConstants.HOST, sessionClient.getPort(), ConnectionType.NETTY_TCP);
    client2.attach();
    SCSessionService sessionService2 = client2.newSessionService(TestConstants.sesServiceName1);
    sessionService2.createSession(new SCMessage(), new SessionMsgCallback(sessionService2));

    // 2: load data to cache (cid=700) by client1
    SCMessage request = new SCMessage();
View Full Code Here

   */
  @Test
  public void t32_cc_2Clients1Cache() throws Exception {
    // 1: connect new client2 to top level (cascaded) SC
    SCClient client2 = new SCClient(TestConstants.HOST, sessionClient.getPort(), ConnectionType.NETTY_TCP);
    client2.attach();
    SCSessionService sessionService2 = client2.newSessionService(TestConstants.sesServiceName1);
    sessionService2.createSession(new SCMessage(), new SessionMsgCallback(sessionService2));

    // 2: load data to cache (cid=700) by client1
    SCMessage request = new SCMessage();
View Full Code Here

   */
  @Test
  public void t33_cc_2Clients2Server1Cache() throws Exception {
    // 1: connect new client2 to top level (cascaded) SC
    SCClient client2 = new SCClient(TestConstants.HOST, sessionClient.getPort(), ConnectionType.NETTY_TCP);
    client2.attach();
    SCSessionService sessionService2 = client2.newSessionService(TestConstants.sesServiceName1);
    sessionService2.createSession(new SCMessage(), new SessionMsgCallback(sessionService2));

    // 2: load data to cache (cid=700) by client1
    SCMessage request = new SCMessage();
View Full Code Here

   */
  @Test
  public void t34_cc_2Clients2Server1Cache() throws Exception {
    // 1: connect new client2 to top level (cascaded) SC
    SCClient client2 = new SCClient(TestConstants.HOST, sessionClient.getPort(), ConnectionType.NETTY_TCP);
    client2.attach();
    SCSessionService sessionService2 = client2.newSessionService(TestConstants.sesServiceName1);
    sessionService2.createSession(new SCMessage(), new SessionMsgCallback(sessionService2));

    // 2: load data to cache (cid=700) by client1
    SCMessage request = new SCMessage();
View Full Code Here

   */
  @Test
  public void t34_cc_2Clients2Server1Cache30000Msgs() throws Exception {
    // 1: connect new client2 to top level (cascaded) SC
    SCClient client2 = new SCClient(TestConstants.HOST, sessionClient.getPort(), ConnectionType.NETTY_TCP);
    client2.attach();
    SCSessionService sessionService2 = client2.newSessionService(TestConstants.sesServiceName1);
    sessionService2.createSession(new SCMessage(), new SessionMsgCallback(sessionService2));

    // 2: load data to cache (cid=700) by client1
    SCMessage request = new SCMessage();
View Full Code Here

    SCClient sc = new SCClient(hostToConnect, portToConnect, conType);

    try {
      sc.setMaxConnections(20);
      sc.setKeepAliveIntervalSeconds(30);
      sc.attach();

      LOGGER.info("FileUploader attached to: " + hostToConnect + ":" + portToConnect + " " + conType + " - " + serviceName);
      SCFileService service = sc.newFileService(serviceName);

      switch (function) {
View Full Code Here

  @Override
  public void run() {
    SCClient client = new SCClient(TestConstants.HOST, TestConstants.PORT_SC0_TCP, ConnectionType.NETTY_TCP);

    try {
      client.attach();

      if (getMethodName() == "createSession_whiteSpaceSessionInfo_sessionIdIsNotEmpty") {
        SCSessionService sessionService = client.newSessionService(TestConstants.sesServiceName1);
        SCMessage scMessage = new SCMessage();
        scMessage.setSessionInfo(" ");
View Full Code Here

  @Override
  public void run() {
    SCClient sc = new SCClient(TestConstants.HOST, TestConstants.PORT_SC0_TCP, ConnectionType.NETTY_TCP);

    try {
      sc.attach();

      SCSubscribeMessage subscibeMessage = new SCSubscribeMessage();
      subscibeMessage.setMask(TestConstants.mask);
      subscibeMessage.setSessionInfo("sessionInfo");
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.