Databases
Goal: Know what the Databases window does, and where each part of a database is managed.
Environment -> Databases manages accounts: the CosmosDB accounts your workspace creates in your own Azure subscription. It is not where databases or containers are made:
| Level | Where you manage it |
|---|---|
| Account | Environment -> Databases (this window) |
| Database | A Database node on the canvas that names the account |
| Container | Manage containers in that node's inspector - see Database Containers |
The fields, the scaling profiles, the region rule and what an account is not for are in CosmosDB Setup. This page covers the window itself.
Before you start
- A connected cloud and a provisioned private landing zone. Until both exist the menu has no Databases. An empty region list in the form is the usual sign that one is missing.
What the window shows
| Part | What it is |
|---|---|
| Latest deployment | The newest save from this window, followed until it ends |
| What is running now | With nothing running, the health of the accounts this window built |
| The hero | CosmosDB accounts, with a strip under it: Documents, not telemetry, Nothing to paste and In your own cloud |
| Proposal banner | "An agent has proposed a data store" (or several), with each one and the agent's reason |
| Accounts | One row per account: its name, region and scaling profile, its state, and its actions |
| The account form | Hidden until you ask for it. One form creates an account, finishes one, or edits a live one |
| What you get | Inside the account form, collapsed: what provisioning creates, and what to do next |
| Before you start | Inside the account form, collapsed: what the account needs, and what it is not for |
| History | "All databases: every change, not filtered by database." |
With no accounts yet: "No accounts yet. Create one below and provisioning starts in the background — you do not have to wait on this screen."
The buttons
| Button | Where | What it does |
|---|---|---|
| Create your first account / Add account | The Accounts header | Opens a blank form |
| Save & Provision | The form | Creates the account, or finishes one, in your Azure subscription |
| Save & Apply | The form, on a live account | Saves your changes and re-runs provisioning against the account |
| Accept Proposal and Save | The form, on a proposal | Accepts the proposal, then provisions it, in one press |
| Reject Proposal | The form, on a proposal | Asks "Reject this proposal? Nothing is created in Azure." and removes it, with any account bundled with it |
| Cancel | The form | Closes the form and clears it |
| Finish setup | An account row | Opens an account whose provisioning has not run |
| Review Proposal | An account row | Opens a proposed account in the form |
| Try again | An account row | Opens an account whose provisioning reported an error |
| Edit settings | An account row | Opens a live account: name, description, scaling profile, backup and Protect from deletion can change; region, resource group and API cannot |
| Remove | An account row | Asks for a removal (see below) |
Save and Deploy
Save & Provision and Save & Apply build in your Azure subscription at once; they do not wait for Deploy. Provisioning runs in the background and the row updates as it completes; you do not have to keep the window open.
Removing an account is not available yet: Remove says so and nothing changes. An account that still holds databases is refused first: remove those databases first, or remove them together.
Rights
Save & Provision checks no access right beyond being in the workspace. Reading and writing documents is a separate grant - see Table endpoints.
Azi and agents
Azi and agents can propose an account: its name, description, notes, scaling profile, backup and delete protection at any time; its type, region, resource group and API only before it is created. Only the NoSQL (SQL API) can be created today. Turning delete protection off needs a person: a proposal that does it is accepted only by a person who confirms it.
A proposed account shows in the proposal banner and as a highlighted row. Review Proposal opens it in the form, and Accept Proposal and Save accepts and provisions it. The Databases menu item counts pending account proposals.
Messages you may see
| Code | Message |
|---|---|
PRIVATE_LANDING_ZONE_REQUIRED | "This needs a private landing zone, which this workspace does not have yet." |
CREATE_TIME_ONLY_FIELD | Region, resource group and API cannot change once the account exists |
API_TYPE_NOT_PROVISIONABLE | Only NoSQL (SQL API) accounts can be created today |
ILLEGAL_TRANSITION | A backup change Azure does not allow (continuous back to periodic), or a switch to or from serverless |
DELETE_PROTECTION_DISABLE | Turning delete protection off needs a person to approve it |
DATA_STORE_HAS_DATABASES | "A data store cannot be removed while databases still live in it. Remove those databases first, or remove them together." |
KIND_TEARDOWN_UNSUPPORTED | Removing an account is not built yet, so it is refused and nothing changes |
| A failed provision | "Provisioning did not complete. Use Finish setup to try again." unless the platform named the reason |
Next steps
- The account fields -> CosmosDB Setup
- Containers -> Database Containers
- The order things unlock in -> Environment