SlideShare a Scribd company logo
Mastering MongoDB
on Kubernetes, the
power of operators
Arek Borucki
Beamery
Agenda
• MongoDB architecture
• Kubernetes Operators
• MongoDB Community K8s Operator
• MongoDB Enterprise K8s Operator
• MongoDB Atlas K8s Operator
• Demo
Mastering MongoDB on Kubernetes, the power of operators
OM java application
• consistent backup
• rolling upgrades
• automation
• monitoring
Agenda
• MongoDB clusters
• Serverless
• Data Lake
• Atlas Search
• The Data API (HTTPS)
• Advanced security
• and more
Mastering MongoDB on Kubernetes, the power of operators
Why to use MongoDB K8s Operators ?
Capabilities like Replication, Sharding,
Failover or Scalability can help more
easily deal with the uncertainty
sidecar pattern- MongoDB
Agent handles configuring,
stopping, restarting and
upgrading the mongod
process, readiness and
liveness probes
Provides out of the box security features
like TLS, authentication, RBAC
Reduce complexity - uses the best
human knowledge of creating and
operating a MongoDB products
Extending Kubernetes API by
MongoDB specific objects, like
OpsManager or ShardedCluster
Uses K8s best practice - Affinity,
Pod Disruption Budget, Resource
management and K8s reliability
features like auto healing
The Operator tell K8s how to configure MDB cluster including provisioning storage,
setting up the network connections, and configuring other resources
The Kubernetes operator watches Custom Resources
_ Observe the actual state
_ Analyse difference from
desired state
_ Take action
_ Drive the actual state
towards the desired stare
_ Repeat!
Observe
Analyse
Act
my-replica set has 2 running
pods
Differs from desired state of
3 replicas (pods)
Action:
- Start a pod
- Add pod to the cluster
- Waiting for replication
• The Operator is Apache open source
• Currently only Replica Set
• Suited for experimentation and testing
• Automated cluster provisioning
• Client-to-server, server-to-server with TLS
• Scale replica sets up and down
• Automated rolling updates
• Provides metrics target that can be used
with Prometheus
MongoDB Community Kubernetes Operator
1
1
custom resource
• 1
1
---
apiVersion: mongodbcommunity.mongodb.com/v1
kind: MongoDBCommunity
metadata:
name: mongodb-replica-set
namespace: mongodb
spec: members: 3
type: ReplicaSet
version: “5.0.5"
security:
authentication:
modes: ["SCRAM"]
Mastering MongoDB on Kubernetes, the power of operators
• Replica Sets, Sharded Clusters, Standalones
• AAA, TLS for all traffic between servers and
between clients and servers
• Ops Manager - monitoring and
management platform for MongoDB
• Backup Infrastructure (PIT Restore,
consistent backup of shard clusters)
• User management support
• Encryption at Rest,
• Multi-Cluster Capabilities
MongoDB Enterprise Kubernetes Operator
MongoDB Custom Resource types
1
4
1
5
custom resources
• 1
5
---
apiVersion: mongodb.com/v1
kind: MongoDBOpsManager
metadata:
name: ops-manager
spec:
version: 5.0.5
externalConnectivity:
type: LoadBalancer
applicationDatabase:
members: 3
version: 4.0.5-ent
---
apiVersion: mongodb.com/v1
kind: MongoDB
metadata:
name: sharded-cluster
spec:
shardCount: 2
mongodsPerShardCount: 3
version: 5.0.5
type: ShardedCluster
MongoDBUser custom resource
1
6
1
7
• 1
7
---
apiVersion: mongodb.com/v1
kind: MongoDBMulti
metadata:
name: multi-replica-set
spec:
version: 5.0.5
type: ReplicaSet
clusterSpecList:
clusterSpecs:
clusterName:
- cluster1.mongokubernetes.com
members: 2
- cluster2.mongokubernetes.com
members: 1
- cluster2.mongokubernetes.com
members: 1
1
8
• Manage Atlas clusters in directly K8s
• Automated Atlas cluster provisioning
• Integrate Atlas with Kubernetes-native
CI/CD pipelines
• Setup Cloud backup
• Database users management
Atlas Kubernetes Operator
2
0
custom resources
• 2
0
---
apiVersion: atlas.mongodb.com/v1 kind:
AtlasProject
metadata:
name: my-project
spec:
name: Test Atlas Operator Project
projectIpAccessList:
- ipAddress: "192.0.2.15”
comment: "IP address for
App Server A"
---
apiVersion: atlas.mongodb.com/v1 kind:
AtlasDeployment
metadata:
name: my-atlas-deployment
spec:
projectRef:
name: my-project
deploymentSpec:
name: test-deployment
providerSettings:
instanceSizeName: M10
2
1
custom resources
• 2
1
---
apiVersion: atlas.mongodb.com/v1
kind: AtlasBackupPolicy
metadata:
name: atlas-backup-policy
spec:
items:
frequencyType: "weekly"
frequencyInterval: 1
retentionUnit: "days"
retentionValue: 7
---
apiVersion: atlas.mongodb.com/v1
kind: AtlasDatabaseUser
metadata:
name: my-database -user
spec:
roles:
- roleName: "readWriteAnyDatabase”
databaseName: "admin"
projectRef:
name: my-project
username: the-user
• Operators reduce complexity
• Extends K8s API by MongoDB objects
• Improve consistency
• Automate at the level you need
• The operator creates persistent volumes and
STS for MongoDB Replica Set
• Recommendedn method of
running databases on K8s
Summary

