1
2 Comments

Which is the best design for multi-tenant app?

Which is the best design for multi-tenant app?

We are working on saas based attendance application with multi organization as the client, but we are not sure about how to achieve or the best way to achieve multi-tenancy. Our requirement

  1. Should introduce feature based pricing model ( less features less price and more feature more price)
  2. For each tenant there should be a subdomain to see their dashboard
  3. Our basic plan should be able to launch soon after the subscription automatically
  4. In auto launch it should have
    a. an subdomain
    b. an app in Apple Store and in Google Play with their logo
    c. the respective backend application in the cloud

How usually multi-tenance is achieved ?

  1. Multiple database ?
  2. Separate tables for each tenants?
  3. Separate backend applications ?

Kindly bear my request if is very basic. Looking for suggesstion's or to reach out some people they can really help us on this.

on February 26, 2019
  1. 1

    Looks like your backend stack is based on spring boot. Personally I’d use hibernate with postgres. Single db with per client schema deployed via RDS or azure. Stateless application tier. Don’t deploy separate apps unless you enjoy pain.

    Good overview:

    https://docs.microsoft.com/en-sg/azure/sql-database/saas-tenancy-app-design-patterns

    Googling “spring boot hibernate Saas design” will uncover several examples with code, depending on your implementation preferences.

    1. 1

      Thanks to your suggestion and the link is quite insightful