More information on Amazon CloudFront:
ArcGIS Enterprise inherently supports secure content which requires a token to access. This content is not a good candidate for caching, as it changes frequently and each user obtains a different token. This will make all requests forward to the origin instead of being served from the edge cache.
ArcGIS Enterprise servers a mix of dynamic and static content. When adding a CDN in front of ArcGIS Enterprise it is important to understand the different type of content that should be cached. If we cache content that is meant to be dynamic, errors may occur in your applications. Below you can find a breakdown of the context paths and the associated content for both Portal for ArcGIS and ArcGIS Server.
|Static Content (context path)
|Dynamic Content (context path)
|Portal JS Files (portal/home/10.7.1/*)
|Sharing API (portal/sharing/*)
|Portal HTML Files (portal/*.html)
|Portal Admin (portal/portaladmin/*)
|Portal Image Files (portal/home/images/*)
* The above examples all use a Web Adaptor name "portal". If you named your web adaptor something different, replace the "portal" with you web adaptor name
|Tiled Services (server/rest/services/<Service Name>/MapServer/tile/*)
|Sharing API (server/sharing/*)
|Select Queries from Map Services *
* The above examples all use a Web Adaptor name "server". If you named your web adaptor something different, replace the "server" with you web adaptor name
There are three steps to deploying your ArcGIS Enterprise with CloudFront. The first step is creating the distribution and specifying what the default behavior for the cache is. This step is critical, as it allows dynamic content to pass thru the edge servers and onto the origin. The second step is adding additional cache behaviors. This step provides the ability to cache specific path patterns from the distribution. The final step is to map the existing DNS Record Set to the CloudFront distribution CNAME.
Note: The Origin Domain Name will be the Load Balancer or Server that your ArcGIS Enterprise is accessible from. In this example we use the an Application Load Balancer but other properties are supported here as well. CloudFront will forward requests to this location when populating it's edge cache.Note:
3. Point your DNS records to the CloudFront CNAME