This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 57016 - There should be an API for management of long running jobs/tasks
Summary: There should be an API for management of long running jobs/tasks
Status: RESOLVED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Window System (show other bugs)
Version: 4.x
Hardware: All All
: P3 blocker (vote)
Assignee: Milos Kleint
URL:
Keywords:
Depends on: 54941
Blocks: 54150
  Show dependency tree
 
Reported: 2005-03-25 16:26 UTC by _ sandipchitale
Modified: 2008-12-22 18:59 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ sandipchitale 2005-03-25 16:26:53 UTC
The long/running job will normally run in foreground meaning that the user 
will not be able to interact with the IDE. It will show % progress and/or 
messages to the user. The user should be able to cancel the job. The user 
should be able to put the job in background meaning that the user should be 
able to interact with the IDE. The user should be able to bring the background 
job back to foreground.
Comment 1 Milos Kleint 2005-03-29 06:37:14 UTC
reassigning
Comment 2 _ rkubacki 2005-03-30 20:34:36 UTC
We would like to understand to your requirements. What are actual use cases for
putting job to background/foreground. Actually we are considering not to
implement this functionality in the first version unless we find reasonable
usecases.
Comment 3 _ sandipchitale 2005-03-30 21:02:48 UTC
Basically, the jobs/tasks APIs should deal with the following concepts 
independently:

o modal vs non-modal tasks - this is more in the GUI sense. In other words 
whether the user can interact GUI wise with the rest of the IDE while the task 
is in progress.

o foreground vs background tasks - this is more from user point of view i.e. 
if the user is expressing that she is focusing on the task or not. This is 
more of an abstract notion. Depending on the task this may imply:

    - the task may run at higher vs lower priority so that it finishes
      quickly or slowly
    - the task may produce more or less verbal/animated feedback
    - the task may employ more or less resource locking
    - the task may employ a time efficient vs space efficient algorithm
    - and so on ...

o Cancellable vs non-cancellable tasks i.e. some task may be cancelled by the 
user if they are running too long. Some task may require taht they finish once 
started.

The API should provide a mechanism so that the user can shift tasks from:

- Modal to/from non-modal
- foreground to/from background

The parsing of Classpath to build the internal AST model to support 
refectoring etc is a good candidate use case to apply all these concepts to.

See the thread:

"[openide-dev] Is there an standard API for long running job/task creation, 
monitoring, foregrounding, backgrounding and termination in NetBeans?"

on the dev@openide.netbeans.org for somewhat detailed discussion on this.
Comment 4 Milos Kleint 2005-04-18 13:12:32 UTC
parts of this are covered by the progress component/api proposal. I'm still
against the foreground<->background (modal<->non-modal) switching ui. it's not
covered by the current proposal and thus won't be implemented for 4.2 at least.
Comment 5 Milos Kleint 2005-05-10 08:40:33 UTC
the progress api is integrated into trunk.

the switching from background to foreground it not implemented in the current
version and not planned in near future.
Comment 6 _ sandipchitale 2005-05-15 19:11:04 UTC
Additional info:

http://www.eclipse.org/articles/index.html

http://www.eclipsecon.org/2004/EclipseCon_2004_TechnicalTrackPresentations/39_A
rthorne-Lemieux.pdf

http://help.eclipse.org/help30/index.jsp?
topic=/org.eclipse.platform.doc.isv/guide/runtime_jobs.htm

http://help.eclipse.org/help30/index.jsp?
topic=/org.eclipse.platform.doc.isv/guide/workbench_jobs.htm