More Related Content

Similar to Mastering MongoDB on Kubernetes, the power of operators (20)

PPTX
Webinar: Enabling Microservices with Containers, Orchestration, and MongoDB
MongoDB
 
PPTX
Kubernetes: від знайомства до використання у CI/CD
Stfalcon Meetups
 
PPTX
The Rise of Microservices - Containers and Orchestration
MongoDB
 
PPTX
Conceptos básicos. Seminario web 6: Despliegue de producción
MongoDB
 
PDF
OSDC 2018 | Three years running containers with Kubernetes in Production by T...
NETWAYS
 
PPTX
Introduction to DevOps on AWS
Shiva Narayanaswamy
 
PDF
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
QAware GmbH
 
PPTX
DevOps, Microservices and Serverless Architecture
Mikhail Prudnikov
 
PPTX
WSO2Con 2015-us-introduction-to-mss-v2
Afkham Azeez
 
PDF
Open shift and docker - october,2014
Hojoong Kim
 
PPTX
Securing & Monitoring Your K8s Cluster with RBAC and Prometheus”.
Opcito Technologies
 
PPTX
IBM BP Session - Multiple CLoud Paks and Cloud Paks Foundational Services.pptx
Georg Ember
 
PDF
Rami Sayar - Node microservices with Docker
Web à Québec
 
PDF
MongoDB Europe 2016 - Powering Microservices with Docker, Kubernetes, and Kafka
MongoDB
 
PPTX
SpringOne Tour: An Introduction to Azure Spring Apps Enterprise
VMware Tanzu
 
PPTX
MERN_Stack_Project_Tracking_System.pptx.
ManoelOhmogar
 
PDF
Stay productive while slicing up the monolith
Markus Eisele
 
PPTX
Securing Your Enterprise Web Apps with MongoDB Enterprise
MongoDB
 
PPTX
Building a production ready meteor app
Ritik Malhotra
 
PPTX
Docker Enterprise Workshop - Technical
Patrick Chanezon
 
Webinar: Enabling Microservices with Containers, Orchestration, and MongoDB
MongoDB
 
Kubernetes: від знайомства до використання у CI/CD
Stfalcon Meetups
 
The Rise of Microservices - Containers and Orchestration
MongoDB
 
Conceptos básicos. Seminario web 6: Despliegue de producción
MongoDB
 
OSDC 2018 | Three years running containers with Kubernetes in Production by T...
NETWAYS
 
Introduction to DevOps on AWS
Shiva Narayanaswamy
 
Kubernetes One-Click Deployment: Hands-on Workshop (Mainz)
QAware GmbH
 
DevOps, Microservices and Serverless Architecture
Mikhail Prudnikov
 
WSO2Con 2015-us-introduction-to-mss-v2
Afkham Azeez
 
Open shift and docker - october,2014
Hojoong Kim
 
Securing & Monitoring Your K8s Cluster with RBAC and Prometheus”.
Opcito Technologies
 
IBM BP Session - Multiple CLoud Paks and Cloud Paks Foundational Services.pptx
Georg Ember
 
Rami Sayar - Node microservices with Docker
Web à Québec
 
MongoDB Europe 2016 - Powering Microservices with Docker, Kubernetes, and Kafka
MongoDB
 
SpringOne Tour: An Introduction to Azure Spring Apps Enterprise
VMware Tanzu
 
MERN_Stack_Project_Tracking_System.pptx.
ManoelOhmogar
 
Stay productive while slicing up the monolith
Markus Eisele
 
Securing Your Enterprise Web Apps with MongoDB Enterprise
MongoDB
 
Building a production ready meteor app
Ritik Malhotra
 
