It's not a secret anymore!*
The moose likes EJB and other Java EE Technologies and the fly likes Upgrade EJB2 Application to EJB3 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Upgrade EJB2 Application to EJB3" Watch "Upgrade EJB2 Application to EJB3" New topic
Author

Upgrade EJB2 Application to EJB3

Kevin Sheng
Greenhorn

Joined: Jun 26, 2012
Posts: 13
I have EJB2 application and I want to move it to EJB3. Has anyone ever done this? Is it worth doing it?
Your ideas are appreciated.
s patnaik
Ranch Hand

Joined: Jul 17, 2011
Posts: 45

There definitely have been applications that moved to EJB 3.

Whether its worthy or not is for you to decide considering what you want to gain out of it !


SCJP 5, OCPJP7, OCMJEA 5
Kevin Sheng
Greenhorn

Joined: Jun 26, 2012
Posts: 13
Thank you for your reply. Is there any guideline or recommended approach for doing it properly?

Many Thanks
s patnaik
Ranch Hand

Joined: Jul 17, 2011
Posts: 45

Thats a pretty generic question. Have you tried googling for migrating from 2.x to 3.x? There are lots of books and online articles on it.
Off the top of my mind, I enjoyed reading EJB3 in action and that has a chapter for migrating.

David Blevins
Greenhorn

Joined: May 03, 2010
Posts: 18
It's been a while since anyone has tried it, but this Eclipse plugin does have some ability to convert EJB 2.x xml metadata to the equivalent EJB 3.x annotations:

http://www.apache.org/dist/openejb/eclipse-plugin/

It will read the ejb-jar.xml and actually insert the annotations in the code. Note this is maybe 1/3 of the effort. Converting Home and LocalHome to be business interfaces will take some work. As well if you have heavy use of CMP 2.x that will be quite a lot more work to convert to JPA.
Kevin Sheng
Greenhorn

Joined: Jun 26, 2012
Posts: 13
Thanks for the information.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Upgrade EJB2 Application to EJB3
 
Similar Threads
Issue with jboss tibco integration after tibco EMS restart
EJBObject question.
EJB 2 or EJB 3 in SCEA part I
overriding container settings for indivisual bean
SCBCD5 Books