Hexagonal Programming
Hexagonal Programming
Hexagonal Programming
ers
SMS
Con PI
troll
App. Services Adapter
A
3rd party apps
Ev
Not <I>
ds
mobile apps Web server
en
lers
man
Domain Services
ifica
tL
message queues
Mailing
and
iste
microservices
Com
Server
tio
Email
H
... Domain Layer
ne
ns
Adapter
C/Q
rs
End-users Domain
Component
Cons ontrollers
consumers Model
Serv
rch
<I>
<I> s
GUI
...
Sea
ice
umer
Search Engine
&C
(ie. Elasticsearch)
Search
Views
Adapter
> e
rd
s <I tenc
nw
a
rsis
Technical users i Pe
cron jobs CLI go MySQL
s
... cie Application Core Adapter PRD DB
d en
en (ie. MySQL)
D ep
ORM
m e
ds
m sol
an
ORM
Co on
Adapter
C
SQLite TST DB
Adapter (ie. SQLite)
However: User Interface Infrastructure
- The map is not the territory. Secondary adapters wrap around a tool
- Plans are worthless, but planning is everything. Primary adapters wrap around a and adapt its input/output to a port, which
- Understand all of this, but use only what you need. use case and adapt its input/output fits the application core needs and can
- The actual architecture is driven by the project requirements. to a delivery mechanism, ie. simply be an interface or a complex set of
HTTP/HTML, HTTP/JSON or CLI. interfaces and objects. www.herbertograca.com