Maven Cargo Plugin を使用して、一連の OSGI バンドルと、Web アプリケーション バンドル (または WAB) とも呼ばれるハイブリッド アプリケーション .war (OSGI を使用する Restservice を使用した Web アプリケーション) をデプロイしようとしています (たとえば、https://glassfish. java.net/public/GF-OSGi-Features.pdf )。
Glassfish 3.1.x への OSGI バンドルのデプロイは正常に機能しますが、Web アプリケーション バンドルをデプロイする方法が見つかりません。
パッケージは「戦争」ですが、OSGIバンドルとして展開する必要があります。では、どうすればこれを Cargo Plugin と言うことができるでしょうか?
私が使用しようとしたmaven構成:
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<version>1.4.0</version>
<configuration>
<wait>false</wait>
<container>
<containerId>glassfish3x</containerId>
<home>${glassfish.home}</home>
<type>installed</type>
</container>
<configuration>
<type>existing</type>
<home>${glassfish.home}</home>
<properties>
<cargo.hostname>localhost</cargo.hostname>
<cargo.rmi.port>4848</cargo.rmi.port>
<cargo.domain.name>${glassfish.domain}</cargo.domain.name>
</properties>
</configuration>
<deployables>
<deployable>
<groupId>com.acme.rest</groupId>
<artifactId>rest-api</artifactId>
<type>bundle</type>
</deployable>
</deployables>
</configuration>
</plugin>
しかし、次のエラーが表示されます。
[エラー] プロジェクト rest-api で目標 org.codehaus.cargo:cargo-maven2-plugin:1.4.0:redeploy (default-cli) を実行できませんでした: Artifact [com.acme.rest:rest-api:bundle] はプロジェクトの依存関係ではありません。-> [ヘルプ 1] org.apache.maven.lifecycle.LifecycleExecutionException: プロジェクト rest-api で目標 org.codehaus.cargo:cargo-maven2-plugin:1.4.0:redeploy (default-cli) を実行できませんでした: Artifact [ com.acme.rest:rest-api:bundle] はプロジェクトの依存関係ではありません。
コンポーネント タイプ「web」としてのデプロイは機能しますが、OSGI バンドルを使用できません...
Web アプリケーション バンドルと OSGI バンドルをデプロイした経験のある人はいますか?