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

   ## Summary
   
   _Claude Code on behalf of davsclaus_
   
   Backport of #24506 to `camel-4.18.x`.
   
   When `logHttpActivity` is enabled and the HTTP server returns a gzip-encoded 
response, the response body is not decompressed, causing downstream processing 
(e.g., Jackson JSON parsing) to fail with `JsonParseException: Illegal 
character (CTRL-CHAR, code 31)`.
   
   **Fix:** Pass the original content encoding to the `ByteArrayEntity` 
constructor when replacing the consumed response entity in 
`LoggingHttpActivityListener`.
   
   Note: On 4.18.x the `ce` variable is a `Header` (not `String` as on `main`), 
so the fix extracts `ce.getValue()`.
   
   ## Test plan
   
   - [x] New `HttpLoggingActivityGzipTest` — verifies gzip-encoded responses 
are correctly decompressed when `logHttpActivity` is enabled
   - [x] All existing `camel-http` tests pass
   
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   
   Co-Authored-By: Claude Opus 4.6 <[email protected]>


-- 
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