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

Bug 325410

Summary: Rienas ProgressProvider clashes with JobManagerAdapter
Product: [RT] RAP Reporter: Jürgen Becker <juergen.becker>
Component: WorkbenchAssignee: Project Inbox <rap-inbox>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: christian.campo
Version: 1.4   
Target Milestone: ---   
Hardware: PC   
OS: All   
Whiteboard:
Bug Depends on:    
Bug Blocks: 324443    

Description Jürgen Becker CLA 2010-09-16 03:42:10 EDT
Riena has its own ProgressProvider (ProgressProviderBridge), which we like to override the default RAP ProgressProvider. At the moment this only possible with a little hack.
The Problem is, JobManagerAdapater not only sets the ProgressProvider (ob.getJobManager().setProgressProvider( this )) but also registers itself as a JobChangeListener (Job.getJobManager().addJobChangeListener( this)). We know this is necessary to active and deactivate the UICallback.
To completely disable the RAP behavior we also need to remove the JobChangeListener. This is only possible because the JobManager itself implements the IJobChangeListener interface. Currently do something like Job.getJobManager().removeJobChangeListener(JobManagerAdapter.getInstance()).
I regard this as a hack. If in the future the listener interface is implemented by an internal class, this would not be possible.
One simple solution could be to add a method to the JobManagerAdapter class which removes the listener. Maybe somebody else has a better idea?
Comment 1 Jürgen Becker CLA 2010-09-16 04:07:58 EDT
Another ugly thing is, that classes from Riena needs to access internal classes from RAP, which are not part of the public API.
Comment 2 Christian Campo CLA 2010-09-16 05:33:26 EDT
@Jürgen, maybe its helpful if you highlight the classes that you need access to. (highlight aka name or list them)
Comment 3 Jürgen Becker CLA 2010-09-16 06:14:28 EDT
To clarify things: We access one class, JobManagerAdapter. This class is part
of an internal package of RAP. We should not do this.
Comment 4 Ivan Furnadjiev CLA 2014-12-01 08:05:32 EST
This is a very old bugzilla. The JobManagerAdapater is still internal class and should not be hacked. The code inside JobManagerAdapater is very sensitive and it's not recomended to modify it. I'll close it as WONTFIX. Please reopen if you disagree.