From f9ea3563261d324a71a14885733a371a210b2aba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20Ko=CC=88ninger?= Date: Fri, 29 Nov 2024 09:02:53 +0100 Subject: [PATCH] fix(#3829): error 404 is shown when // is opened in browser --- .../admin/server/ui/config/AdminServerUiAutoConfiguration.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spring-boot-admin-server-ui/src/main/java/de/codecentric/boot/admin/server/ui/config/AdminServerUiAutoConfiguration.java b/spring-boot-admin-server-ui/src/main/java/de/codecentric/boot/admin/server/ui/config/AdminServerUiAutoConfiguration.java index 80f8ef5612d..2ed484ed775 100644 --- a/spring-boot-admin-server-ui/src/main/java/de/codecentric/boot/admin/server/ui/config/AdminServerUiAutoConfiguration.java +++ b/spring-boot-admin-server-ui/src/main/java/de/codecentric/boot/admin/server/ui/config/AdminServerUiAutoConfiguration.java @@ -258,9 +258,10 @@ public HomepageForwardingFilterConfig homepageForwardingFilterConfig() throws IO List extensionRoutes = new UiRoutesScanner(this.applicationContext) .scan(this.adminUi.getExtensionResourceLocations()); - List routesIncludes = Stream.concat(DEFAULT_UI_ROUTES.stream(), extensionRoutes.stream()) + List routesIncludes = Stream.concat(DEFAULT_UI_ROUTES.stream(), Stream.concat(extensionRoutes.stream(), Stream.of("/"))) .map(this.adminServer::path) .collect(Collectors.toList()); + List routesExcludes = Stream .concat(DEFAULT_UI_ROUTE_EXCLUDES.stream(), this.adminUi.getAdditionalRouteExcludes().stream()) .map(this.adminServer::path)