V5.8.0
Runtime multi-tenant management parity: a Polecat-backed service's Tenants tab is now editable in CritterWatch. MasterTableTenancy declares JasperFx.MultiTenancy.IDynamicTenantSource<string> — the store-agnostic abstraction Marten's tenancies already implement — and AddPolecat registers it in DI when master-table tenancy is configured, so add / disable / enable / remove round-trip against SQL Server with no CritterWatch release required.
Highlights
MasterTableTenancy : ITenancy, IDynamicTenantSource<string>, reportingCardinality == DatabaseCardinality.DynamicMultiple. The interface members adapt to the existing cancellable Polecat-native methods, so nothing on the concrete API changed.FindAsyncthrowsUnknownTenantIdExceptionfor an unknown or disabled tenant.AllActive()returns tenant database identifiers rather than raw connection strings, so credentials never reach an admin dashboard — matching Marten.- The jasperfx#413 auto-assign overload keeps its default
NotSupportedException: database-per-tenant has no pool for Polecat to assign from, so the caller supplies the connection string. - The DI registration is deliberately conditional — single-database and static
MultiTenantedDatabases()stores leaveGetServices<IDynamicTenantSource<string>>()empty, which is the signal consumers use to fall back to a read-only tenant list.
One behavior change
To make the tenancy probe possible while the container is still being assembled, AddPolecat(Action<StoreOptions>) now builds the StoreOptions eagerly and delegates to AddPolecat(StoreOptions) — exactly as Marten's AddMarten(Action<StoreOptions>) does. The configure lambda now runs at registration time rather than on first IDocumentStore resolution; it takes no IServiceProvider, so nothing it can legally reach has changed, and the IConfigurePolecat chain still runs later at store construction. AddPolecat(Func<IServiceProvider, StoreOptions>) cannot probe and does not auto-register the source; see the docs for the one-liner.
Docs
New Store-Agnostic Runtime Tenant Management section in Multi-Tenancy.
What's Changed
- chore: drop the inert parallelizeAssembly from xunit.runner.json by @jeremydmiller in #384
- feat: MasterTableTenancy implements IDynamicTenantSource (#377) by @jeremydmiller in #385
Full Changelog: V5.7.1...V5.8.0