Open shadowmas opened 2 months ago
After the WebSocket service stops, I want to stop reconnecting after a certain period of time.
I found connectionTimeout, but I noticed that connectionTimeout is not effective.
connectionTimeout
I found that at line 440 in client.ts, this.forceDisconnect() is called.
client.ts
this.forceDisconnect()
this.forceDisconnect();
However, in onWebSocketClose (line 486 in client.ts)
onWebSocketClose
this._stompHandler = undefined; // a new one will be created in case of a reconnect
This causes this.forceDisconnect() to not achieve the desired effect.
Version 7.0.0
You should try reconnectDelay: 5000,
reconnectDelay: 5000,
After the WebSocket service stops, I want to stop reconnecting after a certain period of time.
I found
connectionTimeout
, but I noticed thatconnectionTimeout
is not effective.I found that at line 440 in
client.ts
,this.forceDisconnect()
is called.However, in
onWebSocketClose
(line 486 inclient.ts
)This causes
this.forceDisconnect()
to not achieve the desired effect.Version 7.0.0