Examples of TezContext


Examples of org.apache.hadoop.hive.ql.exec.tez.TezContext

  }

  public static MapredContext init(boolean isMap, JobConf jobConf) {
    MapredContext context =
        HiveConf.getVar(jobConf, ConfVars.HIVE_EXECUTION_ENGINE).equals("tez") ?
            new TezContext(isMap, jobConf) : new MapredContext(isMap, jobConf);
    contexts.set(context);
    return context;
  }
View Full Code Here

Examples of org.apache.hadoop.hive.ql.exec.tez.TezContext

  }

  @Override
  public void closeOp(boolean abort) throws HiveException {
    if (!abort) {
      TezContext context = (TezContext) TezContext.get();

      String vertexName = getConf().getVertexName();
      String inputName = getConf().getInputName();

      byte[] payload = null;

      if (hasReachedMaxSize) {
        initDataBuffer(true);
      }

      payload = new byte[buffer.getLength()];
      System.arraycopy(buffer.getData(), 0, payload, 0, buffer.getLength());

      Event event =
          InputInitializerEvent.create(vertexName, inputName,
              ByteBuffer.wrap(payload, 0, payload.length));

      LOG.info("Sending Tez event to vertex = " + vertexName + ", input = " + inputName
          + ". Payload size = " + payload.length);

      context.getTezProcessorContext().sendEvents(Collections.singletonList(event));
    }
  }
View Full Code Here

Examples of org.apache.hadoop.hive.ql.exec.tez.TezContext

  }

  public static MapredContext init(boolean isMap, JobConf jobConf) {
    MapredContext context =
        HiveConf.getVar(jobConf, ConfVars.HIVE_EXECUTION_ENGINE).equals("tez") ?
            new TezContext(isMap, jobConf) : new MapredContext(isMap, jobConf);
    contexts.set(context);
    return context;
  }
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.