Jetty 8 + EJB 3.1 + JTA + CDI + JPA 2堆栈? [英] Jetty 8 + EJB 3.1 + JTA + CDI + JPA 2 stack?

查看:111
本文介绍了Jetty 8 + EJB 3.1 + JTA + CDI + JPA 2堆栈?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人能告诉我目前是否可以通过Jetty粘合部分Java EE 6 Web配置文件?
我发现很多关于将独立EJB 3容器,JTA提供程序等与旧Jetty版本集成的文章,所以如果我可以让它全部协同工作,那我就更有意思了。
我想组装一个Servlet 3.0 + CDI + EJB 3.1 + JTA(如果需要,我真正想要的是声明式事务管理)+ Jetty 8上的JPA 2环境(如果没有可用的Jetty替代品,则为Tomcat 7) 。
我的问题是:可以吗?有人设法做到了吗?有关获取OpenEJB,Atomikos,Weld,EclipseLink和Jetty(或任何其他类似堆栈)一起工作的任何文章?那里有任何神奇的全部pom.xml文件吗?

Can anyone tell me if it is currently possible to "glue together" a partial Java EE 6 Web Profile over Jetty? I've found a lot of articles about integrating standalone EJB 3 containers, JTA providers, etc with older Jetty versions, so I wounder if I could make it all work together. I would like to assemble a Servlet 3.0 + CDI + EJB 3.1 + JTA (if needed, all I really want is declarative transaction management) + JPA 2 environment over Jetty 8 (or Tomcat 7 if no Jetty alternatives are available). My questions are: Can it be done? Has anyone managed to do that? Any articles about getting OpenEJB, Atomikos, Weld, EclipseLink and Jetty (or any other similar stack) working together? Any magical "do it all" pom.xml files out there?

PS:是的,我知道我可以使用GlassFish(我非常喜欢)。我只是想知道如何使用Servlet容器获得类似的功能,以及两个环境在复杂性,性能,大小,部署速度,硬件资源消耗等方面的比较。

PS: Yeah, I know I could just use GlassFish (which I like very much). I'm just wondering about how hard would it be to get something similar working with a Servlet Container, and how the two environments would compare in terms of complexity, performance, size, deploying speed, hardware resource consumption, etc.

推荐答案

我将其描述为仍处于早期阶段,但这是我们目前所做的:

I'd describe this as still in the early stages, but here is what we have so far:

http:// svn .apache.org / repos / asf / openejb / trunk / openejb3 / assembly / openejb-jetty /

注意,Apache TomEE生活在类似的路径上,即'assembly / openejb-tomcat'。计划是调用Jetty版本Apache JetSet并使其完全嵌入。大多数提交者目前正致力于使Apache TomEE正式通过Java EE 6 Web Profile认证。我将这项工作描述为处于后期阶段。我们在Amazon EC2中进行了很好的设置,使用一百个EC2 t1.micro点实例运行针对TomEE的Web配置文件TCK。这很甜蜜。与Apache和Oracle的TCK协议不允许我们公开共享访问权限。但是,任何Apache提交者都可以签署NDA来获取访问权限。

Note, Apache TomEE lives at a similar path, i.e. 'assembly/openejb-tomcat'. Plan is to call the Jetty version Apache JetSet and have it be fully embeddable. Most people with commit are currently working on getting Apache TomEE to be officially Java EE 6 Web Profile certified. I'd describe that work to be in the late stages. We've a great setup in Amazon EC2 to run the web profile TCK against TomEE using a hundred EC2 t1.micro spot instances. It's pretty sweet. The TCK agreement with Apache and Oracle does not allow us to share access publicly. However, any Apache committer can sign an NDA to get access.

好的,所以我提到了有关TomEE的所有信息,因为计划是在我们完成Tomcat版本之后,用Jetty(JetSet)重新做一遍。我们中的许多提交者,例如我自己和Jonathan Gallimore,实际上更喜欢Jetty。但是随着Tomcat集成代码的进一步发展并拥有更多用户,我们决定首先完成该代码。有大量的工作不是Tomcat特定的,我们将能够在Jetty版本中使用;合法访问TCK,使其运行的代码堆,更多的代码使其自动化,以及大量通用且不特定于Tomcat的集成位。

Ok, so I mention all that about TomEE because the plan is once we're done with the Tomcat version, to do it all over again with Jetty (JetSet). Many of us committers, myself and Jonathan Gallimore for example, actually prefer Jetty by a large margin. But as the Tomcat integration code was much further along and had more users, we decided to just finish that one first. There is an incredible amount of work that isn't Tomcat specific that we will be able to leverage in the Jetty version; getting access to the TCK legally, the heaps of code to get it to run, the more heaps of code to get it automated, and numerous integration bits which are generic and not specific to Tomcat.

所有这一切都说,没有其他人必须等待Jetty版本的工作,因为我们大多数人仍在完成Tomcat版本。 Apache项目应该被视为一起工作的个人,而不是Oracle,Redhat或VMWare等公司。这可能既好又坏。好的一面是,如果您或其他任何人想要破解Jetty版本,您现在就可以做到这一点。你必须提交一段时间的补丁,直到你获得提交,但让其他人做实际的提交命令并不是那么糟糕。如果你从小做起并保持活跃和开放,通常很容易获得提交。快速获得补丁的关键是稳定的小到中等大小的补丁。在我看来,任何向前或向侧面没有退步的步骤都是一个很好的补丁。只要人们能够看到你去哪里,它就足够了。肯定比一大补丁方法更敏捷,并允许所有真正有趣和协作的魔术一路上发生。

All that said, there's no reason others have to wait to work on a Jetty version just because most of us are still finishing the Tomcat version. Apache projects should be viewed as individuals working together, not companies like Oracle or Redhat or VMWare. That can be both good and bad. The good part is that if you or anyone else wants to hack on the Jetty version you can do that right now. You'll have to submit patches for awhile till you earn commit, but having someone else do the actual commit command is not that bad. If you start small and stay active and open, it's usually pretty easy to earn commit. The key to getting patches in quickly is a steady stream of small to moderately sized patches. Any step forward or sideways with no steps backward is a good patch in my opinion. As long as people can see where you're going it's good enough. Certainly more Agile than the one-big-patch approach and allows for all the really fun and collaborative magic to happen along the way.

一些线程可能是一个很好的地方问好。第1步就是打招呼。无需手头的代码在开发列表上进行交谈或认真对待:

Some threads which would be good places to say hello. Step 1 is just to say hello. No need to have code in hand to talk on the dev list or be taken seriously:

http://openejb.979440.n4.nabble.com/Jetty-Integration-td1457408.html
http://openejb.979440.n4.nabble.com/Jetty-Integration-td2318962.html

这篇关于Jetty 8 + EJB 3.1 + JTA + CDI + JPA 2堆栈?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