Multi-Tenancy
One deployment serving many isolated customers, with tenancy threaded through data, routing, and access.
Multi-tenancy is serving many customers from one deployment, with each customer's data isolated from the others. The alternative — a separate deployment per customer — is simpler to reason about and vastly more expensive to operate.
Isolation has to be established at several layers, and a gap in any one of them is a data leak. Storage: every query must be scoped to a tenant, ideally by a mechanism that cannot be forgotten rather than by convention. Routing: a request must resolve to exactly one tenant, usually by subdomain or path. Authorization: a user's membership of a tenant must be checked, and an administrative role that spans tenants is a specific hazard — a query run as such a role returns rows from every tenant, so code that takes the first result gets an arbitrary one.
The operational shape matters too. Shared infrastructure means one tenant's load affects others, and per-tenant customization — a theme, a domain, a configuration — has to be data rather than code, or the "one deployment" property is lost.
Local development for a multi-tenant system needs the same addressing scheme as production, which is why wildcard local domains and matching origin configuration are usually required rather than optional. See Same-Origin Policy.
See also4
Domain Name System
The distributed directory translating names to addresses, and the layer where propagation delays live.
Systems & Tooling16 connections
Relational Database
Data organized as tables with declared relationships, queried declaratively and guarded by constraints.
Data & Content13 connections
Feature Flag
A runtime switch that decouples shipping code from enabling behavior.
Data & Content12 connections
Headless CMS
A content system exposing structured data through an API, with presentation left entirely to consumers.
Data & Content9 connections
Related3
Nearby in the graph rather than deliberately chosen. Looser, sometimes surprising.
Linked from8
- Database ShardingData & Content
Splitting one dataset across multiple databases by key, trading a single point of scale for cross-shard complexity.
- Domain Name SystemSystems & Tooling
The distributed directory translating names to addresses, and the layer where propagation delays live.
- Draft and PublishedData & Content
Keeping an in-progress version of content separate from the live one, with all the state that implies.
- Feature FlagData & Content
A runtime switch that decouples shipping code from enabling behavior.
- Headless CMSData & Content
A content system exposing structured data through an API, with presentation left entirely to consumers.
- PortSystems & Tooling
The numeric endpoint a network service listens on, and a scarce shared resource on a developer machine.
- Relational DatabaseData & Content
Data organized as tables with declared relationships, queried declaratively and guarded by constraints.
- Same-Origin PolicyWeb Platform
The browser rule isolating documents by scheme, host, and port, and the mechanisms for relaxing it.