protected void createOutputMap() {
    Preconditions.checkState(outMap == null, "Outputs should only be setup once");
    outMap = new HashMap<>();
    for (Entry<String, LogicalOutput> entry : outputs.entrySet()) {
      TezKVOutputCollector collector = new TezKVOutputCollector(entry.getValue());
      outMap.put(entry.getKey(), collector);
    }
  }
start processing the inputs and writing output
@throws Exception
ql/src/java/org/apache/hadoop/hive/ql/exec/tez/RecordProcessor.java