oscerd opened a new pull request, #23998:
URL: https://github.com/apache/camel/pull/23998

   ## Problem
   
   On `camel-4.14.x`, `LogCaptureTest.testCapture` fails **deterministically** 
in both `camel-netty` and `camel-netty-http`:
   
   ```
   LogCaptureTest.testCapture:32 expected: <false> but was: <true>
   ```
   
   i.e. `LogCaptureAppender.getEvents()` is empty — the appender captures 
nothing. The test relies on a properties-based log4j2 setup 
(`configuration.packages` + a custom `LogCaptureAppender` wired to the 
`io.netty.util.ResourceLeakDetector` logger) that no longer works on this 
branch. It is **pre-existing** and unrelated to any functional change; it 
surfaces on any PR that triggers the netty/netty-http test suites (e.g. the 
CAMEL-23651 backport #23990).
   
   ## Fix
   
   `main` already fixed this by registering the appender **programmatically** 
in the test (`@BeforeEach` adds a `LogCaptureAppender` to the 
`ResourceLeakDetector` logger, `@AfterEach` removes it, the test is 
`@Isolated`) and removing the brittle properties config. This backports that 
fix to `camel-4.14.x` for both modules.
   
   Test-only change (2 test classes + 2 `log4j2.properties`). Verified locally: 
`LogCaptureTest` passes in `camel-netty` and `camel-netty-http` after the 
change.
   
   ## Why this matters
   
   This unblocks docs/test regeneration and the netty test suites for all 
`camel-4.14.x` PRs — in particular the CAMEL-23651 backport #23990, which is 
currently red on this pre-existing failure.
   
   ---
   _Claude Code on behalf of Andrea Cosentino_
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to