Docker Enterprise Workshop - Technical
Patrick Chanezon
 

More from DoKC (20)

PDF
Distributed Vector Databases - What, Why, and How
DoKC
 
PDF
Is It Safe? Security Hardening for Databases Using Kubernetes Operators
DoKC
 
PDF
Stop Worrying and Keep Querying, Using Automated Multi-Region Disaster Recovery
DoKC
 
PDF
Transforming Data Processing with Kubernetes: Journey Towards a Self-Serve Da...
DoKC
 
PDF
The State of Stateful on Kubernetes
DoKC
 
PDF
Colocating Data Workloads and Web Services on Kubernetes to Improve Resource ...
DoKC
 
PDF
Make Your Kafka Cluster Production-Ready
DoKC
 
PDF
Dynamic Large Scale Spark on Kubernetes: Empowering the Community with Argo W...
DoKC
 
PDF
Run PostgreSQL in Warp Speed Using NVMe/TCP in the Cloud
DoKC
 
PDF
The Kubernetes Native Database
DoKC
 
PDF
ING Data Services hosted on ICHP DoK Amsterdam 2023
DoKC
 
PDF
Implementing data and databases on K8s within the Dutch government
DoKC
 
PDF
StatefulSets in K8s - DoK Talks #154
DoKC
 
PDF
Running PostgreSQL in Kubernetes: from day 0 to day 2 with CloudNativePG - Do...
DoKC
 
PDF
Analytics with Apache Superset and ClickHouse - DoK Talks #151
DoKC
 
PPTX
Overcoming challenges with protecting and migrating data in multi-cloud K8s e...
DoKC
 
PDF
Evaluating Cloud Native Storage Vendors - DoK Talks #147
DoKC
 
PDF
Kubernetes Cluster Upgrade Strategies and Data: Best Practices for your State...
DoKC
 
PDF
We will Dok You! - The journey to adopt stateful workloads on k8s
DoKC
 
PDF
Leveraging Running Stateful Workloads on Kubernetes for the Benefit of Develo...
DoKC
 
Distributed Vector Databases - What, Why, and How
DoKC
 
Is It Safe? Security Hardening for Databases Using Kubernetes Operators
DoKC
 
Stop Worrying and Keep Querying, Using Automated Multi-Region Disaster Recovery
DoKC
 
Transforming Data Processing with Kubernetes: Journey Towards a Self-Serve Da...
DoKC
 
The State of Stateful on Kubernetes
DoKC
 
Colocating Data Workloads and Web Services on Kubernetes to Improve Resource ...
DoKC
 
Make Your Kafka Cluster Production-Ready
DoKC
 
Dynamic Large Scale Spark on Kubernetes: Empowering the Community with Argo W...
DoKC
 
Run PostgreSQL in Warp Speed Using NVMe/TCP in the Cloud
DoKC
 
The Kubernetes Native Database
DoKC
 
ING Data Services hosted on ICHP DoK Amsterdam 2023
DoKC
 
Implementing data and databases on K8s within the Dutch government
DoKC
 
StatefulSets in K8s - DoK Talks #154
DoKC
 
Running PostgreSQL in Kubernetes: from day 0 to day 2 with CloudNativePG - Do...
DoKC
 
Analytics with Apache Superset and ClickHouse - DoK Talks #151
DoKC
 
Overcoming challenges with protecting and migrating data in multi-cloud K8s e...
DoKC
 
Evaluating Cloud Native Storage Vendors - DoK Talks #147
DoKC
 
Kubernetes Cluster Upgrade Strategies and Data: Best Practices for your State...
DoKC
 
We will Dok You! - The journey to adopt stateful workloads on k8s
DoKC
 
Leveraging Running Stateful Workloads on Kubernetes for the Benefit of Develo...
DoKC
 
Ad

Recently uploaded (20)

PDF
MiniTool Partition Wizard 12.8 Crack License Key LATEST
hashhshs786
 
PDF
AOMEI Partition Assistant Crack 10.8.2 + WinPE Free Downlaod New Version 2025
bashirkhan333g
 
PPTX
ChiSquare Procedure in IBM SPSS Statistics Version 31.pptx
Version 1 Analytics
 
PDF
NEW-Viral>Wondershare Filmora 14.5.18.12900 Crack Free
sherryg1122g
 
PDF
TheFutureIsDynamic-BoxLang witch Luis Majano.pdf
Ortus Solutions, Corp
 
PDF
4K Video Downloader Plus Pro Crack for MacOS New Download 2025
bashirkhan333g
 
