Skip to content

[stable27] Fix sync errors after network issues - #4486

Merged
mejo- merged 12 commits into
stable27from
backport/4474/stable27
Jul 11, 2023
Merged

[stable27] Fix sync errors after network issues#4486
mejo- merged 12 commits into
stable27from
backport/4474/stable27

Conversation

@mejo-

Copy link
Copy Markdown
Member

📝 Summary

Manual backport of #4474

max-nextcloudand others added 11 commits July 11, 2023 19:12
Signed-off-by: Max <max@nextcloud.com>
Signed-off-by: Max <max@nextcloud.com>
Also drop the `sending` logic from `WebsocketPolyfill`.
It prevented resending the queue after an error.
The queue was non empty then so `this.#initiateSending()` was not called.
`SyncService` is responsible for throttling the network requests if needed.
Signed-off-by: Max <max@nextcloud.com>
Signed-off-by: Jonas <jonas@freesources.org>
Signed-off-by: Max <max@nextcloud.com>
This way the calling function can catch all network errors
and make sure to preserve the unsent steps in the queue.
Signed-off-by: Max <max@nextcloud.com>
SyncService will resend failed steps after network has recovered.
Remove obsolete `data.retry` flag when emitting error of
`ERROR_TYPE.CONNECTION_FAILED`.
Fixes: #4340
Signed-off-by: Jonas <jonas@freesources.org>
Also only wait for `@alive` once in `syncs even when initial state was
present` to fix the test.
Signed-off-by: Jonas <jonas@freesources.org>
This is required for Cypress tests where we want the broadcast channel
synchronization to be disabled.
If not passed, default to `true` in debug mode and `false` otherwise.
Signed-off-by: Jonas <jonas@freesources.org>
Signed-off-by: Jonas <jonas@freesources.org>
@mejo-

Copy link
Copy Markdown
MemberAuthor

/compile

@cypress

cypressBot commented Jul 11, 2023

Copy link
Copy Markdown

1 failed and 1 flaky tests on run #10961 ↗︎

114320Flakiness1

Details:

[stable27] Fix sync errors after network issues
Project: TextCommit:fa7197a83a
Status: FailedDuration: 03:49 💡
Started: Jul 11, 2023 5:35 PMEnded: Jul 11, 2023 5:39 PM
Failed cypress/e2e/sync.spec.js • 1 failed test

ViewOutputVideo

Test Artifacts
Sync > recovers from a lost connection OutputScreenshots
Flakiness cypress/e2e/sync.spec.js • 1 flaky test

ViewOutputVideo

Test Artifacts
Sync > saves the actual file and document state OutputScreenshots

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings.

@mejo-mejo- mentioned this pull request Jul 11, 2023
7 tasks
Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
@mejo-
mejo- merged commit 0b20e0b into stable27Jul 11, 2023
@delete-merged-branch
delete-merged-branchBot deleted the backport/4474/stable27 branch July 11, 2023 20:17
@blizzzblizzz mentioned this pull request Jul 11, 2023
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@mejo-@juliusknorr@max-nextcloud@nextcloud-command