public UserOperationLogContextEntryBuilder inContextOf(TaskEntity task, List<PropertyChange> propertyChanges) { if (propertyChanges == null || propertyChanges.isEmpty()) { if (OPERATION_TYPE_CREATE.equals(entry.getOperationType())) { propertyChanges = Arrays.asList(PropertyChange.EMPTY_CHANGE); } } entry.setPropertyChanges(propertyChanges); ResourceDefinitionEntity definition = task.getProcessDefinition(); if (definition != null) { entry.setProcessDefinitionKey(definition.getKey()); entry.setDeploymentId(definition.getDeploymentId()); } else if (task.getCaseDefinitionId() != null) { definition = task.getCaseDefinition(); entry.setDeploymentId(definition.getDeploymentId()); } entry.setProcessDefinitionId(task.getProcessDefinitionId()); entry.setProcessInstanceId(task.getProcessInstanceId()); entry.setExecutionId(task.getExecutionId()); entry.setCaseDefinitionId(task.getCaseDefinitionId()); entry.setCaseInstanceId(task.getCaseInstanceId()); entry.setCaseExecutionId(task.getCaseExecutionId()); entry.setTaskId(task.getId()); ExecutionEntity execution = task.getExecution(); if (execution != null) { entry.setRootProcessInstanceId(execution.getRootProcessInstanceId()); } return this; }
protected String getActivityIdExceptionMessage(VariableScope variableScope) { String activityId = null; String definitionIdMessage = ""; if (variableScope instanceof DelegateExecution) { activityId = ((DelegateExecution) variableScope).getCurrentActivityId(); definitionIdMessage = " in the process definition with id '" + ((DelegateExecution) variableScope).getProcessDefinitionId() + "'"; } else if (variableScope instanceof TaskEntity) { TaskEntity task = (TaskEntity) variableScope; if (task.getExecution() != null) { activityId = task.getExecution().getActivityId(); definitionIdMessage = " in the process definition with id '" + task.getProcessDefinitionId() + "'"; } if (task.getCaseExecution() != null) { activityId = task.getCaseExecution().getActivityId(); definitionIdMessage = " in the case definition with id '" + task.getCaseDefinitionId() + "'"; } } else if (variableScope instanceof DelegateCaseExecution) { activityId = ((DelegateCaseExecution) variableScope).getActivityId(); definitionIdMessage = " in the case definition with id '" + ((DelegateCaseExecution) variableScope).getCaseDefinitionId() + "'"; } if (activityId == null) { return ""; } else { return " while executing activity '" + activityId + "'" + definitionIdMessage; } }
protected String getActivityIdExceptionMessage(VariableScope variableScope) { String activityId = null; String definitionIdMessage = ""; if (variableScope instanceof DelegateExecution) { activityId = ((DelegateExecution) variableScope).getCurrentActivityId(); definitionIdMessage = " in the process definition with id '" + ((DelegateExecution) variableScope).getProcessDefinitionId() + "'"; } else if (variableScope instanceof TaskEntity) { TaskEntity task = (TaskEntity) variableScope; if (task.getExecution() != null) { activityId = task.getExecution().getActivityId(); definitionIdMessage = " in the process definition with id '" + task.getProcessDefinitionId() + "'"; } if (task.getCaseExecution() != null) { activityId = task.getCaseExecution().getActivityId(); definitionIdMessage = " in the case definition with id '" + task.getCaseDefinitionId() + "'"; } } else if (variableScope instanceof DelegateCaseExecution) { activityId = ((DelegateCaseExecution) variableScope).getActivityId(); definitionIdMessage = " in the case definition with id '" + ((DelegateCaseExecution) variableScope).getCaseDefinitionId() + "'"; } if (activityId == null) { return ""; } else { return " while executing activity '" + activityId + "'" + definitionIdMessage; } }
public UserOperationLogContextEntryBuilder inContextOf(TaskEntity task, List<PropertyChange> propertyChanges) { if (propertyChanges == null || propertyChanges.isEmpty()) { if (OPERATION_TYPE_CREATE.equals(entry.getOperationType())) { propertyChanges = Arrays.asList(PropertyChange.EMPTY_CHANGE); } } entry.setPropertyChanges(propertyChanges); ResourceDefinitionEntity definition = task.getProcessDefinition(); if (definition != null) { entry.setProcessDefinitionKey(definition.getKey()); entry.setDeploymentId(definition.getDeploymentId()); } else if (task.getCaseDefinitionId() != null) { definition = task.getCaseDefinition(); entry.setDeploymentId(definition.getDeploymentId()); } entry.setProcessDefinitionId(task.getProcessDefinitionId()); entry.setProcessInstanceId(task.getProcessInstanceId()); entry.setExecutionId(task.getExecutionId()); entry.setCaseDefinitionId(task.getCaseDefinitionId()); entry.setCaseInstanceId(task.getCaseInstanceId()); entry.setCaseExecutionId(task.getCaseExecutionId()); entry.setTaskId(task.getId()); ExecutionEntity execution = task.getExecution(); if (execution != null) { entry.setRootProcessInstanceId(execution.getRootProcessInstanceId()); } return this; }
.findTaskById(identityLink.getTaskId()); evt.setProcessDefinitionId(task.getProcessDefinitionId());
.findTaskById(identityLink.getTaskId()); evt.setProcessDefinitionId(task.getProcessDefinitionId());
String processDefinitionId = taskEntity.getProcessDefinitionId(); String processInstanceId = taskEntity.getProcessInstanceId(); String executionId = taskEntity.getExecutionId();
String processDefinitionId = taskEntity.getProcessDefinitionId(); String processInstanceId = taskEntity.getProcessInstanceId(); String executionId = taskEntity.getExecutionId();
protected String getActivityIdExceptionMessage(VariableScope variableScope) { String activityId = null; String definitionIdMessage = ""; if (variableScope instanceof DelegateExecution) { activityId = ((DelegateExecution) variableScope).getCurrentActivityId(); definitionIdMessage = " in the process definition with id '" + ((DelegateExecution) variableScope).getProcessDefinitionId() + "'"; } else if (variableScope instanceof TaskEntity) { TaskEntity task = (TaskEntity) variableScope; if (task.getExecution() != null) { activityId = task.getExecution().getActivityId(); definitionIdMessage = " in the process definition with id '" + task.getProcessDefinitionId() + "'"; } if (task.getCaseExecution() != null) { activityId = task.getCaseExecution().getActivityId(); definitionIdMessage = " in the case definition with id '" + task.getCaseDefinitionId() + "'"; } } else if (variableScope instanceof DelegateCaseExecution) { activityId = ((DelegateCaseExecution) variableScope).getActivityId(); definitionIdMessage = " in the case definition with id '" + ((DelegateCaseExecution) variableScope).getCaseDefinitionId() + "'"; } if (activityId == null) { return ""; } else { return " while executing activity '" + activityId + "'" + definitionIdMessage; } }
public UserOperationLogContextEntryBuilder inContextOf(TaskEntity task, List<PropertyChange> propertyChanges) { if (propertyChanges == null || propertyChanges.isEmpty()) { if (OPERATION_TYPE_CREATE.equals(entry.getOperationType())) { propertyChanges = Arrays.asList(PropertyChange.EMPTY_CHANGE); } } entry.setPropertyChanges(propertyChanges); ResourceDefinitionEntity definition = task.getProcessDefinition(); if (definition != null) { entry.setProcessDefinitionKey(definition.getKey()); entry.setDeploymentId(definition.getDeploymentId()); } else if (task.getCaseDefinitionId() != null) { definition = task.getCaseDefinition(); entry.setDeploymentId(definition.getDeploymentId()); } entry.setProcessDefinitionId(task.getProcessDefinitionId()); entry.setProcessInstanceId(task.getProcessInstanceId()); entry.setExecutionId(task.getExecutionId()); entry.setCaseDefinitionId(task.getCaseDefinitionId()); entry.setCaseInstanceId(task.getCaseInstanceId()); entry.setCaseExecutionId(task.getCaseExecutionId()); entry.setTaskId(task.getId()); ExecutionEntity execution = task.getExecution(); if (execution != null) { entry.setRootProcessInstanceId(execution.getRootProcessInstanceId()); } return this; }
.findTaskById(identityLink.getTaskId()); evt.setProcessDefinitionId(task.getProcessDefinitionId());
String processDefinitionId = taskEntity.getProcessDefinitionId(); String processInstanceId = taskEntity.getProcessInstanceId(); String executionId = taskEntity.getExecutionId();