DEV Community

Frederik Banke
Frederik Banke

Posted on

External Dependencies

What is the most difficult stuff to manage in software? I would say external dependencies.

πŸ— As soon as we connect to an external system. Being a database, a queue, or an API, we get a dependency that we must maintain for the system's life.

πŸ€” If the dependency change, we are forced to change our software because we don't have control.

πŸŽ“ Worse still, if we blend the dependency with our business code. Then we are in for a world of pain.

Don't be that guy. Do it right instead.

βœ” Use interfaces to services in your business logic

βœ” Make a bridge towards external services, so changes are contained.

βœ” Use ports and adapters style architecture to protect your code.

Top comments (0)