I have a Uses Constraint Violation using Karaf:

Error executing command: Error starting bundles:
        Unable to start bundle 83: Uses constraint violation. Unable to resolve 
bundle revision org.apache.servicemix.bundles.jaxb-xjc [83.0] because it is 
exposed to package 'org.xml.sax' from bundle revisions 
org.apache.felix.framework [0] and com.springsource.org.apache.xmlcommons 
[100.0] via two dependency chains.

Chain 1:
  org.apache.servicemix.bundles.jaxb-xjc [83.0]
    import: (osgi.wiring.package=org.xml.sax)
     |
    export: osgi.wiring.package=org.xml.sax
  org.apache.felix.framework [0]

Chain 2:
  org.apache.servicemix.bundles.jaxb-xjc [83.0]
    import: 
(&(osgi.wiring.package=com.sun.xml.bind.util)(version>=2.2.0)(!(version>=3.0.0)))
     |
    export: osgi.wiring.package=com.sun.xml.bind.util; uses:=org.xml.sax
  org.apache.servicemix.bundles.jaxb-impl [85.0]
    import: (osgi.wiring.package=org.xml.sax)
     |
    export: osgi.wiring.package=org.xml.sax
  com.springsource.org.apache.xmlcommons [100.0]

I've searched on how to resolve this, and found a mention I like to set the 
version in the system bundle export to 1.0.0 instead of 0.0.0, but I don't know 
how to do this in Karaf.  The example is for Equinox which says to build a 
"profile" using osgi.java.profile, but I can find no mention on how to do this 
in Karaf.  (It also mentions to remove the package from the exports of the 
system bundle, so that everything resolves to the spring source bundle, but I 
don't know how to do that either.)

Any pointers?

Thanks,
-David-

Reply via email to