0
VerifyingPlugin Dependenciesin Eclipse	Shivanshu Singh	sks@cmu.edu		Carnegie Mellon University
Plugin based systems are pretty mainstream	Deployed for serious commercial and noncommercial use		Closed World Open World ...
3
“ How do I debug the Eclipse Plugin error‘Plugin was unable to load class’ ?	”				Missing dependencies not realized until ...
5
(ICSE 2012)	6
“ 	We try to encapsulate the logic as much aspossible to be able to test with unit tests. Whatcannot be encapsulated is no...
8	Plugin testing beyond unit testing is:	annoying distracting painful		Lack of time, resources, infrastructure,combinatori...
9	Understanding user-speci$ed 	dependency speci$cations and how they	map to the actual implementation			Analysing artifact...
Objectives	10	  
Extract dependencies from the speci$cation	and the implementation		Analyse them for satisfaction in the Implementation		Un...
12	package org.some;public class A {public void fn() {....}public String foo(int a) {....}private int process() {B b = new...
OSGi, EclipsePlugins, Features	13
14	lib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plugin Manifest:		UniqueName, Version	Exports:		packages	Imports:		libra...
15	lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plugin Manifest:		UniqueName, Version	...
16	lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plug...
17	lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plug...
18	lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plug...
19	lib/jar!lib/jar!MANIFEST.MF!PLUGINFEATUREfeature.xml!lib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINMANIFEST.MF!PLUGINMANIFE...
20	lib/jar!lib/jar!MANIFEST.MF!PLUGINFEATUREfeature.xml!lib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINMANIFEST.MF!PLUGINMANIFE...
OSGi Plugin Manifest:		UniqueName, Version	Exports:		packages	Imports:		libraries		other plugins		external packages	Host: ...
What Did We Do?	22
23	Specifica+on	  Speci$cation/	ProblemSpace	Implementation/	SolutionSpace
24	feature.xml	feature.xml	feature.xml	feature.xml	manifest.mf 	manifest.mf 	manifest.mf 	 manifest.mf 	manifest.mf 	manif...
25	feature.xml	 manifest.mf 	Speci$cationDependency Extraction	1Spec:	  imp,exp	  
Extracting Spec. Dependencies	Problem Space	26
27	pluginA version= 2.4.0.201305Import-Bundle= pluginB[1.1.0,2.0.2]Import-Package= package.some 1.4.2.1234pluginX version=...
28	pluginA version= 2.4.0.201305Import-Bundle= pluginB[1.1.0,2.0.2]Import-Package= package.some 1.4.2.1234pluginX version=...
29	pluginA version= 2.4.0.201305Import-Bundle= pluginB[1.1.0,2.0.2]Import-Package= package.some 1.4.2.1234pluginX version=...
30	pluginA version= 2.4.0.201305Import-Bundle= pluginB[1.1.0,2.0.2]Import-Package= package.some 1.4.2.1234pluginX version=...
31	feature.xml	 manifest.mf 	Speci$cationDependency Extraction	1Spec:	  imp,exp	  Feature Model:		plugin_b_1.1.1.201 => 	p...
Impl:	  imp,	  exp	  (funcSig)	  	  &	  interfaces	  +	  inheritances	  Interface Extractionfrom Plugins	232	Spec:	  imp,e...
Extracting Impl. Dependencies	Solution Space	33
34	package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b ...
35	package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b ...
36	package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b ...
37	package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b ...
38	package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b ...
39	package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b ...
Why bytecode?		•  fully quali$ed names, signatures and access opcodes	•  no need to to do all sorts of resolution	–  (pars...
Linking & Inter-PluginDependency Analysis	341	Interface Extractionfrom Plugins	2Impl:	  imp,	  exp	  (funcSig)	  	  &	  in...
42	class/interface	  import A....void ba {A.go ();}....pluginW	package org.some;!public class A {!public void fn() {....}!...
B TpluginY	43	class/interface	  import A....void ba {A.go ();}....pluginW	A B	void A.go ()Linking & Inter-PluginDependency...
B TpluginY	44	class/interface	  K {void go() {}}pluginZ	CpluginP	GSimport A....void ba {A.go ();}....pluginW	void K.go() [...
B TpluginY	45	class/interface	  K {void go() {}}pluginZ	CpluginP	GSimport A....void ba {A.go ();}....pluginW	Constraint: p...
46	com.zink.fly.buzz_1.2.1.201104282140 => (org.eclipse.jface_3.8.102.v20130123.162658 &&org.eclipse.ui.workbench_3.104.0....
47	Constraints:		(plugin_b_1.1.1.201 ||	plugin_c_4.0.3) =>	( plugin_a_1.2.4	&& plugin_w_1.1.5.u7256 )	….	Import(invokation...
48	Constraints:		(plugin_b_1.1.1.201 ||	plugin_c_4.0.3) =>	( plugin_a_1.2.4	&& plugin_w_1.1.5.u7256 )	….	Import(invokation...
49
Preliminary Results	50	  
51	  Plugins	 766	Features	 86	Imports	 197188	(external & non-java & non-optional )	Feature Model entries	 4237	Constrain...
52	  void org.apache.xmlbeans.XmlCursor.push ()		Importing Plugins	org.mozilla.javascript 1.7.2.v201005080400		Exporting P...
53	void org.eclipse.jdt.internal.corext.dom.	Modi$erRewrite.setVisibility (….)		Importers	com.stateo%ow.eclipse.tane 	1.3....
54	  
55	  
56	  OSGi
57	  OSGi
58	  OSGi	OSGi	OSGi	Eclipse+OSGi
59	  But we need a whole new animal, you see ....
60	  …. it still works!	But we need to be better ….
Future Work	61	  
62	  Continue analysis of plugin compatibility across(user-speci$ed) version ranges			Discussion on the design of amodule ...
63	  Solution	Space	Problem	Space	Constraints	Feature Model	Import(invokation)SatisfactionReport	ConsistencyReport	Analysi...
Upcoming SlideShare
Loading in...5
×

Verifying Dependencies in Eclipse

762

Published on

Eclipse is a system of plugins, where multiple plugins come together to form any typical instance of the application. The core eclipse infrastructure is in itself a combination of plugins. With a large number of options available from a marketplace of plugins, where an end usr may choose to install just about any arbitrary mix of them on eclipse, ensuring compatibility between plugins in a chosen combination is important especially when considering that eclipse is now being used in all sorts of (sensitive and non-sensitive) contexts. In this talk I presented my ongoing work and experiences so far in checking if given a combination of plugins, all the stated dependencies of all the plugins are satisfied, and to see if any plugins have unnecessary, unstated or unsatisfied dependencies.

Published in: Technology, Art & Photos
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
762
On Slideshare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
3
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • Eclipse Menu item plugin -> nothing happens on click.
  • Consolidate Introduction slides into one.
  • Consolidate Introduction slides into one.
  • Consolidate Introduction slides into one.
  • CLOSED WORLD
  • Consolidate Introduction slides into one.
  • Interesting because of too rigid or too relaxed dep. Range specificationTo see what happens when Plugins with different versions coexist
  • Consolidate Introduction slides into one.
  • Consolidate Introduction slides into one.
  • Transcript of "Verifying Dependencies in Eclipse"

    1. 1. VerifyingPlugin Dependenciesin Eclipse Shivanshu Singh sks@cmu.edu Carnegie Mellon University
    2. 2. Plugin based systems are pretty mainstream Deployed for serious commercial and noncommercial use Closed World Open World Marketplace of plugins 2
    3. 3. 3
    4. 4. “ How do I debug the Eclipse Plugin error‘Plugin was unable to load class’ ? ” Missing dependencies not realized until its too late http://stackover"ow.com/questions/648024/how-do-i-debug-the-eclipse-plugin-error-plugin-was-unable-to-load-class http://stackover"ow.com/questions/9128132/eclipse-plugin-install-error http://androidforums.com/developer-101/543787-error-installing-adt-plugin-in-eclipse.html#post4343892 http://www.eclipsezone.com/eclipse/forums/t93278.rhtml http://stackover"ow.com/questions/1509511/eclipse-plugin-noclassde#ounderror-on-org-eclipse-jdt-ui-javaui http://stackover"ow.com/questions/11514883/con"icting-dependencies-while-installing-adt-plugin-for-eclipse-helios 4
    5. 5. 5
    6. 6. (ICSE 2012) 6
    7. 7. “ We try to encapsulate the logic as much aspossible to be able to test with unit tests. Whatcannot be encapsulated is not tested. ” 7
    8. 8. 8 Plugin testing beyond unit testing is: annoying distracting painful Lack of time, resources, infrastructure,combinatorial complexity Arbitrary dependency speci$cations Too many plugins, too many versions
    9. 9. 9 Understanding user-speci$ed dependency speci$cations and how they map to the actual implementation Analysing artifacts for checking arbitrary dependency speci$cations Compatibility across version ranges
    10. 10. Objectives 10  
    11. 11. Extract dependencies from the speci$cation and the implementation Analyse them for satisfaction in the Implementation Understand implied and/or unstated dependencies Compatibility across various versions 11 Solution Space Problem Space
    12. 12. 12 package org.some;public class A {public void fn() {....}public String foo(int a) {....}private int process() {B b = new B(); boolean flag = B.go();C c=new C(); c.callfn(“hello”);}}------------------------------------------package org.someother;public class C {void callfn(String x) {....}}package com.eother.some;public class B extends G {public boolean go() {return true;}}------------------------------------------package com.eother;public class G {....}Problem Space Solution Scape
    13. 13. OSGi, EclipsePlugins, Features 13
    14. 14. 14 lib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plugin Manifest: UniqueName, Version Exports: packages Imports: libraries Exported Package
    15. 15. 15 lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plugin Manifest: UniqueName, Version Exports: packages Imports: libraries other plugins
    16. 16. 16 lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plugin Manifest: UniqueName, Version Exports: packages Imports: libraries other plugins external packages Exported Package
    17. 17. 17 lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plugin Manifest: UniqueName, Version Exports: packages Imports: libraries other plugins external packages Host: (opt. for fragments)
    18. 18. 18 lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plugin Manifest: UniqueName, Version Exports: packages Imports: libraries other plugins external packages Host: (opt. for fragments)
    19. 19. 19 lib/jar!lib/jar!MANIFEST.MF!PLUGINFEATUREfeature.xml!lib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINMANIFEST.MF!PLUGINMANIFEST.MF!PLUGIN PLUGINPLUGINPLUGINPLUGINPLUGINMANIFEST.MF!PLUGINMANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINOSGi Plugin Manifest: UniqueName, Version Exports: packages Imports: libraries other plugins external packages Host: (opt. for fragments) Eclipse Feature.xml: UniqueName, Version Includes: plugin a, plugin b, (if  q  then  plugin c) ….
    20. 20. 20 lib/jar!lib/jar!MANIFEST.MF!PLUGINFEATUREfeature.xml!lib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINMANIFEST.MF!PLUGINMANIFEST.MF!PLUGIN PLUGINPLUGINPLUGINPLUGINPLUGINMANIFEST.MF!PLUGINMANIFEST.MF!PLUGINFEATUREfeature.xml!lib/jar!lib/jar!MANIFEST.MF!PLUGINPLUGINPLUGIN PLUGINPLUGINPLUGINPLUGIN PLUGINPLUGINPLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINEclipse Feature.xml: UniqueName, Version Includes: plugin a, plugin b, (if q then plugin c) …. Imports: plugin p version 2.1.2 feature x …. OSGi Plugin Manifest: UniqueName, Version Exports: packages Imports: libraries other plugins external packages Host: (opt. for fragments)
    21. 21. OSGi Plugin Manifest: UniqueName, Version Exports: packages Imports: libraries other plugins external packages Host: (opt. for fragments) 21 lib/jar!lib/jar!MANIFEST.MF!PLUGINFEATUREfeature.xml!lib/jar!lib/jar!lib/jar!MANIFEST.MF!PLUGINMANIFEST.MF!PLUGINMANIFEST.MF!PLUGIN PLUGINPLUGINPLUGINPLUGINPLUGINMANIFEST.MF!PLUGINMANIFEST.MF!PLUGINFEATUREfeature.xml!lib/jar!lib/jar!MANIFEST.MF!PLUGINPLUGINPLUGIN PLUGINPLUGINPLUGINPLUGIN PLUGINPLUGINPLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINlib/jar!lib/jar!MANIFEST.MF!PLUGINEclipse Feature.xml: UniqueName, Version Includes: plugin a, plugin b, (if q then plugin c) …. Imports: plugin p version 2.1.2 feature x …. May include platform (OS, ARCH, WS, NL) conditions also
    22. 22. What Did We Do? 22
    23. 23. 23 Specifica+on  Speci$cation/ ProblemSpace Implementation/ SolutionSpace
    24. 24. 24 feature.xml feature.xml feature.xml feature.xml manifest.mf manifest.mf manifest.mf manifest.mf manifest.mf manifest.mf manifest.mf manifest.mf manifest.mf
    25. 25. 25 feature.xml manifest.mf Speci$cationDependency Extraction 1Spec:  imp,exp  
    26. 26. Extracting Spec. Dependencies Problem Space 26
    27. 27. 27 pluginA version= 2.4.0.201305Import-Bundle= pluginB[1.1.0,2.0.2]Import-Package= package.some 1.4.2.1234pluginX version= 5.1.2exports= package.some 1.4.2pluginB version= 1.2.4.qualpluginB version= 1.6.0pluginB version= 1.0.0pluginY version= 2.3.4.someexports= package.some 1.4.2.1234pluginZ version= 2.0.0HostBundle= pluginA 2.4.0.201305
    28. 28. 28 pluginA version= 2.4.0.201305Import-Bundle= pluginB[1.1.0,2.0.2]Import-Package= package.some 1.4.2.1234pluginX version= 5.1.2exports= package.some 1.4.2pluginB version= 1.2.4.qualpluginB version= 1.6.0pluginB version= 1.0.0pluginY version= 2.3.4.someexports= package.some 1.4.2.1234pluginZ version= 2.0.0HostBundle= pluginA 2.4.0.201305pluginA_2.4.0.201305 => (pluginB_1.2.4.qual || pluginB_1.6.0)
    29. 29. 29 pluginA version= 2.4.0.201305Import-Bundle= pluginB[1.1.0,2.0.2]Import-Package= package.some 1.4.2.1234pluginX version= 5.1.2exports= package.some 1.4.2pluginB version= 1.2.4.qualpluginB version= 1.6.0pluginB version= 1.0.0pluginY version= 2.3.4.someexports= package.some 1.4.2.1234pluginZ version= 2.0.0HostBundle= pluginA 2.4.0.201305pluginA_2.4.0.201305 => (pluginB_1.2.4.qual || pluginB_1.6.0)&& pluginY_2.3.4.some
    30. 30. 30 pluginA version= 2.4.0.201305Import-Bundle= pluginB[1.1.0,2.0.2]Import-Package= package.some 1.4.2.1234pluginX version= 5.1.2exports= package.some 1.4.2pluginB version= 1.2.4.qualpluginB version= 1.6.0pluginB version= 1.0.0pluginY version= 2.3.4.someexports= package.some 1.4.2.1234pluginZ version= 2.0.0HostBundle= pluginA 2.4.0.201305pluginA_2.4.0.201305 => (pluginB_1.2.4.qual || pluginB_1.6.0)&& pluginY_2.3.4.somepluginZ_2.0.0 => pluginA_2.4.0.201305
    31. 31. 31 feature.xml manifest.mf Speci$cationDependency Extraction 1Spec:  imp,exp  Feature Model: plugin_b_1.1.1.201 => plugin_a_2.4.6_qual plugin_c_4.0.3) => ( plugin_w_0.0.0 && org_eclipse_core_3.4.1 ) feature_a_1.1.1.I2011 => ( plugin_b_1.1.1.201 && plugin_c_4.0.3 && (_OS_linux => plugin_g) && feature_b_0.0.0 ) one of (_OS_linux _OS_macosx,_OS_solaris, _OS_win32 .... ) ….
    32. 32. Impl:  imp,  exp  (funcSig)    &  interfaces  +  inheritances  Interface Extractionfrom Plugins 232 Spec:  imp,exp  feature.xml manifest.mf Feature Model: plugin_b_1.1.1.201 => plugin_a_2.4.6_qual plugin_c_4.0.3) => ( plugin_w_0.0.0 && org_eclipse_core_3.4.1 ) feature_a_1.1.1.I2011 => ( plugin_b_1.1.1.201 && plugin_c_4.0.3 && (_OS_linux => plugin_g) && feature_b_0.0.0 ) one of (_OS_linux _OS_macosx,_OS_solaris, _OS_win32 .... ) …. Speci$cationDependency Extraction 1
    33. 33. Extracting Impl. Dependencies Solution Space 33
    34. 34. 34 package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b = new B(); boolean flag = B.go();!C c=new C(); c.callfn(“hello”);!}!}!-------------------------------------------!package org.someother;!public class C {!void callfn(String x) {....}!}!package com.eother.some;!public class B extends G {!public boolean go() {!return true;!}!}!----------------------------------!package com.eother;!public class G {!....!}!!!!pluginX pluginY
    35. 35. 35 package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b = new B(); boolean flag = B.go();!C c=new C(); c.callfn(“hello”);!}!}!-------------------------------------------!package org.someother;!public Class C {!void callfn(String x) {....}!}!package com.eother.some;!public class B extends G {!public boolean go() {!return true;!}!}!----------------------------------!package com.eother;!public class G {!....!}!!!!pluginX pluginY Imports: boolean com.eother.some.B.go ()void org.someother.C.callfn (java.lang.String) Exports: void org.some.A.fn ()java.lang.String org.some.A.foo (int)
    36. 36. 36 package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b = new B(); boolean flag = B.go();!C c=new C(); c.callfn(“hello”);!}!}!-------------------------------------------!package org.someother;!public Class C {!void callfn(String x) {....}!}!package com.eother.some;!public class B extends G {!public boolean go() {!return true;!}!}!----------------------------------!package com.eother;!public class G {!....!}!!!!pluginX pluginY Imports: boolean com.eother.some.B.go ()void org.someother.C.callfn (java.lang.String) Exports: void org.some.A.fn ()java.lang.String org.some.A.foo (int)void org.someother.C.callfn (java.lang.String)
    37. 37. 37 package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b = new B(); boolean flag = B.go();!C c=new C(); c.callfn(“hello”);!}!}!-------------------------------------------!package org.someother;!public Class C {!void callfn(String x) {....}!}!package com.eother.some;!public class B extends G {!public boolean go() {!return true;!}!}!----------------------------------!package com.eother;!public class G {!....!}!!!!pluginX pluginY Imports: boolean com.eother.some.B.go ()void org.someother.C.callfn (java.lang.String) Exports: void org.some.A.fn ()java.lang.String org.some.A.foo (int)void org.someother.C.callfn (java.lang.String)
    38. 38. 38 package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b = new B(); boolean flag = B.go();!C c=new C(); c.callfn(“hello”);!}!}!-------------------------------------------!package org.someother;!public Class C {!void callfn(String x) {....}!}!package com.eother.some;!public class B extends G {!public boolean go() {!return true;!}!}!----------------------------------!package com.eother;!public class G {!....!}!!!!pluginX pluginY Imports: boolean com.eother.some.B.go ()void org.someother.C.callfn (java.lang.String)Exports: void org.some.A.fn ()java.lang.String org.some.A.foo (int)void org.someother.C.callfn (java.lang.String)Imports: Exports: boolean com.eother.some.B.go()
    39. 39. 39 package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b = new B(); boolean flag = B.go();!C c=new C(); c.callfn(“hello”);!}!}!-------------------------------------------!package org.someother;!public Class C {!void callfn(String x) {....}!}!package com.eother.some;!public class B extends G {!public boolean go() {!return true;!}!}!----------------------------------!package com.eother;!public class G {!....!}!!!!pluginX pluginY Imports: boolean com.eother.some.B.go ()void org.someother.C.callfn (java.lang.String)Exports: void org.some.A.fn ()java.lang.String org.some.A.foo (int)void org.someother.C.callfn (java.lang.String)Imports: Exports: boolean com.eother.some.B.go() Inheritance: com.eother.some.B com.eother.G
    40. 40. Why bytecode? •  fully quali$ed names, signatures and access opcodes •  no need to to do all sorts of resolution –  (parsing and extraction is simpler) •  that is what we have available from plugin dist anyway ASM all purpose Java bytecode manipulation and analysis framework several interfaces provided: ClassVisitor, MethodVisitor http://asm.ow2.org/ 40 ParsingBytecode
    41. 41. Linking & Inter-PluginDependency Analysis 341 Interface Extractionfrom Plugins 2Impl:  imp,  exp  (funcSig)    &  interfaces  +  inheritances  Spec:  imp,exp  feature.xml manifest.mf Feature Model: plugin_b_1.1.1.201 => plugin_a_2.4.6_qual plugin_c_4.0.3) => ( plugin_w_0.0.0 && org_eclipse_core_3.4.1 ) feature_a_1.1.1.I2011 => ( plugin_b_1.1.1.201 && plugin_c_4.0.3 && (_OS_linux => plugin_g) && feature_b_0.0.0 ) one of (_OS_linux _OS_macosx,_OS_solaris, _OS_win32 .... ) …. Speci$cationDependency Extraction 1
    42. 42. 42 class/interface  import A....void ba {A.go ();}....pluginW package org.some;!public class A {!public void fn() {....}!public String foo(int a) {....}!private int process() {!B b = new B(); !boolean flag = B.go();!C c=new C(); c.callfn(“hello”);!}}!package org.someother;!public Class C {!void callfn(String x) {....}!}!package com.eother.some;!public class B extends G {!public boolean go() {!return true;!}!}!!package com.eother;!public class G {!....!}!!!pluginX pluginY Imports: boolean com.eother.some.B.go ()void org.someother.C.callfn (java.lang.String)Exports: void org.some.A.fn ()java.lang.String org.some.A.foo (int)void org.someother.C.callfn (java.lang.String)Imports: Exports: boolean com.eother.some.B.go() Inheritance: com.eother.some.B com.eother.GA B void A.go ()Linking & Inter-PluginDependency Analysis 3
    43. 43. B TpluginY 43 class/interface  import A....void ba {A.go ();}....pluginW A B void A.go ()Linking & Inter-PluginDependency Analysis 3
    44. 44. B TpluginY 44 class/interface  K {void go() {}}pluginZ CpluginP GSimport A....void ba {A.go ();}....pluginW void K.go() [pluginY, pluginP, pluginZ]A B void A.go ()Linking & Inter-PluginDependency Analysis 3
    45. 45. B TpluginY 45 class/interface  K {void go() {}}pluginZ CpluginP GSimport A....void ba {A.go ();}....pluginW Constraint: pluginW => ( pluginY && pluginP && pluginZ )void K.go() [pluginY, pluginP, pluginZ]A B void A.go ()Linking & Inter-PluginDependency Analysis 3
    46. 46. 46 com.zink.fly.buzz_1.2.1.201104282140 => (org.eclipse.jface_3.8.102.v20130123.162658 &&org.eclipse.ui.workbench_3.104.0.v20130204.164612 && com.zink.fly.buzz_1.2.1.201104282140)|| (org.eclipse.jface_3.8.102.v20130123.162658 && com.zink.fly.buzz_1.2.1.201104282140)com.zink.fly.buzz_1.2.1.201104282140 => org.eclipse.jface_3.8.102.v20130123.162658com.zink.fly.buzz_1.2.1.201104282140 => org.eclipse.swt.cocoa.macosx.x86.64_3.100.1.v4236bcom.zink.fly.buzz_1.2.1.201104282140 => (org.eclipse.ui.workbench_3.104.0.v20130204.164612 &&com.zink.fly.buzz_1.2.1.201104282140)com.zink.fly.buzz_1.2.1.201104282140 => org.eclipse.ui.workbench_3.104.0.v20130204.164612javax.wsdl_1.6.2.v201012040545 => JAVA.CLASSES.SDK || javax.xml_1.3.4.v201005080400javax.wsdl_1.6.2.v201012040545 => JAVA.CLASSES.SDK || javax.xml_1.3.4.v201005080400 ||(javax.xml_1.3.4.v201005080400 && JAVA.CLASSES.SDK)javax.xml.bind_2.1.9.v201005080401 => JAVA.CLASSES.SDK || javax.xml_1.3.4.v201005080400org.apache.ant_1.8.3.v201301120609 => (JAVA.CLASSES.SDK && com.jcraft.jsch_0.1.46.v201205102330)org.apache.ant_1.8.3.v201301120609 => (JAVA.CLASSES.SDK && org.apache.ant_1.8.3.v201301120609)org.apache.ant_1.8.3.v201301120609 => (JAVA.CLASSES.SDK && org.junit_3.8.2.v3.8.2.v20100427.1100) ||(JAVA.CLASSES.SDK && org.junit_4.10.0.v4.10.0.v20120426.0900)org.apache.ant_1.8.3.v201301120609 => (JAVA.CLASSES.SDK &&org.python.pydev.shared.interactive.console_2.7.3.2013031601) || (JAVA.CLASSES.SDK &&org.apache.commons.logging_1.0.4.v201101211617)org.apache.ant_1.8.3.v201301120609 => JAVA.CLASSES.SDK || javax.xml_1.3.4.v201005080400org.apache.ant_1.8.3.v201301120609 => JAVA.CLASSES.SDK || javax.xml_1.3.4.v201005080400 ||(javax.xml_1.3.4.v201005080400 && JAVA.CLASSES.SDK)org.apache.ant_1.8.3.v201301120609 => com.jcraft.jsch_0.1.46.v201205102330org.apache.ant_1.8.3.v201301120609 => org.apache.log4j_1.2.15.v201012070815Linking & Inter-PluginDependency Analysis 3Constraints Set
    47. 47. 47 Constraints: (plugin_b_1.1.1.201 || plugin_c_4.0.3) => ( plugin_a_1.2.4 && plugin_w_1.1.5.u7256 ) …. Import(invokation)SatisfactionReport Linking & Inter-PluginDependency Analysis 3Interface Extractionfrom Plugins 2Impl:  imp,  exp  (funcSig)    &  interfaces  +  inheritances  Spec:  imp,exp  feature.xml manifest.mf Feature Model: plugin_b_1.1.1.201 => plugin_a_2.4.6_qual plugin_c_4.0.3) => ( plugin_w_0.0.0 && org_eclipse_core_3.4.1 ) feature_a_1.1.1.I2011 => ( plugin_b_1.1.1.201 && plugin_c_4.0.3 && (_OS_linux => plugin_g) && feature_b_0.0.0 ) one of (_OS_linux _OS_macosx,_OS_solaris, _OS_win32 .... ) …. Speci$cationDependency Extraction 1
    48. 48. 48 Constraints: (plugin_b_1.1.1.201 || plugin_c_4.0.3) => ( plugin_a_1.2.4 && plugin_w_1.1.5.u7256 ) …. Import(invokation)SatisfactionReport Linking & Inter-PluginDependency Analysis 3Interface Extractionfrom Plugins 2Impl:  imp,  exp  (funcSig)    &  interfaces  +  inheritances  Spec:  imp,exp  feature.xml manifest.mf Feature Model: plugin_b_1.1.1.201 => plugin_a_2.4.6_qual plugin_c_4.0.3) => ( plugin_w_0.0.0 && org_eclipse_core_3.4.1 ) feature_a_1.1.1.I2011 => ( plugin_b_1.1.1.201 && plugin_c_4.0.3 && (_OS_linux => plugin_g) && feature_b_0.0.0 ) one of (_OS_linux _OS_macosx,_OS_solaris, _OS_win32 .... ) …. Speci$cationDependency Extraction 1ConsistencyReport Consistency Check 4
    49. 49. 49
    50. 50. Preliminary Results 50  
    51. 51. 51  Plugins 766 Features 86 Imports 197188 (external & non-java & non-optional ) Feature Model entries 4237 Constraints entries 9756 Time ~ 3 min A typical eclipse installation
    52. 52. 52  void org.apache.xmlbeans.XmlCursor.push () Importing Plugins org.mozilla.javascript 1.7.2.v201005080400 Exporting Plugins -- boolean org.apache.xmlbeans.XmlCursor$TokenType.isAnyAttr ()boolean org.apache.xmlbeans.XmlCursor$TokenType.isAttr ()boolean org.apache.xmlbeans.XmlCursor$TokenType.isComment ()org.apache.xmlbeans.XmlObjectorg.apache.xmlbeans.XmlObject$Factory.newInstance ()org.apache.xmlbeans.XmlObjectorg.apache.xmlbeans.XmlObject$Factory.parse (java.lang.String,)void org.apache.xmlbeans.XmlCursor.dispose ()........Plugin: org.mozilla.javascript version= 1.7.2.v201005080400 Spec. missing package import: org.apache.xmlbeans
    53. 53. 53 void org.eclipse.jdt.internal.corext.dom. Modi$erRewrite.setVisibility (….) Importers com.stateo%ow.eclipse.tane 1.3.1.201104282140 Exporters -- Plugin: com.stateo"ow.eclipse.tane version= 1.3.1.201104282140 Spec: import-package: org.eclipse.idt.internal.corext Still, the function: void org.eclipse.jdt.internal.corext.dom. Modi$erRewrite.setVisibility (….) does not exist! Exists: org.eclipse.jdt.internal.corext.$x.LinkedProposalPositionGroup$PositionInformation org.eclipse.jdt.internal.corext.dom.Modi$erRewrite.setVisibility (….) instead of: void org.eclipse.jdt.internal.corext.dom.Modi$erRewrite.setVisibility (….) A case of API evolution ?
    54. 54. 54  
    55. 55. 55  
    56. 56. 56  OSGi
    57. 57. 57  OSGi
    58. 58. 58  OSGi OSGi OSGi Eclipse+OSGi
    59. 59. 59  But we need a whole new animal, you see ....
    60. 60. 60  …. it still works! But we need to be better ….
    61. 61. Future Work 61  
    62. 62. 62  Continue analysis of plugin compatibility across(user-speci$ed) version ranges Discussion on the design of amodule system based onobservations from eclipse Study API Usage evolution in Java and in anecosystem like Eclipse (Based on historical data from plugins on deprecated api and evolution)
    63. 63. 63  Solution Space Problem Space Constraints Feature Model Import(invokation)SatisfactionReport ConsistencyReport Analysis of user-speci$ed dependencies over version ranges Module system design based on observations from eclipse Deprecation, api and its usage evolution   Consistency Check K {voidfn() {}}import A....void ba{A.fn();}....org.mozilla.javascript Spec. missing package import The function: void ….Modi$erRewrite .setVisibility (….) does not exist! http://shivanshukumar.github.io/PluginAnalyser/ 4321
    1. A particular slide catching your eye?

      Clipping is a handy way to collect important slides you want to go back to later.

    ×