• Post Reply Bookmark Topic Watch Topic
  • New Topic

Build EJB from bean class with ANT

 
Simon Cockayne
Ranch Hand
Posts: 214
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Given a java session bean class ONLY (without no remote interface and home interface or deployment descriptor), is it possible to use ANT to automatically build a full generic (or indeed vendor specific) EJB?

I ask since a colleuge of mine INSISTS he has seen this done, yet my initial research e.g. http://ant.apache.org/manual/OptionalTasks/ejb.html, indicates that the ejbjar task requires a deployment descriptor to exist in advance.

Moreover, it appears the ejbjar task ASSEMBLES the components an EJB, rather than actually CREATING them, e.g. the home and remote interfaces.

Regards,

Simon.
 
Valentin Tanase
Ranch Hand
Posts: 704
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Simon,

That�s very possible though and many projects follow a similar approach. However there is one more requirement to the java session bean class: it should contain special tags that could be introspected by tools like ejbgen or xDoclet, in order to generate other ejb specific artifacts including deployment descriptors, home and remote interfaces, etc. These tools provide also special plugins for ant and they could be invoked as batch process from within ant.
Regards.
 
Simon Cockayne
Ranch Hand
Posts: 214
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Valentin,

Thanks for the feedback.

Much obliged,

Si.
 
Valentin Tanase
Ranch Hand
Posts: 704
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're very welcome Simon
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!