With ArcGIS Pro, you can save service definitions for web layers to be shared to a portal at a later time. A service definition file (.sd) contains information about the web layer's type, properties, and capabilities. See Introduction to saving service definitions to learn more about how service definitions can be used in your organization's sharing workflows.
You can save a service definition for a web feature layer, web tile layer, or map image layer with a specific connection or without a connection when offline or disconnected from the server.
Service definitions cannot be created for vector tile layers, web scene layers, web imagery layers, or web elevation layers.
Save a connected service definition for a web layer
A connected service definition is configured for a specific server connection. The option to save a service definition is available in the Share As Web Layer pane when you are connected to ArcGIS Online or ArcGIS Enterprise.
Tip:
In the Share As Web Layer pane, click the Publish drop-down arrow and click Save As SD to save a service definition file.
Save an offline service definition for a web layer
An offline service definition is connection neutral; it is not configured for a specific server connection. You can save an offline service definition if you are offline or not connected to the server. This workflow explains how to save an offline service definition for a web layer with default settings to be later shared to a portal. To change the default configuration, see the following:
You can also use ArcPy to save an offline service definition. To learn more, see Introduction to arcpy.sharing.
To save a service definition for a web layer in a disconnected environment, complete the following steps:
- Do one of the following:
- Share all usable layers in the map in the service definition.
- On the Share tab, in the Share As group, click the Web Layer drop-down arrow and click Save As Offline Service Definition .
- Right-click the name of the map in the Contents pane, point to Save As Offline Service Definition, and click Web Layer on Portal .
- Share selected layers in the map in the service definition. Select the layers in the Contents pane. Right-click any selected layer, point to Sharing, and click Save As Offline Service Definition .
The Save As Offline Service Definition pane appears.
- Share all usable layers in the map in the service definition.
- Provide a name for the web layer.
- Complete the Summary and Tags fields.
You can enter a maximum of 128 tags.
- Under Version, select the ArcGIS Enterprise version to which the service definition will be published. Specifying a version ensures the service definition contains content compatible with your server. Alternatively, select ArcGIS Online.
Note:
To verify the server version, sign in to ArcGIS Server Manager, browse to Site, and click Software Authorization. You can also access the Server Info at the following URL: https://<host>/<instance>/rest/info.
Alternatively, contact your administrator for assistance.
Tip:
You can create multiple service definition files if you need to publish to portals with different versions.
- If you are saving the service definition for an ArcGIS Enterprise portal, under Data and Layer Type, select the layer type under the data type of your choice.
If you are saving the service definition for ArcGIS Online, under Layer Type, select the layer type of your choice.
- Optionally, under Location, provide a name of an existing portal folder or a new folder.
By default, the web layer is stored at the root level of the portal content.
- Optionally, for Server Folder, provide a name of an existing server folder or a new folder.
By default, the service is stored in the root folder of the server.
Note:
The Server Folder option only appears if you are sharing a map image layer.
- Optionally, click the Content tab to view the folder, new web layers, and sublayers with assigned IDs if available.
If you enabled the Allow assignment of unique numeric IDs for sharing web layers option on the Map Properties dialog box, assigned IDs appear for each sublayer. To change an ID, click the number next to the layer or table. On the Layer Properties or Standalone Table Properties dialog box, on the General tab, type a custom integer ID in the Layer ID or Table ID text box. For more information, see Assign layer IDs.
- Under Finish Staging, click Analyze to review for problems.
Errors and warnings are listed on the Messages tab. Right-click a message to open its help topic or take corrective action in the software. Errors must be resolved before you can save the service definition. Resolving warnings is recommended but not required.
- After you have resolved errors, and optionally resolved warnings, click Save.
The Save As Service Definition File dialog box appears.
- On the dialog box, specify the location and name of the service definition file, and click Save.
- Optionally, click Jobs to monitor the job status.
- Once the service definition has been successfully staged, click the Manage the service definition link at the bottom of the pane to open the location of the service definition file.
If you are ready to publish your web layer to ArcGIS Online or an ArcGIS Enterprise portal, see Publish a service definition.