为 RCP 应用程序构建更新站点的最佳方式
我有一个 RCP 应用程序,包括:
产品定义文件位于主插件中(这是一个坏主意吗?)。
产品定义基于“插件”,并且依赖于工作区中的所有插件。
现在,我希望 RCP 应用程序的用户能够更新该应用程序。这包括新的/更改的 HTML 帮助文件、新插件、现有插件中更改的代码等。
我需要什么才能做到这一点?
设置工作区/项目层次结构的最佳方法是什么?
I have an RCP app, consisting of:
The product definition file lives in the main plug-in (is this a bad idea?).
The product definition is based on "plug-ins", and has a dependency upon all the plug-ins in the workspace.
Now, I want the user of the RCP app to be able to update the app. This includes new / changed HTML help files, new plug-ins, changed code in existing plug-ins etc.
What do I need to be able to do this?
What is the best way to set up my workspace / project heirarchy?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您应该做的第一件事是确保您的 RCP 产品基于功能,而不是插件。在您的产品概述选项卡中,选择“产品配置基于功能”。我认为不可能制作没有功能的可更新产品,但我可能是错的,Eclipse 变化如此之快。无论如何,在执行此操作之前,您当然应该定义您的功能并将插件分配给这些功能。更新的是功能,当自动更新过程发生时,这些功能会拖动与其关联的插件。确保您的功能保持正确的版本,以便更新管理器能够检测更新更改。一旦你把这一切都解决了,你就可以构建一个更新站点,这可以在 Eclipse 中通过创建新的“更新站点项目”来完成。然后您将向其中添加您的功能。当您构建此项目时,它将根据您指定的功能(当然还有插件)生成实际的更新站点结构。采取整个结构并将其部署在某个远程站点上。我将其保存在我的网站上,但它可以在任何地方。是的,在定义功能时,请确保指定更新站点 URL,您的应用程序更新管理器将在此处查找已安装功能的更新。以上所有内容都适用于 eclipse 3.3,也许在新版本中它更加优化,但我相信主要思想不会改变。
可能有一种更简单的方法可以做到这一点,但这就是我这样做的方式..如果您找到更好的方法,请告诉我:)
First thing you should do is to make sure that your RCP product is based on features, not plug-ins. In your product overview tab select "The product configuration is based on features".. I think it's not possible to make update-able product without features, but I could be wrong, eclipse is changing so fast. Anyway, before doing this, you should, of course, define your features and assign plug-ins to those features. What gets updated are features, which drag along the plug-ins associated with them when automatic update process take place. Make sure you keep your features properly versioned so that update manager will be able to detect update changes. Once you've got this all sorted out, you build an update site, this can be done in Eclipse by creating new "Update Site Project". You will then add your features to it. When you build this project it will produce the actual update site structure, based on the features (and of course plug-ins) you specified. Take this whole structure and deploy it on some remote site. I keep it on my web site, but it could be anywhere. And yes, when defining the feature, make sure to specify the update site URL, this is where your application update manager will be looking for the updates of installed features. All above is valid for eclipse 3.3, perhaps in newer versions it's more optimized, but I believe the main idea won't change.
May be there is a simpler way of doing this, but this is the way I do it.. let me know if you find a better way :)
我使用以下资源来帮助我解决此问题:
祝你好运。
I was using the following resources to help me with this problem:
Good luck.