Does the multi-tenancy model support syncing schemas and aggregating across child databases?

I’ll try to answer to the best of my abilities and ask internally for a better response than mine :slight_smile:, there is also this topic with a few answers that might interest you: Best practice for SaaS multi-tenancy - #4 by Luigi_Servini

Yes. However, you won’t be able to perform a query in one transaction over multiple child database which is probably a limitation you want to keep in mind if you set it up like that since it might not be convenient when you need to join customers with customer data. It’s feasible technically to implement transactions over child databases but at this point we don’t have that yet. I don’t think we have a feature request open for that yet, feel free to add one on the forum for people to vote on.

The amount of databases you can make is as good as unlimited to my knowledge.

I don’t think that’s possible, if that’s a requirement I would opt to use a collection with documents that have a User ID and filter on that.

No, this would also not be feasible since you can’t run a query over multiple databases.

I’ll try to get some guidance on the multi-tenant story and get back to you. We’ll add it to our list to write a comprehensive article about this.

1 Like