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
|`connect`| The client is initiating a connection to the server. |_No argument_|
369
-
|`ready`| The client successfully initiated the connection to the server. |_No argument_|
370
-
|`end`| The client disconnected the connection to the server via `.quit()` or `.disconnect()`. |_No argument_|
371
-
|`error`| When a network error has occurred, such as unable to connect to the server or the connection closed unexpectedly. | 1 argument: The error object, such as `SocketClosedUnexpectedlyError: Socket closed unexpectedly` or `Error: connect ECONNREFUSED [IP]:[PORT]`|
372
-
|`reconnecting`| The client is trying to reconnect to the server. |_No argument_|
373
-
374
-
The client will not emit [any other events](./docs/v3-to-v4.md#all-the-removed-events) beyond those listed above.
|`connect`| Initiating a connection to the server |*No arguments*|
369
+
|`ready`| Client is ready to use |*No arguments*|
370
+
|`end`| Connection has been closed (via `.quit()` or `.disconnect()`) |*No arguments*|
371
+
|`error`| An error has occurred—usually a network issue such as "Socket closed unexpectedly" |`(error: Error)`|
372
+
|`reconnecting`| Client is trying to reconnect to the server |*No arguments*|
373
+
|`sharded-channel-moved`| The ["cluster slot"](https://redis.io/docs/reference/cluster-spec/#key-distribution-model) of a subscribed [sharded PubSub](https://redis.io/docs/manual/pubsub/#sharded-pubsub) channel has been moved |`(channel: string, listeners: { buffers: Set<Listener<Buffer>>, strings: Set<Listener<string>> })`|
374
+
375
+
> :warning: You **MUST** listen to `error` events. If a client doesn't have at least one `error` listener registered and an `error` occurs, that error will be thrown and the Node.js process will exit. See the [`EventEmitter` docs](https://nodejs.org/api/events.html#events_error_events) for more details.
376
+
377
+
> The client will not emit [any other events](./docs/v3-to-v4.md#all-the-removed-events) beyond those listed above.
0 commit comments