• Post Reply Bookmark Topic Watch Topic
  • New Topic

local interfaces & stub generation  RSS feed

 
Mahesh Asrani
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All

I hope my doubt is quiet valid. Forgive me if this question sounds frivolous.

The advantage of local interfaces (local home & local component) is if we have the calling entity & the ejb on the same box we can avoid a remote call (ie. no need for call by value) & we can leverage call by reference.

Does this mean that when we have local EJBHome & local EJBObject the stubs & skeletons for the same are not generated as stubs & skeletons are only required in a remote invocation

Do put in your thoughts

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


Does this mean that when we have local EJBHome & local EJBObject the stubs & skeletons for the same are not generated as stubs & skeletons are only required in a remote invocation

As a matter of fact modern containers use dynamic proxies. This way there is no need to generate traditional stubs & skeletons as the traditional RMI systems does. Therefore a client application that talks to an EJB, doesn�t include what we would expect to be client stubs. It only requires the home and remote interfaces (along with their local siblings), the bean class and all other common classes. You might ask though how the client and server talk then? Well the answer relies upon the RMI dynamic class-loading feature.
Regards.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!