gnodet-bot commented on code in PR #29658:
URL: https://github.com/apache/camel/pull/29658#discussion_r4542778663
##########
dsl/camel-jbang/camel-jbang-plugin-tui/src/main/java/org/apache/camel/dsl/jbang/core/commands/tui/StatusParser.java:
##########
@@ -478,6 +478,11 @@ private static void parseConsumers(IntegrationInfo info,
JsonObject root) {
ci.inflight = cj.getIntegerOrDefault("inflight", 0);
ci.polling = Boolean.TRUE.equals(cj.get("polling"));
ci.totalCounter = cj.getLong("totalCounter");
+ for (RouteInfo r : info.routes) {
Review Comment:
Missing `break` after a match — route IDs are unique in Camel (enforced by
`RouteDefinitionHelper.validateUniqueIds`), so at most one entry will match,
but without `break` the loop keeps comparing needlessly. The sibling
`enrichConsumersWithQuartz` method in this same file uses `break` for an
identical lookup pattern.
```suggestion
for (RouteInfo r : info.routes) {
if (r.routeId != null && r.routeId.equals(ci.id)) {
ci.total = r.total;
break;
}
}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]