1

Does anyone have an idea if there is a way to speed up the upload (image) to a container in CloudKit? If I use Parse for the same function, it is 3 to 4 times faster than uploading to CloudKit.... Same applies for downloading. Any ideas?

Thanks Armin

Armin Scheithauer
  • 601
  • 1
  • 7
  • 17
  • Don't know of any way to speed up a single file upload, but I have found if you have many uploads to do, it is much faster to save them all to the cloud in one hit than one at a time (makes sense too). – Drew McCormack Jan 20 '15 at 08:24

1 Answers1

2

If you are using saveRecord, then it could be that the operation is being given lower priority. Per Apple's documentation:

This method saves the record with a low priority, which may cause the task to execute after higher-priority tasks. To save records more urgently, create a CKModifyRecordsOperation object with the desired priority. You can also use that operation object to save multiple records simultaneously.

So, if you are indeed using saveRecord, try using CKModifyRecordsOperation instead and see if that improves upload times.

That being said, also do try to optimize the image as much as possible before uploading. And, in the case of changed (updated) CKRecords, it is not necessary to save all fields of a record (thereby re-uploading existing images) - you can pick and choose the fields you would like to save.

Hope that helps!

Gene Loparco
  • 2,157
  • 23
  • 23