-
Notifications
You must be signed in to change notification settings - Fork 739
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/bma/sdk sync service #6029
Conversation
4448255
to
6e86b02
Compare
override fun startSync(fromForeground: Boolean) { | ||
Timber.i("Starting sync thread") | ||
// TODO How to check that now? | ||
// assert(isOpen) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it OK to not do this check anymore? See the TODO.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For SyncService.doSync (SyncAndroidService now) this assert worked as exit condition. AssertionError was caught and handled and now it won't. Do we know how often it happens? And what will happen if we'll try to start sync without open session - will it fail before network request or will be executed? We shouldn't execute a request if there is no chance that it will result with success 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right. Improved in a33f7d0 which restores the previous checks.
|
||
override fun stopSync() { | ||
// TODO How to check that now? | ||
// assert(isOpen) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it OK to not do this check anymore? See the TODO.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the review. I will rebase to fix all the conflicts, and merge it. |
Merge SyncStatusService to SyncService, and rename some classes
a33f7d0
to
ac61aee
Compare
SonarCloud Quality Gate failed. |
Type of change
Content
First point of #5864
Motivation and context
Improve SDK API
Screenshots / GIFs
Tests
Tested devices
Checklist