hadoop-mapreduce-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Amareshwari Sriramadasu (JIRA)" <j...@apache.org>
Subject [jira] [Created] (MAPREDUCE-2660) MR-279: org.apache.hadoop.mapred.CombineFileInputFormat.getSplits() throws ArrayStoreException
Date Fri, 08 Jul 2011 05:29:16 GMT
MR-279: org.apache.hadoop.mapred.CombineFileInputFormat.getSplits() throws ArrayStoreException
----------------------------------------------------------------------------------------------

                 Key: MAPREDUCE-2660
                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-2660
             Project: Hadoop Map/Reduce
          Issue Type: Bug
            Reporter: Amareshwari Sriramadasu


In branch MR-279, org.apache.hadoop.mapred.getSplits() throws RuntimeException:ArrayStoreException


The following code in trunk:
{noformat}
  public InputSplit[] getSplits(JobConf job, int numSplits) 
    throws IOException {
    List<org.apache.hadoop.mapreduce.InputSplit> newStyleSplits =
      super.getSplits(new Job(job));
    InputSplit[] ret = new InputSplit[newStyleSplits.size()];
    for(int pos = 0; pos < newStyleSplits.size(); ++pos) {
      org.apache.hadoop.mapreduce.lib.input.CombineFileSplit newStyleSplit = 
        (org.apache.hadoop.mapreduce.lib.input.CombineFileSplit) newStyleSplits.get(pos);
      ret[pos] = new CombineFileSplit(job, newStyleSplit.getPaths(),
        newStyleSplit.getStartOffsets(), newStyleSplit.getLengths(),
        newStyleSplit.getLocations());
    }
    return ret;
  }
{noformat}

got changed to

{noformat}
  public InputSplit[] getSplits(JobConf job, int numSplits) 
    throws IOException {
    return super.getSplits(new Job(job)).toArray(new InputSplit[0]);
  }
{noformat}

Code in trunk works fine. We should change the code in MR-279 to the same in trunk.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message