You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@karaf.apache.org by Milan Tomic <to...@yahoo.com> on 2014/11/17 17:34:12 UTC

Unresolved constraint in bundle

I have this exception:
Unresolved constraint in bundle my-api [122]: Unable to resolve 122.0: missing requirement [122.0] osgi.wiring.package; (&(osgi.wiring.package=io.netty.buffer)(version>=4.0.0)(!(version>=5.0.0)))

and I am trying to run PaxExam test (@RunWith(PaxExam.class)).
In my
public Option[] config() {..}
I am not specifying any netty JARs. They are specified in my-api pom.xml:
 <dependency>
      <groupId>io.netty</groupId>
      <artifactId>netty-buffer</artifactId>
    </dependency>
and in my-api parent's pom.xml:
<dependency>
        <groupId>io.netty</groupId>
        <artifactId>netty-buffer</artifactId>
        <version>4.0.23.Final</version>
        <scope>provided</scope>
      </dependency>


even if I try to specify Netty JAR in PaxExam:
public Option[] config() {
    return options(...        mavenJar("io.netty", "netty-buffer", "4.0.23.Final"),        ...);

}
it is still the same error. It should be probably specified as wrapped JAR, bundle or something else? Can you please help me with correct line of code using wrapped JAR?
Thank you in advance,Milan