ACTS Blog Selection
We use machine learning technology to do auto-translation. Click "English" on top navigation bar to check Chinese version.
Use the compatibility tool for Amazon DocumentDB (with MongoDB compatibility) to improve migrations
Amazon DocumentDB was purpose built from scratch to be cloud native by separating compute and storage. You can take advantage of the quickly distributed underlying storage that grows automatically when needed; an Amazon DocumentDB cluster volume can grow to a
In this post, we introduce new feature releases to Amazon DocumentDB and discuss the benefits of the compatibility tool when migrating your workloads to Amazon DocumentDB.
Working backward
At Amazon Web Services, we
-
Performance Insights so you can quickly assess the load on your database and determine when and where to take action -
DML auditing to capture read and write events - Support for
$mergeObjects, $reduce , and theDecimal 128 data type - A
JDBC driver to connect from BI tools - Support for storing, querying, and indexing
geospatial data -
Create clones to enable fast creation of a new cluster that uses the same DocumentDB cluster volume and has the same data as the original -
Elastic clusters that provide elastic scale to handle virtually any number of writes and reads, with petabytes of storage capacity -
Client-side Field Level Encryption (FLE) to selectively encrypt sensitive data in-application usingAmazon Web Services Key Management Service (Amazon Web Services KMS) before it is sent to the database
We have added over 50 additional capabilities to Amazon DocumentDB since its launch, and will continue to work backwards from our customers’ perspective to deliver the capabilities that you need.
Migrate to Amazon DocumentDB
When you consider moving your workload to Amazon DocumentDB, it’s important to consider the
To help expedite and simplify the compatibility checks for your application, the Amazon DocumentDB team has created the
Compatibility tool
The compatibility tool requires one (or both) of the following:
- Access to your application’s source code
- MongoDB Server profiling logs, capturing as much of the application workload as possible
You can download and run the compatibility tool in minutes.
The compatibility tool and example source code files are available in our
In this first example, we have a Python script named sample-python-1.py
with 100% Amazon DocumentDB compatibility. Running the compatibility tool produces the following output:
In this second example, our Python script contains an unsupported operator and produces the following output:
When the compatibility tool finds unsupported operators, it displays the specific files and line numbers of each, making it simple to review the specific code and implement a workaround.
Both of these examples show the compatibility tool analyzing a single file. You can use the --directory
parameter to analyze more of the files in a directory and recursively directories within the directory. Other optional command line arguments are shown by running the tool with the -h
option.
Note that the compatibility tool is simply one step in a
Summary
Amazon DocumentDB interacts with the Apache 2.0 open source MongoDB 3.6, 4.0, and 5.0 APIs. As a result, you can use the same MongoDB drivers, applications, and tools with Amazon DocumentDB with little or no changes. Additionally, you can use the Amazon DocumentDB Compatibility Tool to simplify and expedite your workload migrations to Amazon DocumentDB.
With Amazon DocumentDB, you get a fully-managed document database experience. This means you don’t need to focus on instance failover, database backups and recovery, or software upgrades. You can focus on building your application and innovating for your customers. Visit
About the Authors