/// <summary> /// Add a resource to a job. Check whether there are clashes in resource names. /// </summary> /// <param name="jobSubmission">JobSubmission object which will hold the resources.</param> /// <param name="file">Pathname to file to add as a resource.</param> private void AddResource(IDryadLinqJobSubmission jobSubmission, string file) { // extract basename string basename = Path.GetFileName(file); this.m_jobSubmission.AddLocalFile(file); }
/// <summary> /// Create a new job executor object. /// </summary> public DryadLinqJobExecutor(DryadLinqContext context) { // use a new job submission object for each query this.m_context = context; this.m_currentStatus = JobStatus.NotSubmitted; if (context.LocalExecution) { this.m_jobSubmission = new LocalJobSubmission(context); } else { this.m_jobSubmission = new YarnJobSubmission(context); } }
/// <summary> /// Create a new job executor object. /// </summary> public DryadLinqJobExecutor(DryadLinqContext context) { // use a new job submission object for each query this.m_context = context; this.m_currentStatus = JobStatus.NotSubmitted; if (context.PlatformKind == PlatformKind.LOCAL) { this.m_jobSubmission = new LocalJobSubmission(context); } else { this.m_jobSubmission = new YarnJobSubmission( context, context.Cluster.MakeInternalClusterUri("tmp", "staging")); } }
/// <summary> /// Add a resource to a job. Check whether there are clashes in resource names. /// </summary> /// <param name="jobSubmission">JobSubmission object which will hold the resources.</param> /// <param name="file">Pathname to file to add as a resource.</param> private void AddResource(IDryadLinqJobSubmission jobSubmission, string file) { this.m_jobSubmission.AddLocalFile(file); }