tenant-db-ops
マルチテナント(顧客別DB分離)のDB運用・マイグレーション・調査に使う。
When & Why to Use This Skill
This Claude skill is designed for managing multi-tenant database architectures where customer data is isolated into separate databases. It streamlines complex database operations, including schema migrations, tenant-specific investigations, and infrastructure maintenance, ensuring strict data isolation and consistency across all environments.
Use Cases
- Automating the provisioning of new customer databases with standardized schemas and configurations.
- Executing phased schema migrations (add column, backfill, switch, drop) to minimize downtime and prevent breaking changes in multi-tenant environments.
- Conducting cross-tenant bug investigations by resolving database connections through a centralized tenant_id system.
- Synchronizing database changes with technical specification documents to maintain accurate system documentation and schema integrity.
- Managing audit logs and execution histories to comply with data retention and security auditing requirements.
| name | tenant-db-ops |
|---|---|
| description | マルチテナント(顧客別DB分離)のDB運用・マイグレーション・調査に使う。 |
使いどころ(トリガー例)
- 「顧客DBを追加」「schema 変更」「マイグレーション」「越境バグ調査」
運用原則
- 顧客別DBは越境させない(接続解決は tenant_id 起点で一元化)。
- 破壊的変更は段階導入(add column → backfill → switch → drop)。
- 監査ログ/実行履歴は消さない(保持要件に従う)。
追加するもの
- 新テーブル/列は
仕様書/システム仕様書_技術者向け.mdのスキーマと整合させる。