Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipse-dev] variables, expressions and other small things...


Some time ago I took the responsibility for reviewing where generally useful but small bit of function like variables, expressions etc should live in Eclipse.  Unless there is a strong argument to the contrary, these will be packaged as plugins in their own right.  This has a number of benefits (+) and a few drawbacks (-).

+ classes are shared => objects can be shared
+ uses the Eclipse component mechanism (dependencies, packaging, ...)
+ allows for independent evolution/updating/use
+ scalable solution

- classloader overhead per plugin
- more plugins

The main alternatives considered were
1) growing a "utilities" plugin:  This is appealing in its simplicity but has issues in factoring (I only want some of the utils...), maintenance (who owns/tests/maintains it), scale (after a year or two the utils bucket gets big)

2) copy the code: typically the utils code is small so hey, why not just copy it when you need it?  Individually small but if everyone needs it... (just say "StringMatcher" or "Assert"), saves on classloaders but increases potential for ClassCastExceptions, update/maintenance (how do you patch or even find all N copies).

The proposed approach still allows someone to copy the code if they want to maintain it and are concerned about classloader space and it in general avoids the downsides of the other approaches.

Jeff

Back to the top