jiajunwang commented on a change in pull request #1532:
URL: https://github.com/apache/helix/pull/1532#discussion_r541455433
##########
File path:
helix-core/src/main/java/org/apache/helix/controller/stages/MessageOutput.java
##########
@@ -64,6 +64,18 @@ public void addMessages(String resourceName, Partition
partition,
return Collections.emptyList();
}
+ public Map<Partition, List<Message>> getResourceMessages(String
resourceName) {
+ Map<Partition, List<Message>> map = _messagesMap.get(resourceName);
+ if (map != null) {
+ return map;
+ }
+ return Collections.emptyMap();
+ }
+
+ public void addResourceMessages(String resourceName, Map<Partition,
List<Message>> resourceMessages) {
Review comment:
I understand your concern. One easy way to avoid this performance
concern, while avoiding breaking the clean API design, is pass the output into
the computePerReplicaPartitionState() methods. And inside the method, update
the messages gradually use the existing API.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]