In this article, we will speculate about how software architecture might look like in the next decade. In the first part we will define what good software means. In further parts we'll build a sample following this definition.
The Main Principle
With time we had different limitations on performance and interfaces, but values remained the same. We were always looking for technics that would allow us to create solutions fast and extend them easily.
There are many recommendations on how good software should be created. However, many of them can be inferred form a single idea. It's is coherence & cohesion. In short, it's about putting related concepts together and non-related concepts separately.
- Single Responsibility Principle - consider different responsibilities as different concepts and it becomes clear that they need to be separated.
- Don't Repeat Yourself - if everything related to one entity stays together you are unlikely to have a need to express the same thing twice.
Layered HistoryConcepts that people used to think evolved over time. In 1967 Melvin Conway claimed that software architecture is a product of organizational structure. For a long time, we were able to see different teams responsible for
- site markup
- page logic itself and communicating with the server
- core data manipulation
- the database
To overcomes collaborations issues layers got merged. Now, it's often too fat layers - backend and frontend.
Layers inside this two fat layers got merged. On backend, Ruby-on-Rails developers put in controller what used to be split across Data-Access-Level, Services, and Controllers. On the frontend, React developers are putting markup and js together.
We will explore with concepts remain since there no technical borders in our solutions. For general guidance we will be taking ideas for domain-driven-design powered by command-query responsibility-segregation.
In our example we will be building todo app. We are not gonna use any libraries so you can follow it even if you are not familiar with tools that were released last week.