Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

EJB 3.1 - Deploying EJBs through a WAR file

 
Joe Harry
Ranch Hand
Posts: 10122
3
Eclipse IDE Mac PPC Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Guys,

I went through the postings at theserverside and I'm concerned on one of the following features in EJB 3.1. We can deploy our EJB's in the same location where we deploy our servlets meaning they do not have to be in a seperate jar file. What would it mean to Application Servers like Weblogic and the controvercial App/Web container Tomcat?


[Edited by Jaikiran - Changed the original subject line "Question on EJB 3.1"]
[ December 17, 2008: Message edited by: Jaikiran Pai ]
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jothi, I'm moving your thread to the EJB forum.
 
Jaikiran Pai
Marshal
Pie
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Jothi Shankar Kumar Sankararaj:
We can deploy our EJB's in the same location where we deploy our servlets meaning they do not have to be in a seperate jar file. What would it mean to Application Servers like Weblogic and the controvercial App/Web container Tomcat?

From the serverside discussion:

Support for direct use of EJBs in the servlet container, including simplified packaging options. The current thought is to allow EJBs in the WEB-INF/classes directory while allowing ejb-jar.xml to reside in the WEB-INF directory, just like the web.xml file.

I don't know why this approach is being proposed. I don't see a reason why the Enterprise Java Beans are being proposed to be deployed through a WAR file. The only reason i can think of is, maybe to avoid creating an EAR. I'll have to read the JSR to understand more.

However, do note that you can still package the EJBs in a separate jar (within the WEB-INF/lib). Here's the next sentence from that quote:

In a similar vein, you would be able to place an EJB jar into the WEB-INF/lib directory.
 
Reza Rahman
author
Ranch Hand
Posts: 580
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jothi,

What specifically are you concerned about? In this case, Java EE app servers would support EJBs packaged in EJB-JAR/EAR as well as just a WAR? Are you aware app servers today have to support standalone WARs just as Tomcat, Jetty, etc do?

Regards,
Reza
 
Joe Harry
Ranch Hand
Posts: 10122
3
Eclipse IDE Mac PPC Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Reza Rahman:
Jothi,

What specifically are you concerned about? In this case, Java EE app servers would support EJBs packaged in EJB-JAR/EAR as well as just a WAR? Are you aware app servers today have to support standalone WARs just as Tomcat, Jetty, etc do?

Regards,
Reza


My concern is we can use Tomcat for deploying EJB's which is really amazing!
 
Dmitry Zhelezov
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Jothi Shankar Kumar Sankararaj:


My concern is we can use Tomcat for deploying EJB's which is really amazing!


Have you considered OpenEJB for this? I've read in
this article that it's pretty simple, however, I have no experience with it. Besides, you probaly need JTA implementation, and JOTM is good enough for middle-sized applications, but anyway has limited functionality.
 
Reza Rahman
author
Ranch Hand
Posts: 580
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dmitry,

Actually, you do not need JOTM with OpenEJB and Tomcat. OpenEJB comes with a JTA implementation.

I still don't quite understand what the issue with being abe to use EJB 3 in Tomcat or some other lightweight application server is? In fact, Java EE 6 profiles are aiming to make is possible to have lighter versions of WebLogic, WebSphere, GlassFish, JBoss, etc? What's the concern?

Best regards,
Reza
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic