缺少要求osgi.wiring.package = org.osgi.framework)(版本> = 1.8.0)(!(版本> = 2.0.0)))

时间:2016-08-27 07:24:03

标签: java maven osgi apache-karaf

我在Karaf 4.0.5开始时遇到错误。我收到这个错误:

(version>=1.8.0)(!(version>=2.0.0))) Unresolved requirements: [[Tracking_Service [11](R 11.0)] osgi.wiring.package; (&(osgi.wiring.package=org.osgi.framework)(version>=1.8.0)(!(version>=2.0.0)))]
        at org.apache.felix.framework.Felix.resolveBundleRevision(Felix.java:4111)[org.apache.felix.framework-5.4.0.jar:]
        at org.apache.felix.framework.Felix.startBundle(Felix.java:2117)[org.apache.felix.framework-5.4.0.jar:]
        at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:998)[org.apache.felix.framework-5.4.0.jar:]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1253)[4:org.apache.felix.fileinstall:3.5.4]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1225)[4:org.apache.felix.fileinstall:3.5.4]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:512)[4:org.apache.felix.fileinstall:3.5.4]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:361)[4:org.apache.felix.fileinstall:3.5.4]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:312)

您能否就我如何解决这个问题提出一些建议?

我使用这种依赖:

<dependency>
            <groupId>org.osgi</groupId>
            <artifactId>org.osgi.core</artifactId>
            <version>6.0.0</version>
            <type>jar</type>
        </dependency> 

1 个答案:

答案 0 :(得分:4)

您已使用OSGi第6版构建了捆绑包,但是您正在部署到较低/较早版本的OSGi Framework版本。