Multi-tenancy
How it works
Each request is associated with a tenant through an identifier (tenant ID / tenant context), typically derived from authentication, a subdomain, or a header. An isolation layer enforces that operations and queries act only within that tenant's data. Data is partitioned using one of three models: separate databases per tenant (strongest isolation, highest cost), a shared database with separate schemas, or a shared database and shared schema with a tenant discriminator column (highest density, lowest cost, strongest reliance on application-layer security). At the deployment level, the silo (resources dedicated to a tenant), pool (shared, scalable resources), and bridge (a hybrid of both) models are used. An overarching control plane manages tenant onboarding, identity, configuration, and lifecycle, while resource governance mechanisms — limits, quotas, and throttling — guard against one tenant degrading the performance of others.
Problem solved
Running a separate, dedicated application instance for every customer is expensive and hard to maintain: the number of environments to update, monitor, and scale grows while resources stay underutilized. Multi-tenancy solves this by letting a single instance serve many tenants on shared infrastructure, while preserving isolation of each tenant's data and configuration.
Components
An identifier that associates every request, record, and operation with a specific tenant. Propagated through the whole stack, from authentication to the data layer.
Mechanisms ensuring that one tenant's data and activity are not accessible to others — from query filtering and access policies to network and runtime separation.
The strategy for separating tenant data: separate databases, a shared database with separate schemas, or a shared schema with a tenant discriminator column.
Official
A shared component responsible for onboarding, identity, configuration, billing, and the lifecycle of tenants — even when their resources are dedicated (silo).
Limits, quotas, and throttling preventing a single tenant from consuming a disproportionate share of shared resources.
Official
Implementation
A single tenant generating disproportionate load can degrade performance for the other tenants sharing resources.
With a shared schema, missing tenant-ID filtering in even a single query can expose another tenant's data.
If tenant context is not consistently propagated across the whole stack (queues, background jobs, service calls), operations may act on the wrong tenant's data.
Evolution
The commercial success of software delivered as a service on shared, multi-tenant infrastructure established multi-tenancy as the dominant SaaS pattern.
The arrival of public cloud (including Amazon EC2) made shared, scalable infrastructure standard, reinforcing the economies of scale of multi-tenancy.
Hyperparameters (configurable axes)
Choice between silo (dedicated resources), pool (shared resources), and bridge (hybrid) for individual system components.
How tenant data is separated at the storage level.
How the tenant for a request is determined: subdomain, header, or a claim in the authentication token.
Per-tenant limits and throttling protecting shared resources from overuse.
Hardware requirements
Multi-tenancy is a software- and deployment-level architectural pattern — it does not depend on any specific hardware type.