Skip to content

Commit

Permalink
chore(merge): master into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
bonita-ci committed Nov 19, 2024
2 parents 4d6da42 + 6c8d70b commit c6b656a
Showing 1 changed file with 14 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3918,22 +3918,26 @@ public Map<String, Map<String, Long>> getFlownodeStateCounters(final long proces
.getNumberOfFlownodesInAllStates(
processInstanceId);
for (final SFlowNodeInstanceStateCounter nodeCounter : flownodes) {
final String flownodeName = nodeCounter.getFlownodeName();
final Map<String, Long> flownodeCounters = getFlowNodeCounters(countersForProcessInstance,
flownodeName);
flownodeCounters.put(nodeCounter.getStateName(), nodeCounter.getNumberOf());
countersForProcessInstance.put(flownodeName, flownodeCounters);
if (nodeCounter.getStateName() != null) {
final String flownodeName = nodeCounter.getFlownodeName();
final Map<String, Long> flownodeCounters = getFlowNodeCounters(countersForProcessInstance,
flownodeName);
flownodeCounters.put(nodeCounter.getStateName(), nodeCounter.getNumberOf());
countersForProcessInstance.put(flownodeName, flownodeCounters);
}
}
// Archived flownodes:
final List<SFlowNodeInstanceStateCounter> archivedFlownodes = serviceAccessor.getActivityInstanceService()
.getNumberOfArchivedFlownodesInAllStates(
processInstanceId);
for (final SFlowNodeInstanceStateCounter nodeCounter : archivedFlownodes) {
final String flownodeName = nodeCounter.getFlownodeName();
final Map<String, Long> flownodeCounters = getFlowNodeCounters(countersForProcessInstance,
flownodeName);
flownodeCounters.put(nodeCounter.getStateName(), nodeCounter.getNumberOf());
countersForProcessInstance.put(flownodeName, flownodeCounters);
if (nodeCounter.getStateName() != null) {
final String flownodeName = nodeCounter.getFlownodeName();
final Map<String, Long> flownodeCounters = getFlowNodeCounters(countersForProcessInstance,
flownodeName);
flownodeCounters.put(nodeCounter.getStateName(), nodeCounter.getNumberOf());
countersForProcessInstance.put(flownodeName, flownodeCounters);
}
}
} catch (final SProcessInstanceNotFoundException e) {
//cannot throw directly a ProcessInstanceNotFoundException to avoid API break
Expand Down

0 comments on commit c6b656a

Please sign in to comment.