This week's book giveaway is in the JDBC forum.
We're giving away four copies of Make it so: Java DB Connections & Transactions and have Marcho Behler on-line!
See this thread for details.
The moose likes Architect Certification (SCEA/OCMJEA) and the fly likes ques reg facade layer Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Make it so: Java DB Connections & Transactions this week in the JDBC forum!
JavaRanch » Java Forums » Certification » Architect Certification (SCEA/OCMJEA)
Bookmark "ques reg facade layer" Watch "ques reg facade layer" New topic

ques reg facade layer

Giju George
Ranch Hand

Joined: Jun 08, 2004
Posts: 333
"A session facade delegating some of the business process to a helper class which is a POJO"... Is this considered a good practice ???

SCJP 1.4, SCWCD 1.4, SCBCD 1.3, SCEA
Jeremy Hsu
Ranch Hand

Joined: Mar 28, 2005
Posts: 79
It really depends on the complexity of your system, and the readability of your session facade source code.

If your session facade is really simple, I would not do such thing. If your session facade gets really complicated and you put all this logic inside the session facade, I wonder anyone can understand that but me. Therefore, I introduce POJO and delegate some business methods in it.

Other practice you can do is to break your session facade into two or more session facades instead of using POJO. That also gives a much simplier session facade to work with to the client.

I would say it is only a good practice, but you should not think of that as a rule of thumb. When you have more experience, you should know when to apply to give you the maximum benefits.
[ August 30, 2005: Message edited by: Jeremy Hsu ]
I agree. Here's the link:
subject: ques reg facade layer
It's not a secret anymore!