Understanding and fixing sync log errors

Problem

One of my users has received the following error on his device, what does it mean and how do I fix it?

Cause

Depending on the device, all notifications will be displayed in a single list or there will be a drop down filter allowing you to select which records are displayed.  There are five groupings for filters:

  1. All: Displays all notifications
  2. Success:  This shows records successfully received from your data source such as new records, updates, deletions and loads
  3. Failed: This shows updates to records that were processed against your data source and failed (Usually in Delivery In as FAILED or RETRIED status)
  4. Queued Records: The record was received by the Swift MEAP™ Server, but there was another failure ahead of it in the queue that needs to be resolved before this record is sent to your data source (PENDING in Delivery In)
  5. Records Upsynced: The transaction was processed against your data source and a success message was returned

Some records are not immediately processed if there are other failures in the queue, these will be 'Queued' until failures ahead of it are resolved.  This needs to be done to preserve the submission of records to the data source in the same order as they were created, otherwise data errors can occur.

 

Administrators should be monitoring the Delivery In Queue failures to see if errors are temporary or reoccurring.  Some errors can be prevented by introducing increased validation in the client through JavaScript or ensuring that required data is submitted.  This can often be controlled by tweaking the configuration.

All errors are reported to users, it is important to stress the importance to users that errors are identified and fixed, if errors are left this can cause a build up of failures that prevents future submissions (which will be queued).  If there is a failure, it should be fixed by the user / administrator as soon as possible as it was rejected by the data source (and so the information in the data source could be out of sync with your user's device).

Users get immediate feedback of the number of records they have created that require fixing (either by them or by administrators), these are indicated by a red circle icon on the sync log icon which displays the number of failures.

Solution

Understanding the issue
For records that are queued for processing, you need to identify what is in the queue preventing submission:
  1. Locate the users details in the User screen, make a note of email and PIN
  2. Go to Queues->Delivery In
  3. Use the search facility to search for records either by PIN or by object type, you are trying to find the notification that the user is referring to
  4. When a record has been identified, click on the 'Edit Request' icon to view its details
  5. You should see a summary of the details, depending on your server version the actions you perform are as follows:
    1. On older servers, you will get a summary of the current record, check the 'Error' section which will detail whether there are parent or child dependencies.  If there is a child dependency, search delivery in for the records listed in Child Details section, for parent dependencies, check those listed in Parent Details section.  You will need to make a note of the related records and research delivery in from step 2 above.
    2. On newer servers, we display the current record, related records and their status in the same detailed information screen.  Scrolling down will show all related records and their current status (whether they are in failed / retried / pending status).  Look for related records in failed or retried status that have an error displayed.  Click on the view icon to navigate to the related record where you can correct any errors.

For records that show as Failed on a device, you need to identify and fix the failure:

  1. Locate the users details in the User screen, make a note of email and PIN
  2. Go to Queues->Delivery In
  3. Use the search facility to search for records either by PIN or by object type, you are trying to find the notification that the user is referring to
  4. When a record has been identified, click on the 'Edit Request' icon to view its details:
    1. On older servers you will get a single page detailing the request / response from your data source and a summary of the error (from your data source).  Records values can be fixed (if there is an error) by typing a new value in the fields and tapping Submit.
    2. On newer servers you will get a tabbed page.  The detailed information section shows a summary error, view "Error Details" to see the request / response / summary and history.  Select Edit Transaction to fix any incorrect values and Submit changes

Notes on error details

The errors displayed in FAILED or RETRIED records are from your data source, not from the Swift MEAP™ application.  To find out what information is incorrect and how to fix the error is beyond the scope of this document.  It will depend on the error returned, but you should be able to pass the error returned to a Data Source Administrator to identify why the record is failing and what needs to be done to ensure it passes.

If you see repeated failures with common reasons, you will need to look at the data structure / validation to ensure that errors are prevented / minimised.