-1

I am a bit confused where I should implement the business Facade? In a 3 tier distributed model, I want to add a facade in between presentation tier and the business logic tier. They are running on a separate systems. Now my question where should I implement the facade class -- in the presentation tier or business tier?

If I am not wrong the facade pattern represents a set of use case. There may be multiple task can take place from a single call to the facade. Example credit card validation and payment. In this case ,it should be implemented on business tier.

Am I on the right path? Is there any example where we implement facade in first tier?

dbugger
  • 15,868
  • 9
  • 31
  • 33
SBha
  • 1
  • 2

1 Answers1

0

It is reasonable to keep your "beautifiers" (façades, wrappers, services) close to code which really executes requests.

In case of façade you are trying to cover complicated set of classes with simple api. You should keep your façade close to that set of classes. Which means it should be placed in business tier.

Marcin Szymczak
  • 11,199
  • 5
  • 55
  • 63