Service instance per container

When we use the service instance per container pattern, each microservice instance runs in a container unique to the instance. Containers are a virtualization engine operating at the system level. A good example of a container is Docker, which we are already using in our project for local development.

To use this pattern, we need a container image of a microservice. After the container is created, we release one or more containers. Multiple containers are usually run on each physical or virtual host. You are advised to use a cluster manager such as Kubernetes to manage the containers.

The service instance per container pattern has benefits and drawbacks. The benefits of the containers are similar to those of ...

Get Microservice Patterns and Best Practices now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.