-
Notifications
You must be signed in to change notification settings - Fork 86
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
SubscriptionSet: find subscription by name #328
Comments
nielsenko
added a commit
that referenced
this issue
May 17, 2022
* Introduce hierarchy on Configurations * Deprecate the inMemory field. Replaced with InMemoryConfiguration * Support for flexible sync configuration * Add SubscriptionSet (and MutableSubscriptionSet) * Align with kotlin naming * Support session stop policy * Support async SubscriptionSet.waitForStateChange This requires support for out-of-isolate callbacks. To do this a dart specific EventLoopDispatcher is introduced. * Make subscription non-nullable. Throw, if configuration not a FlexibleSyncConfiguration * Add version & state properties to SubscriptionSet Also, SubscriptionSet.remove* are now void methods, and corresponding _RealmCore functions uses invokeGetBool. * Annoying hack * Fix SubscriptionSet.find* when nothing found 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. * More tests * Add elementAt test * Fix windows build * Add subscription tests to flutter tests * Add subscription tests to test_driver/realm_test.dart * Allow network use from test_driver app on macos * Update core to c9c9f5e62 (v11.15.0-8-gc9c9f5e62) * Use C-API in realm_dart_sync_on_subscription_set_state_change_async * Prevent downcast of Realm.subscriptions to MutableSubscriptionSet * Remove lifetime hack * Fix PR feedback * Rename addOrUpdate to add and return subscription 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. * Reorder and enhance doc comments * Rework SubscriptionSet.remove* * 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 * More PR feedback * Update core to dc15bdc (v11.15.0-16-gdc15bdc36) * Wire up properties on Subscription * Add Subscription properties test * Fix PR feedback * Update core to 8c2ad6f (v11.15.0-24-g8c2ad6fc8) * Avoid storing _queryHandle on RealmResult This is possible given recent changes to the C-API. * Added sync roundtrip test Using delay instead of awaiting sync session upload/download, since SyncSession is not yet implemented. * Hide SubscriptionSetState uncommitted and bootstrapping from users * Tweak Subscription.operator== to use .id (workaround for capi issue) * Test subscriptions with same name, but different classes throws * Test adding subscriptions with same name, different classes, with update flag * Test adding subscriptions with same query, different classes * Test SubscriptionSet.find return match, even if named * Test MutableSubscriptionSet.remove same query, different classes * Augment elementAt tests, and throw proper RangeError on out-of-bounds * Test MutableSubscriptionSet.add illegal query * Add some missing docs * A different way.. * Simplify some allocation calls: `arena.allocate<Uint8>(1)` become `arena<Uint8>()` * Don't deprecate Configuration ctor, remove immediately Use Configuration.local factory instead. * Outcome of PR review * Change factories on Configuration to static methods * Update realm-core to v11.16.0 (#572) * Fix a doc comment Co-authored-by: Yavor Georgiev <fealebenpae@gmail.com> Fixes: #318, #319, #329, #321, #322 , #323, #324, #325, #326, #327, #328, #329, #330, #331, #333, #334, #336, #337, #349, #351, #362, #436, #437
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
No description provided.
The text was updated successfully, but these errors were encountered: