• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

EJB method with use case logic ?

 
Samuel Pessorrusso
Ranch Hand
Posts: 164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,


When I'm in a real project, I don't inject Use Case logic in the EJB methods (Examples: when you set the selected Flights, the EJB method won't automatically search for alternative flights); but for the assignment I'm not sure about it.
What do you think? Should I insert the use case logic in the EJB method or the client (web or client application) need to call each specific method (setSelectedFlights, retrieveAlternativeFlights, priceItinerary, etc...)?


Best Regards
 
Santiago Urrizola
Ranch Hand
Posts: 172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
you can put this logic (consecutives calls) in business delegate
 
Samuel Pessorrusso
Ranch Hand
Posts: 164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hum.. that is a good approach.

Thank you
[ July 19, 2006: Message edited by: Samuel Pessorrusso ]
 
Samuel Pessorrusso
Ranch Hand
Posts: 164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Infact, I've changed my mind. I've read a post from Parag Doshi and he explains the situation very well.
I'm going to use the Session Facade as a real FACADE. Therefore instead of performing two or more remote calls, I will just perform one.

Best Regards
[ July 29, 2006: Message edited by: Samuel Pessorrusso ]
 
Vinay Singh
Ranch Hand
Posts: 174
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't agree with business logic in BD. But yes, use SLSB as real facade.
The business logic can be put in a seperate business domain class for eg Payment logic can be in a different class.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic