14
What is the difference between multi-layer and multi-tier applications? One depends on the other?
14
What is the difference between multi-layer and multi-tier applications? One depends on the other?
18
People normally exchange the two terms to describe the same architecture as multi-layered and multi-tiered simultaneously. That’s not exactly true.
Adapting the distinction made by Arch Guide App, layers refer to the component-type, the logic of the Application, while tiers (2-Tier, 3-Tier, N-Tier) refer to the physical distribution of the patterns. It is particularly easy to understand when speaking where (in which Tier) your layer will be executed.
Although there are variations in the terms used, many people who build Applications identify the Presentation Layer (Presentation), Business Layer (Rules of Business) and Data Layer (Data Access). An image is worth a thousand words, so:
As said, the tiers are the physical representations of the patterns to be distributed. No use repeating if it doesn’t make practical sense, so let’s see the most common patterns translated into images:
2-tiers
I researched a little about it and the most sensible definition I arrived at refers to Intranets, where the Application needs to be installed in each Station and all of them individually communicate with a single server.
As an advantage we have the ease of understanding architecture. But as disadvantages we have, beyond the inconvenience of individuality in this case, we have the slowness when many Stations are operating the Application simultaneously.
3-tiers
The most common, popularized by MVC, defines the presentation layer only to define the visual elements through which the Application will be operated.
The "intermediate" layer more quickly interchanges the requests made by the User with the data of the third layer, where the data resides.
Note the distinction between where the data resides and the data themselves, which reinforces the difference between layer (logic) and Tier (physical) previously said.
N-Tier
The most difficult to describe in an example, but I would say that Service Authentication fits nicely.
The Customer decides that he wants to authenticate in Stack Overflow PT with his Google account, the Application communicates with the Google Auth service, this returns to the Application Business Rules that uses the e-addressAuthenticated mail as conditional to get the replies and comments made.
Original Article: J. D. Meier
Translation and Adaptation: Some stranger named Bruno Augusto :P
4
Response brought to the SOEN (https://stackoverflow.com/questions/120438/whats-the-difference-between-layers-and-tiers)
Layers are a way to organize your code. Typically, layers include, presentation, business, data, which is basically the concept 3-layer. But layer does not mean another process, computer, cluster. Layers are logical divisions of the code according with its functions.
Tiers however it is about where the code runs. Tiers are the places where the Layers are placed and where they run. Tier is therefore the physical deploy where the Layers run.
I didn’t translate the terms because in Portuguese everything is called layers. But in summary, Layers are logical layers and Tier physical layers.
Browser other questions tagged software-architecture
You are not signed in. Login or sign up in order to post.