Prevent cache bypass in AEM as a Cloud Service by ignoring unnecessary query parameters
This article describes how to prevent cache bypass and request throttling in Adobe Experience Manager (AEM) as a Cloud Service publish environments by configuring the system to ignore unnecessary query parameters.
Description description
Environment
Adobe Experience Manager as a Cloud Service (publish tier)
Issue/Symptoms
- When query parameters that do not affect content rendering are not configured to be ignored by the CDN or AEM Dispatcher, requests containing these parameters can bypass the cache and reach the origin server.
- This can result in increased origin load, high thread pool utilization, and request throttling.
- Such parameters are often used for analytics or client-side logic and should be ignored to ensure optimal caching.
- Increased number of requests reaching the origin server.
- High Jetty thread pool utilization.
- Throttling of incoming requests.
- Cache misses for requests containing unnecessary query parameters.
Cause
A burst of requests containing query parameters not configured to be ignored caused cache bypass, resulting in excessive origin load and triggering request throttling.
Resolution resolution
Follow the steps below to resolve the issue:
-
Identify which query parameters are causing cache bypass by reviewing access logs and thread dumps for requests with varying query parameters that do not affect content rendering.
-
Update your CDN or AEM Dispatcher configuration to ignore these unnecessary query parameters:
- For AEM Dispatcher, add the parameters to the
/ignoreUrlParamssection of your Dispatcher configuration. - For CDN, use the configuration pipeline to strip or ignore these parameters according to your CDN documentation.
- For AEM Dispatcher, add the parameters to the
-
Deploy the updated configuration.
-
Monitor access logs to confirm that requests with the ignored parameters are now being cached and are not reaching the origin unnecessarily.
-
Continue to monitor for new query parameters that may require similar handling and update your configuration as needed.
Related reading
Caching in AEM as a Cloud Service