hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Enis Soztutar (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HADOOP-2834) Iterator for MapFileOutputFormat
Date Thu, 20 Mar 2008 15:09:26 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-2834?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12580787#action_12580787
] 

Enis Soztutar commented on HADOOP-2834:
---------------------------------------

I think we can keep the iterator functionality but, name the class Reader. The Reader might
not have seek, etc, but iterating the elements *reusing* Writables will be more intuitive
in :
{code}
  MapFileOutputFormat.Reader  reader;
  K key; 
  V value;
  ...
  while(reader.next(key, value)) { 
  //use key, value
  }
{code}

than : 
{code}
Iterator<Entry<K, V>> it = MapFileOutputFormat.getIterator(path, conf);
while(it.hasNext()) {
  Entry<K, V> entry = it.next();
  // entry.getKey(); entry.getValue():
}
{code}


> Iterator for MapFileOutputFormat
> --------------------------------
>
>                 Key: HADOOP-2834
>                 URL: https://issues.apache.org/jira/browse/HADOOP-2834
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: mapred
>    Affects Versions: 0.17.0
>            Reporter: Andrzej Bialecki 
>            Assignee: Andrzej Bialecki 
>             Fix For: 0.17.0
>
>         Attachments: map-file-v2.patch, map-file-v3.patch
>
>
> MapFileOutputFormat produces output data that is sorted locally in each part-NNNNN file
- however, there is no easy way to iterate over keys from all parts in a globally ascending
order.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message