Rico Neubauer created JBOSGI-555:
------------------------------------
Summary: Cannot activate OSGi subsystem with fragment bundle deployments
Key: JBOSGI-555
URL:
https://issues.jboss.org/browse/JBOSGI-555
Project: JBoss OSGi
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Core Framework
Affects Versions: JBossOSGi 1.3.0
Reporter: Rico Neubauer
Assignee: Thomas Diesler
Occurs with JBoss 7.1.2.Final (EAP) running with jbosgi-framework 1.3.0.Final
See
https://issues.jboss.org/browse/AS7-4814 for an issue in the same area. This bug here
happens independently of the other.
Having OSGi bundles, that are fragments leads to
{noformat}
INFO [org.jboss.as.controller] (Controller Boot Thread) JBAS014774: Service status
report
JBAS014775: Neue fehlende/unbefriedigte Abhängigkeiten: (this is German, in English. sth.
like Missing/unresolved dependencies)
service jbosgi.integration.PersistentBundlesHandler.COMPLETE (missing) dependents:
[service jbosgi.framework.INIT]
{noformat}
This is because when bundle is installed via
{noformat}org.jboss.osgi.framework.internal.BundleManagerPlugin.installBundle(Deployment,
ServiceListener<Bundle>){noformat} in case of a fragment, the listener is not passed
to the FragmentBundleInstalledService (BundleManagerPlugin, line 364).
In consequence, there is no notification for this bundle in
{noformat}org.jboss.osgi.framework.util.ServiceTracker.listenerAdded(ServiceController<?
extends S>){noformat} which leads to
org.jboss.osgi.framework.util.ServiceTracker.addedNames not containing the bundle and then
when org.jboss.osgi.framework.util.ServiceTracker.checkAndComplete() is invoked the check
for completeness in
{noformat}org.jboss.as.osgi.service.PersistentBundlesIntegration.InitialDeploymentTracker.InitialDeploymentTracker(...).new
PersistentBundlesComplete() {...}.allServicesAdded(Set<ServiceName>){noformat} fails
due to different sizes of bundleInstallServices and trackedServices.
I will attach a proposed patch, which resolves the issue by adding the listener also to
FragmentBundleInstalledService.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see:
http://www.atlassian.com/software/jira