Remove concept of "stop" state from SharedPreferencesSyncManager

We have removed stop() api and removed callbacks for notification of
error. The idea is that SyncManager will deal with all errors internally
without putting any burden to the user.

There can be two kind of errors: sandbox is unavailable and everything
else.

If sandbox is unavailable, we should move to a waiting state and resume
syncing once it is available.

For all kinds of other errors, log the error and just keep on syncing.
Ideally, there should be no errors at all. If there are any, we have to
fix them to gurantee seamless syncing.

If user wants to stop syncing, they can just remove all the keys from
sync pool. API for removal of keys will be added soon.

So there is only two state for SyncManager now: running and waiting.
That can be figured by a single boolean, so refactored accordingly.

Bug: 239403323
Test: atest SdkSdkSandboxFrameworkUnitTests
Change-Id: Ibe0b75b95c38125711bc5726dee30b6693ad06c4
2 files changed
tree: c5b15387405450cb239353b3e90e41aeb5b05a06
  1. adservices/
  2. apex/
  3. sdksandbox/
  4. groups
  5. OWNERS
  6. PREUPLOAD.cfg
  7. project.config