Skip to content

[confighttp] Reuse zstd reader objects #13396

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

ethercrow
Copy link

Description

Allocating zstd reader objects on every incoming requests leads to a lot of byte buffers being allocated and collected. The compression library recommends reusing readers to avoid these allocations.

Link to tracking issue

Fixes #11824

Copy link

linux-foundation-easycla bot commented Jul 15, 2025

CLA Signed

The committers listed above are authorized under a signed CLA.

@ethercrow ethercrow force-pushed the zstd-reader-pool branch 3 times, most recently from 49a3fbd to 9fb5b2f Compare July 17, 2025 18:52
@ethercrow ethercrow marked this pull request as ready for review July 17, 2025 18:53
@ethercrow ethercrow requested a review from a team as a code owner July 17, 2025 18:53
@ethercrow ethercrow requested a review from codeboten July 17, 2025 18:53
Copy link

codecov bot commented Jul 18, 2025

Codecov Report

Attention: Patch coverage is 85.00000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 91.44%. Comparing base (be09659) to head (0419397).
Report is 17 commits behind head on main.

Files with missing lines Patch % Lines
config/confighttp/compression.go 85.00% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #13396      +/-   ##
==========================================
- Coverage   91.48%   91.44%   -0.05%     
==========================================
  Files         529      529              
  Lines       29508    29523      +15     
==========================================
  Hits        26996    26996              
- Misses       1985     1996      +11     
- Partials      527      531       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

Excessive memory consumption when using ZSTD to receive compressed data
4 participants