How do you define how much memory a bundle uses? It is generally not 
possible to do this unless you have a very specific definition of memory 
use. Bundles can extend classes imported from other bundles. Bundles can 
call other bundles which allocate memory for the caller. To which bundle 
does this memory "belong"? A bundle is a unit of encapsulation and 
classloader isolation but it is not a unit of memory isolation. From a 
memory perspective, bundles are very intertwined and it is extremely hard 
to try and disentangle them.

-- 

BJ Hargrave
Senior Technical Staff Member, IBM
OSGi Fellow and CTO of the OSGi Alliance
hargr...@us.ibm.com

office: +1 386 848 1781
mobile: +1 386 848 3788





From:   masti whoknows <masti...@yahoo.com>
To:     "osgi-dev@mail.osgi.org" <osgi-dev@mail.osgi.org>, 
Date:   2011/11/17 12:51
Subject:        [osgi-dev] Question about Memory Usage per Bundle
Sent by:        osgi-dev-boun...@mail.osgi.org



Hi,
 
     I am using OSGi to create a plug & play framework. My goal is to 
measure how much memory each bundle is using. Is there a way to do this 
dynamically when the bundle is loaded/started? Please note I don't want to 
use any external tools. I want to do it while the system is running.
 
   Any help is highly appreciated.
 
Thanks
Masti_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev
_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to