Bug 350438 - Investigate splitting jdt.launching to remove the jdt.debug.core dependency
Summary: Investigate splitting jdt.launching to remove the jdt.debug.core dependency
Status: CLOSED DUPLICATE of bug 259196
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 3.7   Edit
Hardware: All All
: P3 normal with 1 vote (vote)
Target Milestone: ---   Edit
Assignee: JDT-Debug-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 351415 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-06-27 09:00 EDT by Martin Oberhuber CLA
Modified: 2013-06-10 16:30 EDT (History)
14 users (show)

See Also:


Attachments
Screenshot showing defective launch config Dlg (55.68 KB, image/png)
2011-06-27 09:00 EDT, Martin Oberhuber CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Oberhuber CLA 2011-06-27 09:00:26 EDT
Created attachment 198643 [details]
Screenshot showing defective launch config Dlg

+++ This bug was initially created as a clone of Bug #289107 +++

With the new rhino.ui bundle added through bug 289107, a dependency onto 
org.eclipse.jdt.launching was added to JSDT, which in turn drags in jdt.debug and jdt.core.

As a result, when I start with the Indigo C/C++ package and then install PHP from Indigo (which includes JSDT), I get a Launch Configuration Dialog as in attached screenshot:

  - There's "Java Applet", "Java Application" and "Remote Java" Launch 
    Configuration Types, but no respective icons
  - Trying to create such a launch brings up an error dialog ("No tab 
    group defined")

This is because the jdt.core extensions are present without their jdt.ui counterparts.

I'm wondering whether the JDT dependency in the Rhino Launch could be avoided or at least be made optional? A quick check seems to indicate that

   RhinoLocalLaunchDelegate.java

is the only class which drags in the extra JDT dependency.
Comment 1 Michael Rennie CLA 2011-06-27 13:58:48 EDT
(In reply to comment #0)
> 
> I'm wondering whether the JDT dependency in the Rhino Launch could be avoided
> or at least be made optional? A quick check seems to indicate that

I agree whole-heartily this is a problem, but currently I can't think of any way to avoid this - to launch Rhino we have to use a VM, and jdt.launching controls all of that (specifically we use JavaRuntime, StandardVMType and SocketUtil).

I am open to suggestions.
Comment 2 Martin Oberhuber CLA 2011-06-28 03:55:00 EDT
In our product we don't have a strong need for JavaScript debugging (editor / syntax highlighting are our main concerns). 

We already thought about removing the rhino.ui bundle entirely from our product. Not sure if that would deprive us from any debug capabilities entirely? A couple other thoughts that come to mind (not being a Javascript developer myself)...

- In last year's version, there was no jdt dependency... is that Launch still
  available? Or would that make no sense at all?

- Could the VM information be re-used that was used to launch the current
  Eclipse instance as a fallback? There's lots of System Properties which 
  provide information about every aspect of the VM.

- Could essential jdt.launching infrastructure be refactored out of JDT into
  a common bundle? With newer languages (like Scala) that execute on top of 
  the VM that might be a good idea anyways. JDT dependencies came up in 
  another context too (bug 271627 comment 19)
Comment 3 Michael Rennie CLA 2011-06-28 10:24:58 EDT
(In reply to comment #2)
> In our product we don't have a strong need for JavaScript debugging (editor /
> syntax highlighting are our main concerns). 
> 
> We already thought about removing the rhino.ui bundle entirely from our
> product. Not sure if that would deprive us from any debug capabilities
> entirely? A couple other thoughts that come to mind (not being a Javascript
> developer myself)...
> 
> - In last year's version, there was no jdt dependency... is that Launch still
>   available? Or would that make no sense at all?

Yes. Last year all we had was the 'Remote JavaScript' launch configuration, if you removed the rhino.ui bundle all you would lose is the 'Rhino JavaScript' launcher / configuration / launch shortcut

> 
> - Could the VM information be re-used that was used to launch the current
>   Eclipse instance as a fallback? There's lots of System Properties which 
>   provide information about every aspect of the VM.
>

That would be one way to get rid of the dependency, and would involve some code copying from jdt.launching.
 
> - Could essential jdt.launching infrastructure be refactored out of JDT into
>   a common bundle? With newer languages (like Scala) that execute on top of 
>   the VM that might be a good idea anyways. JDT dependencies came up in 
>   another context too (bug 271627 comment 19)

That sounds quite reasonable to me, the major problem I see with that idea is that it would require a lot of API changes. Although I guess if jdt.launching re-exported the new bundle / APIs we would be ok.
Comment 4 Michael Rennie CLA 2011-07-07 10:10:37 EDT
*** Bug 351415 has been marked as a duplicate of this bug. ***
Comment 5 Michael Rennie CLA 2011-07-07 12:11:17 EDT
Moving this to JDT debug, all of the investigatory work for splitting jdt.launching will happen there anyway.
Comment 6 Martin Oberhuber CLA 2012-01-24 06:52:12 EST
Ping, is this going to be followed up on ?
Comment 7 Dani Megert CLA 2012-01-24 06:56:25 EST
(In reply to comment #6)
> Ping, is this going to be followed up on ?

There is currently no one having time to do this.
Comment 8 Martin Oberhuber CLA 2013-06-10 11:33:56 EDT
Is this a duplicate, or related to, bug 259196 ?
Comment 9 Michael Rennie CLA 2013-06-10 16:30:06 EDT
Yes, it is a duplicate of bug 259196

*** This bug has been marked as a duplicate of bug 259196 ***