Skip to content
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

Sync config client reset handler #608

Merged
merged 124 commits into from
May 31, 2022
Merged

Conversation

desistefanova
Copy link
Contributor

@desistefanova desistefanova commented May 23, 2022

Support SyncClientResetHandler

Fixup SyncErrors support

fixes #628

nielsenko and others added 30 commits May 12, 2022 08:12
Only synchonous version for now, since async C-API doesn't allow userdata
This requires support for out-of-isolate callbacks. To do this a dart
specific EventLoopDispatcher and DispatchFreeUserdata is introduced.
Also, SubscriptionSet.remove* are now void methods, and corresponding
_RealmCore functions uses invokeGetBool.
When nothing is found we should return null on find. Hence we cannot use
invokeGetPointer, and also we need to pass null up the conversion stack.
* Add subscription tests to test_driver/realm_test.dart
* Allow network use from test_driver app on macos
The add method takes an optional update parameter, that default to
false. If true, the add will update the existing subscription if any.
Otherwise, it will fail if the subscription exists.
* remove is now called removeByQuery
* remove instead takes a Subscription as an argument
* removeAll is renamed to clear to match List.clear
* all remove* methods now returns a boolean indicating whether a
  subscription was removed
common/lib/src/realm_types.dart Show resolved Hide resolved
lib/src/configuration.dart Outdated Show resolved Hide resolved
lib/src/configuration.dart Outdated Show resolved Hide resolved
lib/src/configuration.dart Show resolved Hide resolved
lib/src/configuration.dart Outdated Show resolved Hide resolved
lib/src/configuration.dart Outdated Show resolved Hide resolved
lib/src/native/realm_core.dart Outdated Show resolved Hide resolved
move SyncErrorHandler to a callback
handle PR feedback
# Conflicts:
#	common/lib/src/realm_types.dart
#	lib/src/configuration.dart
Copy link
Member

@nirinchev nirinchev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some final suggestions for restructuring the type hierarchy, otherwise looks good.

lib/src/configuration.dart Outdated Show resolved Hide resolved
lib/src/configuration.dart Show resolved Hide resolved
lib/src/configuration.dart Outdated Show resolved Hide resolved
lib/src/configuration.dart Show resolved Hide resolved
lib/src/native/realm_core.dart Outdated Show resolved Hide resolved
@blagoev blagoev requested a review from nirinchev May 31, 2022 11:04
test/session_test.dart Outdated Show resolved Hide resolved
test/session_test.dart Outdated Show resolved Hide resolved
test/session_test.dart Outdated Show resolved Hide resolved
@blagoev blagoev merged commit ced7c42 into master May 31, 2022
@blagoev blagoev deleted the ds/sync_config_client_reset_handler branch May 31, 2022 14:49
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 15, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support SyncErrorHandler and SyncClientResetHandler
5 participants