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

Yang Tang commented on MAPREDUCE-6215:
--------------------------------------

This bug has been around for 7+ years. Running a for loop on 
{{Iterable<SortedMapWritable>}} would yield incorrect values.

It's essentially a one-line patch. Any plans to fix it?

> Map is not cleared in SortedMapWritable.readFields(DataInput in)
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-6215
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-6215
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: mrv1, mrv2
>    Affects Versions: 2.6.0
>            Reporter: Ahmed Radwan
>            Assignee: Ahmed Radwan
>            Priority: Major
>         Attachments: apache-sortedMapWritable.patch
>
>
> The readFields(DataInput in) in SortedMapWritable doesn't reset the 
> internally used SortedMap. If this Writable object is reused then entries 
> will get accumulated in the map with every call of readFields().
> I have seen this behavior when using SequenceFileInputFormat. See  
> SequenceFileRecordReader.java and SequenceFile.Reader.
>  



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

---------------------------------------------------------------------
To unsubscribe, e-mail: mapreduce-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: mapreduce-issues-h...@hadoop.apache.org

Reply via email to