adoroszlai commented on a change in pull request #1610:
URL: https://github.com/apache/ozone/pull/1610#discussion_r533323808
##########
File path:
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/KeyManagerImpl.java
##########
@@ -2322,21 +2322,22 @@ void sortDatanodes(String clientMachine, OmKeyInfo...
keyInfos) {
}
for (OmKeyLocationInfo k : key.getLocationList()) {
Pipeline pipeline = k.getPipeline();
- PipelineID pipelineId = pipeline.getId();
- List<DatanodeDetails> sortedNodes = sortedPipelines.get(pipelineId);
+ List<DatanodeDetails> nodes = pipeline.getNodes();
+ List<String> uuidList = toNodeUuid(nodes);
+ Set<String> uuidSet = new HashSet<>(uuidList);
Review comment:
I tried that first. The problem is we'd need to return a sorted set
(for setting up reproducible expectations in unit tests), which somewhat goes
against the goal of optimization.
----------------------------------------------------------------
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]