PPTX
Agentic Automation Journey Series Day 2 – Prompt Engineering for UiPath Agents
klpathrudu
 
PPTX
OpenChain @ OSS NA - In From the Cold: Open Source as Part of Mainstream Soft...
Shane Coughlan
 
PPTX
Hardware(Central Processing Unit ) CU and ALU
RizwanaKalsoom2
 
PDF
Odoo CRM vs Zoho CRM: Honest Comparison 2025
Odiware Technologies Private Limited
 
PPTX
Empowering Asian Contributions: The Rise of Regional User Groups in Open Sour...
Shane Coughlan
 
PDF
Top Agile Project Management Tools for Teams in 2025
Orangescrum
 
PPTX
In From the Cold: Open Source as Part of Mainstream Software Asset Management
Shane Coughlan
 
PPTX
Homogeneity of Variance Test Options IBM SPSS Statistics Version 31.pptx
Version 1 Analytics
 
PPTX
Coefficient of Variance in IBM SPSS Statistics Version 31.pptx
Version 1 Analytics
 
PDF
Driver Easy Pro 6.1.1 Crack Licensce key 2025 FREE
utfefguu
 
PPTX
Foundations of Marketo Engage - Powering Campaigns with Marketo Personalization
bbedford2
 
PDF
AI + DevOps = Smart Automation with devseccops.ai.pdf
Devseccops.ai
 
PPTX
Tally_Basic_Operations_Presentation.pptx
AditiBansal54083
 
PDF
Generic or Specific? Making sensible software design decisions
Bert Jan Schrijver
 
MiniTool Partition Wizard 12.8 Crack License Key LATEST
hashhshs786
 
AOMEI Partition Assistant Crack 10.8.2 + WinPE Free Downlaod New Version 2025
bashirkhan333g
 
ChiSquare Procedure in IBM SPSS Statistics Version 31.pptx
Version 1 Analytics
 
NEW-Viral>Wondershare Filmora 14.5.18.12900 Crack Free
sherryg1122g
 
TheFutureIsDynamic-BoxLang witch Luis Majano.pdf
Ortus Solutions, Corp
 
4K Video Downloader Plus Pro Crack for MacOS New Download 2025
bashirkhan333g
 
Agentic Automation Journey Series Day 2 – Prompt Engineering for UiPath Agents
klpathrudu
 
OpenChain @ OSS NA - In From the Cold: Open Source as Part of Mainstream Soft...
Shane Coughlan
 
Hardware(Central Processing Unit ) CU and ALU
RizwanaKalsoom2
 
Odoo CRM vs Zoho CRM: Honest Comparison 2025
Odiware Technologies Private Limited
 
Empowering Asian Contributions: The Rise of Regional User Groups in Open Sour...
Shane Coughlan
 
Top Agile Project Management Tools for Teams in 2025
Orangescrum
 
In From the Cold: Open Source as Part of Mainstream Software Asset Management
Shane Coughlan
 
Homogeneity of Variance Test Options IBM SPSS Statistics Version 31.pptx
Version 1 Analytics
 
Coefficient of Variance in IBM SPSS Statistics Version 31.pptx
Version 1 Analytics
 
Driver Easy Pro 6.1.1 Crack Licensce key 2025 FREE
utfefguu
 
Foundations of Marketo Engage - Powering Campaigns with Marketo Personalization
bbedford2
 
AI + DevOps = Smart Automation with devseccops.ai.pdf
Devseccops.ai
 
Tally_Basic_Operations_Presentation.pptx
AditiBansal54083
 
Generic or Specific? Making sensible software design decisions
Bert Jan Schrijver
 
Ad

