Hacker News new | past | comments | ask | show | jobs | submit login

Core Data now provides NSIncremental store, which lets you use any web API as your persistent data store. It's possible to roll your own alternative to iCloud in this way, if you choose.



Core Data + NSIncremental store with a web api backend does not solve the problem of offline sync. It is possible to roll your own, its hard to get it right. It is complicated by iOS restriction of not able to run your own daemon. But then if I have the resource to roll my own then I would not complain about Apple.

Dropbox does not come close as alternative. Dropbox as of now is file-based sync. Core Data iCloud sync is trying to sync an always opened SQLite3 database file, they do it through database log files. Possible alternatives are TouchDB, Simperium, Firebase but then you have to change your app from not using Core Data. Or rewrite your app to use file based storage as what 1password did. The key is offline sync. File based cloud sync is solved problem. So maybe the way to go is persistent store of client app has to use files.


Very true. The pain point seems to be largely the database merges; it's possible to roll your own db while using iCloud mainly as a key/value store for synching user preferences and status between devices. This is particularly useful if you support more than just apple devices...

Edit: regarding offline sync (which I didn't address) something like AFIncremental store is a good example of how a local persistent store can be maintained in tandem with the online store.

(But, as you say, non- trivial and hard to get right.)


We've tried to use NSIncrementalStore and we found it quite tough. Documentation is sparse. You buy yourself into the SQL-ish interface of NSFetchRequest throughout the app. There are fun bugs to discover like this one:

https://github.com/stackmob/stackmob-ios-sdk/blob/master/Cor...

And once you discover that you can't fix all the problems that Apple is struggling with, you have dug yourself into a VERY deep hole :)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: