An architectural style or pattern is:
a description of the component and connector types
involved in the style
the collection of rules that constrain and relate
A layered architecture organizes a system into a set of
layers each of which provide a set of services to the
Layering consists of a hierarchy of layers, each
providing service to the layer above it and serving as
client to the layer below.
Supports the incremental development of sub-systems
in different layers.
When a layer interface changes, only the adjacent
layer is affected
While working with a large, complex system and you want
to manage complexity by decomposition.
How do you structure an application to support such
important requirements as maintainability, scalability,
extensibility, robustness, and security?
Compose the solution into a set of layers. Each layer
should be cohesive and at roughly the same level of
abstraction. Each layer should be loosely coupled to the
Interaction between layers(1)
Interactions among layers are defined by suitable
Interactions among non-adjacent layers must be kept
to the minimum possible.
Normally layers are constrained so elements only
other elements in the same layer, or
elements of the layer below
Interaction between layers(2)
requests from higher layer to lower layer
answers from lower layer to higher layer
incoming data or event notification from low to
Different components of the application can be
independently deployed, maintained, and updated, on
different time schedules
Makes possible for team members to work in parallel on
different parts of the application with minimal
Testing the components independently of each other.
Each layer may hide private information from other layers
Each layer, being cohesive and is coupled only to lower
layers, makes it easier for reuse by others and easier to be
replaced or interchanged
Reusing components easily:
For example if we want a windows user interface rather than a web
browser interface, this can be done in an easy and fast way by just
replacing the UI component. All the other components like business
logic, data access and the database remains the same. Layered
architecture allows to swap and reuse components at will.
Increases flexibility, maintainability, and
We separate the user interface from the business logic, and the
business logic from the data access logic.
Performance degrades if we have too many layers
(extra overhead of passing through layers and also
changes will pass slowly to higher layers )
Sometimes difficult to cleanly assign functionality to
the “right” layer
Can’t be used for simple applications because it adds
Information systems – lower layer is database
Some operating systems – Windows NT
Example 1 :
Layered Architecture for OS
network, file, etc.)
Kernel (Device & memory
Process (classification &
Example 2 :