grpc / grpc/grpc-node

Question: node grpc versus grpc-js performance

Open
#1,797 25 comments 7 reactions 0 assignees View on GitHub
package: @grpc/grpc-js
Dominant language
TypeScript
Stars
4.8k
Forks
716
Avg merge
2d 3h
Merged PRs (30d)
10

Description

My team just updated our internal tools to use grpc-js in lieu of grpc. A primary motivation for this is that we want to be able to use later versions of node and no longer use a library that's deprecated.

After a couple weeks, we've identified that the `node 12 + grpc` to `node 14 + grpc-js` upgrade has resulted in significant performance degradation for one of our endpoints. This endpoint makes a protobuf network call for a `repeated` type that returns 100+ objects. Locally we're seeing a 3x latency increase between the two versions of the endpoint, but we haven't debugged the issue more than just swapping the libraries so far, so there is a chance that the issue could be specific to our app.

Is this a known tradeoff between the two libraries, potentially for example that serialization takes longer with the raw JS version? Are there recommended optimizations or configurations that I might not be following that would be contributing to our problem? I would really prefer to keep grpc-js and try to optimize code rather than doing a rollback if possible.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.