googleapis / googleapis/google-cloud-node

Streaming pull subscriber does not notify of loss of network

Open
#7,633 18 comments 5 reactions 1 assignee Claimed by @feywind View on GitHub
api: pubsub priority: p3 type: bug
Dominant language
TypeScript
Stars
3.2k
Forks
712
Avg merge
2d 3h
Merged PRs (30d)
99

Description

- OS: Ubuntu 22.04
- Node.js version: 18.16.0
- npm version: 9.5.1
- `@google-cloud/pubsub` version: 3.7.1

#### Steps to reproduce

1. Call PubSub.subscription(), and then setup on() handlers for 'message', 'debug', 'error', and 'close'
2. After initiating the initial subscription and receiving some streaming pull messages, disconnect the network on the machine
3. Notice that there are no error or debug events of any kind after several minutes. In other words, there is no notice of the fact that the network is gone and the subscription pull is therefore no longer operating. If the network is disconnected before the streaming pull begins, then there are debug messages and eventually there is an error after the default 5 minute timeout where the subscription is closed. But none of this happens if the network disconnects after the stream has been established.

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.