[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] Bundle Granularity?


I recommend to device developers not to go overboard creating bundles. The very small performance impacts seen on a desktop machine are larger on slower devices. Also, Eclipse is capable of handling thousands of bundles, but other OSGI runtimes may be optimized for devices to improve their performance and may not handle so many bundles very well.

        Mark
 


Oleg Besedin <obesedin@xxxxxxxxxx>
Sent by: equinox-dev-bounces@xxxxxxxxxxx

01/31/2007 09:20 AM

Please respond to
Equinox development mailing list <equinox-dev@xxxxxxxxxxx>

To
Equinox development mailing list <equinox-dev@xxxxxxxxxxx>
cc
Subject
Re: [equinox-dev] Bundle Granularity?






Hi Craig,

Back when we were doing the runtime split for 3.2 I did some testing on how having code in separate plugins vs. one plugin impacts performance.


Performance-wise having code in separate bundles had small impact on startup time. To be more concrete, having an extra bundle on WinXP 2GHz 2Gb adds about 1ms to the "warm" startup time. The impact is more significant for the "cold" startup, but those are very hard to quanitfy. My guess would be 2 - 5 ms, but it is just a guess (variability of cold startups is too high).


What did seem to impact startup performance was the amount of code that had to be loaded. More features -> more code -> slower startup. Again, to put some numbers, on the system above having a few extra classes loaded in activators added 28 ms to the startup sime.


There was no detectable impact on the runtime performance. Memory impact was rather hard to measure reliable; from the common sense there should be very little cost memory-wise. As for threads, there is no relationship between the number of threads and number of bundles.


In my opinion, granularity of bundles should be determined more by things like:

- business considerations;

- need to keeping things compartmentalized / reusable;

- separation of work between developers / teams.


>From a technical side there is a small cost associated with having extra bundles, but it seems to be rather small. That said please don't create a bundle per class :-)


Sincerely,

Oleg Besedin




Craig Setera <craigjunk@xxxxxxxxxx>
Sent by: equinox-dev-bounces@xxxxxxxxxxx

01/31/2007 08:00 AM

Please respond to
Equinox development mailing list <equinox-dev@xxxxxxxxxxx>

To
equinox-dev@xxxxxxxxxxx
cc
Subject
[equinox-dev] Bundle Granularity?







I'm wondering if there are any rules of thumb in terms of the
granularity of bundles?  What are the advantages and disadvantages of
having fine grained bundles versus coarser grained bundles?  For
instance, what is the average cost of a bundle in terms of:

- Memory overhead?
- Classloader lookup times?
- Threads in the system?
- Other overhead?

The positive things I can think of include the ability for the system to
lazily load only the bundles that are actually necessary.  What are the
other advantages of finer grained bundles?

Thanks for any insights you can provide.
Craig

PS - I'm primarily talking about bundles in the context of the Eclipse
platform rather than at the Equinox framework level.
_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev

_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev