什么是适合与 Vaadin 一起使用的紧凑型嵌入式 Servlet 容器?
我正在用 Java 开发一个桌面应用程序,我想使用 vaadin 作为它的用户界面(所以用户将通过其网络浏览器访问它)。我正在使用 Maven,因此如果我的所有依赖项都可以通过 Maven 获得(Vaadin 就是),那是非常可取的。
Vaadin 需要一个 servlet 容器,因此我需要找到一个可以嵌入到我的应用程序中的 servlet 容器,这不会显着增加我的可分发文件的大小(我希望将其保持在几兆字节以下)。
我查看了 Jetty,但我能找到的作为 Maven 依赖项支持的最新版本是 5.1.10,这是一个古老的版本。有一个 Maven 插件,但它试图接管整个应用程序的启动和停止控制,这在这里不合适(Jetty 所属的 UI 只是整个应用程序的一小部分)。
谁能推荐一个小型、易于嵌入的 servlet 容器,可能适合于此?如果您能提供有关如何与 Vaadin 一起使用它的指导,则额外加分:-)
I'm developing a desktop application in Java, and I want to use vaadin as a user interface for it (so the user will access it through their web browser). I'm using Maven, so it is greatly preferred if all of my dependencies are available through Maven (Vaadin is).
Vaadin requires a servlet container, so I need to find a servlet container that I can embed in my app, which won't significantly increase the size of my distributable file (I'm hoping to keep it under several megabytes).
I looked at Jetty, but the latest version supported as a Maven dependency that I could find is 5.1.10, which is ancient. There is a Maven plugin, but that tries to take over control of starting and stopping your entire app, which isn't appropriate here (the UI, which Jetty will be part of, is just a small part of the overall app).
Can anyone recommend a small, easily embeddable servlet container that might be suitable for this? Extra points if you can provide pointers on how to use it together with Vaadin :-)
我正在使用 Jetty 8 和 Maven。该工件更名为 jetty-server 并移至 Eclipse 基础设施。
教程链接:http://wiki.eclipse.org/Jetty/Feature/Jetty_Maven_Plugin
基本上:
运行
就完成了。
I'm using Jetty 8 with Maven. The artifact changed name to jetty-server and moved to Eclipse infrascruture.
Link for the tutorial: http://wiki.eclipse.org/Jetty/Feature/Jetty_Maven_Plugin
Basicaly:
Run
And you are done.