Example — multi-tenant
Example — multi-tenant
Per-tenant connection-pool isolation and per-tenant cost budgets via the cost-governor plugin.
Source on GitHub: HDB-HeliosDB-Proxy/examples/multi-tenant
Demonstrates
- Three demo tenants (
acme-co,globex,initech) each with their own pool slice - Per-tenant CPU / memory / connection budgets enforced at the proxy layer
cost-governorWASM plugin rejecting queries that exceed the daily cost budgetcolumn-maskWASM plugin redacting PII columns based on the caller’s role
Run
cd HDB-HeliosDB-Proxy/examples/multi-tenantdocker compose up -d./test-tenants.shtest-tenants.sh runs queries as each tenant and shows:
- Acme connecting through its dedicated pool
- Globex hitting its budget and getting
ERROR: cost-governor: daily budget exhausted - Initech’s analyst role seeing
mask_ssn(ssn)instead of raw SSNs
Plugin configuration
The proxy.toml references the bundled plugins from HDB-HeliosDB-Proxy-Plugins. For the publisher path (sign + push to OCI registry), see the helios-plugin CLI.