Plugin product VS Feature product

≡放荡痞女 提交于 2019-12-19 03:22:59

问题


In the context of an RCP application I am wondering if I should base my product on plugins or on features.

The main difference I can see for now is about the content of the exported application.

Using plugins as product base result in an exported (with GUi or headless build, it's the same) with ALL the required plugins (computed I guess through plugins manifest).

On the opposite, when using feature as bases the exported product only contain the listed features in the product file. Thus I have to add manually add all the required features in order to let my product work correctly. This also has the side effect to bring all the features plugins even if they are not needed.

What are your experiences on the subject ?

EDIT As suggested by Vonc comments I created my own feature including only plugins I need from other features. This solution works but I have to manually add all the required plugins by my product in this feature. Today to do that, the only solution I found is to use the launch configuration plugins tabb with the compute required plugins button and to report by hand in my feature all the selected plugins. It's really boring :-( Is there any other solutions existing ?

Thanks


回答1:


After many investigations here is a "clear" (I hope) status on the subject.

Plugin Products:

  • No problem when building (Gui or headless) => all the required (the same than the required plugins computed in the launch configuration dialog when debugging the app) plugins are present
  • The RCP application disk footprint is optimized !! No useless plugins
  • No features are exported: as a ressult the features list tab of about dialog is empty !!!
  • It seems that plugin products are not recommended for RCP with self update (I didnd't tested that yet)

Feature Products:

  • When exporting (headless), the only present plugins and features are the one listed in the .product file
  • Need to create a "dependencies" features including all the required plugins OR depend on all the features containing the required plugins => bring a lot of useless plugins
  • Features listed in the about dialog

In my personal situation, I decided to use a Feature Product and then to "manually" create a feature including all the 90 plugins required by my RCP.

Because I am lazy and hate repetitive tasks, I wrote a simple Java main parsing a launch configuration file (.launch located in the workspace metadata folder) and generating from a template the feature with all the required dependencies.

Hope this can help others, and if you need my simple Java feature dependency creator, just ask it.

Manu



来源:https://stackoverflow.com/questions/3140299/plugin-product-vs-feature-product

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!