【问题标题】:How do I properly deploy Eclipse OSGI plug-in that I created?如何正确部署我创建的 Eclipse OSGI 插件?
【发布时间】:2017-01-19 16:44:41
【问题描述】:

我按照下一页上的说明将 primefaces jar 库转换为 OSGi 插件,并将其添加为我的 OSGi 包中的必需插件之一。 http://www.vogella.com/tutorials/EclipseJarToPlugin/article.html#jar-files-without-osgi-meta-data

但是,当我部署我的 OSGi 包时,我得到了missing requirement,我想这是因为我从未将新插件部署到 glassfish。我该如何部署它?

这是我得到的堆栈跟踪,以防错误是由其他原因引起的:

[#|2016-09-12T11:14:04.150+0200|SEVERE|glassfish3.1.2|javax.enterprise.system.tools.admin.org.glassfish.deployment.admin|_ThreadID=85;_ThreadName=Thread-2;|Exception while loading the app : org.osgi.framework.BundleException: Unresolved constraint in bundle test.osgi.primefaces [293]: Unable to resolve 293.0: missing requirement [293.0] osgi.wiring.bundle; (&(osgi.wiring.bundle=org.primefaces.osgi)(bundle-version>=1.0.0))
org.osgi.framework.BundleException: Unresolved constraint in bundle test.osgi.primefaces [293]: Unable to resolve 293.0: missing requirement [293.0] osgi.wiring.bundle; (&(osgi.wiring.bundle=org.primefaces.osgi)(bundle-version>=1.0.0))
        at org.apache.felix.framework.Felix.resolveBundleRevision(Felix.java:3826)
        at org.apache.felix.framework.Felix.startBundle(Felix.java:1868)
        at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:944)
        at org.glassfish.extras.osgicontainer.OSGiDeployedBundle.startBundle(OSGiDeployed

【问题讨论】:

    标签: java eclipse primefaces eclipse-plugin osgi


    【解决方案1】:

    错误表明您的测试包需要具有符号名称 org.primefaces.osgi 的包。所以你还需要部署这个包。

    【讨论】:

    • 一个快速的谷歌给我这个:deploy --type=osgi MyBundle.jar
    猜你喜欢
    • 1970-01-01
    • 2018-12-21
    • 1970-01-01
    • 2015-12-23
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-10-15
    相关资源
    最近更新 更多