2011-01-03 10 views
3

私はこれを何時間も見つけましたが、何か役に立つものが見つかりませんでした。 私はいくつかのOSGiバンドルを開発してきたし、今私は春分のコンテナ内のEclipse IDEの外でそれらを実行したいが、それは常に例外をスロー:適切な春分のインストールをセットアップする方法

!SESSION 2011-01-03 14:26:58.958 ----------------------------------------------- 
eclipse.buildId=unknown 
java.version=1.6.0_20 
java.vendor=Sun Microsystems Inc. 
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=de_CH 
Framework arguments: -Dosgi.clean=true -Declipse.ignoreApp=true -Dosgi.noShutdown=true -console; 
Command-line arguments: -consoleLog -Dosgi.clean=true -Declipse.ignoreApp=true -Dosgi.noShutdown=true -console; 

!ENTRY org.eclipse.osgi 4 0 2011-01-03 14:26:59.567 
!MESSAGE Error starting bundle: [email protected]:file:javax.transaction_1.1.1.v201006150915.jar/ 
!STACK 0 
org.osgi.framework.BundleException: A fragment bundle cannot be started: javax.transaction_1.1.1.v201006150915 [49] 
     at org.eclipse.osgi.framework.internal.core.BundleFragment.startWorker(BundleFragment.java:228) 
     at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:284) 
     at org.eclipse.core.runtime.adaptor.EclipseStarter.startBundle(EclipseStarter.java:1133) 
     at org.eclipse.core.runtime.adaptor.EclipseStarter.startBundles(EclipseStarter.java:1126) 
     at org.eclipse.core.runtime.adaptor.EclipseStarter.loadBasicBundles(EclipseStarter.java:646) 
     at org.eclipse.core.runtime.adaptor.EclipseStarter.startup(EclipseStarter.java:301) 
     at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:175) 
     at org.eclipse.core.runtime.adaptor.EclipseStarter.main(EclipseStarter.java:150) 
init dd core... 

!ENTRY org.eclipse.osgi 4 0 2011-01-03 14:26:59.773 
!MESSAGE Bundle javax.transaction_1.1.1.v201006150915 [49] is not active. 

(「INIT DDコア...」テキストが来ます。適切に私のプロジェクトから)

私は、次のファイルの構造を有する:

+configuration 
+config.ini 
+ch.thobens.dd.commands_1.0.0.jar 
+ch.thobens.dd.common.items_1.0.0.jar 
+ch.thobens.dd.core_1.0.0.jar 
+ch.thobens.dd.game_1.0.0.jar 
+javax.transaction_1.1.1.v201006150915.jar 
+org.eclipse.core.contenttype_3.4.100.v20100505-1235.jar 
+org.eclipse.core.jobs_3.5.0.v20100515.jar 
+org.eclipse.core.runtime.compatibility.auth_3.2.200.v20100517.jar 
+org.eclipse.core.runtime.compatibility.registry_3.3.0.v20100520/runtime_registry_compatibility.jar 
+org.eclipse.core.runtime_3.6.0.v20100505.jar 
+org.eclipse.equinox.app_1.3.0.v20100512.jar 
+org.eclipse.equinox.common_3.6.0.v20100503.jar 
+org.eclipse.equinox.preferences_3.3.0.v20100503.jar 
+org.eclipse.equinox.registry_3.5.0.v20100503.jar 
+org.eclipse.osgi.services_3.2.100.v20100503.jar 
+org.eclipse.osgi_3.6.0.v20100517.jar 

を、私のconfig.iniファイルには、次のような内容があります。

[email protected], [email protected], [email protected], or[email protected]start,org.eclipse.core.runtime.compatibility.registry_3.3.0.v20100520/[email protected], [email protected], [email protected], [email protected]:start, [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]:start 
eclipse.ignoreApp=true 
osgi.noShutdown=true 

ここに表示されているバンドルは、実行設定で「必要なプラグインを追加」を選択した場合に選択されるバンドルと同じバンドルです。 Eclipse PDEからこれらのバンドルを実行すると、正常に動作します。

さらに、私は(eclipse.exeを介して)春分ランチャーを使用する場合、コマンドを

java -jar org.eclipse.osgi_3.6.0.v20100517.jar -consoleLog -Dosgi.clean=true -Declipse.ignoreApp=true -Dosgi.noShutdown=true 

を実行するとの間に違いはありません。任意のヘルプ

答えて

6

ため

おかげで私は(Eclipse製品の輸出を通じて)解決策を見つけた:

をjavax.transaction_1.1.1.v201006150915.jarは、OSGiのは、自分自身を束ねないで、それはOSGiフレームワークの拡張機能です。私はconfig.iniファイルに変更しなければならなかった

のOSGi: プロパティosgi.bundlesに javax_transactionバンドルのエントリを削除し

  1. は、次の行を追加しました。 framework.extensions = javax.transaction_1.1.1.v201006150915.jar

+2

実際にjavax.transactionは断片バンドルのようです。 osgi.bundlesリストに残しておけば、 '@ start'を削除するだけです。しかし、とにかく私はこのエラーが致命的であるとは思わないので、アプリケーションを実行し続けることができます。それはログのような例外を持っているとうまくいきません;-) –

関連する問題