
E-commerce Platform - MongoDB self-host to Atlas
What is this MongoDB cluster
- Core database for the e-commerce platform.
- Has 500,000 shop datas including orders, customers … etc.
- self-host in AWS EC2 with 3 shards, and each shard has 4 nodes (2 secondaries, 1 primary and 1 arbiter).
Why we did this
- Moved our self-host MongoDB cluster to MongoDB Atlas (fully managed service).
- MongoDB Atlas provides permission control and near real-time monitor.
In this project, I contributed to those items
- Made a migration plan and completed the migration within three months.
- Created 4TB cluster with 2 shards and 8 nodes (1 read-only、2 secondary、1 primary per shard).
- Managed Atlas cluster with Terraform.
- Upgraded MongoDB driver version and ruby version due to MongoDB upgrade.
- Made a plan to restrict traffic during migration.
- In charge of core MongoDB stability.
- Sharded MongoDB collections to ensure high performance.
Architecture

What benefits MongoDB Atlas brings to?
- Fine-grained Access Control:
You can control who can access your data and who can manage your cluster. - MongoDB Atlas Search:
Natively support text search functionality. you don't need to run a search engine anymore. - Monitoring:
Atlas provides near real-time monitoring dashboard. You can know what queries are running on the cluster.