Routing services allow you to perform several types of spatial analysis on transportation networks, such as finding the best route across a city, finding the closest emergency vehicle or facility, identifying a service area around a location, or servicing a set of orders with a fleet of vehicles.
Default administrators and those with the appropriate privileges can configure the ArcGIS Enterprise portal to use routing services to perform various tasks. The routing services can be configured on the ArcGIS Enterprise portal using one of three methods:
- Configure routing services from ArcGIS Online
- Configure routing services by publishing routing services using your network dataset to a federated ArcGIS Server site
- Configure routing services by updating the ArcGIS Enterprise portal routing utility services URLs
Once configured, the routing services can be used with various applications, such as ArcGIS Pro, or to get directions and perform analysis in Map Viewer Classic. You can also write applications using ArcGIS web APIs and ArcGIS Runtime SDK that use these routing services.
To configure routing services, follow the steps below.
- Sign in to your organization as an administrator.
- At the top of the site, click Organization and click the Settings tab.
- Click Utility services on the left side of the page.
- Click Directions and Routing on the right side of the page.
- Click Configure routing services and choose one of the three methods to configure routing services on the ArcGIS Enterprise portal.
Configure routing services from ArcGIS Online
You can configure your ArcGIS Enterprise portal routing services from ArcGIS Online. To use routing services provided by Esri, you must have an ArcGIS Online organizational account. The account must have credits associated with it and the appropriate permissions to use the routing services.
- On the Configure routing services dialog box, select the ArcGIS Online option, and click Next.
- Enter the credentials for the ArcGIS Online account to be used for the routing services, and select the folder or create a folder where the corresponding items will be created in the ArcGIS Enterprise portal.
- Click Save.
Once it succeeds, it will show that the routing services on the ArcGIS Enterprise portal are coming from ArcGIS Online. It will also show the ArcGIS Online user account that is used to set up the ArcGIS Enterprise routing services. This is the account from which credits will be deducted when you use routing services on the ArcGIS Enterprise portal.
Configure and publish routing services using your network dataset to a federated ArcGIS Server site
If you have a network dataset that models your street data, and want to use it as sources for your routing services, you can configure your ArcGIS Enterprise routing services by publishing routing services using your network dataset to a federated ArcGIS Server site. This process creates all the routing services based on your network dataset and registers them as utility services in your ArcGIS Enterprise portal for various applications to discover and use them.
Ensure that the network dataset that is used to publish routing services is accessible to the server site where you want routing services to be hosted. You can do this by storing the file geodatabase or the mobile geodatabase containing the network dataset in a folder that is registered as a folder data store item within the content of your ArcGIS Enterprise portal, or by adding a database data store item for the enterprise geodatabase that stores the network dataset. The data store item should allow access to the federated ArcGIS Server site that is being used to host routing services.
Learn more about data stores in ArcGIS Enterprise
Caution:
If you have specified ArcGIS Enterprise portal's maximum token duration to be less than 120 minutes, you may run into issues since this process could take a while. It is recommended that you set ArcGIS Enterprise portal's maximum token duration to be more than 120 minutes before running this process and reset it to your desired value after the process.
- On the Configure routing services dialog box, select A network dataset that I'd like to publish, and click Next
- From the Data store item containing the network dataset drop-down menu, select a data store item that contains your network dataset.
- From the GIS Server site to host your routing services drop-down menu, choose the GIS Server site that will be used to host your routing services. The drop-down menu only includes GIS Server sites that can access the data store item. It also only includes ArcGIS Server sites of version 11.0 or later.
- The Network dataset relative path is the path to the network dataset in the data store. For example, if the catalog path of the network dataset in a file geodatabase is C:\data \streets\NorthAmerica.gdb\Routing\Routing_ND and the data store item is referencing C:\data, the value for the network dataset relative path is /streets/NorthAmerica.gdb/Routing/Routing_ND.
Note:
You need to provide the network dataset relative path using forward slashes.
- For the Service folder parameter, specify a name for the server folder that will contain all the routing services created by the tool.
- For the Service types parameter, turn off the services you don't need.
Note:
Some out- of- the box client applications may have functionality disabled. To make use of all or the needed services, ensure they are turned on in the Configure routing services dialog box. - In the Advanced properties section, specify a configuration file to specify certain properties for the routing services such as the minimum and maximum number of service instances. The framework/runtime/ArcGIS/Resources/ArcToolBox/Services/routingservices folder in the ArcGIS Server installation directory includes two sample configuration files, publishroutingservices.json and publishroutingservices_dedicated.json. The process uses the publishroutingservices.json file by default if you don't specify a configuration file.
Learn more about publishing a routing services config file
Before publishing, ensure all the parameters are entered correctly. Once the process starts, you will get a progress indicator. Since it can take a while to run the process, you can continue with other tasks on your portal and return to the progress indicator page to see whether the process has finished.
Once the process finishes, it should show you the ArcGIS Server site that hosts your routing services, as well as the network dataset that is used for your routing services. If you are using StreetMap Premium data to publish routing services, and if the data is set up to use live traffic, it should show you the traffic data service item indicating your routing services have live traffic configured from ArcGIS Online.
Error and warning messages
If you run into issues while publishing, you will see warning messages or error messages. Learn more about warnings and errors when publishing routing services.
When you have more than one warning or error messages, you can see them all by clicking View publishing routing services warnings or View publishing routing services errors. By clicking Detailed messages from publish routing services, you can open the raw JSON messages returned from publishing routing services REST API, which could contain more information.
Configure routing services by updating the ArcGIS Enterprise portal routing utility services URLs
If you have routing services hosted on a stand-alone server and want to register the services with the ArcGIS Enterprise portal so that various applications can discover and use these routing services, you can configure routing services by updating the ArcGIS Enterprise portal routing utility services.
- On the Configure routing services dialog box, select Existing routing services (Advanced).
- Construct URLs to the various routing utility services. You don't need to specify a URL for all the services.
- Click Save.
Once routing services are configured on the ArcGIS Enterprise portal using one of the three methods mentioned above, you can view an individual routing service URL and service item by clicking the Options button and clicking View routing services details. You can delete routing services from the ArcGIS Enterprise portal by clicking Delete routing services. If you configure routing services by updating the ArcGIS Enterprise portal routing utility services URLs, you can directly edit each utility service by clicking the Options button and clicking Edit routing services.
If you configure routing services on your ArcGIS Enterprise portal, and later need to update routing services, you can click the Update routing services button and follow the same steps to update routing services on your ArcGIS Enterprise portal. You could also delete existing routing services on the ArcGIS Enterprise portal and configure routing services on the ArcGIS Enterprise portal from scratch. The benefit of doing so is the existing service items and routing services on the ArcGIS Server site are deleted and cleaned. If your routing services source is Custom, you only have the Remove routing services option, which only removes the utility services from the ArcGIS Enterprise portal.