Synchronizing Attachments in the Server Workflow

Since the release of Trimble Positions, we have seen an increasing number of customers looking at the “server” workflow in ArcGIS for Windows Mobile.  In this workflow, the mobile device (running ArcGIS for Windows Mobile + Trimble Positions Mobile extension) synchronizes data changes directly to the enterprise geodatabase through a mobile service on ArcGIS for Server.  All feature and feature attachment data synchronizes through the service.  The mobile service will synchronize the feature (shape and attributes) and each attachment as separate transactions to minimize the packet size as much as possible.  As a reminder, the binary GNSS “session” data that gets recorded in the background during data collection, as required for post processing, is stored as an attachment to a feature in the TrimbleSessions layer.  This data accumulates at the rate of roughly 1MB per hour and so a typical data collection work session might yield an attachment of 2~3MB.  This is likely among the larger attachment sizes a customer may deal with in typical workflows.

Due mainly to the very restrictive application memory space for Windows Mobile applications (32MB; into which both Esri’s application and our extension have to fit), and the fact that Esri has to support different types of secured mobile services (token, web auth, Windows auth, etc.), synchronizing large attachments (say >= 4MB) may be problematic in certain scenarios.  Logic in the existing ArcGIS for Windows Mobile 10.1.1 application may not notify the user that one or more attachments has failed to synchronize and may also prevent any retries of failed attachment synchronizations.  It’s not until the Trimble Positions office user gets failure messages when trying to “check for new sessions” that there is any indication of a problem.  In such cases, a message about “no GNSS measurements” will be logged to the Trimble Positions Desktop add-in log file.  This indicates that a feature in the TrimbleSessions feature class is missing the binary attachment and thus it cannot be imported into the Trimble Positions office database.  In these scenarios, there is no data loss as the unsynchronized session attachments will continue to sit in the device’s mobile cache folder.

We are working closely with Esri on these limitations and Esri is improving both the underlying attachment synchronization logic and error notification within the 10.2 release to accommodate larger attachments.  For customers that may encounter problems now, there are several workarounds available:

  1. Copy the mobile project from the device onto a Windows computer that has the ArcGIS for Windows Mobile tablet application installed.  This application gets installed by default when you install Mobile Project Center.  Open the project in the tablet application and use the ‘Synchronize’ task to push data changes up to the mobile service.  This may require you to create a new session to make sure that TrimbleSessions is available in the list of layers to synchronize.  The initial warning message about a ‘Missing Extension PositionsProjectExtension.dll’ can be ignored as it just indicates that the project is referencing an extension that does not exist on the Windows machine.
  2. Utilize the stand-alone ‘SessionUploader’ synchronization application that Trimble has created and made available through the dealer support channel.  This allows the user to perform synchronization outside of the ArcGIS for Windows Mobile application and thus avoid most memory-related problems.  Provided as a simple zip file, it should be unzipped and copied to the \Program Files\ folder on the device.  From there it can be run manually.  The user simply selects the project from a list and clicks a button to perform a full, upload-only synchronization.  This will synchronize all new or changed features and attachments in all layers.  The desired project should be closed first in the ArcGIS for Windows Mobile application before selecting it for synchronization in this application.

Unfortunately, workarounds are never perfect and even the work that Esri is doing for 10.2 will have its limits.  It is always recommended that adequate testing be performed in an environment as close as possible to what is expected in production.  This would include network topology (DMZ, WiFi/cellular, LAN/WAN), software versions, mobile hardware, attachment workflows (number and size), synchronization workflows, etc.

For the Trimble Positions Mobile extension workflow, it is best to keep session attachments to a reasonable size (1~3MB) by closing the project (or application) in between work activities (e.g., when taking a break or meal).  This will close the session and store it as an attachment.  If the user simply hits the power button on the device (suspend), the session will be resumed upon start-up and will continue to grow in size.  Disconnecting from the GNSS receiver does not stop the session.  Advanced users can also use the ‘GNSS Sessions’ task to manually start and stop sessions.

This entry was posted in How To, Known Issues, Tips and Tricks. Bookmark the permalink.