all groups > dotnet distributed apps > october 2003 >
You're in the

dotnet distributed apps

group:

Question on Facade


Question on Facade jimpappa
10/31/2003 10:42:08 AM
dotnet distributed apps: Hi All,

We are developing a smart client based applicattion in .NET.

When the application design is finalised, we will have about 60-70 objects
in the middle layer...

We want to decide whether to expose these objects directly as remotable or
whether to use a thin facade layer to suite our business needs..

my concern is,

We might not be able to "fine grain" the objects as it is in a "real" OO
application, but then again, this is very subjective i guess..
in that case the facade and the BLL will have methods in a one to one
form...


Any helpful thought is highly appreciated....

regards
s


Question on Facade Jason Steele
11/3/2003 7:47:10 AM
As always, "it depends" !

Things to consider:
How are you handling transactions? If you're usinf seviced
components then you will your BLL to be split into
transactional and non-transactional classes so that you
don't start a transaction unnecessarily. Imn this scnario
implementing a thin facade over the of the BLL can help
prove a more consistent user interface as your BLL
consumer won't know whether it's transactional or not.

Another related reason you might want to implement a
facade is to simplify the client access to the middle
tier. Perhaps not all BLL objects should be used by the
clientand therefore should be hidden by not having a route
through the facade. Also several related classes may map
to one task orientated class in the facade. That way your
client only needs to create one class to accomplish the
task it wishes to perform.

Also, as you hint at, the facade provides an oppotunity to
implement whatever rempting strategy you wish without
affecting the BLL. In fact, you may wish to implement
several facades. One for each type of client being
services. In that way you hide all the stuff that a
particular client shouldnt have access to.

On the other hand, its more code to write.

From the sounds of it (70 classes) your project is big
enough to consider the benefits of implementing a facade.

Jason Steele

[quoted text, click to view]
Re: Question on Facade Jacek He³ka
11/7/2003 8:20:56 AM
What's the reason to avoid "fine graining"?
Problems with persistence layer?
[quoted text, click to view]

AddThis Social Bookmark Button