views:

38

answers:

2

I've looked at a few sites now, and I'm still struggling to find a complete listing of all the possible layers/tiers you can have in an application.

From back in college (1999) I remember the following:

  • Presentation Layer (Views)
  • Application Layer (Controllers)
  • Business Logic Layer (API/Rules)
  • Persistence Layer (Database/Object Persistence/Model)

I'm not advocating that they all be used...especially when you consider that too many layers/tiers could lead to an increase in complexity...I just wondered what the complete list might look like...

Based on a couple of blogs I've found several different answers...and Javascript and client side technologies seem to have leaked in adding more client-side layers according to one blog the client side tier might even consist of

  • Behavior Layer (Javascript, Flash)
  • Presentation Layer (CSS/Images) Note: I though the entire client side layer was the presentation layer
  • Structure Layer (XHTML, HTML)

I'm just trying to get an abstract idea of what all the possible layers might be, (even though some people call them different things)

A: 

I would add an "Integration Layer" to your list. This layer contains wrapper classes for external systems (email servers, web services, etc.). These classes implement interfaces thar are provided by your Business Logic Layer (in the same way that the "Persistence Layer" should).

bloparod
A: 

If you're talking abstract then you probably won't find a definative list of layers or tiers; in addition, any list you do come across will be dependant on the context.

Layers (or tiers) can be logical or physical; the presentation tier is usually physically seperate from the business logic - but I'd say the application layer and business layer you have above would be more of a logical thing (?).

Another crucial aspect is your view-point. Depending on what view you take you'll see different layers: http://www.opengroup.org/architecture/togaf8-doc/arch/chap31.html#tag_32

Finally, and further along those lines, the complexity and/or nature of the solution will also impact on this - if you're making extensive use of services then you'll have a service view - or a service layer. The layers you consider will be influenced by whether you're consdidering a single system/components or a wider solution.

Adrian K