19 lines
581 B
Python
19 lines
581 B
Python
"""
|
|
app/tenancy/
|
|
============
|
|
Host-based tenant resolution and per-tenant database routing (MT-1).
|
|
|
|
Public surface:
|
|
RoutingSession — tenant-aware session class (installed on `db`)
|
|
init_tenancy — registers the before_request resolver hook
|
|
TenantContext — detached descriptor carried on g.tenant
|
|
|
|
Inert unless config MULTI_TENANT_ENABLED is True.
|
|
"""
|
|
|
|
from app.tenancy.routing import RoutingSession
|
|
from app.tenancy.middleware import init_tenancy
|
|
from app.tenancy.context import TenantContext
|
|
|
|
__all__ = ['RoutingSession', 'init_tenancy', 'TenantContext']
|