mirror of
https://github.com/pgsty/minio.git
synced 2026-08-02 16:45:57 +03:00
rpc: Avoid using Pool since it conflicts with http2 (#7467)
A race is detected between a bytes.Buffer generated with cmd/rpc.Pool and http2 module. An issue is raised in golang (https://github.com/golang/go/issues/31192). Meanwhile, this commit disables Pool in RPC code and it generates a new 1kb of bytes.Buffer for each RPC call.
This commit is contained in:
@@ -253,8 +253,7 @@ func TestServerCall(t *testing.T) {
|
||||
}
|
||||
|
||||
for i, testCase := range testCases {
|
||||
buf := bufPool.Get()
|
||||
defer bufPool.Put(buf)
|
||||
buf := bytes.NewBuffer([]byte{})
|
||||
|
||||
err := testCase.server.call(testCase.serviceMethod, testCase.argBytes, buf)
|
||||
expectErr := (err != nil)
|
||||
|
||||
Reference in New Issue
Block a user