Multi-tenancy
Estimated reading time: 2 minutes 预计阅读时间: 2 分钟Full Chinese version:
/guide/core/multi-tenancy.
Four isolation levels
Config
How rewriting works
Business code stays plain SeaORM:
The plugin pipeline parses the prepared SQL, injects the tenant context, and emits the rewritten SQL transparently. Business code stays agnostic.
Verification
Or enable SeaORM logging:
Capabilities included
encrypt/— column-level encryption before persistingmasking/— output masking by rule (phone, ID, email)shadow/— mirror traffic to a shadow DBaudit/— pluggableSqlAuditorhookscdc/— Postgres logical replication (pgwire-replication)migration/— assist in moving tenants between isolation modesddl/— DDL fan-out across tenants
Tables shared across tenants
Add to ignore list:
Source files
crates/summer-sharding/src/{config,tenant,rewrite,encrypt,masking,cdc,migration,ddl}/crates/summer-sql-rewrite/src/
