How to Implement MultiTenancy with Spring Boot and Keycloak
Secure your web application using different Keycloak realms in a single Keycloak instance.
In some cases, we need to secure a single web application with different realms. This concept is called multi-tenancy. The realms can be located on a single or different Keycloak instance. While it's easier to have a single realm per app, it could be costly as you have to host them on different servers.
Keycloak makes it possible by offering a config resolver that can be customized and where the Keycloak adapter config can be loaded and initialized. The configuration file from different realms will be saved in the project and loaded depending on a parameter. The realm name can be defined in the query parameter, header, or for this blog in the path parameter.
Github Repository: https://github.com/czetsuya/spring-keycloak-multi-tenant
-- Paid Gig --
I'm currently offering paid consultation and development gigs to help with your application development. Follow this link for more details https://czetsuya-tech.blogspot.com/p/consultation-services.html.
-- Help Us Grow --
Help us build an online community where software engineering students and professionals can have discussions about the fundamentals and advanced concepts of programming, current tech trends & job opportunities, and the struggles & life wins of programmers.
Discord: https://discord.gg/ByzExTg
FB Page: https://www.facebook.com/czetsuyatech
--- Channel Support ---
I hope I was able to impart some knowledge that could be of help to your personal life or professional career. SUBSCRIBE to my channel and hit the bell icon to get updated when new videos are uploaded.
Want to help SUPPORT my channel? Thank you in advance!
- PayPal: https://www.paypal.me/czetsuya
- Patreon: https://www.patreon.com/czetsuya
----- About this Channel -----
I am Edward Legaspi, the content creator of Czetsuya Tech.
And I create Youtube Tutorials and Write Blog Articles that
- Teach beginner and advance concepts of programming and software engineering design and development.
- Share my life experiences as a remote programmer.
- Introduce remote-work as a source of income.
Topics included in my videos and blogs are:
- Software Engineering
- Databases
- DevOps
- Tips and Tricks on being a Programmer
- WordPress Website Development
- Remote Work Environment, Tools, & Stories
With your support, I'll be able to produce more, well-researched, and high-quality learning videos and blog posts. I would be most grateful for any support.
I believe that by sharing this knowledge we can empower a community of tech people who have the passion and vision to develop tech that will make this world a better place to live.
Thank you always for all your support!
- Website
https://czetsuya.github.io/
- Facebook:
https://www.facebook.com/czetsuya
- Linkedin:
https://www.linkedin.com/in/czetsuya/
- Twitter:
https://twitter.com/czetsuya
--- Disclaimer ---
Keep in mind that I may receive commissions when you click on the links and make purchases, they will help support this channel. However, this does not impact the content of the videos. I'm trying my best to keep things base on my experience, fair and balanced, in order to help you make the best choice.
#czetsuyatech
Видео How to Implement MultiTenancy with Spring Boot and Keycloak канала czetsuyatech
In some cases, we need to secure a single web application with different realms. This concept is called multi-tenancy. The realms can be located on a single or different Keycloak instance. While it's easier to have a single realm per app, it could be costly as you have to host them on different servers.
Keycloak makes it possible by offering a config resolver that can be customized and where the Keycloak adapter config can be loaded and initialized. The configuration file from different realms will be saved in the project and loaded depending on a parameter. The realm name can be defined in the query parameter, header, or for this blog in the path parameter.
Github Repository: https://github.com/czetsuya/spring-keycloak-multi-tenant
-- Paid Gig --
I'm currently offering paid consultation and development gigs to help with your application development. Follow this link for more details https://czetsuya-tech.blogspot.com/p/consultation-services.html.
-- Help Us Grow --
Help us build an online community where software engineering students and professionals can have discussions about the fundamentals and advanced concepts of programming, current tech trends & job opportunities, and the struggles & life wins of programmers.
Discord: https://discord.gg/ByzExTg
FB Page: https://www.facebook.com/czetsuyatech
--- Channel Support ---
I hope I was able to impart some knowledge that could be of help to your personal life or professional career. SUBSCRIBE to my channel and hit the bell icon to get updated when new videos are uploaded.
Want to help SUPPORT my channel? Thank you in advance!
- PayPal: https://www.paypal.me/czetsuya
- Patreon: https://www.patreon.com/czetsuya
----- About this Channel -----
I am Edward Legaspi, the content creator of Czetsuya Tech.
And I create Youtube Tutorials and Write Blog Articles that
- Teach beginner and advance concepts of programming and software engineering design and development.
- Share my life experiences as a remote programmer.
- Introduce remote-work as a source of income.
Topics included in my videos and blogs are:
- Software Engineering
- Databases
- DevOps
- Tips and Tricks on being a Programmer
- WordPress Website Development
- Remote Work Environment, Tools, & Stories
With your support, I'll be able to produce more, well-researched, and high-quality learning videos and blog posts. I would be most grateful for any support.
I believe that by sharing this knowledge we can empower a community of tech people who have the passion and vision to develop tech that will make this world a better place to live.
Thank you always for all your support!
- Website
https://czetsuya.github.io/
- Facebook:
https://www.facebook.com/czetsuya
- Linkedin:
https://www.linkedin.com/in/czetsuya/
- Twitter:
https://twitter.com/czetsuya
--- Disclaimer ---
Keep in mind that I may receive commissions when you click on the links and make purchases, they will help support this channel. However, this does not impact the content of the videos. I'm trying my best to keep things base on my experience, fair and balanced, in order to help you make the best choice.
#czetsuyatech
Видео How to Implement MultiTenancy with Spring Boot and Keycloak канала czetsuyatech
Показать
Комментарии отсутствуют
Информация о видео
Другие видео канала
Securing Spring Boot Microservices with Keycloak using OpenID | OAuth2.0 | JavaTechieMulti-tenancy OAuth with Spring Security 5.2Multi-tenant architecture in 20 minutesMultitenancy ExplainedBilding an effective identity and access management architecture with KeycloakSpring Tips: Multitenant JDBCFine - Grained Authorization with Keycloak SSOCreate multi tenant microservice using Springboot, Hibernate and PostgresSpring security using OAuth2 with Microsoft AzureADAuthentication and Authorization for Java Microservices with Keycloak, Quarkus and MicroprofileSpring Boot and Spring Security with JWT including Access and Refresh Tokens 🔑What is OAuth really all about - OAuth tutorial - Java BrainsKeycloak: Customizing Multi-tenant Login Pages06 - Keycloak com Spring bootHow to Configure Keycloak as a Wildfly ModuleHow To Integrate Keycloak With Spring Cloud Gateway - Part 1Angular + Spring Boot REST API Example Tutorial | Java GuidesSecure Spring Boot Microservices with Keycloak Part 1 | DevNation Tech Talkkeycloak #7 - Integrando um cliente REACT com Keycloaksetup java com Spring security e Multitenancy