Search in sources :

Example 1 with TerminateWorkflowExecutionRequest

use of com.uber.cadence.TerminateWorkflowExecutionRequest in project cadence-client by uber-java.

the class GenericWorkflowClientExternalImpl method terminateWorkflowExecution.

@Override
public void terminateWorkflowExecution(TerminateWorkflowExecutionParameters terminateParameters) {
    TerminateWorkflowExecutionRequest request = new TerminateWorkflowExecutionRequest();
    WorkflowExecution workflowExecution = terminateParameters.getWorkflowExecution();
    request.setWorkflowExecution(terminateParameters.getWorkflowExecution());
    request.setDomain(domain);
    request.setDetails(terminateParameters.getDetails());
    request.setReason(terminateParameters.getReason());
    // request.setChildPolicy(terminateParameters.getChildPolicy());
    try {
        service.TerminateWorkflowExecution(request);
    } catch (TException e) {
        throw CheckedExceptionWrapper.wrap(e);
    }
}
Also used : TException(org.apache.thrift.TException) WorkflowExecution(com.uber.cadence.WorkflowExecution) TerminateWorkflowExecutionRequest(com.uber.cadence.TerminateWorkflowExecutionRequest)

Aggregations

TerminateWorkflowExecutionRequest (com.uber.cadence.TerminateWorkflowExecutionRequest)1 WorkflowExecution (com.uber.cadence.WorkflowExecution)1 TException (org.apache.thrift.TException)1