我目前正在开发一个应用程序,其服务器部分基于JavaEE 6.0,基于JBos.1和基于Eclipse RCP 3.7的客户。
For a simple OSGi package for a shared API I already run into trouble due to some differences in versions and depdencenies. The API requires "org.osgi.framework." for the bundle activator and "org.slf4j." for the slf4j logging API.
目前,我的客户工作良好,但JBoss告诉我,OSGi进口的预期版本和Slf4j的进口也不符合......。
我在Eclipse和JBos之间交流OSGi捆包的最佳做法? 我是否需要回到简单的进口和出口申报中,或者我能够利用“需求-选择”? 我是否需要为联合博爱建立一些相容的 b,以使之得以运行? 下一步工作的最佳方式是什么?
UPDATE I solved the issue by using Import-Package exclusively. For the dependency like org.osgi.framework is use version="0.0" to explain it does not matter. :-( It is not very safe, but currently I do not see another option. Is there a better way?
UPDATE 2 One also needs to pay attention to implement the correct verion of the OSGi Framework. JBoss 7.1.x only has OSGi 4.2 implemented, which has no support for typesafe service retrieval.