3 ms·
One of the largest open-source Rails apps has all of those features: Canvas LMS[1]. It uses Switchman[2] for abstracting the multi-tenancy logic. Their approac
by guptaneil 6y ago
One of the largest open-source Rails apps has all of those features: Canvas LMS[1]. It uses Switchman[2] for abstracting the multi-tenancy logic.
Their approach has scaled to millions of concurrent users, but admittedly not helpful if you’re looking for a guide since the code is buried in a legacy monolith.
Part of the reason there isn’t a generic guide to this is that multi-tenancy is probably a premature optimization if a generic guide would be helpful. Just use nested user accounts to accomplish your business logic. By the time you really need true multi-tenancy, generic sample code won’t be much more helpful than the docs of the various plugins like Switchman.
1: https://github.com/instructure/canvas-lms https://github.com/instructure/canvas-lms
2: https://github.com/instructure/switchman https://github.com/instructure/switchman
- node-bayarea 6y agoNice. It's amazing so many Rails multi-tenant projects but almost nothing in the Node.js world
- yodon 6y agoThat said, Canvas is also AGPL 3 which might be a concern for some people looking for code to base their new SaaS startup on.