Skip to content

[stable-25.0.x] Bugfix/6710/fix multiple websockets - #6748

Merged
AndyScherzinger merged 1 commit into
stable-25.0.xfrom
backport/6737/stable-25.0.x
Sep 21, 2026
Merged

AndyScherzinger merged 1 commit into
stable-25.0.xfrom
backport/6737/stable-25.0.x

Conversation

@backportbot

@backportbot backportbot Bot commented Sep 21, 2026

Copy link
Copy Markdown

Backport of PR #6737

WebSocketConnectionHelper only reused the cached WebSocketInstance for a
user while it reported isConnected() == true. Since the ping interval
added in #6543 makes the connection cycle through a brief disconnected
state every 30-60s by design, any caller (ChatActivity, CallActivity,
WebsocketConnectionsWorker) asking for the instance during that window
got handed a brand new WebSocketInstance instead, orphaning the old one
which kept retrying unsupervised in the background.

Within a single instance, restartWebSocket() could also be triggered
concurrently (from sendMessage, processErrorMessage, closeWebSocket)
without cancelling any socket already in flight, and a stale/superseded
socket's failure would still force a reconnect of the current one. Both
issues together produced the "5-13 parallel sockets" / repeated
"Closing previous client ... for session X" churn from #6710.

Fixes #6710.

Assisted-by: Claude Code:claude-sonnet-5

Signed-off-by: Marcel Hibbe <dev@mhibbe.de>
@backportbot backportbot Bot added 3. to review Waiting for reviews AI assisted labels Sep 21, 2026
@backportbot backportbot Bot added this to the 25.0.1 milestone Sep 21, 2026
@github-actions

Copy link
Copy Markdown
Contributor

APK file: https://github.com/nextcloud/talk-android/actions/runs/35648215030/artifacts/10661332902
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

@AndyScherzinger
AndyScherzinger merged commit 5d331af into stable-25.0.x Sep 21, 2026
12 of 15 checks passed
@AndyScherzinger
AndyScherzinger deleted the backport/6737/stable-25.0.x branch September 21, 2026 21:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review Waiting for reviews AI assisted

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants