Example #1
0
        /// <summary>
        /// Try to find the job information from cluster and summary.
        /// </summary>
        /// <param name="manager">Communication manager.</param>
        protected void FindJobInfo(CommManager manager)
        {
            DryadLinqJobInfo jobinfo = DryadLinqJobInfo.CreateDryadLinqJobInfo(this.cluster, this.Summary, true, manager);

            if (jobinfo == null)
            {
                manager.Status("Cannot collect information for " + Summary.ShortName() + " to diagnose", StatusKind.Error);
                return;
            }

            this.Job        = jobinfo;
            this.StaticPlan = JobObjectModel.DryadJobStaticPlan.CreatePlan(jobinfo, manager);
        }
Example #2
0
        /// <summary>
        /// Start a job browser on the specified job.
        /// </summary>
        /// <param name="sender">Unused.</param>
        /// <param name="e">Unused.</param>
        private void jobBrowserToolStripMenuItem_Click(object sender, EventArgs e)
        {
            IEnumerable <ClusterJobInformation> ti = this.SelectedJobs();

            this.Status("Starting job browser...", StatusKind.LongOp);
            IEnumerable <DryadLinqJobSummary> jobs = ti.Select(t => t.DiscoverDryadLinqJob(this.clusterStatus, this.Status)).ToList();

            CommManager manager = new CommManager(this.Status, delegate { }, new System.Threading.CancellationTokenSource().Token);
            IEnumerable <DryadLinqJobInfo> detailed = jobs.Select(j => DryadLinqJobInfo.CreateDryadLinqJobInfo(this.clusterStatus.Config, j, false, manager));

            foreach (DryadLinqJobInfo j in detailed)
            {
                if (j == null)
                {
                    continue;
                }
                JobBrowser jb = new JobBrowser(j);
                jb.Show();
            }
            this.Status("OK", StatusKind.OK);
        }
Example #3
0
        /// <summary>
        /// Start the job browser from a job summary.
        /// </summary>
        /// <param name="js">Job summary to browse.</param>
        private void browseFromJobSummary(DryadLinqJobSummary js)
        {
            if (js == null)
            {
                return;
            }

            // TODO: this should run in the background
            CommManager      manager = new CommManager(this.Status, delegate { }, new System.Threading.CancellationTokenSource().Token);
            DryadLinqJobInfo job     = DryadLinqJobInfo.CreateDryadLinqJobInfo(this.clusterStatus.Config, js, false, manager);

            if (job != null)
            {
                JobBrowser browser = new JobBrowser(job);
                browser.Show();
                this.Status("OK", StatusKind.OK);
            }
            else
            {
                this.Status("Could not find information about job", StatusKind.Error);
            }
        }