| Summary: | Enhance runtime artifact model to work with framework hooks | ||
|---|---|---|---|
| Product: | [RT] Virgo | Reporter: | Glyn Normington <glyn.normington> |
| Component: | runtime | Assignee: | Glyn Normington <glyn.normington> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | enhancement | ||
| Priority: | P3 | CC: | eclipse |
| Version: | 3.0.0.M01 | ||
| Target Milestone: | 3.0.0.M04 | ||
| Hardware: | PC | ||
| OS: | Mac OS X - Carbon (unsup.) | ||
| Whiteboard: | |||
| Bug Depends on: | |||
| Bug Blocks: | 337233, 338159 | ||
|
Description
Glyn Normington
A temporary work around is in place for uses of the RAM. org/eclipse/virgo/kernel/model/internal/KernelRegionBundle Will now be returned whenever a dependency strays in to the Kernel region. *** Bug 338521 has been marked as a duplicate of this bug. *** The RAM for the 2.x kernel is specified in http://git.eclipse.org/c/virgo/org.eclipse.virgo.documentation.git/plain/design-docs/kernel/kernel.pdf. Implementation Notes The kernel deployer code ensures that at most one bundle may be deployed into the kernel region with a given symbolic name and version. (If there are cases where additional copies of a bundle are auto-provisioned, then this is a bug which should be fixed.) So we can rely on looking up user region bundles using symbolic name and version. We need to make sure BundleDependencyDeterminer includes kernel bundles in its dependency calculation. KernelRegionBundle and KernelRegionFauxQuasiLiveBundle should be deleted. KRB is constructed only by NotifyingRuntimeArtifactRepository and returned when the getArtifact method cannot find an artifact (not just a bundle - this is a bug) with the given type, name, and version. This method can be changed to return null if the artifact is not found. The only caller where this matters is BundleDependencyDeterminer which should test for the null return value and return a new Artifact wrapping the QuasiBundle. KRFQLB is constructed only in the constructor of StandardQuasiLiveBundle in the case where a null 3rd Bundle parameter has been supplied. The callers of the SQLB constructor obtain the 3rd Bundle parameter in one of two ways: 1. StandardQuasiLiveFramework uses this.bundleContext.getBundle(bundleId). If the system bundle context is used instead, then the bundle should be returned. In earlier testing, this did not appear to be the case, which indicates a possible bug in the region bundle find hook. 2. StandardQuasiLiveService uses this.quasiFramework.getBundle(user.getBundleId()) which uses SQLF covered by item 1. Note that more workaround code is in StandardRamAccessorHelper - search in there for bug 337211. In addition to adding regions into the runtime artifact model, I added KernelModel mbeans to augment the runtime model. |