use of org.camunda.bpm.engine.impl.incident.IncidentHandler in project camunda-bpm-platform by camunda.
the class PvmExecutionImpl method createIncident.
public Incident createIncident(String incidentType, String configuration, String message) {
IncidentContext incidentContext = new IncidentContext();
incidentContext.setTenantId(this.getTenantId());
incidentContext.setProcessDefinitionId(this.getProcessDefinitionId());
incidentContext.setExecutionId(this.getId());
incidentContext.setActivityId(this.getActivityId());
incidentContext.setConfiguration(configuration);
IncidentHandler incidentHandler = findIncidentHandler(incidentType);
if (incidentHandler == null) {
incidentHandler = new DefaultIncidentHandler(incidentType);
}
return incidentHandler.handleIncident(incidentContext, message);
}
Aggregations