Asset Searches in ArcGIS Online and Portal

December 7, 2015 — Skye Perry

Our data is only truly valuable if we can easily find it on a map! ArcGIS Online and Portal for ArcGIS allow us to configure our own geocoding services as the default searches used within the web browser and their various mobile applications:

Asset Searches

I previously wrote a blog post on how to use the Esri asset locator solution template to create your own geocoding services based on your own authoritative asset data using these straight forward steps:

  1. Create a single field locator for each feature class / field you want to search
  2. Create a composite locator that joins all of the individual single field locators into a single search
  3. Publish the composite locator to ArcGIS Server as a geocoding service
  4. Configure the geocoding service in ArcGIS Online as your default search

If you want more details on any of the above, please check out the original post. We have, however, run into a couple of issues with the scalability above approach. The most important point is that when you perform step 1 above (create a single field locator), the Esri geoprocessing tools are actually creating a cache of the search terms (your asset numbers) along with the geometry on the map. This is good because it allows the searches to be extremely performant even on large datasets. The big downside is that it is a cache of your data and this therefore isn’t a perfect solution for the dynamic facility data we typically manage at a utility or telecom.

No ResultsFor example, if I create a cache off of my light company numbers (as shown in the picture above) today it will work perfectly. However, if 10 lights were removed from service and another 15 lights were put into service in the next month, my cache would be out of date. Searching on the company number for a newly installed light would not return any results and I would still be able to search on those old lights even though they are no longer in service.

What’s the solution?

The easy remedy is to have your GIS team follow the four steps above to recreate the locators and republish the geocoding service on a regular basis. How often? I would recommend monthly at a mininum but weekly would be ideal. This will work well if you have a handful of searches you want to perform in ArcGIS Online or Portal. The creation of the locators takes a bit of time though depending on the size of your dataset so you should be prepared to wait a bit. We’ve seen locators created for small datasets in 15 seconds whereas large datasets might take a couple of minutes depending on the horsepower of your machine.

This recommendation worked well until we hit a customer who wanted to have 30 asset searches available in ArcGIS Online/Portal and wanted to have them refreshed on a weekly basis. As noted in the previous post, you typically specifiy four key inputs to create a single field locator: Feature Class, Field Name, Field Label, and the Output Location:
Single Field Locator

No big deal for a few locators but when you want to create 30 locators and have them created the exactly the same each week, then you are managing 120 different data inputs into the geoprocessing (GP) model. And then there is the factor of the time it takes to create all 30 locators each week. It’s a pretty monotonous job and prone to manual error. You see where I’m going… a definite candidate for automation!

So in response we wanted to use the Esri GP model for what it does best but wanted to create an automated process that provided easy and configurable management of the end result. To accomplish this we designed a new SSP Nightly Batch Suite (NBS) application aptly named RebuildAssetLocators. This application utilizes some tweaked up Python GP scripts from Esri to automate the entire process. The configurable inputs are organized as follows:

  • Connections – allows you to specify one or more connections to different geodatabases that contain the feature classes to search against.
  • Dataset Locationfor each connection allows you to specify the location in the geodatabase where the feature classes exist. This could be the root of the GDB or within a specific Esri dataset
  • Feature Classesfor each connection / dataset location combination, allows you to specify the name of the feature class (i.e. Electric.Pole or Gas.Valve).
  • Field NamesFor each feature class, allows you to specify the name of the field that the search should be performed against (i.e. FacilityId or ValveNumber).
  • Field Labelsfor each field,  allows you to alias the field search name that the user will see in ArcGIS Online or Portal (i.e. Pole_Number or Gas_Valve_Number). These could be the same as the field number but in the case where you have the same field name on multiple classes like Pole.FacilityId and Transformer.FacilityId, you will want to distinguish between the classes with the label).

The RebuildAssetLocators NBS application also accepts parameters for connecting to your ArcGIS Server instance. When the NBS application is run weekly (or nightly or monthly if desired) it utilizes the above configuration to automatically generate a unique single field asset locator for each configured input. It then automatically merges the single field asset locators into a composite locator and finally automatically publishes that locator to your ArcGIS Server. ArcGIS Online and/or Portal utilize the REST end point of the published locator and therefore immediately have the updated search data available.

Asset Locator Log

This solution works great and requires no user involvement beyond the initial configuration. If additional fields need to be added over time, no problem – just update the configuration and the new fields are added the next time the NBS is executed. We hope this post closes the loop on how you can effectively use your authoritative asset data to empower searches across the Esri platform!

We Wrote the Book

The Indispensible Guide to ArcGIS Online

Download It for Free
Chairman of the Board

What do you think?

Leave a comment, and share your thoughts

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>


This site uses Akismet to reduce spam. Learn how your comment data is processed.