High Availability on K8S
HA solutions for MongoDB
In production environments it's recommended to use a managed database service from a cloud provider, Azure, AWS and Google Cloud all provide MongoDB compatible services. These services have built-in HA and can scale dynamically depending on the required load.
If a highly available database is required inside the k8s cluster, then there are publicly available solutions that can deploy a MongoDB Replica Set. For a k8s cluster, MongoDB provides an operator for deploying a Replica Set:
https://www.mongodb.com/docs/kubernetes-operator/master/tutorial/deploy-replica-set/
HA deployment for MDSS
MDSS containers can be scaled independently depending on the availability and performance requirements. For example, just the webclient
and apigateway
pods can be replicated to provide high availability to outside requests and for the web interface.
mdss_components
webclient
replicas3
apigateway
replicas3
3rd party services should not be replicated from the helm chart but the can be replaced with managed external services:
mongodb
: The MongoDB database, see above for HA solutionsrabbitmq
: The RabbitMQ service used by MDSS pods to communicate with each otherredis
: Redis cache service
The mongomigrations
service is used to keep the database up to date at startup and provides no benefits if replicated .