• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

ejb-link ??

 
Deep Chand
Ranch Hand
Posts: 133
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ejb-link is an optional element. Then why an App Assembler would provide the ejb-link element in the DD? If the bean/app would work even without the ejb-link element then what's the need of providing this extra element i.e. if the (ejb-ref-name, ejb-ref-type, home, remote) are sufficient to get a bean home interface then why introduce one more link stuff. Any ideas?

May be I'm missing something.

Thanks
Deep
 
Gemini Moses
Ranch Hand
Posts: 245
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
DTD fro DD is showing ejb-link as optional element as when Bean provider puts ejb-ref element in DD , he is not going to put ejb-link element in there.

However functinaly it does not make sence having run the application without having <ejb-link> element in ejb-ref, as the mapping wont be known.

Anybody to confirm this?

Gemini
 
Keerthi P
Ranch Hand
Posts: 203
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If the bean/app would work even without the ejb-link element then what's the need of providing this extra element


Your application won't work if the ejb references are not properly resolved with ejb-link element. You get big fat NamingException when looking up using the reference.
 
Gemini Moses
Ranch Hand
Posts: 245
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Kirti for you insight.

Deep,
I also notice on http://java.boot.by/bcd-guide/ch14.html --

A role-link element must be used even if the value of role-name is the same as the value of the role-link reference.

Thanks
Gemini
[ March 21, 2005: Message edited by: Gemini Moses ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic