Chew Chai Teong created SM-5217: ----------------------------------- Summary: Unable to start up OSGi service with ServiceMix bundle - POI 5.2.2_1 Key: SM-5217 URL: https://issues.apache.org/jira/browse/SM-5217 Project: ServiceMix Issue Type: Bug Reporter: Chew Chai Teong
The OSGi cannot be started up successfully when ServiceMix bundle - POI 5.2.2._1 version is used. The related repository is [https://github.com/apache/servicemix-bundles/tree/master/poi-5.2.2.] There are two issues were encountered. When first issue is resolved, second issue happened. +*First issue: Duplicate import*+ {code:java} 2022-07-01 09:05:09,235 [main] ERROR c.o.m.container.scanner.BundleLoader - - Failed to install bundle: bundles/app-bundles/org.apache.servicemix.bundles.poi-5.2.2_1.jar org.osgi.framework.BundleException: Duplicate import: org.apache.xmlbeans.impl.schema at org.apache.felix.framework.util.manifestparser.ManifestParser.normalizeImportClauses(ManifestParser.java:370) at org.apache.felix.framework.util.manifestparser.ManifestParser.<init>(ManifestParser.java:181) at org.apache.felix.framework.BundleRevisionImpl.<init>(BundleRevisionImpl.java:117) at org.apache.felix.framework.BundleImpl.createRevision(BundleImpl.java:1282) at org.apache.felix.framework.BundleImpl.<init>(BundleImpl.java:113) at org.apache.felix.framework.Felix.installBundle(Felix.java:3042) at org.apache.felix.framework.BundleContextImpl.installBundle(BundleContextImpl.java:167) at org.apache.felix.framework.BundleContextImpl.installBundle(BundleContextImpl.java:140) at com.openet.modules.container.scanner.BundleLoader.installBundle(BundleLoader.java:247) at com.openet.modules.container.scanner.BundleLoader.installBundlesFromPath(BundleLoader.java:189) at com.openet.modules.container.scanner.BundleLoader.scanAndDeploy(BundleLoader.java:155) at com.openet.modules.container.scanner.BundleLoader.run(BundleLoader.java:405) at com.openet.modules.container.launcher.OsgiContainerManager.start(OsgiContainerManager.java:228) at com.openet.sba.core.platform.CmpOsgiContainerLauncher.startContainer(CmpOsgiContainerLauncher.java:44) at com.openet.sba.core.platform.CmpOsgiContainerLauncher.main(CmpOsgiContainerLauncher.java:84) 2022-07-01 09:05:09,235 [main] ERROR c.o.m.container.scanner.BundleLoader - - Failed to launch bundles org.osgi.framework.BundleException: Duplicate import: org.apache.xmlbeans.impl.schema at org.apache.felix.framework.util.manifestparser.ManifestParser.normalizeImportClauses(ManifestParser.java:370) at org.apache.felix.framework.util.manifestparser.ManifestParser.<init>(ManifestParser.java:181) at org.apache.felix.framework.BundleRevisionImpl.<init>(BundleRevisionImpl.java:117) at org.apache.felix.framework.BundleImpl.createRevision(BundleImpl.java:1282) at org.apache.felix.framework.BundleImpl.<init>(BundleImpl.java:113) at org.apache.felix.framework.Felix.installBundle(Felix.java:3042) at org.apache.felix.framework.BundleContextImpl.installBundle(BundleContextImpl.java:167) at org.apache.felix.framework.BundleContextImpl.installBundle(BundleContextImpl.java:140) at com.openet.modules.container.scanner.BundleLoader.installBundle(BundleLoader.java:247) at com.openet.modules.container.scanner.BundleLoader.installBundlesFromPath(BundleLoader.java:189) at com.openet.modules.container.scanner.BundleLoader.scanAndDeploy(BundleLoader.java:155) at com.openet.modules.container.scanner.BundleLoader.run(BundleLoader.java:405) at com.openet.modules.container.launcher.OsgiContainerManager.start(OsgiContainerManager.java:228) at com.openet.sba.core.platform.CmpOsgiContainerLauncher.startContainer(CmpOsgiContainerLauncher.java:44) at com.openet.sba.core.platform.CmpOsgiContainerLauncher.main(CmpOsgiContainerLauncher.java:84) 2022-07-01 09:05:09,235 [main] ERROR c.o.s.c.p.CmpOsgiContainerLauncher - - Failed to initialise the OSGi container com.openet.modules.container.exceptions.OsgiContainerManagerException: Bundle loader failure: Duplicate import: org.apache.xmlbeans.impl.schema at com.openet.modules.container.launcher.OsgiContainerManager.start(OsgiContainerManager.java:230) at com.openet.sba.core.platform.CmpOsgiContainerLauncher.startContainer(CmpOsgiContainerLauncher.java:44) at com.openet.sba.core.platform.CmpOsgiContainerLauncher.main(CmpOsgiContainerLauncher.java:84) Caused by: org.osgi.framework.BundleException: Duplicate import: org.apache.xmlbeans.impl.schema {code} *Solution:* remove this line of code [https://github.com/apache/servicemix-bundles/blob/6806c269d2b716fa3dc2eb0e09a1b846b47cf062/poi-5.2.2/pom.xml#L100] +*Second issue*+ {code:java} Bundle Error:org.apache.servicemix.bundles.poi has unsatisfied requirement on (osgi.wiring.package=org.w3c.dom.svg) {code} *Solution:* remove this line of code [https://github.com/apache/servicemix-bundles/blob/6806c269d2b716fa3dc2eb0e09a1b846b47cf062/poi-5.2.2/pom.xml#L89] -- This message was sent by Atlassian Jira (v8.20.10#820010)