基于 Luna 构建的 Eclipse RCP 应用程序有时会在 Windows 10 上丢失捆绑包
Eclipse RCP application built on Luna sometime misses bundle on Windows 10
我有一个基于 Eclipse Luna 4.4 构建的 Eclipse RCP 应用程序。
这是一个托管在 GitHub 上的开源项目:https://github.com/andreafeccomandi/bibisco and executable can be downloaded at here。
该应用程序通常在 Windows 10 上运行良好,但在 一些 Windows 10 PC 上无法启动并出现此错误:
!SESSION 2016-02-14 13:37:46.274 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.6.0_26
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
Command-line arguments: -os win32 -ws win32 -arch x86 -data @none
!ENTRY org.eclipse.equinox.ds 4 0 2016-02-14 13:37:47.563
!MESSAGE FrameworkEvent ERROR
!STACK 0
org.osgi.framework.BundleException: The bundle "org.eclipse.equinox.ds_1.4.101.v20130813-1853 [3]" could not be resolved. Reason: Missing Constraint: Import-Package: org.eclipse.equinox.internal.util.event; version="1.0.0"
at org.eclipse.osgi.framework.internal.core.AbstractBundle.getResolverError(AbstractBundle.java:1332)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.getResolutionFailureException(AbstractBundle.java:1316)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:323)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:390)
at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1176)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
应用程序自带 JRE (1.6.0_26),config.ini
是:
#Product Runtime Configuration File
eclipse.application=bibisco.application
osgi.bundles.defaultStartLevel=4
eclipse.product=bibisco.product
osgi.splashPath=platform:/base/plugins/bibisco
osgi.bundles=org.eclipse.equinox.common@2:start,org.eclipse.update.configurator@3:start,org.eclipse.equinox.ds@2:start,org.eclipse.core.runtime@start
有什么想法吗?
我看了一下项目的MANIFEST.MF,可以看到项目正在声明使用Java 7.
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
但是查看您的日志,您似乎正在(运送和)运行 应用程序 Java 1.6
java.version=1.6.0_26
所以,我和 Modus Tollens 有相同的观察,我的理论是修复 Java 版本可以解决错误。
因此,我认为您可以通过 Java 1.7 分发应用程序来解决这个问题。如果这不是一个选择;您应该在清单中声明使用 Java 1.6,并相应地修复依赖项。
我认为这个非确定性错误可以通过在启动配置中设置启动级别来解决,如下所述:
http://www.vogella.com/tutorials/EclipseRCP/article.html#plugin_startlevels
详情:
日志中的主要错误是:eclipse Missing Constraint: Import-Package: org.eclipse.equinox.internal.util.event;版本="1.0.0"
我在网上找到了一些相关的指针:一个topic on eclipse forums, and a comment on an eclipse bug。后一个指针建议使用以下设置解决错误:
<configurations>
<plugin id="org.eclipse.core.runtime" autoStart="true" startLevel="4" />
<plugin id="org.eclipse.equinox.common" autoStart="true" startLevel="2"/>
<plugin id="org.eclipse.equinox.ds" autoStart="true" startLevel="2" />
<plugin id="org.eclipse.equinox.simpleconfigurator" autoStart="true" startLevel="1" />
<plugin id="org.eclipse.update.configurator" autoStart="true" startLevel="4" />
<property name="org.eclipse.update.reconcile" value="false" />
</configurations>
这可能是由初始加载阶段的问题引起的,可以通过更改启动配置和设置启动级别来解决,如下所示:
这些设置与您在 Vogella 教程中看到的设置完全相同 Eclipse RCP > set start levels。
我有一个基于 Eclipse Luna 4.4 构建的 Eclipse RCP 应用程序。
这是一个托管在 GitHub 上的开源项目:https://github.com/andreafeccomandi/bibisco and executable can be downloaded at here。
该应用程序通常在 Windows 10 上运行良好,但在 一些 Windows 10 PC 上无法启动并出现此错误:
!SESSION 2016-02-14 13:37:46.274 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.6.0_26
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
Command-line arguments: -os win32 -ws win32 -arch x86 -data @none
!ENTRY org.eclipse.equinox.ds 4 0 2016-02-14 13:37:47.563
!MESSAGE FrameworkEvent ERROR
!STACK 0
org.osgi.framework.BundleException: The bundle "org.eclipse.equinox.ds_1.4.101.v20130813-1853 [3]" could not be resolved. Reason: Missing Constraint: Import-Package: org.eclipse.equinox.internal.util.event; version="1.0.0"
at org.eclipse.osgi.framework.internal.core.AbstractBundle.getResolverError(AbstractBundle.java:1332)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.getResolutionFailureException(AbstractBundle.java:1316)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:323)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:390)
at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1176)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
应用程序自带 JRE (1.6.0_26),config.ini
是:
#Product Runtime Configuration File
eclipse.application=bibisco.application
osgi.bundles.defaultStartLevel=4
eclipse.product=bibisco.product
osgi.splashPath=platform:/base/plugins/bibisco
osgi.bundles=org.eclipse.equinox.common@2:start,org.eclipse.update.configurator@3:start,org.eclipse.equinox.ds@2:start,org.eclipse.core.runtime@start
有什么想法吗?
我看了一下项目的MANIFEST.MF,可以看到项目正在声明使用Java 7.
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
但是查看您的日志,您似乎正在(运送和)运行 应用程序 Java 1.6
java.version=1.6.0_26
所以,我和 Modus Tollens 有相同的观察,我的理论是修复 Java 版本可以解决错误。
因此,我认为您可以通过 Java 1.7 分发应用程序来解决这个问题。如果这不是一个选择;您应该在清单中声明使用 Java 1.6,并相应地修复依赖项。
我认为这个非确定性错误可以通过在启动配置中设置启动级别来解决,如下所述: http://www.vogella.com/tutorials/EclipseRCP/article.html#plugin_startlevels
详情:
日志中的主要错误是:eclipse Missing Constraint: Import-Package: org.eclipse.equinox.internal.util.event;版本="1.0.0"
我在网上找到了一些相关的指针:一个topic on eclipse forums, and a comment on an eclipse bug。后一个指针建议使用以下设置解决错误:
<configurations>
<plugin id="org.eclipse.core.runtime" autoStart="true" startLevel="4" />
<plugin id="org.eclipse.equinox.common" autoStart="true" startLevel="2"/>
<plugin id="org.eclipse.equinox.ds" autoStart="true" startLevel="2" />
<plugin id="org.eclipse.equinox.simpleconfigurator" autoStart="true" startLevel="1" />
<plugin id="org.eclipse.update.configurator" autoStart="true" startLevel="4" />
<property name="org.eclipse.update.reconcile" value="false" />
</configurations>
这可能是由初始加载阶段的问题引起的,可以通过更改启动配置和设置启动级别来解决,如下所示:
这些设置与您在 Vogella 教程中看到的设置完全相同 Eclipse RCP > set start levels。