Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] Can I avoid having all my OSDI containers copied?

OSGi persists the state of all installed bundles in the Framework storage directory; by default in Equinox this is 'configuration/org.osgi.eclipse'. Therefore, once the bundles are installed they are no longer needed in the external "plugins" directory.

You might want to consider writing a custom OSGi launcher. On first use it could download the bundles from a URL or temporary filesystem. The BundleContext.installBundle() method can read bundles from any InputStream, so local files are not necessarily required. This will cache the bundles into the framework storage dir. Then on subsequent uses the framework will start up with all the same bundles in the same state.

Alternatively you could pre-cache the bundles as part of the install process before shipping the device to users. This has the advantage that Equinox will persist the resolution state, which may improve start-up time.

Regards
Neil

On 19 November 2013 at 08:21:03, Patrick Valsecchi (pvalsecc@xxxxxxxxx) wrote:

Hi,

I'm running on a platform that has very limited disk space and I was looking at disk usage of OpenDaylight.

The biggest directories are the plugins and configuration/org.eclipse.osgi/bundlesdirectories. The plugins directory is where all my bundles are, so I'm OK with it. But theconfiguration/org.eclipse.osgi/bundles directory seems to contain mostly copies of my bundles.

For example configuration/org.eclipse.osgi/bundles/117/1/bundlefile is an exact copy ofplugins/org.opendaylight.controller.clustering.services-implementation-0.4.0.jar. That is a big waste of disk space.

I've tried to find a configuration option to disable that and found nothing. Is there something?

I've looked at the Equinox source code as well and didn't find anything. Can somebody point me to the location in the code where this is done? I'd like to disable that or at least replace it by a hard link.

Thanks

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

Back to the top