Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 172327

Summary: [Progress] ProgressManager instantiates a new JobInfo when done() on an invalid job monitor is called
Product: [Eclipse Project] Platform Reporter: Alex Nan <apnan>
Component: UIAssignee: Platform UI Triaged <platform-ui-triaged>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: john.arthorne
Version: 3.2.1Keywords: helpwanted
Target Milestone: ---   
Hardware: PC   
OS: Windows 2000   
Whiteboard: stalebug

Description Alex Nan CLA 2007-01-31 10:59:43 EST
There are scenarios (see for example https://bugs.eclipse.org/bugs/show_bug.cgi?id=169219) in which clients are caching job information and calling monitor.done() on a job monitor after the job fas finished. This is causing the ProgressManager to reinitialize a JobInfo object for that particular job and generate a memory leak.
Make sure that the ProgressManager is protected against this potential memory leak.
Also document in the org.eclipse.core.runtime.jobs.Job.run(IProgressMonitor monitor) javadoc that job monitors shouldn't be used outside the scope of a job.
Thanks.
Comment 1 Susan McCourt CLA 2009-07-09 19:37:55 EDT
As per http://wiki.eclipse.org/Platform_UI/Bug_Triage_Change_2009
Comment 2 John Arthorne CLA 2009-07-10 12:00:05 EDT
>Also document in the org.eclipse.core.runtime.jobs.Job.run(IProgressMonitor
>monitor) javadoc that job monitors shouldn't be used outside the scope of a
>job.

This part of the bug has been addressed. The remaining part is to protect against ProgressManager.JobMonitor methods being called after the job is done. For example JobMonitor.done() could set a flag (done=true) and other methods could ignore progress updates when done: if (done==true) return;
Comment 3 Eclipse Webmaster CLA 2019-09-06 16:08:07 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.
Comment 4 Eclipse Genie CLA 2021-10-21 13:56:44 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.