This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Journey To Enterprise Agility and have Daryl Kulak & Hong Li on-line!
See this thread for details.
Win a copy of The Journey To Enterprise Agility this week in the Agile and Other Processes forum! And see the welcome thread for 20% off.
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Jeanne Boyarsky
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
Sheriffs:
  • Paul Clapham
  • Junilu Lacar
  • Knute Snortum
Saloon Keepers:
  • Ron McLeod
  • Ganesh Patekar
  • Tim Moores
  • Pete Letkeman
  • Stephan van Hulst
Bartenders:
  • Carey Brown
  • Tim Holloway
  • Joe Ess

Confused about Pet Store controllers and J2EE patterns  RSS feed

 
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
After some studying Pet Store WAF, J2EE patterns and Cade's component diagrams some questions came up...

How does Pet Store Web Controller relate with patterns Business Delegate and Service Locator? Can we think of Web controller as a component including Business Delegate and Service Locator?

Can we think of EJB Controller as a session facade? Cade is using stateless session bean, WAF EJB Controller is a stateful one (why?).

In general.. do you think we should model WAF controllers as components or J2EE patterns as components (as Cade is modeling Service Locator)?

Thanks,
Tomi
 
Ranch Hand
Posts: 344
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tomi,
P375, Fourth paragraph, of Blueprints says that a local architecture (which PetStore is) does not need BusinessDelegates and ServiceLocators. The WebController passes an Event to the EJBController. The EJBController has a command pattern which passes the event to the correct Session Facade (note. Doesn't have to be a Session Facade. Could be a POJO).

The EJBController is stateful because it is storing conversational state on behalf of a client (i.e. shopping cart).

Choosing between WAF Controllers or J2EE patterns as components is a tough one. Hopefully, someone who's passed can answer better. I suppose you can do either as long as the comments explain things. Do you model based on Cade or Petstore?

Ray
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!