I've recently been given the opportunity to rewrite a legacy Java application that uses Session and Entity EJBs using EJB 1.0 and 1.1 deploying on WebLogic 5.1. I'm getting a bit confused as to what the best option is here, so thought I'd see if anyone had any opinions.

The original suggestion was that the application was upgraded to EJB 2.1 deploying on GlassFish, but I'm now not sure whether it would be better to go straight to EJB 3 or to use an alternative such as Spring/Hibernate.

Does anyone have any advice on this? Any suggestions gratefully received as theres noone here who I can ask!