[
https://issues.apache.org/jira/browse/YARN-5350?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15385047#comment-15385047
]
Subru Krishnan commented on YARN-5350:
--------------------------------------
[~asuresh], +1 for the fix.
A minor feedback for the test:
* it would be good to add a assertion on the total number of OPPORTUNISTIC
containers.
* add another check to ensure sort order is maintained by doing a second
round of allocation and/or request for multiple OPPORTUNISTIC containers.
Thanks.
> Ensure LocalScheduler does not lose the sort order of allocatable nodes
> returned by the RM
> ------------------------------------------------------------------------------------------
>
> Key: YARN-5350
> URL: https://issues.apache.org/jira/browse/YARN-5350
> Project: Hadoop YARN
> Issue Type: Sub-task
> Reporter: Arun Suresh
> Assignee: Arun Suresh
> Fix For: 2.9.0
>
> Attachments: YARN-5350.001.patch, YARN-5350.002.patch
>
>
> The LocalScheduler receives an ordered list of nodes from the RM with each
> allocate call. This list, which is used by the LocalScheduler to allocate
> OPPORTUNISTIC containers, is sorted on the Nodes free capacity (queue length
> / wait time).
> Unfortunately, the LocalScheduler stores this list in a HashMap thereby
> losing the sort order.
> The trivial fix would be to replace the HashMap with a LinkedHashMap which
> retains the insertion order.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]