wangyusheng1985 commented on code in PR #4061:
URL: https://github.com/apache/iggy/pull/4061#discussion_r3974997931
##########
foreign/node/src/client/client.socket.ts:
##########
@@ -211,8 +211,16 @@ export class CommandResponseStream extends EventEmitter {
*/
_init() {
this.heartbeat(this.options.heartbeatInterval);
+ this.connection.on('connecting', () => {
+ this.emit('connecting');
+ });
+ this.connection.on('connect', () => {
+ this.emit('connected');
+ });
this.connection.on('error', (error: Error) => {
this._failQueue(error);
+ if (this.listenerCount('error') > 0)
Review Comment:
<!--
repo-agent-review-reply:85f0b177-e874-449c-9bea-f0cb9f0e94a8:thread:3955043410:target:3955043410
-->
Could you point to the specific listener-presence check you mean? The patch
evidence describes typed on/once for connecting, connected, and error events
and forwarding of transport lifecycle events, but it does not describe a
listener check that applies only to the error event or the reasoning behind
such a check.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]