Uploaded October 2026 | Updated November 2026, 2 days ago
In this episode, I keep working on the new organization and LTI tool registration data model in Tsugi—and CodeRabbit finds a few issues that send us deeper into the rabbit hole than expected.
We work through what should happen when an organization is deleted, how courses and tool deployments should behave, where database constraints help, and where the application service layer needs to take responsibility. That leads into transactions, hierarchical organizations, tenant-level deployments, foreign keys, and designing an eventual administrative UI that makes destructive operations explicit rather than magical.
We also clean up several CodeRabbit review comments around dynamic registration messages and JSON handling, add tests based directly on examples from the LTI Dynamic Registration specification, and discuss why malformed examples in a specification are worth preserving and documenting in test fixtures.
Toward the end, we add MySQL 8 testing alongside MariaDB and get the branch ready for another full CodeRabbit review.
This is one of those episodes where a seemingly small data-model decision turns into a long discussion—but getting the model right now is far easier than fixing it after years of production data have accumulated.
Topics include:
- Tsugi organization hierarchy
- LTI tool registration and deployment
- Tenant, organization, and course-level deployment
- Foreign keys and ON DELETE behavior
- Transactions and safe hierarchy changes
- Database constraints versus application logic
- CodeRabbit AI code review
- LTI Dynamic Registration
- JSON columns and parsing
- Unit tests using specification fixtures
- MySQL 8 and MariaDB testing
- Designing data models before production migration
AI Coding with Dr. Chuck is an ongoing series where I build real software with AI tools, think through architecture out loud, make mistakes, change my mind, and try to understand why the code works—not merely get an AI to generate it.
In this episode, I keep working on the new organization and LTI tool registration data model in Tsugi—and CodeRabbit finds a few issues that send us deeper into the rabbit hole than expected.
We work through what should happen when an organization is deleted, how courses and tool deployments should behave, where database constraints help, and where the application service layer needs to take responsibility. That leads into transactions, hierarchical organizations, tenant-level deployments, foreign keys, and designing an eventual administrative UI that makes destructive operations explicit rather than magical.
We also clean up several CodeRabbit review comments around dynamic registration messages and JSON handling, add tests based directly on examples from the LTI Dynamic Registration specification, and discuss why malformed examples in a specification are worth preserving and documenting in test fixtures.
Toward the end, we add MySQL 8 testing alongside MariaDB and get the branch ready for another full CodeRabbit review.
This is one of those episodes where a seemingly small data-model decision turns into a long discussion—but getting the model right now is far easier than fixing it after years of production data have accumulated.
Topics include:
- Tsugi organization hierarchy
- LTI tool registration and deployment
- Tenant, organization, and course-level deployment
- Foreign keys and ON DELETE behavior
- Transactions and safe hierarchy changes
- Database constraints versus application logic
- CodeRabbit AI code review
- LTI Dynamic Registration
- JSON columns and parsing
- Unit tests using specification fixtures
- MySQL 8 and MariaDB testing
- Designing data models before production migration
AI Coding with Dr. Chuck is an ongoing series where I build real software with AI tools, think through architecture out loud, make mistakes, change my mind, and try to understand why the code works—not merely get an AI to generate it.










