org.camunda.bpm.engine.impl.cmd
Class HandleExternalTaskFailureCmd

java.lang.Object
  extended by org.camunda.bpm.engine.impl.cmd.ExternalTaskCmd
      extended by org.camunda.bpm.engine.impl.cmd.HandleExternalTaskCmd
          extended by org.camunda.bpm.engine.impl.cmd.HandleExternalTaskFailureCmd
All Implemented Interfaces:
Command<Void>

public class HandleExternalTaskFailureCmd
extends HandleExternalTaskCmd

Author:
Thorben Lindhauer, Christopher Zell, Askar Akhmerov

Field Summary
protected  String errorDetails
           
protected  String errorMessage
           
protected  int retries
           
protected  long retryDuration
           
 
Fields inherited from class org.camunda.bpm.engine.impl.cmd.HandleExternalTaskCmd
workerId
 
Fields inherited from class org.camunda.bpm.engine.impl.cmd.ExternalTaskCmd
externalTaskId
 
Constructor Summary
HandleExternalTaskFailureCmd(String externalTaskId, String workerId, String errorMessage, int retries, long retryDuration)
           
HandleExternalTaskFailureCmd(String externalTaskId, String workerId, String errorMessage, String errorDetails, int retries, long retryDuration)
          Overloaded constructor to support short and full error messages
 
Method Summary
 void execute(ExternalTaskEntity externalTask)
          Executes the specific external task commands, which belongs to the current sub class.
 String getErrorMessageOnWrongWorkerAccess()
          Returns the error message.
protected  void validateInput()
          Validates the current input of the command.
 
Methods inherited from class org.camunda.bpm.engine.impl.cmd.HandleExternalTaskCmd
execute
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

errorMessage

protected String errorMessage

errorDetails

protected String errorDetails

retryDuration

protected long retryDuration

retries

protected int retries
Constructor Detail

HandleExternalTaskFailureCmd

public HandleExternalTaskFailureCmd(String externalTaskId,
                                    String workerId,
                                    String errorMessage,
                                    int retries,
                                    long retryDuration)

HandleExternalTaskFailureCmd

public HandleExternalTaskFailureCmd(String externalTaskId,
                                    String workerId,
                                    String errorMessage,
                                    String errorDetails,
                                    int retries,
                                    long retryDuration)
Overloaded constructor to support short and full error messages

Parameters:
externalTaskId -
workerId -
errorMessage -
errorDetails -
retries -
retryDuration -
Method Detail

execute

public void execute(ExternalTaskEntity externalTask)
Description copied from class: ExternalTaskCmd
Executes the specific external task commands, which belongs to the current sub class.

Specified by:
execute in class ExternalTaskCmd
Parameters:
externalTask - the external task which is used for the command execution

validateInput

protected void validateInput()
Description copied from class: HandleExternalTaskCmd
Validates the current input of the command.

Overrides:
validateInput in class HandleExternalTaskCmd

getErrorMessageOnWrongWorkerAccess

public String getErrorMessageOnWrongWorkerAccess()
Description copied from class: HandleExternalTaskCmd
Returns the error message. Which is used to create an specific message for the BadUserRequestException if an worker has no rights to execute commands of the external task.

Specified by:
getErrorMessageOnWrongWorkerAccess in class HandleExternalTaskCmd
Returns:
the specific error message


Copyright © 2017 camunda services GmbH. All rights reserved.