Expand my Community achievements bar.

AEM dispatcher filter

Avatar

Level 2

Hi All,

 

If one my file with some exxtension got cached in dispatcher cache and after that i blocked that file through filter rules , and i'm trying to hit the file will the file gets served or it gets blocked. After updating filter rules I restarted dispatcher server and trying to hit the file.

Thank You.

2 Replies

Avatar

Community Advisor

Hi @Ns334 

If a file is cached in the Dispatcher and later blocked by filter rules, it will continue to be served unless explicitly invalidated. The Dispatcher prioritizes checking the cache before applying filter rules. If a valid cached version is found, it serves the file directly without considering the filters. Filters only control requests that reach AEM Publish instances.

Thanks,

Asutosh Jena

Avatar

Community Advisor

Hi @Ns334 ,

In AEM Dispatcher, filter rules are applied before checking the cache.

So, after you updated the filter rules to block the file and restarted Dispatcher, any request for that file will be blocked, even if it exists in the cache.

Dispatcher will not serve the cached file because:

     - The filter rule denies the request first, and the Dispatcher will not proceed to cache lookup.

Key Points:

Dispatcher follows this order:

     - Apply /filter rules.
     - If allowed, check the cache.
     - If not in cache, forward to AEM Publish.

Since the file is now blocked by the filter, the request is denied immediately—no cache check, no AEM access.

After you block a file through filter rules, it will be blocked and not served, even if it was previously cached. Dispatcher always applies filter rules first, then checks cache only if the request is allowed.

Regards,
Amit