hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yufei Gu (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (YARN-7270) Fix unsafe casting from long to int for class Resource and its sub-classes
Date Fri, 13 Oct 2017 20:09:00 GMT

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

Yufei Gu updated YARN-7270:
---------------------------
    Attachment: YARN-7270.branch-3.0.patch

> Fix unsafe casting from long to int for class Resource and its sub-classes
> --------------------------------------------------------------------------
>
>                 Key: YARN-7270
>                 URL: https://issues.apache.org/jira/browse/YARN-7270
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: resourcemanager
>    Affects Versions: 3.1.0
>            Reporter: Yufei Gu
>            Assignee: Yufei Gu
>             Fix For: 3.1.0
>
>         Attachments: YARN-7270.001.patch, YARN-7270.002.patch, YARN-7270.003.patch, YARN-7270.004.patch,
YARN-7270.005.patch, YARN-7270.branch-3.0.patch
>
>
> Class {{Resource}} has three sub classes(FixedValueResource, LightWeightResource, and
ResourcePBImpl). Only FixedValueResource handle long-to-int casting nicely. The other two
didn't. This bug is introduced by resource type feature and causes several unit test failures.
For example:
> {code}
> Error Message
> expected:<<memory:4096, vCores:4>> but was:<<memory:4096, vCores:-1>>
> Stacktrace
> java.lang.AssertionError: expected:<<memory:4096, vCores:4>> but was:<<memory:4096,
vCores:-1>>
> 	at org.junit.Assert.fail(Assert.java:88)
> 	at org.junit.Assert.failNotEquals(Assert.java:743)
> 	at org.junit.Assert.assertEquals(Assert.java:118)
> 	at org.junit.Assert.assertEquals(Assert.java:144)
> 	at org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.TestFSAppAttempt.testHeadroomWithBlackListedNodes(TestFSAppAttempt.java:325)
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: yarn-issues-help@hadoop.apache.org


Mime
View raw message