In EJB2.1 using XDoclet was a 'must' in my opinion to avoid pulling your hair out - you'd annotate just one EJB and get everything else built for you. EJB3 seems to make things much better with the use of annotations and I could pretty much get rid of XDoclet, but I'm curious why they don't have the default behavior of annotating the ejb with @Remote(MyRemoteInterface.class) or @Local(SomeInterface.class) automatically generate those interfaces if they don't exist? The majority of time your interface is just the contract for your ejb and the method implementations match up perfectly. Seems like the generation of the interfaces could be done for you by the container (you could always change this behavior by providing your own of course.)
posted 10 years ago
To clarify a bit, I can see this idea not working so well for the creation of Remote interfaces since the container would be required to create the Remote interface that you'd need to hand off to your client. At least, though, for local interfaces, I would think the container could automatically create that for an annotated EJB.