MongoDB
In this section, we will go over how to gather your credentials and prepare your MongoDB server to start providing CDC logs.
Introduction
We will be running Debezium to fetch CDC logs from MongoDB by using Change Streams which is a more performant and reliable approach than tailing the oplog
.
MongoDB server must be in a replica set. If your deployment only has a standalone
server, you can create a replica set with one member.
Need help? Check out this guide.
Finding your MongoDB settings
This is necessary so that we are able to run a Debezium deployment to subscribe to Change Events within your MongoDB cluster. To see additional configuration properties, please click here to see Debezium's documentation.
Name | Description | Default value |
---|---|---|
Connection string | Click here to see how to retrieve this. | No default. |
Username | Username for authentication into your database. | No default |
Password | Password for authentication into your database. | No default |
Authentication source | MongoDB authSource (which database should we authenticate against) | admin |
Creating a service account
You can either use the Atlas UI or use MongoDB CLI.
Option #1 - Atlas UI
Click on "Database Access" on the left
Click on "Add New Database User"
Under "Database User Privileges", open "Built-in Role" and Select "Only read any database"
Option #2 - Service account script
Connection string
Go to Atlas UI
Find your deployment and click "Connect"
We support both MongoDB SRV format or standard connection string.
Supported types
Artie supports every MongoDB data type 🙂
Running it yourself
Self-hosted notes:
value.converter
must be set toorg.apache.kafka.connect.json.JsonConverter
value.converter.schemas.enable
must be set totrue
Last updated