Łukasz Wróbel

Writing

Microservices are supposed to follow the business

Microservices are supposed to follow the business. From what I’ve seen, they follow the path of least resistance.

Imagine that team A needs a change to be implemented by team B, which belongs somewhere else in the organizational structure. If there are too many obstacles in the way, chances are, team A will end up implementing the change in one of their microservices. Not because there’s something inherently wrong with team A, but because communication, procedures, approvals, and friction tend to overwhelm people.

If friction is high in an organization, what happens over time is that microservices, instead of mirroring business domains, begin to mirror the ineffective communication structure. What seemed like a quick win (“We did it in two days instead of waiting for weeks!”) eventually backfires and increases the friction even more. New bugs emerge, and the next change might need two teams instead of one. Largely because the entangled architecture no longer follows business needs.

How do you fix it? Or even better, how do you prevent it? I don’t believe that friction can be eliminated completely in complex organizations. But there are some things that I know will help:

  • Team independence. The more knowledge, tools, access, and freedom a team has, the less friction there is. Someone might argue that a team may not have the context required to make all the decisions. I get it, and this argument is particularly strong in regulated industries. But at least dropping external gates (such as change boards or manager sign-off) might be beneficial. There is a DORA capability page which says that “no evidence was found to support the hypothesis that a more formal, external review process was associated with lower change fail rates.”
  • Priority alignment. If the reason for team B not picking up the task is a mismatch in priorities, that needs to change. Communication and especially processes need to be aligned around common goals. We should prioritize according to them and only pick up other tasks when our involvement is not needed or would be ineffective.
    Check whether your organization’s size and complexity have outgrown your process. Lean toward methodologies addressing more than just one team’s needs.
  • Moving ownership. Maybe team B owning the service was the right thing to do at the time, but the circumstances have changed. Maybe it was wrong from the beginning. Either way, admit the problem and deal with its consequences.
    There’s nothing wrong with moving ownership; it’s part of the microservice lifecycle.

How do you minimize friction in your organization?

Microservices are supposed to follow the business. From what I've seen, they follow the path of least resistance. Team A sends a request to Team B; the arrow is labeled Friction: approvals, waiting, other priorities. A piece of one of Team B's services moves into Team A's services, wedged in at an angle, along the path of least resistance.