• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Tim Cooke
  • Devaka Cooray
  • Ron McLeod
  • Jeanne Boyarsky
  • Liutauras Vilda
  • paul wheaton
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Carey Brown
  • Tim Holloway
  • Martijn Verburg
  • Frits Walraven
  • Himai Minh

HFE: Pages 107 and 109

Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello all,
I was hoping I could get some clarification on the solution (p. 109) to the exercise on p. 107. I have read Kathy's response (see link) to a similar question but I would like to follow up. I'm sorry if I'm splitting hairs here -- maybe this is getting too detailed...


The solution (p. 109) shows the EJBObject interface and Home stub class are both needed on the server. Kathy's posting (above) indicates that the Home interface and EJB object stub class are needed on the server as well.
So, page 109 plus Kathy's post means the following are all needed on the server:
1. EJBObject interface
2. EJB object stub class
3. Home interface
4. Home stub class
Now, if we assume the client already has local access to the stub classes why should the stub classes have to also reside on the server? I realize the stub classes are [bold]generated[/bold] on the server at deployment time but once these generated stubs are distributed to the client(s), why should they be needed on the server? Keep in mind I'm talking about the stub classes, not the stub objects which, obviously need to be present on the server so they can be downloaded to clients.
The only possible reason I can see for the stub classes to reside on the server is if we're doing dynamic class downloading (as in RMI) but if we are [bold]not[/bold] doing that, if the clients already have the stub classes, then why does the server need them?
Similarly, why are the EJBObject interface and Home interface needed on the server after stub generation has occurred? These interfaces are obviously needed [italics]during[/italics] stub generation but I don't see why they're needed after. Again, if we were doing dynamic class downloading then these interfaces would have to be present on the server but otherwise, I think they should be unnecessary.
He's giving us the slip! Quick! Grab this tiny ad!
the value of filler advertising in 2021
    Bookmark Topic Watch Topic
  • New Topic