Examples of invoke()


Examples of org.rzo.netty.ahessian.rpc.callback.ClientCallback.invoke()

    if (callback == null)
    {
      System.out.println("no callback found for "+callbackId);
      return;
    }
    callback.invoke(message);
    if (message.isDone())
    {
      _callbacks.remove(callbackId);
      //System.out.println("removed callback "+callbackId);
    }
View Full Code Here

Examples of org.serviceconnector.call.ISCMPCall.invoke()

    SCMPClnExecuteCall executeCall = new SCMPClnExecuteCall(this.requester, TestConstants.sesServerName1, this.sessionId);
    executeCall.setMessageInfo(TestConstants.echoCmd);
    ISCMPCall groupCall = executeCall.openGroup();

    TestCallback cbk = new TestCallback(true);
    groupCall.invoke(cbk, 3000);
    TestUtil.checkReply(cbk.getMessageSync(3000));

    for (int i = 0; i < TestConstants.pangram.length(); i++) {
      cbk = new TestCallback(true);
      groupCall.setRequestBody(TestConstants.pangram.subSequence(i, i + 1));
View Full Code Here

Examples of org.serviceconnector.call.SCMPAttachCall.invoke()

          this.connectionType.getValue(), this.keepAliveIntervalSeconds, 0, this.maxConnections);
      this.requester = new SCRequester(remoteNodeConf, this.keepAliveTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
      SCServiceCallback callback = new SCServiceCallback(true);
      SCMPAttachCall attachCall = new SCMPAttachCall(this.requester);
      try {
        attachCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
      } catch (Exception e) {
        this.requester.destroy();
        // release resources
        AppContext.destroy();
        throw new SCServiceException("Attach to " + host + ":" + port + " failed. ", e);
View Full Code Here

Examples of org.serviceconnector.call.SCMPCheckRegistrationCall.invoke()

    // cancel server timeout not if its running already, you might interrupt current thread
    this.cancelServerTimeout(false);
    SCMPCheckRegistrationCall checkRegistrationCall = new SCMPCheckRegistrationCall(this.requester, this.serviceName);
    SCServerCallback callback = new SCServerCallback(true);
    try {
      checkRegistrationCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
    } catch (Exception e) {
      throw new SCServiceException("Check registration failed. ", e);
    }
    SCMPMessage reply = callback.getMessageSync(operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
    if (reply.isFault()) {
View Full Code Here

Examples of org.serviceconnector.call.SCMPClnChangeSubscriptionCall.invoke()

    changeSubscriptionCall.setCompressed(scSubscribeMessage.isCompressed());
    changeSubscriptionCall.setRequestBody(scSubscribeMessage.getData());
    changeSubscriptionCall.setSessionInfo(scSubscribeMessage.getSessionInfo());
    SCServiceCallback callback = new SCServiceCallback(true);
    try {
      changeSubscriptionCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
    } catch (Exception e) {
      throw new SCServiceException("Change subscription failed.", e);
    }
    // 3. receiving reply and error handling
    SCMPMessage reply = callback.getMessageSync(operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
 
View Full Code Here

Examples of org.serviceconnector.call.SCMPClnCreateSessionCall.invoke()

    // 2. initialize call & invoke
    SCServiceCallback callback = new SCServiceCallback(true);
    SCMPClnCreateSessionCall createSessionCall = new SCMPClnCreateSessionCall(this.requester, this.serviceName);
    createSessionCall.setEchoIntervalSeconds(Constants.DEFAULT_FILE_SESSION_TIMEOUT_SECONDS);
    try {
      createSessionCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
    } catch (Exception e) {
      throw new SCServiceException("Create file session on SC failed. ", e);
    }
    // 3. receiving reply and error handling
    SCMPMessage reply = callback.getMessageSync(operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
 
View Full Code Here

Examples of org.serviceconnector.call.SCMPClnDeleteSessionCall.invoke()

    try {
      SCServiceCallback callback = new SCServiceCallback(true);
      SCMPClnDeleteSessionCall deleteSessionCall = new SCMPClnDeleteSessionCall(this.requester, this.serviceName,
          this.sessionId);
      try {
        deleteSessionCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
      } catch (Exception e) {
        // only logging the failure no further action
        LOGGER.warn("deleting file session on SC failed sid=" + sessionId + " " + e.toString());
        return;
      }
View Full Code Here

Examples of org.serviceconnector.call.SCMPClnExecuteCall.invoke()

    clnExecuteCall.setPartSize(scMessage.getPartSize());
    clnExecuteCall.setRequestBody(scMessage.getData());
    SCServiceCallback callback = new SCServiceCallback(true);
    try {
      PerformanceLogger.beginThreadBound();
      clnExecuteCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
    } catch (Exception e) {
      PerformanceLogger.endThreadBound(this.sessionId);
      throw new SCServiceException("Execute request failed. ", e);
    }
    // 3. receiving reply and error handling
View Full Code Here

Examples of org.serviceconnector.call.SCMPClnSubscribeCall.invoke()

    subscribeCall.setSessionInfo(scSubscribeMessage.getSessionInfo());
    subscribeCall.setNoDataIntervalSeconds(scSubscribeMessage.getNoDataIntervalSeconds());
    subscribeCall.setCompressed(scSubscribeMessage.isCompressed());
    subscribeCall.setRequestBody(scSubscribeMessage.getData());
    try {
      subscribeCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
    } catch (Exception e) {
      throw new SCServiceException("Subscribe failed.", e);
    }
    // 3. receiving reply and error handling
    SCMPMessage reply = callback.getMessageSync(operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
 
View Full Code Here

Examples of org.serviceconnector.call.SCMPClnUnsubscribeCall.invoke()

      SCMPClnUnsubscribeCall unsubscribeCall = new SCMPClnUnsubscribeCall(this.requester, this.serviceName, this.sessionId);
      if (scSubscribeMessage != null) {
        unsubscribeCall.setSessionInfo(scSubscribeMessage.getSessionInfo());
      }
      try {
        unsubscribeCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
      } catch (Exception e) {
        throw new SCServiceException("Unsubscribe failed.", e);
      }
      // 3. receiving reply and error handling
      SCMPMessage reply = callback.getMessageSync(operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
 
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.