sadanand48 commented on code in PR #11962:
URL: https://github.com/apache/ozone/pull/11962#discussion_r4512160366
##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/statemachine/StateContext.java:
##########
@@ -466,6 +515,141 @@ List<Message> getIncrementalReports(
return reportsToReturn;
}
+ private List<Message> getIncrementalReportsExcludingCommandStatus(
+ HostAndPort endpoint, int maxLimit) {
+ List<Message> reportsToReturn = new LinkedList<>();
+ synchronized (incrementalReportsQueue) {
+ List<Message> reportsForEndpoint =
+ incrementalReportsQueue.get(endpoint);
+ if (reportsForEndpoint != null) {
+ Iterator<Message> iterator = reportsForEndpoint.iterator();
+ while (iterator.hasNext() && reportsToReturn.size() < maxLimit) {
+ Message report = iterator.next();
+ if (!(report instanceof CommandStatusReportsProto)) {
+ reportsToReturn.add(report);
+ iterator.remove();
+ }
+ }
+ }
+ }
+ return reportsToReturn;
+ }
+
+ private CommandStatusReportSplit splitCommandStatusReport(
Review Comment:
The intention is to limit command-status/delete-ACK data in each heartbeat.
We do not split an individual command response. CommandStatusReportsProto is an
aggregate containing repeated CommandStatus entries, potentially for multiple
SCM commands. The split occurs only between those entries, while each
CommandStatus and its complete blockDeletionAck.results remain atomic.
Even if every response is similar in size to its SCM command, their
aggregate can exceed the heartbeat budget.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]