I was just watching the WWDC 2016 session Crafting Modern Cocoa Apps and they mentioned that with the new macOS Sierra version, local copies of documents could get moved out from underneath you up to the user's cloud storage.
They suggest a few things:
Register as a NSFilePresenter to ensure that the document isn't evicted out from under you.
Use NSFileCoordinator to coordinate reading and writing.
File coordination will make sure the file is downloaded and up to date.
I'm just wondering how Couchbase would handle this situation? If the underlying database file gets moved, that would be a bad thing.
Should the opening of the database file use an NSFilePresenter to prevent the file from being evicted while it's open?
Thanks,
Brendan