开发者

What lift do I gain from using EJB3 in my seam project?

开发者 https://www.devze.com 2022-12-27 06:07 出处:网络
I am starting a new seam project targeted at a JBoss EAP server and I have very little experience with EJB3.What do I gain from using EJB3 over just using a war proje开发者_JS百科ct with pojos and sea

I am starting a new seam project targeted at a JBoss EAP server and I have very little experience with EJB3. What do I gain from using EJB3 over just using a war proje开发者_JS百科ct with pojos and seam annotation?


Don't know Seam but you must know that in EJB3.1 specs you can put your ejb's inside a war... See http://community.jboss.org/wiki/EJB31inAS600M2 Glassfish v3 also support it i think.

I guess Tomcat supports/will support it too but anyway you can use EJB3 in Tomcat with an embedded EJB3 impl like OpenEJB ( http://openejb.apache.org/ )


This has been asked a lot on the Seam forum and there's never been any great reason to use the EAR project over WAR. On the flip-side there are several advantages to using WAR projects for example:

  • Hot deploy of code
  • Use lightweight server eg Tomcat

Most of the EJB features have been made available to WAR projects (eg. Transactions, Clustering etc)


We use EJB's extensively in our project. I tend to like normal JavaBeans better, however after two years, I finally got one of the key benefits of EJB, and that is that you can create a new implementation without changing any other code.

We upgraded a key component, but all the interface methods where the same. Thus we only needed to create a new implementation and deprecate the old one.

I also want to note that JRebel 3.0 provides hot deployment of EJB's.

0

精彩评论

暂无评论...
验证码 换一张
取 消