Layered Architecture
Learn about layered architecture and its pros and cons.
We'll cover the following...
Overview
Ideally, the different components of a system must be developed independently by having clear and well-defined documentation. The software system needs to be divided so that its different components can be developed with minimal (if any) interaction between them, and it should be reusable, portable, and easily modifiable.
A layered pattern is a design pattern that divides a system into units or layers. This is one of the most frequently used methods. Every layer is a collection of modules that provide a consistent set of services. The software program is organized into horizontal levels in a tiered architecture, with each layer sitting on top of a lower layer. Generally, a layer can only access and utilize its next lower neighbor.
Open vs. closed layers
Each layer is reliant on one or more levels below it (depending on whether the layers are open or closed), but is independent of the ones above it.
Requests coming down the stack from the layer above must go via a closed layer and can’t circumvent it. If the business layer is closed in a standard three-layered design with the presentation layer, business layer, and data layer, the presentation layer must submit all requests to the business layer and can’t bypass it to send a request straight to the data layer.
Closed layers provide separation, making code ...