/** * Constructs a TezTaskID object from given {@link TezVertexID}. * @param vertexID the vertexID object for this TezTaskID * @param id the tip number */ public static TezTaskID getInstance(TezVertexID vertexID, int id) { Preconditions.checkArgument(vertexID != null, "vertexID cannot be null"); return tezTaskIDCache.getInstance(new TezTaskID(vertexID, id)); }
@InterfaceAudience.Private public static void clearCache() { tezVertexIDCache.clear(); }
@InterfaceAudience.Private public static void clearCache() { tezDAGIDCache.clear(); }
@InterfaceAudience.Private public static void clearCache() { tezTaskAttemptIDCache.clear(); }
@InterfaceAudience.Private public static void clearCache() { tezTaskIDCache.clear(); }
/** * Constructs a TaskAttemptID object from given {@link TezTaskID}. * @param taskID TaskID that this task belongs to * @param id the task attempt number */ public static TezTaskAttemptID getInstance(TezTaskID taskID, int id) { return tezTaskAttemptIDCache.getInstance(new TezTaskAttemptID(taskID, id)); }
/** * Get a DAGID object from given {@link ApplicationId}. * @param applicationId Application that this dag belongs to * @param id the dag number */ public static TezDAGID getInstance(ApplicationId applicationId, int id) { // The newly created TezDAGIds are primarily for their hashCode method, and // will be short-lived. // Alternately the cache can be keyed by the hash of the incoming paramters. Preconditions.checkArgument(applicationId != null, "ApplicationID cannot be null"); return tezDAGIDCache.getInstance(new TezDAGID(applicationId, id)); }
/** * Constructs a TezVertexID object from given {@link TezDAGID}. * @param dagId TezDAGID object for this TezVertexID * @param id the tip number */ public static TezVertexID getInstance(TezDAGID dagId, int id) { Preconditions.checkArgument(dagId != null, "DagID cannot be null"); return tezVertexIDCache.getInstance(new TezVertexID(dagId, id)); }
/** * Get a DAGID object from given parts. * @param yarnRMIdentifier YARN RM identifier * @param appId application number * @param id the dag number */ public static TezDAGID getInstance(String yarnRMIdentifier, int appId, int id) { // The newly created TezDAGIds are primarily for their hashCode method, and // will be short-lived. // Alternately the cache can be keyed by the hash of the incoming paramters. Preconditions.checkArgument(yarnRMIdentifier != null, "yarnRMIdentifier cannot be null"); return tezDAGIDCache.getInstance(new TezDAGID(yarnRMIdentifier, appId, id)); }