Skip to content

CAMEL-24057: check actually-used classes in @ConditionalOnClass for access log configurations#1850

Merged
Croway merged 1 commit into
apache:mainfrom
Croway:fix/CAMEL-24057
Jul 15, 2026
Merged

CAMEL-24057: check actually-used classes in @ConditionalOnClass for access log configurations#1850
Croway merged 1 commit into
apache:mainfrom
Croway:fix/CAMEL-24057

Conversation

@Croway

@Croway Croway commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

Summary

Claude Code on behalf of Federico Mariani

@ConditionalOnClass(name = "io.undertow.Undertow") only checks for the top-level Undertow class, but the access log configurations use internal classes from io.undertow.server.handlers.accesslog.*. On JBoss EAP, the top-level class is visible (JBoss is built on Undertow) but the modular classloader doesn't export all internal packages, causing ClassNotFoundException.

  • Updated ManagementAccessLogConfiguration.UndertowAccessLogCustomizerConfiguration to also check for AccessLogHandler and JBossLoggingAccessLogReceiver
  • Updated ManagementAccessLogConfiguration.TomcatAccessLogCustomizerConfiguration to also check for AccessLogValve (defensive consistency)
  • Updated UndertowAccessLogConfiguration to also check for AccessLogHandler and JBossLoggingAccessLogReceiver

On main, the Undertow code is commented out pending Spring Boot 4.0 spring-boot-starter-undertow, but the annotations are fixed now so the bug won't return when the code is uncommented.

Test plan

  • core/camel-spring-boot builds successfully
  • camel-platform-http-starter builds successfully
  • CI passes

@Croway Croway merged commit d244c4d into apache:main Jul 15, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants