• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

What GOF pattern is used for which component of J2EE (specially EJB)

 
faisal mahmood
Ranch Hand
Posts: 349
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Which GOF patterns are used in which components of EJB and other J2EE components?
I am mainly interested in the ones relevent to the certification.
Thank you,
Faisal
 
Amanda Waite
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
Thta's a difficult question to answer as you can use most GOF patterns when developing a J2EE application. The J2EE framework really only uses three (OK all, correct me if you think that I'm wrong), the Factory Method, The Abstract Factory and the Proxy. The Proxy is used for both the Home and Remote interfaces and the Factory Method and Abstract Factory are mainly used together when getting hold of Resource Ref's via JNDI and with JNDI itself. It could be said that Abstract Factory is used by the container for creating EJB Objects (as opposed to Beans). Dependent on the implementation of the underlying container, it could be said that the either the Bridge or Mediator patterns are used in order to access the Bean itself.

Amanda
 
Jignesh H Shah
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1 Proxy Method : For remote interface
2 Decorator Method : For EJBObject
3 Factory Method and Abstract Factory Method for Home Interface
 
Brandon Hill
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is used for ResultSet? I've heard ResultSet may be referenced in the exam.
 
faisal mahmood
Ranch Hand
Posts: 349
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do I need to know all the 23 GOF patterns for part I
 
Jignesh H Shah
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yet I didn't give exam and I am preparing for the exam so, I might wrong. But my understanding is atleast you need to know each pattern.

Here is some detail about J2EE Patterns.
Architectural Design Goals includes
1 Component Extensibility : For that J2EE uses Factory and Facade pattern.
2. Contracts: Adaptor pattern
3. Pluggable behaviour : Command and Strategy Pattern.
4. Performance : facade pattern.
Other than that
WEB Tier uses Mediator Pattern
EJB Tier uses Session Entity Facade pattern
Client Tier / WEB Tier/ EJB Tier uses Business Delegate Pattern.
If I am wrong then let me know.
Thanks
Jignesh Shah
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic