Introduction to Relational Migrator
Relational Migrator is a free tool to help you migrate from a relational database to MongoDB. This page provides an overview of Relational Migrator's key features, use cases, migration scenarios, and supported databases and versions.
Key Features
Map and Model Data
Relational Migrator provides an entity-relationship diagram builder to map your relational schema to a MongoDB schema. You can start with a recommended schema, a 1:1 mapping, or create a new schema from scratch. For more information, see Data Modeling.
Generate Application Code
Relational Migrator generates MongoDB-compatible C#, Java, and JavaScript application code for entity classes, persistence layers, and APIs.
Code generation templates support JSON output and common application frameworks like Spring Data, Node, and Mongoose. For more information, see Code Generation Templates.
Convert and Validate SQL Objects
Relational Migrator uses generative AI to convert SQL queries, views, and stored procedures into MongoDB-compatible code for C#, Java, or JavaScript.
You can test queries within Relational Migrator to validate converted SQL and ensure that your queries are compatible with MongoDB.
Migrate to MongoDB
Use Relational Migrator to migrate data from supported relational databases to MongoDB Atlas or a self-managed MongoDB deployment. You can choose either a snapshot migration, or continuous synchronization with Change Data Capture (CDC). For more information, see Use Cases.
Relational Migrator integrates with Apache Kafka and Confluent Cloud for large scale migrations. For more information, see Kafka Deployment Guide.
Use Cases
Relational Migrator supports both Snapshot and Continuous migration jobs.
Snapshot migration jobs migrate all data once, and then stop.
Continuous migration jobs run a snapshot migration and then enter a CDC stage, which continuously replicates data changes.
Some relational databases are only compatible with Snapshot migration jobs. For more information, see the following table:
Database | Snapshot Migration Job Support | Continuous Migration Job Support |
---|---|---|
Databases supported with a JDBC driver |
Migration Scenarios
You can use Relational Migrator to migrate one legacy application at a time to MongoDB. Depending on your application's needs, you can migrate either with or without downtime.
Migrate During Scheduled Downtime
If your application does not require constant uptime, such as in the case of an internal application, you can have the migration occur during scheduled downtime. Migrating during downtime is the easiest way to configure and complete the migration process.
When you start the migration process, Relational Migrator takes a snapshot of the data on the legacy application and migrates the data from that point in time. During the migration process, your legacy application can remain online to support incoming reads, but cannot support incoming writes. The length of the migration process depends on several factors, such as the amount of data being migrated and your connection speed.
After the migration completes, take your legacy application offline and launch your new application.
Migrate Without Downtime
If your application must remain online to support reads and writes during the migration process, you can use Change Data Capture (CDC) to migrate data without downtime. This process is called a continuous migration.
When you start a continuous migration job, Relational Migrator takes a snapshot of the data on the legacy application and tracks database updates in near real time. During the migration process, your source and destination databases remain in sync.
After the continuous migration job completes, you can transfer users to the new application and shut down the legacy application.
To learn more about migration jobs, see Data Migration.
Unsupported Scenarios
Relational Migrator currently does not support migrating an operational data store. Depending on your workload, migrating a data store could cause CDC to run indefinitely without completing, which is not recommended with Relational Migrator.
Relational Migrator will support more migration scenarios and use cases in future releases.
Supported Databases and Versions
Source Databases and Versions
Relational Migrator supports the following source databases:
Database | Supported Versions | Deployments |
---|---|---|
2012 and higher (Enterprise or Developer edition required for versions before 2016) | Self hosted, AWS RDS, Azure SQL Database | |
5.7 and higher | Self hosted, AWS RDS/Aurora, Azure Database | |
11g and higher | Self hosted, AWS RDS | |
10 and higher | Self hosted, AWS RDS/Aurora, Azure Database | |
10 and higher | Self hosted, AWS RDS/Aurora, Azure Database |
Databases Supported with a JDBC Driver
Important
This feature is in public preview.
Some databases are supported for snapshot data migration through a JDBC connection. You can run snapshot migration jobs against these databases, but not continuous CDC sync jobs.
Database | Supported Versions | Deployments |
---|---|---|
CockroachDB | 24.3.0 and higher | Self hosted |
DB2 | 11.5 and higher | Self hosted, AWS RDS |
SQL Anywhere | 16.0 and higher | Self hosted |
Sybase ASE | 15 and higher | Self hosted |
Sybase IQ | 16.0 and higher | Self hosted |
Yugabyte | 2.20 and higher | Self hosted |
Target Databases and Versions
Relational Migrator supports the following target databases:
Deployment Type | Supported Versions |
---|---|
MongoDB Server (Self-Managed) | 5.0 and higher |
MongoDB Atlas | 5.0 and higher |