1

I noticed that the docs mention that the newly introduced shared CloudKit databases do not support CKQuerySubscription (in earlier iOS versions these were called CKSubscription). So I guess that means that it is not possible to notify users when privately shared records have changed. Major disappointment. Has anyone run into this problem?

Zoef
  • 228
  • 2
  • 13

1 Answers1

3

According to the WWDC video about CloudKit this year:

So, new this year in iOS 10, there's an API called CKDatabaseSubscription.

This allows you to subscribe to any change across an entire database, and it works in a private database, in a shared database.

It shows you how starting on slide 51:

CloudKit Best Practices WWDC 2016 Presentation Slides

Community
  • 1
  • 1
Justin Stanley
  • 390
  • 3
  • 11
  • Thanks Justin. I'll have a try. It sounds like overkill when I only need to subscribe to changes in a single record, but maybe that can be solved with a recordZone – Zoef Aug 19 '16 at 10:12
  • Is it still the case (in 2018) that to get shared database changes, your only option is to subscribe to the entire shared database with `CKDatabaseSubscription`? – Clifton Labrum Jun 13 '18 at 05:43