Database - Azure CosmosDB
Following are steps for Azure Cosmos DB deployment for integration with DecisionRules.
After navigating to Azure Cosmos DB, hit Create. Choose Azure DocumentDB (with MongoDB compatibility).
From version 1.21.0, we recommend using the Azure DocumentDB (formerly vCore) type instead of RU-based type for new environments, following Microsoft’s own recommendation.

Azure DocumentDB (formerly vCore)
Assign your resource group, give the cluster a name, choose a location and choose the cluster tier and version if necessary.

Next go to the Networking tab and fill in the settings.
It is recommended to use a Private Endpoint connection but for hassle free non-Prod environment deployments a Public Endpoint is also an option.
Create your private endpoint, making sure it shares the same virtual network as your future server container.

For the Global distribution, Encryption and Tags choose whatever fits your use-case. Review the account and create.
If you use Azure DocumentDB (formerly called vCore-based Cosmos DB) you need to specify the DB_TYPE environmental variable in your server container with value COSMOSDB_VCORE. More information here: Environment Variables
RU-based
Assign your resource group, give the account a name, choose a location and choose the Serverless capacity mode.
Serverless Capacity mode has much lower operating costs compared to the Provisioned Throughput option. If for whatever reason you decide to go with the Provisioned Throughput option anyways, make sure to set the limit to a minimum of 12000 RUs.

Set your Global Distributions settings if needed. Next go to the Networking tab and fill in the settings.
It is recommended to use a Private Endpoint connection but for hassle free non-Prod environment deployments a Public Endpoint is also an option.
Create your private endpoint, making sure it shares the same virtual network as your future server container.

For the Backup Policy, Encryption and Tags choose whatever fits your use-case. Review the account and create.
Where to find a connection string
After the database account has been created, navigate to Settings / Connection strings. The connection string can be found under Primary/Secondary connection string.
If you use RU-based Cosmos DB you need to specify the DB_TYPE environmental variable in your server container with value COSMOSDB. More information here: Environment Variables
Last updated
Was this helpful?

