Table of Contents

TTenantRoutingConnectionPool Class

IDBConnectionPool facade that resolves the current tenant on every connection request and routes it to the pool of the tenant's shard.

Remarks

Hand it to any code expecting a plain connection pool, such as an XData server module. Each call to GetConnection asks the ITenantResolver for the current tenant id and delegates to the ITenantDBPoolProvider.

Syntax

Unit: Aurelius.Tenancy.Provider

TTenantRoutingConnectionPool = class(TInterfacedObject, IDBConnectionPool);

Constructors

Name Description
Create Creates a new TTenantRoutingConnectionPool instance.

Methods

Name Description
GetConnection Returns a connection to the shard database of the current tenant.