简体   繁体   中英

HTTP/2 flow control in Node.js (grpc-js)

How is HTTP/2 flow control implemented in the Node.js version of gRPC (grpc-js)?

For the Go implementation (grpc-go), the logic is mainly inhttps://github.com/grpc/grpc-go/blob/master/internal/transport/ (flowcontrol.go, bdp_estimator.go); also, it's described here . However, I couldn't find anything for grpc-js.

I am mainly interested in when does a Node.js receiver send WINDOW_UPDATE frames.

The grpc-js library is implemented using Node's http2 module, which handles the details of the HTTP/2 protocol, including flow control. So, there is no code in grpc-js that explicitly performs flow control operations. The http2 module, in turn, is implemeted using the nghttp2 library, so that code is where you will probably find the flow control logic.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM