Skip to content

[pull] master from mattermost:master#815

Merged
pull[bot] merged 1 commit into
code:masterfrom
mattermost:master
Jul 4, 2026
Merged

[pull] master from mattermost:master#815
pull[bot] merged 1 commit into
code:masterfrom
mattermost:master

Conversation

@pull

@pull pull Bot commented Jul 4, 2026

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

…te clusters (#37346)

* [MM-69689] Self-heal orphaned shared channel remotes for deleted remote clusters

When a SharedChannelRemote row is still live (DeleteAt = 0) but its
RemoteCluster has been soft-deleted, the sync loop repeatedly picks up the
orphaned row and logs a warning on every tick without ever cleaning it up.

Soft-delete the orphaned SharedChannelRemote when the remote cluster lookup
returns sql.ErrNoRows, so the row stops recurring in the sync loop. Logs a
Warn (not Error) and skips the task.

Co-authored-by: mattermost-code <matty-code@mattermost.com>

* [MM-69689] Expand self-heal test coverage for orphaned shared channel remotes

Add subtests covering the DeleteRemote failure branch and an end-to-end
doSync run proving a self-healed orphan is drained and not retried, and
assert DeleteRemote call counts.

Co-authored-by: mattermost-code <matty-code@mattermost.com>

* [MM-69689] Log already-deleted remote skip at debug instead of warn

A soft-deleted RemoteCluster no longer syncing is the expected steady
state, so skipping it does not warrant a warning. Downgrade the log for
the already-soft-deleted SCR case to debug to avoid noise.

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: mattermost-code <matty-code@mattermost.com>
@pull pull Bot locked and limited conversation to collaborators Jul 4, 2026
@pull pull Bot added the ⤵️ pull label Jul 4, 2026
@pull pull Bot merged commit 5433e6e into code:master Jul 4, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants