envoyproxy/envoy

Lazy evaluation of compression decision in compressor_filter for http response w/o content-length

開放

#21,807 建立於 2022年6月21日

 (4 則留言) (0 個反應) (0 位負責人)C++ (5,373 個分叉)batch import
area/compressionhelp wanted

倉庫指標

星標
 (27,997 顆星)
PR 合併指標
 (PR 指標待抓取)

描述

If you are reporting any crash or any potential security issue, do not open an issue in this repo. Please report the issue via emailing envoy-security@googlegroups.com where the issue will be triaged appropriately.

Title: One line description Buffer response header in compressor_filter and perform compression decision when receiving first data frame (encode_data)

Description:

Describe the issue.

Snap leverages on compressor_filter to perform response compression for gRPC responses. gRPC server doesnt add content-length to response header that the compressor filter will compress small response payload as well , which causes some overhead in egress bandwidth.

What Snap does(already running in prod env) is to perform a lazy evaluation when receiving first data frame instead of buffering all data frames.

Snap want to seek some feedback from envoy community that

  1. this operation is feasible (Snap can create a draft PR to review later)
  2. upstream the change to envoy

[optional Relevant Links:]

Any extra documentation required to understand the issue.

貢獻者指南