Page MenuHomePhorge

Extract sync preparation and single sync cycle into own functions
Needs ReviewPublic

Authored by tusooa on Wed, Apr 15, 6:58 PM.

Details

Reviewers
None
Group Reviewers
O1: the Kazv Project
Summary

Allow the application to call ensureReadyForSyncing() and doOneSyncCycle() to gain finer control to the sync process. For example, they can decide when to retry if there is a failure, instead of relying on the fixed logic in syncForever(). There is no behaviour change for applications.

Currently, these functions offer no particular interest to applications because the login functions will still call startSyncing(). In the future, we will add other login functions that do not call startSyncing() to replace the current functions. However, this change is still useful for unit tests, because it allows us to assert model changes after "one sync cycle."

CCBUG: https://iron.lily-is.land/T110

Type: skip

Test Plan

Test kazv works the same way as before.

Diff Detail

Repository
rL libkazv
Branch
servant
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 602
Build 1186: Invoke BuildbotBuildbot build #1603
Build 1185: arc lint + arc unit

Event Timeline

src/client/client.hpp
518
Harbormaster returned this revision to the author for changes because remote builds failed.Sat, Apr 18, 9:43 AM
Harbormaster failed remote builds in B602: Diff 928!
Harbormaster failed remote builds in B603: Diff 929!