Bermuda’s National Park system manages and preserves the island’s natural resources. Recognizing the challenges involving internet and network connectivity on the island, such as unavailability, unreliability, or slowness, the department decided to temporarily adapt their editing workflows to a disconnected environment. This blog follows the national parks as they prepare for this transition by getting their data ready for offline use, testing the setup by making edits without being connected to the network, and synchronizing edits.
Prepare and publish a feature service
The first step in the workflow is for the department’s GIS specialist to prepare the enterprise geodatabase data for offline use. The data preparation process varies based on data type and the type of offline editing workflows that the department needs.
Because offline editing requires that you publish the data as a web feature layer (feature service), the GIS specialist must also take the department’s requirements into consideration when publishing the service, because these requirements also impact the settings used when publishing the feature service.
The following table provides an overview of the key requirements for different data types and offline editing workflows:
In this scenario, the Parks Department is using branch versioning as the multiuser environment of choice to maintain its assets, which include the following:
- The Railway Trail, the longest trail on the island
- The National Park boundaries
- The Marine areas, protected by the island
Data preparation
Following the table above to prepare the data for offline use, the GIS specialist registers the feature classes as branch versioned and enables replica tracking. The GIS specialist enables enable both functionalities with two clicks from the Manage tab of each feature class’s properties dialog.
Although not part of the data preparation, it is important for publishing and administration workflows to set the geodatabase connection Versioning type to Branch.
Publish a feature service
Once the data is prepared, the next step is to publish it as a feature service, which will be used for offline work. During the publishing process, it is important to configure the correct settings for to meet your offline workflow requirements. This ensures the layer will be correctly used for offline editing.
In the Share As Web Layer pane, the specialist fills in the appropriate item details and checks the Feature option to publish a feature service.
When sharing branch versioned data, to take full advantage of the management capabilities necessary to support versioned editing, you must enable the Version Management capability. This is set on the Configuration tab, as shown below.
On the Configure Web Layer Properties dialog box accessed from the Configuration tab of the Share As Web Layer pane, the following settings need to be checked:
- Enable editing and allow editors to—Allows editors to add, update, and delete features. This allows full editing of the data.
- Enable Sync—Allows the layer to be taken offline. Set the Sync option to Create a version for each downloaded map. A uniquely named replica version is created for the offline map when the mobile worker downloads the map. This replica version is then used when the worker synchronizes edits.
The GIS specialist publishes the Bermuda National Resources feature service that will be used for offline editing.
Now that the feature service is published, the next step is to test the offline editing workflow.
Download the map and review the feature service replica and the version replica
In this section, the GIS specialist tests the offline editing workflow in ArcGIS Pro by adding the Bermuda National Resources feature service (web feature layer) to a map, taking the map offline, performing edits, and synchronizing the edits.
Note: To use your data offline using another client, such as ArcGIS Field Maps, check out this technical paper.
Take the map offline
Taking a map offline allows editors to perform edits and complete their work without a network connection.
First, the published feature layer must be added to the active map in ArcGIS Pro. When you add the feature layer to the map, it accesses the data in the default version.
The Download Map button on the ribbon takes the web layer offline by downloading its content locally. This option is available only if the web layers have been configured to support downloading content and synchronization.
Once the map downloading process completes, it generates the following:
- A local mobile geodatabase containing a copy of the offline data, which is added to the project home folder.
Note: If the ArcGIS Pro project is started without a template, the mobile geodatabase is created in the temp folder of the project. It is important to save the project before closing the desktop application to avoid the mobile geodatabase being deleted when the temp folder is removed.
- A feature service replica that supports data synchronization back to the feature service.
- A replica version to synchronize the offline edits with.
Before we proceed with testing the offline workflow, let’s review the components created when you take data offline in ArcGIS Pro.
Mobile geodatabase
Let’s start reviewing the mobile geodatabase first.
The offline mobile geodatabase is a type of mobile geodatabase (.geodatabase) designed for offline workflows. It stores a copy of the feature layer data locally and makes it available for editing when an internet connection is not available.
Feature service replica
When a feature service is taken offline, a feature service replica is created. Feature service replicas allow the offline data to be synchronized with the source data.
The feature service replica receives edits made offline and sends them to the source feature layer. During synchronization, the feature service replica also receives the edits made in the source feature layer and makes them available to the feature layer that was taken offline.
Feature service replicas are managed on the Feature Service Replicas tab in the Manage Replicas pane of the database connection file used to access the source enterprise geodatabase.
Each feature service replica contains the following general properties:
- Name—The name of the feature service replica. This name is system generated.
- Owner—The replica owner, which is the portal member who caused the replica to be created.
- Created—The date and time that the replica was created.
- Last Sync Date—The date and time that the offline data was last synchronized with the source feature layer.
- Version—The replica version associated with this feature service replica. If the data in the feature service is not versioned or the feature service was published with the option to not create a version, no version is associated with the replica.
- Replica ID—A unique identifier of the feature service replica.
- Service URL—The URL of the feature service associated with the replica.
Replica version
A replica version is a geodatabase version that is automatically created each time a map is downloaded to be used offline from a feature service that is published with the Create a version for each downloaded map option. This replica version is associated with a feature service replica and contains the features within the feature service.
When the offline edits are synchronized with the feature service, they are applied to the replica version.
All replica versions are visible and can be managed in the Versions view, as shown below.
A replica version can be identified based on its name. The replica version name includes the following to ensure the version name is unique:
- The name of the portal user who downloads the map
- The name of the feature service
- A unique identifier (ID)
Note: It is important not to rename replica versions, as offline editors cannot synchronize if the replica version name is changed.
As with all geodatabase versions, edits from the replica version must reconciled and posted to the parent version. When working with branch versioned data, the parent version is always the default version.
See Work with offline maps and branch versioned data for more information about using these options in offline editing workflows.
Make edits offline
After reviewing all the components created when a map is downloaded for offline use, it is time to test the offline editing by making some edits to the local mobile geodatabase that stores the offline data.
Note: To work in a disconnected environment, you need to authorize ArcGIS Pro to work offline using the ArcGIS Pro Settings Licensing options.
The GIS specialist will edit the offline data, which is currently stored in the mobile geodatabase, to extend the Railway Trail H segment.
Using the Continue Feature tool, the GIS specialist extends the trail segment H to reach the next segment.
After the sketch is completed and edits are saved to the mobile geodatabase, the GIS specialist moves on to the sync operation.
Note: You can edit offline features with the same editing tools and workflows you use when you are connected to the data through the network. You can edit simple features and attributes and undo and redo editing operations. You can also edit feature relationships and file attachments.
Synchronize edits
Once the GIS specialist reconnects to the network, they synchronize the local changes to the feature service.
To synchronize changes in ArcGIS Pro, the GIS specialist uses the Sync button. The Synchronize Offline Map option is on the Map tab on the ribbon, in the Offline group. A progress bar appears while the edits to the offline data are shared with the replica version and the local copy receives updates from others if edits have been made to the replica version. When the process is completed, the map displays updates to show the current offline data.
Because the GIS specialist chose to enable Create a version for each downloaded map as the sync option, the edits made offline are applied to the replica version. The next step is to reconcile and post the replica version, to make the edits available in the default version.
Reconcile and post
The GIS specialist activates the map that is pointing to the Bermuda feature service.
Notice the default version doesn’t have the changes made offline, as there is still a gap between trail segments H and I. To make the changes available in the default version, the replica version must be reconciled and posted.
In the Contents pane, with the List by Data Source option active, the GIS specialist changes versions and connects to the replica version to confirm the edits synchronized.
From the Versioning contextual tab, the GIS specialist selects the Reconcile option, to reconcile the replica version.
Because no conflicts are detected between the replica version that the GIS specialist is currently connected to and the default version, the GIS specialist will post the changes.
The GIS specialist changes to the default version.
They confirm the changes are now available in the default version.
Note: For more instructions on how to manage branch versioned data, check out this help topic.
Remove the local copy and delete the replica version
With the testing phase completed, the GIS specialist will need to tidy up operations.
Remove the local copy of the data
To remove the local mobile geodatabase, there are two options:
- Click the Remove button on the ribbon.
This process performs one last synchronization of the offline edits if prompted by the editor. It then removes the local geodatabase containing the copy of the offline data from the project’s Catalog pane and unregisters the feature service replica from the enterprise geodatabase. Finally, the map layers are automatically updated to access the web feature layers again.
The operation does not delete the geodatabase file from the project home folder. This is done manually by the editor.
- Manually delete the mobile geodatabase from the Catalog pane.
This approach removes the mobile geodatabase from the ArcGIS Pro project and deletes the geodatabase file from project folder; however, it does not delete the feature service replica. In this scenario, the replica owner must unregister the feature service replica, using the Manage Replicas pane.
Delete the replica version
Regardless of the chosen option, deleting the offline data from the client application does not delete the replica version from the enterprise geodatabase. Because of this, the GIS specialist deletes the replica version manually using the Versions view.
Keep in mind the replica version cannot be deleted if it is still actively referencing an offline map. The feature service replica must be unregistered before deleting the replica version.
To identify whether the feature service replica is still registered with the version, search for the replica name on the Feature Service Replica tab of the Manage Replicas pane.
In this workflow, we followed the example of Bermuda’s National Park system that transitioned its editing workflows to offline use. We started with an overview of preparing branch versioned data for offline use and publishing the feature service with the sync capability enabled. Then we tested the editing workflow, by downloading the map in ArcGIS Pro and performing edits offline directly in the local mobile geodatabase. Finally, the edits became available to the replica version through the sync process.
Commenting is not enabled for this article.