Uploaded image for project: 'Realm Kotlin'
  1. Realm Kotlin
  2. RKOTLIN-421

Add support for keypath filtering

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None

      From Realm Java we had this issue: https://github.com/realm/realm-java/issues/4786

      Which is about object level notifications only triggering if top-level properties are modified, but not if nested objects are modified. For RealmResults this also works for nested objects.

      This is a highly surprising behavior and something we should fix: https://github.com/realm/realm-core/issues/5212

      One work-around is adding support for keypath filtering, which also has other use cases where you want to filter notifications.

      We should add support for this to our query API.

      A suggested API could be something like:

      RealmQuery.asFlow(keyPaths: Array<String>)
      RealmSingleQuery.asFlow(keyPaths: Array<String>)
      

      We need Core support before this can happen: https://github.com/realm/realm-core/issues/5216

      I don't believe Core currently has support for wildcards, e.g {} or myList., which would probably also be helpful, but we should push for that in Core instead.

            Assignee:
            Unassigned Unassigned
            Reporter:
            unitosyncbot Unito Sync Bot
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: