Back to Flyway

CosmosDB

documentation/Reference/Database Driver Reference/CosmosDB.md

latest2.7 KB
Original Source
  • Flyway configuration: Native Connectors only
  • Verified Versions: 7.0
  • Maintainer: {% include redgate-badge.html %}

Supported Versions and Support Levels

{% include database-boilerplate.html %}

Driver

ItemDetails
URL formatmongodb://ip address:port number/database_name
SSL supportYes
Ships with Flyway Command-lineJSON migrations: Yes.
Javascript migrations requires Mongosh to be installed separately
Maven Central coordinatesn/a

Using Flyway with MongoDB Native Connectors

Observations

CosmosDB aims to be MongoDB compatible - as such we use the Flyway MongoDB infrastructure and can only verify that Flyway's verb testing works.

  • We saw this error: The request did not complete due to a high rate of metadata requests. which was overcome by enabling Server Side Retry on the Settings/Features page on the CosmosDB management tool.

Limitations

The Flyway Native Connectors blog post describes more of the details of the Native Connectors changes.

  • Transactions are only available with JSON migrations (these use the API and not Mongosh)
  • Dry run is not available

Terminology

We have to map Flyway concepts and language rooted in the relational database world to MongoDB - this is how Flyway sees the mapping:

MongoDB ConceptFlyway Concept
databasedatabase/schema
collectiontable
rowdocument
transactiontransaction