Skip to content

Use paid tier for production workloads#

Reliability · Cosmos DB · Rule · 2024_06 · Important

Use a paid tier to qualify for a Service Level Agreement (SLA).

Description#

Cosmos DB offers one account on selected subscriptions to be marked to use a free tier allowance of 1000 DTUs. This free tier is intended for developers to try Cosmos DB during early development and proof of concepts (PoC). Using the free tier offer is not intended to be used for production level workloads.

When using the free tier, the SLA for Cosmos DB does not apply.

Recommendation#

Consider using a paid SKU to qualify for a Service Level Agreement (SLA).

Examples#

Configure with Azure template#

To deploy Cosmos DB accounts that pass this rule:

  • Set the properties.enableFreeTier property to false or do not configure the property.

For example:

Azure Template snippet
{
  "type": "Microsoft.DocumentDB/databaseAccounts",
  "apiVersion": "2023-04-15",
  "name": "[parameters('name')]",
  "location": "[parameters('location')]",
  "properties": {
    "enableFreeTier": false,
    "consistencyPolicy": {
      "defaultConsistencyLevel": "Session"
    },
    "databaseAccountOfferType": "Standard",
    "locations": [
      {
        "locationName": "[parameters('location')]",
        "failoverPriority": 0,
        "isZoneRedundant": true
      }
    ],
    "disableKeyBasedMetadataWriteAccess": true
  }
}

Configure with Bicep#

To deploy Cosmos DB accounts that pass this rule:

  • Set the properties.enableFreeTier property to false or do not configure the property.

For example:

Azure Bicep snippet
resource account 'Microsoft.DocumentDB/databaseAccounts@2023-04-15' = {
  name: name
  location: location
  properties: {
    enableFreeTier: false
    consistencyPolicy: {
      defaultConsistencyLevel: 'Session'
    }
    databaseAccountOfferType: 'Standard'
    locations: [
      {
        locationName: location
        failoverPriority: 0
        isZoneRedundant: true
      }
    ]
    disableKeyBasedMetadataWriteAccess: true
  }
}

Comments