Interface JobRecordValue

All Superinterfaces:
JsonSerializable, ProcessInstanceRelated, RecordValue, RecordValueWithVariables
All Known Implementing Classes:
ImmutableJobRecordValue

@Immutable public interface JobRecordValue extends RecordValueWithVariables, ProcessInstanceRelated
Represents a job related event or command.

See JobIntent for intents.

  • Method Details

    • getType

      String getType()
      Returns:
      the type of the job
    • getCustomHeaders

      Map<String,String> getCustomHeaders()
      Returns:
      user-defined headers associated with this job
    • getWorker

      String getWorker()
      Returns:
      the assigned worker to complete the job
    • getRetries

      int getRetries()
      Returns:
      remaining retries
    • getRetryBackoff

      long getRetryBackoff()
      Returns:
      the time of backoff in milliseconds. If backoff is disabled this method returns 0 (default value).
    • getRecurringTime

      long getRecurringTime()
      Returns:
      the timestamp when this job record should be recurred. This method is used by backoff to determine the date when the job is needed to be recurred after backoff.
    • getDeadline

      long getDeadline()
      Returns:
      the unix timestamp until when the job is exclusively assigned to this worker (time unit is milliseconds since unix epoch). If the deadline is exceeded, it can happen that the job is handed to another worker and the work is performed twice. If this property is not set it will return '-1'.
    • getErrorMessage

      String getErrorMessage()
      Returns:
      the message that contains additional context of the failure/error. It is set by the job worker then the processing fails because of a technical failure or a non-technical error.
    • getErrorCode

      String getErrorCode()
      Returns:
      the error code to identify the business error. It is set by the job worker then the processing fails because of a non-technical error that should be handled by the process.
    • getElementId

      String getElementId()
      Returns:
      the element id of the corresponding service task
    • getElementInstanceKey

      long getElementInstanceKey()
      Returns:
      the element instance key of the corresponding service task
    • getBpmnProcessId

      String getBpmnProcessId()
      Returns:
      the bpmn process id of the corresponding process definition
    • getProcessDefinitionVersion

      int getProcessDefinitionVersion()
      Returns:
      the version of the corresponding process definition
    • getProcessDefinitionKey

      long getProcessDefinitionKey()
      Returns:
      the process key of the corresponding process definition