public JobConf initializeVertexConf(JobConf conf, Context context, BaseWork work) {

    // simply dispatch the call to the right method for the actual (sub-) type of
    // BaseWork.
    if (work instanceof MapWork) {
      return initializeVertexConf(conf, context, (MapWork)work);
    } else if (work instanceof ReduceWork) {
      return initializeVertexConf(conf, context, (ReduceWork)work);
    } else if (work instanceof MergeJoinWork) {
      return initializeVertexConf(conf, context, (MergeJoinWork) work);
    } else {
      assert false;
      return null;
    }
  }
Creates and initializes the JobConf object for a given BaseWork object.

@param conf Any configurations in conf will be copied to the resulting new JobConf object.
@param work BaseWork will be used to populate the configuration object.
@return JobConf new configuration object
ql/src/java/org/apache/hadoop/hive/ql/exec/tez/DagUtils.java