Migrate your programmatic tools from M2, M5, or Serverless Instances to Flex Clusters
On this page
Atlas will deprecate M2 and M5 clusters and Serverless instances in the near future. Atlas will automatically migrate all M2 and M5 clusters to Flex clusters. For Serverless instances, Atlas will determine whether to migrate instances to Free clusters, Flex clusters, or Dedicated clusters according to your usage. To see which tiers Atlas will migrate your instances to, consult the All Clusters page in the Atlas UI.
After your tool of choice supports Flex clusters, update your code by replacing all references to deprecated instance types with references to Flex Clusters.
Note
If your workloads require Private Endpoints or Continuous Backup and Point-in-Time Restore, we recommend that you switch to Atlas Dedicated Clusters.
Migrating API Configuration
The Cluster API endpoints listed in the table in this
section are compatible with M2
/M5
clusters. These will retain their
present functionality until January of 2025, at which time these
endpoints will begin managing Flex clusters. You can
continue using these API endpoints without change until they reach End of Life
(EOL) in January 2026.
API endpoints for Serverless Instances will begin managing Flex clusters in January of 2025. After March 2025, all existing Serverless instances will be migrated to Free clusters, Flex clusters, or Dedicated clusters, according to your usage. If your Serverless instance is migrated to a Free cluster or Dedicated cluster, you must use the Cluster API endpoint instead. To see which tiers Atlas will migrate your instances to, consult the All Clusters page in the Atlas UI.
If you attempt to create an M2
/M5
cluster using the
createCluster endpoint, or a Serverless instance
using the createServerlessInstance endpoint, between
January of 2025 and January of 2026, you will instead create a
Flex cluster. Support for these endpoints ends January 2026.
You must replace calls to Serverless instance API endpoints with appropriately configured calls to the Clusters API endpoints before your Serverless instances are migrated to Flex clusters.
The following changes also apply to the listed API endpoints beginning January of 2025.
Endpoint | Impact |
---|---|
Deprecated for new Flex clusters. Will return an error once
Serverless instances are migrated to Free, Flex or Dedicated clusters
after March 2025. | |
When used on Flex clusters, upgradeSharedCluster takes the
value set by the user, but does not toggle Continuous Backup because
Continuous Backup is not available for Flex clusters. | |
When used on Flex clusters, createServerlessInstance takes the
value set by the user, but does not toggle Continuous Backup because
Continuous Backup is not available for Flex clusters. | |
When used on Flex clusters, updateServerlessInstance takes the
value set by the user, but does not toggle Continuous Backup because
Continuous Backup is not available for Flex clusters. | |
When used on Flex clusters, setServerlessAutoIndexing takes the
value set by the user, but does not toggle Auto-Indexing because
Auto-Indexing is not available for Flex clusters. | |
When used on Flex clusters, getServerlessAutoIndexing takes the
value set by the user, but does not toggle Auto-Indexing because
Auto-Indexing is not available for Flex clusters. |
Terraform Atlas Provider Migration
The HashiCorp Terraform MongoDB Atlas Provider will support Flex clusters
starting in November of 2024. General Terraform support for
M2
/M5
clusters and Serverless instances will continue
until January 2026. You must update your Terraform configurations to
operate on Flex clusters according to the following timelines,
depending on which features you use:
Feature | Update Deadline |
---|---|
March, 2025 | |
Serverless PrivateLink Endpoint Service
for new Serverless instances | January, 2025 |
Serverless PrivateLink Endpoint Service
for existing Serverless instances | March, 2025 |
All other features | January, 2026 |
Go SDK Migration
The Atlas Go SDK will support Flex clusters starting in November
of 2024. General SDK support for M2
/M5
clusters and
Serverless instances will continue until January 2026. You must
update your SDK scripts to operate on Flex clusters according to
the following timelines, depending on which features you use:
Feature | Update Deadline |
---|---|
March, 2025 | |
All other features | January, 2026 |
Atlas CLI Migration
The Atlas CLI will support Flex clusters beginning December of
2024. General Atlas CLI support for M2
/M5
clusters and
Serverless instances will continue until January 2026. Support for
continuous cloud backup on Serverless instances will end January 2025. You
must update your Atlas CLI workflows to remove
Serverless Instance continuous cloud backup before January 2025; you must
remove all M2
/M5
and Serverless Instance commands from
your Atlas CLI workflows before January 2026.
Atlas Kubernetes Operator Migration
The Atlas Kubernetes Operator will support
Flex clusters beginning January 2025. This includes the ability to create
and manage Flex instances in the same Atlas Deployment Custom Resources. New
releases of Atlas Kubernetes Operator will cease supporting M2
/M5
clusters and
Serverless instances in Summer 2025. Older versions of Atlas Kubernetes Operator
will continue to support these instance types until January
2026.
Support for private endpoints on Serverless instances will end March 2025.
You must update your Atlas Kubernetes Operator configurations to remove private endpoints the
reach EOL. You must remove all remaining M2
/M5
and
Serverless Instance features from your Atlas Kubernetes Operator configurations before
January 2026.
Atlas CloudFormation Migration
Atlas CFN and CDK will support Flex clusters beginning in
the first half of 2025. General support for M2
/M5
clusters
will continue until January 2026.
Support for Serverless Private Endpoints
and the Properties.ContinuousBackupEnabled
parameter of the
Serverless Instance
resource will end when Atlas CFN introduces Flex cluster
support. You must update your CFN and CDK resources to remove these
resources by March 2025. You must remove all M2
/M5
and
Serverless instance features from your Atlas CFN and CDK resources
before January 2026.