Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf(client): use grpc.SharedBufferPool for grpc.DialOption
When a client library parses incoming gRPC messages, it allocates new buffers frequently. This can result in the creation of a large number of heap objects. However, gRPC offers an experimental feature called the shared buffer pool that can be used to address this issue. This pull request (PR) aims to optimize the gRPC receiving path using the shared buffer pool. Various experiments have shown that this optimization leads to a decrease in CPU time of runtime.gcBgMarkWorkers, depending on the workload. Refs: - https://pkg.go.dev/google.golang.org/[email protected]/experimental#WithRecvBufferPool - https://pkg.go.dev/google.golang.org/[email protected]#SharedBufferPool
- Loading branch information