Apache Felix:扩展包是什么?

时间:2022-12-22 02:29:50

Apache Felix has the concept of an "extension bundle". This seems to be a bundle that contributes to the system bundle. There is also a special URL "felix://extensions/" being registered for them.

Apache Felix具有“扩展包”的概念。这似乎是一个有助于系统包的捆绑包。还有一个特殊的URL“felix:// extensions /”正在注册。

When would I need to use extensions as opposed to regular bundles?

我什么时候需要使用扩展而不是常规捆绑?

Are there examples of bundles that use this approach?

是否有使用此方法的捆绑包的示例?

Is this a Felix-only feature or part of the OSGi spec?

这是仅限Felix功能还是OSGi规范的一部分?

2 个解决方案

#1


according to the felix Implement extension bundles issue, extension bundles are described in section 3.15 of the OSGi R4 specification - so it is part of the OSGi spec. both that issue and the spec answers your question about when to use them. for examples, i would check google.

根据felix实现扩展束问题,扩展束在OSGi R4规范的第3.15节中描述 - 因此它是OSGi规范的一部分。该问题和规范都回答了关于何时使用它们的问题。例如,我会检查谷歌。

#2


Please, read paragraph 3.15 (Extension bundles) of the official OSGi Service Platform Core Specification. There are answers on all your questions.

请阅读官方OSGi服务平台核心规范的第3.15段(扩展包)。你的所有问题都有答案。

Here is quote from the Specification:

以下是规格引用:

Extension bundles can deliver optional parts of the Framework implementation or provide functionality that must reside on the boot class path. These packages cannot be provided by the normal import/export mechanisms.

扩展束可以提供Framework实现的可选部分,或者提供必须驻留在引导类路径上的功能。正常的导入/导出机制无法提供这些包。

Boot class path extensions are necessary because certain package implementations assume that they are on the boot class path or are required to be available to all clients. An example of a boot class path extension is an implementation of java.sql such as JSR 169.

引导类路径扩展是必需的,因为某些包实现假定它们位于引导类路径上或者要求所有客户端都可用。引导类路径扩展的一个示例是java.sql的实现,例如JSR 169。

#1


according to the felix Implement extension bundles issue, extension bundles are described in section 3.15 of the OSGi R4 specification - so it is part of the OSGi spec. both that issue and the spec answers your question about when to use them. for examples, i would check google.

根据felix实现扩展束问题,扩展束在OSGi R4规范的第3.15节中描述 - 因此它是OSGi规范的一部分。该问题和规范都回答了关于何时使用它们的问题。例如,我会检查谷歌。

#2


Please, read paragraph 3.15 (Extension bundles) of the official OSGi Service Platform Core Specification. There are answers on all your questions.

请阅读官方OSGi服务平台核心规范的第3.15段(扩展包)。你的所有问题都有答案。

Here is quote from the Specification:

以下是规格引用:

Extension bundles can deliver optional parts of the Framework implementation or provide functionality that must reside on the boot class path. These packages cannot be provided by the normal import/export mechanisms.

扩展束可以提供Framework实现的可选部分,或者提供必须驻留在引导类路径上的功能。正常的导入/导出机制无法提供这些包。

Boot class path extensions are necessary because certain package implementations assume that they are on the boot class path or are required to be available to all clients. An example of a boot class path extension is an implementation of java.sql such as JSR 169.

引导类路径扩展是必需的,因为某些包实现假定它们位于引导类路径上或者要求所有客户端都可用。引导类路径扩展的一个示例是java.sql的实现,例如JSR 169。