0

I had implemented Multi-tenant Architecture in my one ERP Application. I am happy with that learning.

multi databases with own identity tables should connect with single web api and validate jwt token

Now I am planning to make system which should support multi-tenancy for multiple product with common user base.

Take a scenario, There is a company ABC which owns 2 Products P1 and P2. Now this company selling these products to several customers including (C1,C2,C3)

**Customer|Products**
C1|P1
C2|P1,P2
C3|P2  

*Each Customer has its employees obviously, Specially in C2 
Employee E1 has its emailId.
Now E1 must login on customer site www.ABC.C2.com which looks like google now (gmail is P1, translate is P2) on right menu when it clicks on any P1/P2 icon without login it should be redirected to a login page which is common as Authentication DB is common for all users all Customer's Products. if its authenticated it must move to the dashboard of that P1 products site.
In case not authenticated it should display an error message.*

P1 and P2 has separate APIs for each customer, sometimes common also, which has actions but those must be authorized as per user roles on customer and product basis 

Authentication DB and API is common for all.

I want your assistance and guidance over it.
Please try to guide me over it.
  • I think your question is not a real coding question. Why don't you start by creating two different API resources in IdentityServer4 and two different clients so you can link each client with a resource and clients with one product have access to one client/resource at a time? – mkanakis Mar 27 '19 at 13:34
  • Do you mean 1 API for authentication which is IS4 and another 1 api for product P1 and 3 rd API for product P2 now as my customer (Tenant) will increase I will be hosting separate Apis for each customer (tenant). – Bhanu Pratap singh Mar 28 '19 at 17:17

0 Answers0