Skip to content

Quiet ESI streaming gunzip zero-output logs#13171

Open
bneradt wants to merge 1 commit into
apache:masterfrom
bneradt:quiet-esi-stream-gunzip-log-apache
Open

Quiet ESI streaming gunzip zero-output logs#13171
bneradt wants to merge 1 commit into
apache:masterfrom
bneradt:quiet-esi-stream-gunzip-log-apache

Conversation

@bneradt
Copy link
Copy Markdown
Contributor

@bneradt bneradt commented May 18, 2026

ESI streaming gunzip can receive valid gzip chunks that consume input
without producing output, such as an initial header-only chunk. Those
chunks currently emit a buf below zero error even though the stream
continues successfully, which creates noisy Traffic Server logs.

This treats zero-output progress as normal streaming inflate behavior
and reserves error logging for actual zlib failures. It also extends the
ESI gzip unit test support to capture error logs and covers the
header-only chunk case.

ESI streaming gunzip can receive valid gzip chunks that consume input
without producing output, such as an initial header-only chunk. Those
chunks currently emit a `buf below zero` error even though the stream
continues successfully, which creates noisy Traffic Server logs.

This treats zero-output progress as normal streaming inflate behavior
and reserves error logging for actual zlib failures. It also extends the
ESI gzip unit test support to capture error logs and covers the
header-only chunk case.
@bneradt bneradt added this to the 11.0.0 milestone May 18, 2026
@bneradt bneradt self-assigned this May 18, 2026
Copy link
Copy Markdown
Contributor

@JosiahWI JosiahWI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks reasonable

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR reduces noisy ESI streaming gunzip error logging by treating zero-output inflate progress as normal streaming behavior, while preserving error logging for actual zlib failures. It also adds unit-test coverage for a header-only gzip chunk.

Changes:

  • Updates streaming inflate logic to avoid logging errors when input is consumed without producing output.
  • Adds fake error-log capture support for ESI unit tests.
  • Adds a gzip streaming test for the header-only chunk case.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
plugins/esi/lib/EsiGunzip.cc Adjusts streaming inflate handling and zlib error reporting.
plugins/esi/test/print_funcs.cc Adds fake error-log capture support for tests.
plugins/esi/test/gzip_test.cc Adds coverage for zero-output gzip streaming chunks.

@shukitchan
Copy link
Copy Markdown
Contributor

This looks fine. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants