Adhesion
I recently gave a short talk in our engineering all-hands. I got a ton of responses, leading me to think that this might be a subject worth a post.
Back when I was racing bikes, I went to PT regularly; muscle adhesion was something that my PT taught me (in an excruciating way I might add).
Muscle adhesion happens as a result of an injury, causing muscles to be essentially "stuck" together, causing them to move inefficiently (furthering the damage and injury).
Adhesion in software delivery
In software delivery, adhesion happens when one piece of code can't be shipped without another piece of code. When service X has to be aware of the service Y lifecycle.
I've seen adhesions pretty much in every place I've worked at in my career. Some companies went as far as creating tools to override these adhesions. However, I find that the best way to solve these adhesions is with simple rules.
- API -> This API FIRST AND LAST. Even if you have access to edit service X while working on service Y - Don't! API for services should not consider the implementation of the consumers in a special way. If your consumer requires a change in the API, make that as a request to the team.
- CHANGELOG -> Enforce the use of a changelog in all services that expose API endpoints.
- SemVer -> Learn it, use it, love it. Semantic versioning in service API should be enforced at all times.
- Schema migration -> Schema migrations should always be backward and forward compatible. You should separate DDL from DML in your migrations as much as possible.
- Data Migration -> Avoid data migrations as much as humanly possible. If one service is "born" needing to migrate data from another service, it's probably the wrong idea. Think about the source-of-truth for any object in the system religiously.
Culture
The good news (and bad) is that adhesions are usually rooted in culture. It's about discipline and policies. Think about your product. Can one team move without the other? Can one service be dropped into production without coordinating with other teams?
Have you seen similar at your workplace? Happy to discuss in the comments.
Rock on!