grpc-js: Restore socket disconnect handling

This commit is contained in:
Michael Lumish 2024-12-02 15:14:40 -05:00
parent f0c58f79c5
commit 848e00e54c
2 changed files with 6 additions and 1 deletions

View File

@ -1,6 +1,6 @@
{
"name": "@grpc/grpc-js",
"version": "1.12.2",
"version": "1.12.3",
"description": "gRPC Library for Node - pure JS implementation",
"homepage": "https://grpc.io/",
"repository": "https://github.com/grpc/grpc-node/tree/master/packages/grpc-js",

View File

@ -227,6 +227,11 @@ class Http2Transport implements Transport {
this.handleDisconnect();
});
session.socket.once('close', () => {
this.trace('connection closed');
this.handleDisconnect();
});
if (logging.isTracerEnabled(TRACER_NAME)) {
session.on('remoteSettings', (settings: http2.Settings) => {
this.trace(