ArcGIS Online

Best Practices for High Demand/Viral Apps

updated from an article published March 2017

News Flash! ArcGIS Online users make great Apps that are used to inform and engage the public about important and interesting geospatial topics. Apps hosted on ArcGIS Online are easily shareable and can receive hundreds of thousands of views in a short amount of time. ArcGIS Online scales to meet the demand of your application, making it easy to create and share applications that may receive a high demand of requests (1000s of request per second) from your users.

Consider a natural disaster, where apps are created to inform the public of evacuation zones and shelters. These apps may receive hundreds of thousands of views in a matter of days, receiving a high amount of web traffic. In order to ensure that these apps are performing at their best under high demand, consider these best practices for layer management, so ArcGIS Online can handle the rest.

Host your data and apps on scalable infrastructure

Ensure that your layers and apps are hosted on architecture that is ready to meet the demand of your audience. If you have a dedicated team ready to manage the resources of ArcGIS Enterprise/Server have them monitoring your resources. If you don’t have a dedicated person/team, publish your layers and applications to ArcGIS Online. Let us manage the infrastructure and scaling so that your apps perform and are available when its critical.

Pick the most appropriate Layer Type for your data and workflow

 Hosted Feature Services Optimized for High Demand Checklist

  • Editing is Disabled
  • No Filters on the layer (use feature layer views)
  • Increase the Max Cache Age for the layer

Increase Max Cache Age Information

The Max Cache Age is a service setting that determines how long a service response is stored on the CDN. By default, the CDN checks back to the service with with every request to look for new updates. If this value is increased, the CDN will not check back to the service for updates the time specified. This reduces the load on the server improving the scalability and performance for layers under load. We recommend setting this value for feature layer where data is not updated more often than once a minute.

Instructions to enable setting (note this will be available in ArcGIS Online in the next release):

    1. Navigate to the hosted feature service item and click on the service url:

example

    1. The REST URL should look like this:  https://services5.arcgis.com/cuQhNeNcUrgLmYGD/arcgis/rest/services/<Service_name>/FeatureServer/0?token=<your token>
    2. Modify the url to include admin in the url:https://services5.arcgis.com/cuQhNeNcUrgLmYGD/arcgis/rest/admin/services/<Service_name>/FeatureServer/0?token=<your token>
    3. Click on update definition at the bottom of the page:

Update Definition

    1. Remove all existing text in the update layer definition box and add the following text with the appropriate amount of time as indicated above:

{“cacheMaxAge” : 300}
Max Age

  1. Anytime service is republished, repeat steps 1-5.

Note: This functionality will be included in the upcoming ArcGIS Online Release

Apps with updating data

Many apps, especially in the emergency management space need to show updating data, requiring the ability to edit and display data in an easily scalable way. The December 2016 release of ArcGIS Online, introduced the ability to create hosted feature layer views. This allowed data owners to create an editable and uneditable view to achieve this requirement. The March 2017 release added the ability to set view definitions, allowing data owners to specify the features and fields displayed in each view.

To configure a feature layer view that is optimized for high demand from a layer that can be edited by a group of editors, follow these steps:

First, publish your primary hosted feature layer which will be your Editable layer.

  1. Name it something that is easy to identify like Shelters_ edit
  2. Ensure that your editing settings are appropriate for who will be updating the data.
  3. Create a web map and app that contains the editable layer.
  4. Share the layer, app and map with a group where editors are members of the group.

After following these steps, the layer will be ready to be edited by only the members in your group.

Next, create a hosted feature layer view that it is optimized for high demand.

  1. Navigate to the Primary layer that you just created and select the Create View button.
  2. Name the layer something that is easy to identify like Shelters_ display
  3. Ensure that this layer meets all of the requirements outlined in the optimized for high demand checklist.
           – Ensure that Editing is disabled on the feature layer view
           – Use  Set View Definition if you need to hide any fields or features instead of using filters
           – Verify that the geometry doesn’t exceed the requirements.
 4. Use the display layer in your web map and create your application.

Lastly, add a thumbnail and descriptive summary text to your item details page so that this information appears in social sharing and ArcGIS Online searches. Then take a step back to your admire great app that is ready to scale to meet the interest and high demand of web traffic that awaits.

 

 

Resources

Hurricane Toolkit Group

 

 

About

Kelly is a Product Manager on the ArcGIS Online team. She has been with Esri since 2012 and enjoys blogging, Web Apping and outdoor adventures!

Next Article

Custom Basemaps Webinar recording available

Read this article