The domain, or business, of our shopping application is that of human beings shopping for stuff, or, in more formal terms, of customers adding items to orders. We need to represent these business entities and their rules as code in the innermost layer, the domain layer.
Learning Uncle Bob’s concept of The Clean Architecture.
Creation of a simple yet complete Go application, applied the concepts of The Clean Architecture.
The application is a very (very!) rudimentary but working online shopping system which allows to retrieve a list of items, belonging to an order, through an HTTP web service.
If there is duplicate code, no error handling and many other smells, it is because this example is neither code style nor design patterns: it is an example of the architecture of application, and therefore I took the liberty to create very simple that just needs to be simple and understandable, not smart and smart - oh and yes, I’m still a beginner Go, which proves it.
Domain:
Use Cases:
Infrastructure: