Architectural pattern is a general, reusable solution to a commonly occurring problem in software architecture within a given context
Layered Pattern
For programs that can be decomposed into groups of subtasks, each group is abstracted to a layer
Consists of: presentation layer (UI), application Layer (service), business logic layer (domain), data Access Layer (persistence)
Client-server Pattern
For programs that can be broken into server and multiple clients
The server provides services to the clients and listens for requests
Master-slave Pattern
For programs that can have the work distributed by the master to identical slave components, then collected back to compute the final result
Pipe-filter Pattern
For programs that produce and process a stream of data
Each processing step is enclosed within a filter component
Data to be processed is passed through pipes, which is used for buffering or synchronization
Compliers or bioinformatics programs might use this
Broker Pattern
For distributed systems with decoupled components, the components interact via the broker. Examples include Apache Kafka
Peer-to-peer Pattern
The peers in this pattern are components that can act both as clients or servers
Event-bus Pattern
This typically has 4 components: event source, event listener, channel and event bus
The source publish messages to particular channels on an event bus
Listeners will subscribe to channels on the event bus and be notified of the messages that are published to a channel
Model-view-controller Pattern
Interactive applications use this pattern which divides into 3 parts: model (core functionality and data), view (display the information), controller (handles inputs from the user)
Blackboard Pattern
Suited for programs with no known deterministic solution strategy
Contains 3 components: blackboard (a structured global memory containing object), knowledge source (specialized modules with their own representation) and control (selects, configures and executes modules)
Interpreter Pattern
For programs that interpret other programs written in a dedicated language