diff --git a/components-starter/camel-platform-http-starter/src/main/java/org/apache/camel/component/platform/http/springboot/customizer/UndertowAccessLogConfiguration.java b/components-starter/camel-platform-http-starter/src/main/java/org/apache/camel/component/platform/http/springboot/customizer/UndertowAccessLogConfiguration.java index 33f0bca01b9c..01070e8665a3 100644 --- a/components-starter/camel-platform-http-starter/src/main/java/org/apache/camel/component/platform/http/springboot/customizer/UndertowAccessLogConfiguration.java +++ b/components-starter/camel-platform-http-starter/src/main/java/org/apache/camel/component/platform/http/springboot/customizer/UndertowAccessLogConfiguration.java @@ -35,7 +35,11 @@ */ @Configuration(proxyBeanMethods = false) @EnableConfigurationProperties(UndertowAccessLogProperties.class) -@ConditionalOnClass(name = "io.undertow.Undertow") +@ConditionalOnClass(name = { + "io.undertow.Undertow", + "io.undertow.server.handlers.accesslog.AccessLogHandler", + "io.undertow.server.handlers.accesslog.JBossLoggingAccessLogReceiver" +}) @ConditionalOnProperties( { @ConditionalOnProperty(name = "server.undertow.accesslog.enabled", havingValue = "false"), @ConditionalOnProperty(name = "camel.component.platform-http.server.undertow.accesslog.use-camel-logging", havingValue = "true"), diff --git a/core/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/accesslog/ManagementAccessLogConfiguration.java b/core/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/accesslog/ManagementAccessLogConfiguration.java index dd3b9ee1702c..bca4ddeecb65 100644 --- a/core/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/accesslog/ManagementAccessLogConfiguration.java +++ b/core/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/accesslog/ManagementAccessLogConfiguration.java @@ -48,7 +48,11 @@ public class ManagementAccessLogConfiguration { * Undertow-specific configuration. */ @Configuration(proxyBeanMethods = false) - @ConditionalOnClass(name = "io.undertow.Undertow") + @ConditionalOnClass(name = { + "io.undertow.Undertow", + "io.undertow.server.handlers.accesslog.AccessLogHandler", + "io.undertow.server.handlers.accesslog.JBossLoggingAccessLogReceiver" + }) static class UndertowAccessLogCustomizerConfiguration { /** @@ -78,7 +82,10 @@ public WebServerFactoryCustomizer managementAcc * Tomcat-specific configuration to disable access logging in the management context. */ @Configuration(proxyBeanMethods = false) - @ConditionalOnClass(name = "org.apache.catalina.startup.Tomcat") + @ConditionalOnClass(name = { + "org.apache.catalina.startup.Tomcat", + "org.apache.catalina.valves.AccessLogValve" + }) @ConditionalOnProperty(name = "management.server.accesslog.enabled", havingValue = "false") static class TomcatAccessLogCustomizerConfiguration {