I am a bit confused. I am using iCloud Drive to store backups from my internal data each time the user clicks 'backup'. This doesn't work as I would like to, because sometimes it just doesn't sync between the devices and users that click restore get's their old backup.
Now I've read about iCloud Documents and that you could trigger a sync manually from there. What's the difference between iCloud Drive and iCloud Documents for me as a developer? I just don't get it..
I am not sure whether it would be better to store backups with iCloud Documents...?
I think iCloud Drive provides the service that user can edit document through specified interface.
In contrast, iCloud Documents Storage provides a kind of service that stores some confidential or unchangeable data for application.
iCloud Drive - Apple's Cloud-Based Service for consumers. Typical known for their ability to sync between different devices through storage in the Cloud.
iCloud Document - A single file of UIDocument type.
iCloud document storage - Service that provides developer access to iCloud for their files which are usually UIDocument type or file packages which are of NSFileWrapper.
iCloud - Cumulative set of Apple's cloud services consisting of iCloud document storage, Key-value storage, CloudKit, Core Data.
So above question is not relevant as they are not comparable technology.
Related
I have an app that needs to work offline but sync across devices. The plan is to use Core Data and CloudKit to achieve this.
My question is how to store mp3 and image files (small file sizes). Is it ok to store it as Data and enable "Allows external storage" ? Will That works for CloudKit synchronisation
C.f. Apple website page on iCloud Drive:
http://www.apple.com/ios/ios8/icloud-drive/
I understand iCloud Drive makes easy for an individual user to save a file to the cloud and work on it from any of his or her own devices, i.e. a solo use case.
My question is: with the new iCloud Drive, can different users, with different Apple accounts (not necessarily in the same family), share and collaborate on files? E.g. Could an iOS 8 app help a bunch of users collaborate on, say, a video editing project where all the heavy raw footage video files are shared on iCloud Drive?
CloudKit is for backend app usage for developers. It has nothing to do with iCloud Drive user accounts. Time will tell how sharing works with iCloud Drive.
Answering my own question: yes, it is possible thanks to CloudKit, c.f.
https://developer.apple.com/icloud/documentation/cloudkit-storage/
Mine is a background application. There are thousands of data that are stored in local storage and till now i've been syncing the data to a remote server using http post. I want to know whether it is possible for me to use iCloud to sync my core data and then is it possible to sync from iClod to a remote server. I just want to use iCloud for storage purpose. I meant can it be operated like Parse and other third party cloud servers. I'm stuck with this. Any help would be greatly appreciated.
The only thing iCloud with Core Data does for you is sync data between multiple devices that use the same iCloud account.
I want to know whether it is possible for me to use iCloud to sync my core data...
Sync from one device to another, yes.
...and then is it possible to sync from iClod to a remote server.
If you're using Core Data with iCloud, you're still using Core Data, so any server sync you're doing now with Core Data will continue to work in the same way.
I just want to use iCloud for storage purpose.
It does store the user's data on the iCloud service, though it can only be accessed through your app.
I meant can it be operated like Parse and other third party cloud servers.
It depends on what Parse (or other third party) services you're interested in. Parse does more than iCloud, it's not really the same thing. If you would use Parse only to sync data between different devices, you could probably use iCloud. If you would use Parse in any other way at all, iCloud is not a replacement.
I have db which is kept in Core Data and I need to download full data from some storage. I don't want to write web server for this. Is there any way to store my full data for further downloading? Can I use iCloud for this? Or anything else? Thank you
iCloud is connected to you personal Apple ID, so it would not be possible (or at least not its intended use) to allow others to download data from your iCloud account.
Have a look at Parse or Azure. One of them might be the solution you are looking for.
I want to design an app which stores documents on iCloud. But there are some question which has answer before doing actual implementation.
The question are as follows,
What is maximum file size to upload on iCloud?
Can I programmatically calculate/know the available space on user's
iCloud account?
How can I get the event for uploading and Downloading files from
iCloud?
Can anyone please help me here ? I read the apple documentation but not understood all the things completely.
Thanks In Advance.
Although you mentioned you've read the apple icloud documentation, the designing for icloud documentation page from Apple is still a good starting point for this question.
File Size Limits
The documentation doesn't specify a Document file size limit, nor a Core Data storage limit, other than a user account icloud storage allowance. There is a limit for Key Value storage which is 1Mb for a value (in a value-key pair), which could be an issue for you, but otherwise it seems you can store large files as long as the user has enough space available.
Given the 5gb default amount and accounting for the default user storage needs (photos, contacts, calendars and the like), you may encounter limits for Document and Core Data storage, like any other app. The file management for icloud page mentions good app behaviour:
Apps that take advantage of iCloud storage features should act
responsibly when storing data in there. The space available in each
user’s account is limited and is shared by all apps. In addition,
users can see how much space is consumed by a given app and choose to
delete documents and data associated with your app. For these reasons,
it is in your app’s interest to be responsible about what files you
store.
Check Available Space Programmatically
No
Upload/Download Events
The file uploading and downloading is handled by the OS. All files are stored locally, it's from this local store that you request/modify/save documents. From the icloud fundamentals page:
When you adopt iCloud, the operating system initiates and manages
uploading and downloading of data for the devices attached to an
iCloud account. Your app does not directly communicate with iCloud
servers and, in most cases, does not invoke upload or download of
data.
See this app coda tutorial for an example of key-value store integration, this Tim Roadley tutorial for Core Data store integration or this Ray Wenderlich tutorial for Document store integration.
Edit: The Document-Based App Programming Guide for iOS provides code snippets for moving files to/from iCloud, uploading and downloading as well as monitoring file changes. See "Downloading Document Files from iCloud" and "Moving a Document to iCloud Storage".