Does each queue consumer process need its own Docker image? Does each queue consumer process need its own Docker image? kubernetes kubernetes

Does each queue consumer process need its own Docker image?


It is common practise to have a high degree of separation of workloads in during execution when it comes to Kubernetes. Thus it would make sense that consumer is its own Deployment or Job. Since you already have multiple queues that are spearate it makes sense to also separate the consumers. For example if one consumer hands, or needs a restart or upgrade it can be done with no impact on other consumers.

It does not require you to have separate Docker images though. If all consumers are the same excpet some configuration values like endpoints. You can define and build one common image and pass in configuration through environment variables, configmaps or secrets.

In other words, during execution it is common to have the consumers separated, but they can still share the same image with differences just in configuration