Mastering MongoDB on Kubernetes, the power of operators

  • 1. Mastering MongoDB on Kubernetes, the power of operators Arek Borucki Beamery
  • 2. Agenda • MongoDB architecture • Kubernetes Operators • MongoDB Community K8s Operator • MongoDB Enterprise K8s Operator • MongoDB Atlas K8s Operator • Demo
  • 4. OM java application • consistent backup • rolling upgrades • automation • monitoring
  • 5. Agenda • MongoDB clusters • Serverless • Data Lake • Atlas Search • The Data API (HTTPS) • Advanced security • and more
  • 7. Why to use MongoDB K8s Operators ? Capabilities like Replication, Sharding, Failover or Scalability can help more easily deal with the uncertainty sidecar pattern- MongoDB Agent handles configuring, stopping, restarting and upgrading the mongod process, readiness and liveness probes Provides out of the box security features like TLS, authentication, RBAC Reduce complexity - uses the best human knowledge of creating and operating a MongoDB products Extending Kubernetes API by MongoDB specific objects, like OpsManager or ShardedCluster Uses K8s best practice - Affinity, Pod Disruption Budget, Resource management and K8s reliability features like auto healing
  • 8. The Operator tell K8s how to configure MDB cluster including provisioning storage, setting up the network connections, and configuring other resources
  • 9. The Kubernetes operator watches Custom Resources _ Observe the actual state _ Analyse difference from desired state _ Take action _ Drive the actual state towards the desired stare _ Repeat! Observe Analyse Act my-replica set has 2 running pods Differs from desired state of 3 replicas (pods) Action: - Start a pod - Add pod to the cluster - Waiting for replication
  • 10. • The Operator is Apache open source • Currently only Replica Set • Suited for experimentation and testing • Automated cluster provisioning • Client-to-server, server-to-server with TLS • Scale replica sets up and down • Automated rolling updates • Provides metrics target that can be used with Prometheus MongoDB Community Kubernetes Operator
  • 11. 1 1 custom resource • 1 1 --- apiVersion: mongodbcommunity.mongodb.com/v1 kind: MongoDBCommunity metadata: name: mongodb-replica-set namespace: mongodb spec: members: 3 type: ReplicaSet version: “5.0.5" security: authentication: modes: ["SCRAM"]
  • 13. • Replica Sets, Sharded Clusters, Standalones • AAA, TLS for all traffic between servers and between clients and servers • Ops Manager - monitoring and management platform for MongoDB • Backup Infrastructure (PIT Restore, consistent backup of shard clusters) • User management support • Encryption at Rest, • Multi-Cluster Capabilities MongoDB Enterprise Kubernetes Operator
  • 15. 1 5 custom resources • 1 5 --- apiVersion: mongodb.com/v1 kind: MongoDBOpsManager metadata: name: ops-manager spec: version: 5.0.5 externalConnectivity: type: LoadBalancer applicationDatabase: members: 3 version: 4.0.5-ent --- apiVersion: mongodb.com/v1 kind: MongoDB metadata: name: sharded-cluster spec: shardCount: 2 mongodsPerShardCount: 3 version: 5.0.5 type: ShardedCluster
  • 17. 1 7 • 1 7 --- apiVersion: mongodb.com/v1 kind: MongoDBMulti metadata: name: multi-replica-set spec: version: 5.0.5 type: ReplicaSet clusterSpecList: clusterSpecs: clusterName: - cluster1.mongokubernetes.com members: 2 - cluster2.mongokubernetes.com members: 1 - cluster2.mongokubernetes.com members: 1
  • 18. 1 8
  • 19. • Manage Atlas clusters in directly K8s • Automated Atlas cluster provisioning • Integrate Atlas with Kubernetes-native CI/CD pipelines • Setup Cloud backup • Database users management Atlas Kubernetes Operator
  • 20. 2 0 custom resources • 2 0 --- apiVersion: atlas.mongodb.com/v1 kind: AtlasProject metadata: name: my-project spec: name: Test Atlas Operator Project projectIpAccessList: - ipAddress: "192.0.2.15” comment: "IP address for App Server A" --- apiVersion: atlas.mongodb.com/v1 kind: AtlasDeployment metadata: name: my-atlas-deployment spec: projectRef: name: my-project deploymentSpec: name: test-deployment providerSettings: instanceSizeName: M10
  • 21. 2 1 custom resources • 2 1 --- apiVersion: atlas.mongodb.com/v1 kind: AtlasBackupPolicy metadata: name: atlas-backup-policy spec: items: frequencyType: "weekly" frequencyInterval: 1 retentionUnit: "days" retentionValue: 7 --- apiVersion: atlas.mongodb.com/v1 kind: AtlasDatabaseUser metadata: name: my-database -user spec: roles: - roleName: "readWriteAnyDatabase” databaseName: "admin" projectRef: name: my-project username: the-user
  • 22. • Operators reduce complexity • Extends K8s API by MongoDB objects • Improve consistency • Automate at the level you need • The operator creates persistent volumes and STS for MongoDB Replica Set • Recommendedn method of running databases on K8s Summary

Editor's Notes

  • #10: All of this is made possible by our robust global operations. We designed, own and operate the world’s largest Data Processing center dedicated to travel. This world-class data center is high-performance and highly-resilient, capable of processing billions of transactions involving sensitive data, securely and reliably, every day. Our global operations are supported by more than 900 employees from more than 45 nationalities and is based on a follow-the-sun model, with specialist support groups in Germany, the US, Australia, India and the United Kingdom.