Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Virgo/Design/EquinoxHooks"

< Virgo‎ | Design
m
m
 
Line 8: Line 8:
 
* the following bundle file wrapper factory hooks:
 
* the following bundle file wrapper factory hooks:
 
**<tt>ExtendedBundleFileWrapperFactoryHook</tt> which wraps the Equinox <tt>BundleFile</tt> class to ensure that all returned resource URLs have the <tt>file:</tt> protocol rather than the <tt>bundleresource:</tt> protocol which is the Equinox default.
 
**<tt>ExtendedBundleFileWrapperFactoryHook</tt> which wraps the Equinox <tt>BundleFile</tt> class to ensure that all returned resource URLs have the <tt>file:</tt> protocol rather than the <tt>bundleresource:</tt> protocol which is the Equinox default.
** <tt>BundleFileClosingBundleFileWrapperFactoryHook</tt> which worked around Equinox [https://bugs.eclipse.org/bugs/show_bug.cgi?id=404390" bug 404390]. This bug is now fixed, so it may be possible to delete this hook.
+
** <tt>BundleFileClosingBundleFileWrapperFactoryHook</tt> which worked around Equinox [https://bugs.eclipse.org/bugs/show_bug.cgi?id=404390 bug 404390]. This bug is now fixed, so it may be possible to delete this hook.
 
** <tt>PluggableBundleFileWrapperFactoryHook</tt> which is used by the Virgo kernel to wrap <tt>BundleFile</tt> with <tt>TransformedManifestProvidingBundleFileWrapper</tt> which replaces the manifest in the <tt>BundleFile</tt> with one that has been transformed in memory by the deployment pipeline.
 
** <tt>PluggableBundleFileWrapperFactoryHook</tt> which is used by the Virgo kernel to wrap <tt>BundleFile</tt> with <tt>TransformedManifestProvidingBundleFileWrapper</tt> which replaces the manifest in the <tt>BundleFile</tt> with one that has been transformed in memory by the deployment pipeline.
 
* a class loader delegate hook <tt>PluggableDelegatingClassLoaderDelegateHook</tt> which is used by the Virgo kernel in <tt>postFindResource</tt> and <tt>postFindResources</tt> to propagate any attempts to get <tt>META-INF</tt> resource(s) to the principal bundle's dependencies, unless the request is being driven through Gemini Blueprint's <tt>DelgatedNamespaceHandlerResolver</tt> which is exempted from such propagation.
 
* a class loader delegate hook <tt>PluggableDelegatingClassLoaderDelegateHook</tt> which is used by the Virgo kernel in <tt>postFindResource</tt> and <tt>postFindResources</tt> to propagate any attempts to get <tt>META-INF</tt> resource(s) to the principal bundle's dependencies, unless the request is being driven through Gemini Blueprint's <tt>DelgatedNamespaceHandlerResolver</tt> which is exempted from such propagation.

Latest revision as of 10:04, 15 April 2013


Kernel Hooks

The Virgo kernel's ExtensionsHookConfigurator class registers various Equinox hooks:

  • a class loading hook, PluggableClassLoadingHook, which is used to set a custom class loader KernelBundleClassLoader which in turn implements the InstrumentableClassLoader interface and thereby enables load time weaving and the construction of "throw away" class loaders for instrumentation purposes.
  • the following bundle file wrapper factory hooks:
    • ExtendedBundleFileWrapperFactoryHook which wraps the Equinox BundleFile class to ensure that all returned resource URLs have the file: protocol rather than the bundleresource: protocol which is the Equinox default.
    • BundleFileClosingBundleFileWrapperFactoryHook which worked around Equinox bug 404390. This bug is now fixed, so it may be possible to delete this hook.
    • PluggableBundleFileWrapperFactoryHook which is used by the Virgo kernel to wrap BundleFile with TransformedManifestProvidingBundleFileWrapper which replaces the manifest in the BundleFile with one that has been transformed in memory by the deployment pipeline.
  • a class loader delegate hook PluggableDelegatingClassLoaderDelegateHook which is used by the Virgo kernel in postFindResource and postFindResources to propagate any attempts to get META-INF resource(s) to the principal bundle's dependencies, unless the request is being driven through Gemini Blueprint's DelgatedNamespaceHandlerResolver which is exempted from such propagation.

Note that the Virgo kernel's hooks are registered by EquinoxHookRegistrar.

Web Hooks

There are two class loading hooks in the Virgo web layer: AppLoaderClasspathExtenderClassLoadingHook and OpenEjbEmptyProtectionDomainClassloadingHook.

Back to the top