DefaultHttp2HeadersEncoder.encodeHeaders are slow
- 主要言語
- Java
- スター
- 12.1k
- フォーク
- 4k
- 平均マージ
- 2日 17時間
- マージ済み PR(30日)
- 37
説明
After GC and syscalls, `io.netty.handler.codec.http2.DefaultHttp2HeadersEncoder.encodeHeaders` takes the most CPU on a simple ping pong stress test. It accounts for about 3.3% of total program time. The offending line is:
https://github.com/netty/netty/blob/83c349ffa94d3992c4ee511d3625afc0c97c12bb/codec-http2/src/main/java/io/netty/handler/codec/http2/DefaultHttp2HeadersEncoder.java#L68
I am not sure why this is so slow, but we should probably investigate it. My test does nothing special with headers.
コントリビューションガイド
調査の方向性
Start at io.netty.handler.codec.http2.DefaultHttp2HeadersEncoder.encodeHeaders in codec-http2/src/main/java/io/netty/handler/codec/http2/DefaultHttp2HeadersEncoder.java, around line 68, and reproduce the simple ping-pong stress test described in the issue. Profile the method to investigate the reported 3.3% CPU share. Done means the cause is identified and a validated performance improvement or clear conclusion is recorded.
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- java
- 領域
- backend-api-design, performance
- issue の種類
- バグ
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 35/100