Expand my Community achievements bar.

SOLVED

Cache Invalidation in AEM Dispatcher: Exploring 'statfileslevel' and Cache Flushing Strategies

Avatar

Level 2

I need understanding of cache invalidation in AEM Dispatcher, particularly regarding the 'statfileslevel' setting and its significance in cache management. Can someone explain how this setting affects cache invalidation and share some best practices for optimizing it?

Additionally, I'd appreciate insights on how AEM Dispatcher combines various cache flushing strategies and its role in ensuring a balance between content freshness and optimal performance.

1 Accepted Solution

Avatar

Correct answer by
Level 8

Hi @aem101 

           /statfileslevel properties of the dispatcher configuration file to selectively invalidate cached files according to their path. There are some rules for /statfileslevel properties mechanism:

  • The dispatcher creates .stat files in every folder, starting from docroot and up to the level you specify. The level of the docroot folder is 0.
  • When you update a file, the dispatcher finds a folder located at the statfileslevel level and invalidates all files in that folder and all files that lie below within that folder.
  • If the level of the updated file is lower than the statfileslevel, then only the files of the folder containing the updated file are disabled, but the files lying below within this folder remain valid.
  • When updating a file, all files of the corresponding folder and above up to and including the root level will become invalid.

 

The below blog has explained it very crisp and clear

https://www.axamit.com/blog/adobe/dispatcher-4

https://www.aemrules.com/2020/04/dispactherhacks-statfile.html

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/what-is-the-best-approach-...

 

 

Note: The recommendation is too keep the stat file level lower and not at root 0 depending upon your content structure to make sure you are not invalidating a lot of content.

 

On the strategies please looks at the community post , it has all the considerations.

 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager-blogs/deep-dive-into-aem-d...

 

https://experienceleague.adobe.com/docs/experience-cloud-kcs/kbarticles/KA-17458.html?lang=en

 

 

 

 

 

 

View solution in original post

2 Replies

Avatar

Correct answer by
Level 8

Hi @aem101 

           /statfileslevel properties of the dispatcher configuration file to selectively invalidate cached files according to their path. There are some rules for /statfileslevel properties mechanism:

  • The dispatcher creates .stat files in every folder, starting from docroot and up to the level you specify. The level of the docroot folder is 0.
  • When you update a file, the dispatcher finds a folder located at the statfileslevel level and invalidates all files in that folder and all files that lie below within that folder.
  • If the level of the updated file is lower than the statfileslevel, then only the files of the folder containing the updated file are disabled, but the files lying below within this folder remain valid.
  • When updating a file, all files of the corresponding folder and above up to and including the root level will become invalid.

 

The below blog has explained it very crisp and clear

https://www.axamit.com/blog/adobe/dispatcher-4

https://www.aemrules.com/2020/04/dispactherhacks-statfile.html

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/what-is-the-best-approach-...

 

 

Note: The recommendation is too keep the stat file level lower and not at root 0 depending upon your content structure to make sure you are not invalidating a lot of content.

 

On the strategies please looks at the community post , it has all the considerations.

 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager-blogs/deep-dive-into-aem-d...

 

https://experienceleague.adobe.com/docs/experience-cloud-kcs/kbarticles/KA-17458.html?lang=en