Hide Forgot
The ModeShape JCR jar (version 3.8.1) contains invalid OSGi meta-data. This leads to errors with loading it in an OSGi container: > Error executing command: Could not start bundle mvn:org.modeshape/modeshape-jcr/3.8.1.GA-redhat-1 in feature(s) s-ramp-dependencies-0.5.0.Beta3-redhat-1: Uses constraint violation. Unable to resolve bundle revision org.modeshape.jcr [551.0] because it exports package 'org.modeshape.common.util' and is also exposed to it from bundle revision org.modeshape.common [550.0] via the following dependency chain: > > org.modeshape.jcr [551.0] > import: (&(osgi.wiring.package=org.modeshape.common)(version>=3.8.0)(!(version>=4.0.0))) > | > export: osgi.wiring.package=org.modeshape.common; uses:=org.modeshape.common.util > export: osgi.wiring.package=org.modeshape.common.util > org.modeshape.common [550.0] It looks like this is because the source contains a class under org.modeshape.common.util, and there are also classes under org.modeshape.common.util in the modeshape-common module. This causes the OSGi export entry in MANIFEST.MF: org.modeshape.common.util; uses:="org.modeshape.common,org.modeshape.common.i18n,org.modeshape.common.annotation,org.modeshape.common.logging";version="3.8.1.GA-redhat-1", which clashes with the (different) org.modeshape.common.util entry in the modeshape-common jar: org.modeshape.common.util; uses:="org.modeshape.common,org.modeshape.common.i18n,org.modeshape.common.annotation,org.modeshape.common.logging,org.modeshape.common.text";version="3.8.1.GA-redhat-1" There are other classes not under org.modeshape.jcr, for example: org.modeshape.connector.filesystem; uses:="javax.jcr,org.modeshape.jcr.mimetype,org.modeshape.jcr.federation.spi ,org.infinispan.schematic.document,org.modeshape.jcr,org.modeshape.common.i18n,o rg.modeshape.jcr.cache,org.modeshape.jcr.federation,org.modeshape.jcr.cache.docu ment,org.modeshape.jcr.value,org.modeshape.jcr.api.nodetype,org.modeshape.common .logging,org.modeshape.common.util,org.modeshape.jcr.value.binary,org.infinispan .schematic,org.modeshape.common.text,org.modeshape.jcr.api";version="3.8.1.GA-re dhat-1", but these don't appear to clash with other jars currently.
Created attachment 933517 [details] OSGi bundle workaround Workaround patch overriding the parent bundle configuration.
Fixed and merged into the product branch for DV 6.1: https://github.com/jboss-integration/modeshape/commit/807e12e1411a12c3e376c0b522062779620fd6d4
Verified. The org.modeshape.common.util doesn't define dependencies in modeshape-jcr*jar anymore.