Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Worker Jobs: track process run per worker #107

Merged
merged 1 commit into from
Jun 28, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -320,11 +320,11 @@ public void notify(final DelegateExecution execution) throws Exception {
log.error("procDefKey unable to be determined!");
}
log.trace("sendProcEventTopicMessageWithRetries");
//String startedOnWorkerId = execution.getVariable("startedOnWorkerId").toString();
//if (startedOnWorkerId != null && !startedOnWorkerId.equals(workerId)) {
// log.trace("Started on worker != ended on worker");
//}

String startedOnWorkerId = execution.getVariable("startedOnWorkerId").toString();
if (startedOnWorkerId != null && !startedOnWorkerId.equals(workerId)) {
log.debug("PROCESS '" + procDefKey + "' - Started on worker[" + startedOnWorkerId + "] != ended[" + workerId + "] on worker");
}
// FIXME: UUID might not be right
if (execution.getVariable("uuid") != null) {
processService.sendProcEventTopicMessageWithRetries(
Expand All @@ -333,6 +333,8 @@ public void notify(final DelegateExecution execution) throws Exception {
procDefKey,
repositoryService.getProcessDefinition(execution.getProcessDefinitionId()).getDeploymentId(),
"processEndEventDetected");
} else {
log.warn("WARNING: UUID of an instance of procDef '" + procDefKey + "' cannot be found. ");
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public boolean canAcceptMoreWork() {

return locked < numCores;
} catch (Exception e) {
// We don't really care if this fails
log.error("Exception canAcceptMoreWork: ", e);
return false;
}
}
Expand Down