Migrate to Astra DB Serverless
The migration process includes exporting data from its original location, uploading or importing your data to your new Astra DB databases, and then updating your applications to connect to your new databases.
Migrate your data
DataStax offers several options to help migrate your data to Astra DB.
Migrate from DSE, HCD, or Apache Cassandra®
The following tools are designed to migrate Cassandra table data into a Cassandra-compatible cluster, such as Astra DB:
-
DataStax Zero Downtime Migration (ZDM) tools: Move your data to Astra DB with minimal configuration changes and little or no downtime.
The ZDM tools orchestrate live read and write traffic between your original database and new Astra DB database while you use a data migration tool (Astra DB Sideloader, CDM, or DSBulk) to migrate your preexisting data to the new database.
All new writes are sent to both databases, and your original database remains the source of truth for reads until you’re ready to permanently switch to your Astra DB database.
You can terminate the migration at any time before the final cutover with no impact to your original database.
-
Astra DB Sideloader: A service running in Astra DB that directly imports data from snapshot backups that you’ve uploaded to Astra DB from an existing Apache Cassandra®, DataStax Enterprise (DSE), or Hyper-Converged Database (HCD) cluster.
You can use Astra DB Sideloader alone or in conjunction with the ZDM tools.
-
Cassandra Data Migrator (CDM): Migrate and validate tables between origin Cassandra clusters and target Astra DB databases, with available logging and reconciliation support.
You can use CDM alone or in conjunction with the ZDM tools.
-
DataStax Bulk Loader (DSBulk) is an OSS command-line tool that you can use to extract and load CSV and JSON files containing Cassandra table data. You can use DSBulk to bring data from Cassandra, DSE, or HCD into Astra DB, as well as move data between collections and tables in Astra DB databases.
For more information about all of these options, see the DataStax data migration documentation.
Migrate from non-Cassandra sources
Because Astra DB is based on Apache Cassandra, it expects data to be in a format that is compatible with Cassandra table schemas.
When migrating from a schemaless source, you can use the Data API to insert documents into Astra DB collections. However, the Data API cannot transform your data if it is incompatible with Data API limits or functionality. For example, if fields exceed the maximum character limit or contain invalid values, the Data API throws an error. You must modify the incompatible data, and then reattempt the insert operation.
You can also use techniques like super shredding to flatten, normalize, and map schemaless or semi-structured JSON/CSV data into a Cassandra-compatible fixed schema, and then load the data into Astra DB with DSBulk or other tools. However, super shredding can be complex and cumbersome, depending on the structure (or lack thereof) of the source data.
Migrate your code
After migrating your data to Astra DB, your applications can connect exclusively to your Astra DB databases.
Aside from the database connection, your code might not require any other changes if you already use a compatible driver and CQL statements. However, you might consider migrating your code to the Data API, which provides programmatic access to collections and tables in your Serverless (vector) databases, including vector search and hybrid search capabilities.
For more information about connecting to Astra DB and migrating your applications, see the following: