Win a copy of Escape Velocity: Better Metrics for Agile Teams this week in the Agile and Other Processes forum!
  • 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 ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

Methods calling in session bean

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There are two ways to call a method from session bean .
One is client look for each bean and call methods from the beans one after other
Other is bean itself looks for the methods in other beans and then client only calls the reqired method.
Which of this is the right appraoch and when to use them
 
Saloon Keeper
Posts: 26067
186
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What's right is what works for you. It's commonly considered to be good practice to put all your business logic in a session bean and have the session bean do all the interaction with entity beans, but in many simple cases, it's easier to put the business logic in a servlet and invoke the entity beans directly.
The extra layer is most beneficial when creating a business package where you want to provide the business logic totally independent of any user-interface component and/or where you want to take advantage of the extr security mechanisms that EJBs offer.
 
Ranch Hand
Posts: 334
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I just started to learn EJB by follow the examples in "The Java 2 Enterprise Edition Developer's Guide" by Sun.
How to package the files and classes in stead of putting everything in the root directory ? Please comments.
Thanks,
Ruilin
 
incandescent light gives off an efficient form of heat. You must be THIS smart to ride this ride. Tiny ad:
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic