Multi-tenant Database Demo for Ninja Web Framework
I have just written a short demo on how to support multi-tenant database for Ninja Web Framework.
The full source code can be downloaded from github.
Features of this demo
- Support multi-tenant databases using Ninja web framework. Majority of the existing Ninja web framework documentation for database access is still applicable; only small amount of changes is required to provide tenant database information, and to bind the EntityManager provider to each tenant at runtime.
- Existing database migration scripts can be used to migrate database changes to all tenant databases.
- Use HikariCP connection pool in Ninja web framework.