About Sync Task Errors

In Mobile SDK 7.1 and later, sync task methods return error information consistently across platforms.

Sync tasks—sync down, sync up, resync, and clean resync ghosts—can fail for the following reasons:

  • Invalid ID or name
  • The requested sync operation is already running
  • Sync manager is stopped or stopping
To inform apps of the nature of failures, sync methods in Mobile SDK 7.1 and later return error information as follows.
  • On iOS:

    • Swift methods throw a SyncState object.
    • Objective-C methods include an NSError** parameter. Earlier versions of these methods are deprecated.
  • On Android, these methods throw MobileSyncException.


The following methods now support and NSError parameter.


The following methods now throw a SyncState object.


Existing sync methods that do not support an NSError output parameter are slated for removal in a future major release.

For changes to cleanResyncGhosts methods, see Handling “Ghost” Records After Sync Down Operations.