saas - How to implement customer subdomain in Spring framework -
in many of saas web applications (ex, atlassian jira), user can have dedicated subdomain. example, if user name helloworld, after log in web application, redirected helloworld.atlassian.net
how implement in spring framework?
do have have 1 application server instance running each customer? dosent seem cheapest solution. spring have such feature can create dynamic subdomain based on username, , in backend, 1 instance of application server running?
create custom filter parses whole url , extracts subdomain, check if user on proper domain proper rights. worth mentioning nginx should redirect "*.yourdomain.com" subdomains don't have exist in nginx, exist in database , each user has unique or can multiple sudomains attached, custom filter checking on each request.
Comments
Post a Comment