[ 
https://issues.apache.org/jira/browse/YARN-3580?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robert Kanter updated YARN-3580:
--------------------------------
    Attachment: YARN-3580.001.patch

When setting node labels, port 0 is considered a "wildcard" port, and the 
{{CommonNodeLabelsManager}} applies the given label to all NMs that previously 
had a label on that host.  Due to the iteration ordering being different 
between JDK 7 and JDK 8, this was changing the labeling from:
{noformat:title=JDK7}
z
        host1:1
        host3:1
y
        host2:0
        host3:0
x
        host1:0
{noformat}
to
{noformat:title=JDK8}
x
        host1:1
        host1:0
y
        host3:0
        host2:0
z
        host3:1
{noformat}

The patch fixes the problem by using different port numbers.  It also cleans 
the test up a little.

> [JDK 8] TestClientRMService.testGetLabelsToNodes fails
> ------------------------------------------------------
>
>                 Key: YARN-3580
>                 URL: https://issues.apache.org/jira/browse/YARN-3580
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: test
>    Affects Versions: 2.8.0
>         Environment: JDK 8
>            Reporter: Robert Kanter
>            Assignee: Robert Kanter
>         Attachments: YARN-3580.001.patch
>
>
> When using JDK 8, {{TestClientRMService.testGetLabelsToNodes}} fails:
> {noformat}
> java.lang.AssertionError: null
>       at org.junit.Assert.fail(Assert.java:86)
>       at org.junit.Assert.assertTrue(Assert.java:41)
>       at org.junit.Assert.assertTrue(Assert.java:52)
>       at 
> org.apache.hadoop.yarn.server.resourcemanager.TestClientRMService.testGetLabelsToNodes(TestClientRMService.java:1499)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to