hadoop-mapreduce-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MAPREDUCE-5136) TestJobImpl->testJobNoTasks fails with IBM JAVA
Date Fri, 12 Apr 2013 13:08:18 GMT

    [ https://issues.apache.org/jira/browse/MAPREDUCE-5136?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13630035#comment-13630035
] 

Hudson commented on MAPREDUCE-5136:
-----------------------------------

Integrated in Hadoop-Hdfs-trunk #1370 (See [https://builds.apache.org/job/Hadoop-Hdfs-trunk/1370/])
    MAPREDUCE-5136. TestJobImpl->testJobNoTasks fails with IBM JAVA. Contributed by Amir
Sanjar (Revision 1467061)

     Result = FAILURE
jlowe : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1467061
Files : 
* /hadoop/common/trunk/hadoop-mapreduce-project/CHANGES.txt
* /hadoop/common/trunk/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/test/java/org/apache/hadoop/mapreduce/v2/app/job/impl/TestJobImpl.java

                
> TestJobImpl->testJobNoTasks fails with IBM JAVA
> -----------------------------------------------
>
>                 Key: MAPREDUCE-5136
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-5136
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>    Affects Versions: 2.0.3-alpha
>         Environment: Linux + IBM JAVA 6
>            Reporter: Amir Sanjar
>            Assignee: Amir Sanjar
>             Fix For: 2.0.5-beta
>
>         Attachments: MAPREDUCE-5136.patch
>
>
> I am not sure if this is a testcase or a design issue. During execution of TestJobImpl->testJobNoTasks()
there is an assertion made based on the order of key/value pairs stored in adjacency list.
However adjacency list was created by Configuration->getValByRegex() as a HashMap (order
is not guaranteed):
> Testcase:
>     JobSubmittedEventHandler jseHandler = new JobSubmittedEventHandler("testId",
>         "testName", "testNodeName", "\"key2\"=\"value2\" \"key1\"=\"value1\" ");
>    ....
>    ....
>     try {
>       Assert.assertTrue(jseHandler.getAssertValue()); <===
> Configuration->getValByRegex():
> public Map<String,String> getValByRegex(String regex) {
>     Pattern p = Pattern.compile(regex);
>     Map<String,String> result = new HashMap<String,String>(); <=======
>    
> as we all know, HashMap makes absolutely no guarantees about the iteration order. It
can (and will) even change completely when new elements are added.
> Changing HashMap to LinkedHashMap fixes the ordering inconsistency, however with a small
performance side effect. 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message