Hexagonal Architecture (Ports and Adapters)


Application
The Business Logic
The business logic (usecases), uses a Driven Port. And this Driven Port is implemented by a Driven Adapter, and the Resources (Driven Side) use this Adapters to communicate with the application.
Here the Driven Port, could be seen as a Generic Interface.
This Generic Interface can be implemented by multiple types of Adapters:
Like Database adapter.
Memory adapter.
File adapter.
Also the business logic, implements a Driver Port.
Drivers
What drives the application, it is what consumes.
Driven Actors (Resources)
Is what is consumed by the drivers.
SMTP Server
Queue
File system
Database
In the application border we will have the application API. This means that the API is not a resource to be consumed.
Last updated