Examples of SHUFFLE


Examples of org.apache.hadoop.mapreduce.task.reduce.Shuffle

      Class combinerClass = conf.getCombinerClass();
      CombineOutputCollector combineCollector =
        (null != combinerClass) ?
            new CombineOutputCollector(reduceCombineOutputCounter) : null;

      Shuffle shuffle =
        new Shuffle(getTaskID(), job, FileSystem.getLocal(job), umbilical,
                    super.lDirAlloc, reporter, codec,
                    combinerClass, combineCollector,
                    spilledRecordsCounter, reduceCombineInputCounter,
                    shuffledMapsCounter,
                    reduceShuffleBytes, failedShuffleCounter,
                    mergedMapOutputsCounter,
                    taskStatus, copyPhase, sortPhase, this);
      rIter = shuffle.run();
    } else {
      final FileSystem rfs = FileSystem.getLocal(job).getRaw();
      rIter = Merger.merge(job, rfs, job.getMapOutputKeyClass(),
                           job.getMapOutputValueClass(), codec,
                           getMapFiles(rfs, true),
View Full Code Here

Examples of org.apache.hadoop.mapreduce.task.reduce.Shuffle

      Class combinerClass = conf.getCombinerClass();
      CombineOutputCollector combineCollector =
        (null != combinerClass) ?
        new CombineOutputCollector(reduceCombineOutputCounter, reporter, conf) : null;

      Shuffle shuffle =
        new Shuffle(getTaskID(), job, FileSystem.getLocal(job), umbilical,
                    super.lDirAlloc, reporter, codec,
                    combinerClass, combineCollector,
                    spilledRecordsCounter, reduceCombineInputCounter,
                    shuffledMapsCounter,
                    reduceShuffleBytes, failedShuffleCounter,
                    mergedMapOutputsCounter,
                    taskStatus, copyPhase, sortPhase, this,
                    mapOutputFile);
      rIter = shuffle.run();
    } else {
      // local job runner doesn't have a copy phase
      copyPhase.complete();
      final FileSystem rfs = FileSystem.getLocal(job).getRaw();
      rIter = Merger.merge(job, rfs, job.getMapOutputKeyClass(),
View Full Code Here

Examples of org.apache.hadoop.mapreduce.task.reduce.Shuffle

      Class combinerClass = conf.getCombinerClass();
      CombineOutputCollector combineCollector =
        (null != combinerClass) ?
        new CombineOutputCollector(reduceCombineOutputCounter, reporter, conf) : null;

      Shuffle shuffle =
        new Shuffle(getTaskID(), job, FileSystem.getLocal(job), umbilical,
                    super.lDirAlloc, reporter, codec,
                    combinerClass, combineCollector,
                    spilledRecordsCounter, reduceCombineInputCounter,
                    shuffledMapsCounter,
                    reduceShuffleBytes, failedShuffleCounter,
                    mergedMapOutputsCounter,
                    taskStatus, copyPhase, sortPhase, this,
                    mapOutputFile);
      rIter = shuffle.run();
    } else {
      // local job runner doesn't have a copy phase
      copyPhase.complete();
      final FileSystem rfs = FileSystem.getLocal(job).getRaw();
      rIter = Merger.merge(job, rfs, job.getMapOutputKeyClass(),
View Full Code Here

Examples of org.apache.hadoop.mapreduce.task.reduce.Shuffle

      Class combinerClass = conf.getCombinerClass();
      CombineOutputCollector combineCollector =
        (null != combinerClass) ?
            new CombineOutputCollector(reduceCombineOutputCounter) : null;

      Shuffle shuffle =
        new Shuffle(getTaskID(), job, FileSystem.getLocal(job), umbilical,
                    super.lDirAlloc, reporter, codec,
                    combinerClass, combineCollector,
                    spilledRecordsCounter, reduceCombineInputCounter,
                    shuffledMapsCounter,
                    reduceShuffleBytes, failedShuffleCounter,
                    mergedMapOutputsCounter,
                    taskStatus, copyPhase, sortPhase, this);
      rIter = shuffle.run();
    } else {
      final FileSystem rfs = FileSystem.getLocal(job).getRaw();
      rIter = Merger.merge(job, rfs, job.getMapOutputKeyClass(),
                           job.getMapOutputValueClass(), codec,
                           getMapFiles(rfs, true),
View Full Code Here

Examples of org.apache.tez.runtime.library.common.shuffle.impl.Shuffle

  @Override
  public synchronized void start() throws IOException {
    if (!isStarted.get()) {
      memoryUpdateCallbackHandler.validateUpdateReceived();
      // Start the shuffle - copy and merge
      shuffle = new Shuffle(getContext(), conf, getNumPhysicalInputs(), memoryUpdateCallbackHandler.getMemoryAssigned());
      shuffle.run();
      if (LOG.isDebugEnabled()) {
        LOG.debug("Initialized the handlers in shuffle..Safe to start processing..");
      }
      List<Event> pending = new LinkedList<Event>();
View Full Code Here

Examples of org.apache.tez.runtime.library.common.shuffle.impl.Shuffle

   * @throws IOException
   * @throws InterruptedException
   */
  public void waitForInputReady() throws IOException, InterruptedException, TezException {
    // Cannot synchronize entire method since this is called form user code and can block.
    Shuffle localShuffleCopy = null;
    synchronized (this) {
      Preconditions.checkState(isStarted.get(), "Must start input before invoking this method");
      if (getNumPhysicalInputs() == 0) {
        return;
      }
      localShuffleCopy = shuffle;
    }

    TezRawKeyValueIterator localRawIter = localShuffleCopy.waitForInput();
    synchronized(this) {
      rawIter = localRawIter;
      createValuesIterator();
    }
  }
View Full Code Here

Examples of org.apache.tez.runtime.library.common.shuffle.impl.Shuffle

    this.inputKeyCounter = inputContext.getCounters().findCounter(TaskCounter.REDUCE_INPUT_GROUPS);
    this.inputValueCounter = inputContext.getCounters().findCounter(
        TaskCounter.REDUCE_INPUT_RECORDS);
    this.conf.setStrings(TezJobConfig.LOCAL_DIRS, inputContext.getWorkDirs());

    shuffle = new Shuffle(inputContext, this.conf, numInputs);
    return Collections.emptyList();
  }
View Full Code Here

Examples of org.apache.tez.runtime.library.common.shuffle.impl.Shuffle

    this.inputValueCounter = inputContext.getCounters().findCounter(TaskCounter.REDUCE_INPUT_RECORDS);
    this.conf.setStrings(TezJobConfig.LOCAL_DIRS,
        inputContext.getWorkDirs());

    // Start the shuffle - copy and merge.
    shuffle = new Shuffle(inputContext, this.conf, numInputs);
    shuffle.run();

    return Collections.emptyList();
  }
View Full Code Here

Examples of org.apache.tez.runtime.library.common.shuffle.impl.Shuffle

  @Override
  public synchronized void start() throws IOException {
    if (!isStarted.get()) {
      memoryUpdateCallbackHandler.validateUpdateReceived();
      // Start the shuffle - copy and merge
      shuffle = new Shuffle(inputContext, conf, numInputs, memoryUpdateCallbackHandler.getMemoryAssigned());
      shuffle.run();
      if (LOG.isDebugEnabled()) {
        LOG.debug("Initialized the handlers in shuffle..Safe to start processing..");
      }
      List<Event> pending = new LinkedList<Event>();
View Full Code Here

Examples of org.apache.tez.runtime.library.common.shuffle.impl.Shuffle

   * @throws IOException
   * @throws InterruptedException
   */
  public void waitForInputReady() throws IOException, InterruptedException {
    // Cannot synchronize entire method since this is called form user code and can block.
    Shuffle localShuffleCopy = null;
    synchronized (this) {
      Preconditions.checkState(isStarted.get(), "Must start input before invoking this method");
      if (this.numInputs == 0) {
        return;
      }
      localShuffleCopy = shuffle;
    }
   
    TezRawKeyValueIterator localRawIter = localShuffleCopy.waitForInput();
    synchronized(this) {
      rawIter = localRawIter;
      createValuesIterator();
    }
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.