Re:A Sketch of the Biggest Idea in Software Architecture (2022)
by blowski on Monday April 22, 2024 @08:45AM
(#40113838)
True, which is perhaps why it's unclear what the difference is between a "skinny waist" and hexagonal architecture, "ports and adapters".
[ Parent
| on HN ]
Re:A Sketch of the Biggest Idea in Software Architecture (2022)
by mrkeen on Monday April 22, 2024 @12:04PM
(#40115651)
hexagonal architecture gives you the direction of the "waist", not its thickness.
You could have a really skinny interface (one method call only):
class TaxLogic {
data = iDatabase.loadOneDatabaseRow(id);
process(data);
}
interface IDatabase {
loadOneDatabaseRow(id);
}
class PostgresDb implements IDatabase {
loadOneDatabaseRow(id) {...}
}
But this violates ports and adapters because the logic is on the outside and the database is on the inside.