Package org.serviceconnector.call

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


  private String manageCall(int operationTimeoutSeconds, String instruction) throws SCServiceException {
    SCMPManageCall manageCall = new SCMPManageCall(this.requester);
    SCServiceCallback callback = new SCServiceCallback(true);
    try {
      manageCall.setRequestBody(instruction);
      manageCall.invoke(callback, operationTimeoutSeconds * Constants.SEC_TO_MILLISEC_FACTOR);
    } catch (Exception e) {
      this.requester.destroy();
      throw new SCServiceException(instruction + " SC failed.", e);
    }
    if (instruction.equalsIgnoreCase(Constants.CC_CMD_KILL)) {
View Full Code Here


    TestCallback cbk = new TestCallback();

    // disable service
    manageCall.setRequestBody(Constants.CC_CMD_DISABLE + Constants.QUESTION_MARK + Constants.SERVICE_NAME
        + Constants.EQUAL_SIGN + TestConstants.sesServerName1);
    manageCall.invoke(cbk, 1000);
    SCMPMessage result = cbk.getMessageSync(3000);
    TestUtil.checkReply(result);
    // try to create a session on disabled service - should fail
    SCMPMessage fault = this.clnCreateSession();
    TestUtil.verifyError(fault, SCMPError.SERVICE_DISABLED, SCMPMsgType.CLN_CREATE_SESSION);
View Full Code Here

    TestUtil.verifyError(fault, SCMPError.SERVICE_DISABLED, SCMPMsgType.CLN_CREATE_SESSION);

    // enable service
    manageCall.setRequestBody(Constants.CC_CMD_ENABLE + Constants.QUESTION_MARK + Constants.SERVICE_NAME + Constants.EQUAL_SIGN
        + TestConstants.sesServerName1);
    manageCall.invoke(cbk, 1000);
    result = cbk.getMessageSync(3000);
    TestUtil.checkReply(result);
  }

  /**
 
View Full Code Here

    TestCallback cbk = new TestCallback();

    // disable service
    manageCall.setRequestBody(Constants.CC_CMD_DISABLE + Constants.QUESTION_MARK + Constants.SERVICE_NAME
        + Constants.EQUAL_SIGN + TestConstants.sesServerName1);
    manageCall.invoke(cbk, 1000);
    SCMPMessage result = cbk.getMessageSync(3000);
    TestUtil.checkReply(result);

    // state of enableService
    SCMPInspectCall inspectCall = new SCMPInspectCall(this.requester);
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.