You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Observe the Used Heap Space Size (Old space) for a few hours (in my case it's leaking ~15M/day)
Environment
OS name, version and architecture: [docker container x86_64 GNU/Linux Ubuntu 20.04.3 LTS]
Node version [v16.12.0]
Package name and version: @grpc-js@1.4.1, consumed by @nestjs/microservice@8.0.11 (same case for 8.1.2)
Additional context
This is the screenshot of the snapshot diff with 15 hours gap in between.
As the object stack indicates, the timestamp pushed into events array each time addTrace is called, it keeps adding new trace but is never garbage collected somehow.
According to the grpc version diff, the problem might be introduced by this commit: grpc-js: Add channelz support, when introducing the new object ChannelzTrace in server.ts after release of 1.4.0.
Is it something now should be disabled explicitly if not needed?
The text was updated successfully, but these errors were encountered:
Thank you for the report. This was also reported in #1941, and as a result, I published grpc-js version 1.4.2 with hard limits on the number of retained channelz trace events per channel/subchannel/server, and support for the channel/server option grpc.enable_channelz, which can be set to 0 to disable channelz entirely. Please try it out to see if it solves your problem.
Problem description
Upgrading @grpc-js from 1.3.8 to 1.4.1 introduces memory leak.
The image shows the heap space size used (old space)
Reproduction steps
Environment
Additional context
This is the screenshot of the snapshot diff with 15 hours gap in between.
As the object stack indicates, the
timestamp
pushed intoevents
array each timeaddTrace
is called, it keeps adding new trace but is never garbage collected somehow.According to the grpc version diff, the problem might be introduced by this commit: grpc-js: Add channelz support, when introducing the new object
ChannelzTrace
in server.ts after release of 1.4.0.Is it something now should be disabled explicitly if not needed?
The text was updated successfully, but these errors were encountered: