diff --git a/src/gwc/autoconfigure/src/main/java/org/geoserver/cloud/autoconfigure/web/gwc/GeoWebCacheUIAutoConfiguration.java b/src/gwc/autoconfigure/src/main/java/org/geoserver/cloud/autoconfigure/web/gwc/GeoWebCacheUIAutoConfiguration.java
index 39f5aee81..7e1002e52 100644
--- a/src/gwc/autoconfigure/src/main/java/org/geoserver/cloud/autoconfigure/web/gwc/GeoWebCacheUIAutoConfiguration.java
+++ b/src/gwc/autoconfigure/src/main/java/org/geoserver/cloud/autoconfigure/web/gwc/GeoWebCacheUIAutoConfiguration.java
@@ -6,9 +6,10 @@
import lombok.extern.slf4j.Slf4j;
-import org.geoserver.cloud.autoconfigure.gwc.ConditionalOnGeoWebCacheRestConfigEnabled;
+import org.geoserver.catalog.Catalog;
import org.geoserver.cloud.autoconfigure.gwc.ConditionalOnWebUIEnabled;
import org.geoserver.cloud.gwc.config.core.GeoWebCacheConfigurationProperties;
+import org.geoserver.gwc.controller.GwcUrlHandlerMapping;
import org.geowebcache.GeoWebCacheDispatcher;
import org.geowebcache.rest.controller.ByteStreamController;
import org.gwc.web.rest.GeoWebCacheController;
@@ -32,13 +33,39 @@ GeoWebCacheController gwcController(GeoWebCacheDispatcher gwcDispatcher) {
return new GeoWebCacheController(gwcDispatcher);
}
- /**
- * Provide a handler for static web resources if missing, for example, because {@link
- * ConditionalOnGeoWebCacheRestConfigEnabled} is disabled
- */
+ /** ConditionalOnGeoWebCacheRestConfigEnabled} is disabled */
@Bean
@ConditionalOnMissingBean(ByteStreamController.class)
ByteStreamController byteStreamController() {
return new ByteStreamController();
}
+
+ /**
+ * GS's src/web/gwc/src/main/java/applicationContext.xml
+ *
+ *
Copied from {@link GeoServerGWCDispatcherController} */ @Controller -@RequestMapping("/gwc") +@RequestMapping(path = {"/gwc", "/{namespace}/gwc"}) @RequiredArgsConstructor public class GeoWebCacheController { private final @NonNull GeoWebCacheDispatcher gwcDispatcher; - @GetMapping( - path = { - "", - "/home", - "/demo/**", - "/proxy/**", - }) + @GetMapping(path = {"", "/home", "/demo/**", "/proxy/**"}) public void handleGet(HttpServletRequest request, HttpServletResponse response) throws Exception { gwcDispatcher.handleRequest(request, response);