可以在沙盒中运行的Mini-OSGi(如AppEngine或WebStart)?

时间:2022-10-12 23:15:45

I really like the concept of modular bundles as implemented by OSGi.

我非常喜欢OSGi实现的模块化bundle的概念。

I also like "managed deployment" services like Google AppEngine (for web application) or Java WebStart (for client software).

我也喜欢“托管部署”服务,如Google AppEngine(用于Web应用程序)或Java WebStart(用于客户端软件)。

These two ideas seem to complement each-other rather well conceptually.

这两个想法似乎在概念上相互补充。

However, the OSGi standard includes a couple of features that make it impossible for implementations like Felix or Equinox to run on top of sandboxed virtual machines, such as AppEngine or Webstart. In these environments, it is not possible to get direct access to a file system, for example, which precludes the OSGi bundle cache that is used to store persistent bundle state and native libraries.

但是,OSGi标准包含一些功能,使得像Felix或Equinox这样的实现无法在沙盒虚拟机(如AppEngine或Webstart)之上运行。在这些环境中,无法直接访问文件系统,例如,这会阻止用于存储持久性捆绑状态和本机库的OSGi捆绑缓存。

Now, I have no great interest in using native libraries or have persistent bundle state. Is there some framework that implements the core bundle and services concept of OSGi (ideally in a compatible way so that OSGi bundles can be deployed into it as is), but can work without a bundle cache (and other facilities not available in a sandbox)?

现在,我没有兴趣使用本机库或具有持久的bundle状态。是否有一些框架实现了OSGi的核心包和服务概念(理想情况是以兼容的方式使OSGi包可以按原样部署到其中),但是可以在没有包缓存(以及沙箱中不可用的其他工具)的情况下工作?

I am looking for something like a limited version of Felix that works on AppEngine or WebStart.

我正在寻找类似于在AppEngine或WebStart上运行的有限版本的Felix。

Of course, if the WebStart engine and the Google AppEngine just provided OSGi framework services out-of-the-box that would be great, too...

当然,如果WebStart引擎和Google AppEngine刚刚提供了开箱即用的OSGi框架服务,那也很棒......

Update: Another very limiting aspect of AppEngine is that you cannot start new Threads. This prevents (among other things) asynchronous bundle life-cycle management. Obviously not an issue with WebStart.

更新:AppEngine的另一个非常有限的方面是你无法启动新的线程。这可以防止(除其他外)异步包生命周期管理。显然不是WebStart的问题。

5 个解决方案

#1


EclipseSource have a patched version of osgi engine that (kind of) working in AppEngine, download the project zip files from the blog: http://eclipsesource.com/blogs/2009/04/10/osgi-on-appengine/

EclipseSource有一个修补版的osgi引擎(有点)在AppEngine中工作,从博客下载项目zip文件:http://eclipsesource.com/blogs/2009/04/10/osgi-on-appengine/

#2


I'm pretty sure it can be done, and This eclipse help page could probably get you started. If I understand it correctly, your bundles must be signed and your jnlp file needs to request all permissions.

我很确定它可以完成,而这个eclipse帮助页面可能会让你开始。如果我理解正确,您的捆绑包必须签名,并且您的jnlp文件需要请求所有权限。

#3


You should talk to Chris Aniszczyk. He made it work with Equinox and Knopflerfish. See the screenshot here: http://twitpic.com/300lk He was planning on blogging about it, but I guess he is pretty busy at the moment. Here is the link to his blog: http://mea-bloga.blogspot.com/

你应该和Chris Aniszczyk谈谈。他与Equinox和Knopflerfish合作。请看这里的截图:http://twitpic.com/300lk他正在计划博客,但我猜他现在很忙。以下是他博客的链接:http://mea-bloga.blogspot.com/

#4


http://code.google.com/p/lemmon/

however, check the issues for URLStreamHandler Problem.

但是,请检查URLStreamHandler问题。

No personal experience, just a clue that might help you.

没有个人经验,只是一条可能对您有帮助的线索。

#5


If your sole problem comes from the bundle cache and you don't need it, you can may be get rid of it by set this property to null in Equinox or Felix ? I'm pretty sure that this cache is not mandatory to have Equinox to run (don't know for Felix)

如果您的唯一问题来自捆绑缓存并且您不需要它,您可以通过在Equinox或Felix中将此属性设置为null来摆脱它吗?我很确定这个缓存不是必须运行Equinox(不知道Felix)

#1


EclipseSource have a patched version of osgi engine that (kind of) working in AppEngine, download the project zip files from the blog: http://eclipsesource.com/blogs/2009/04/10/osgi-on-appengine/

EclipseSource有一个修补版的osgi引擎(有点)在AppEngine中工作,从博客下载项目zip文件:http://eclipsesource.com/blogs/2009/04/10/osgi-on-appengine/

#2


I'm pretty sure it can be done, and This eclipse help page could probably get you started. If I understand it correctly, your bundles must be signed and your jnlp file needs to request all permissions.

我很确定它可以完成,而这个eclipse帮助页面可能会让你开始。如果我理解正确,您的捆绑包必须签名,并且您的jnlp文件需要请求所有权限。

#3


You should talk to Chris Aniszczyk. He made it work with Equinox and Knopflerfish. See the screenshot here: http://twitpic.com/300lk He was planning on blogging about it, but I guess he is pretty busy at the moment. Here is the link to his blog: http://mea-bloga.blogspot.com/

你应该和Chris Aniszczyk谈谈。他与Equinox和Knopflerfish合作。请看这里的截图:http://twitpic.com/300lk他正在计划博客,但我猜他现在很忙。以下是他博客的链接:http://mea-bloga.blogspot.com/

#4


http://code.google.com/p/lemmon/

however, check the issues for URLStreamHandler Problem.

但是,请检查URLStreamHandler问题。

No personal experience, just a clue that might help you.

没有个人经验,只是一条可能对您有帮助的线索。

#5


If your sole problem comes from the bundle cache and you don't need it, you can may be get rid of it by set this property to null in Equinox or Felix ? I'm pretty sure that this cache is not mandatory to have Equinox to run (don't know for Felix)

如果您的唯一问题来自捆绑缓存并且您不需要它,您可以通过在Equinox或Felix中将此属性设置为null来摆脱它吗?我很确定这个缓存不是必须运行Equinox(不知道Felix)