Instead of making direct call from Author to Dispatcher to clear the cache, can there be a flow to directly clear cache from publisher to dispatcher. So, as soon as content it activated to publish, it send an HTTPS Flush call to dispatcher to clear the cache? Is it feasible. If not then why not?
Solved! Go to Solution.
It’s recommended to use publish flush agent for more robust autoinvalidation because using author flush agent may cause the following issues:
● The Dispatcher must be reachable from the authoring instance. If your network (e.g. the firewall) is configured such that access between the two is restricted this may not be the case.
● Publication and cache invalidation take place at the same time. Depending on the timing a user may request a page just after it was removed from the cache and just before the new page is published. AEM now returns the old page and the Dispatcher caches it again. This is more of an issue for large sites.
Hi,
The way AEM works is, publisher sends flush call to dispatcher to either flush or rebuild the cache depending on replication agent serialization type.
If I understand your question correctly(it's asking about publish dispatcher and not author dispatcher), this is how AEM should work -
Page is activated from author, as soon as it reaches to publisher, publisher sends flush/re-fetch call to dispatcher to either flush or rebuild it's cache for the activated page.
Regards,
Rachna
Hi Rachna,
I asked this question to get the recommended approach to clear cache. What if I move my cache clearing logic from author to publisher. What impact would it have? Should I go ahead with it?
It’s recommended to use publish flush agent for more robust autoinvalidation because using author flush agent may cause the following issues:
● The Dispatcher must be reachable from the authoring instance. If your network (e.g. the firewall) is configured such that access between the two is restricted this may not be the case.
● Publication and cache invalidation take place at the same time. Depending on the timing a user may request a page just after it was removed from the cache and just before the new page is published. AEM now returns the old page and the Dispatcher caches it again. This is more of an issue for large sites.
I think recommended way to clear publish dispatcher cache is always from publisher via replication agent on publisher as oppose to author.
Not sure why do you need to clear publish dispatcher cache from author directly.
Regards,
Rachna
Thanks Kalyan.
Thanks Kalyan and Rcahna!
Can someone from Adobe also confirm if it is ok to go ahead with sending dispatcher flush request from publisher instead of author?
If yes then we can go ahead with this approach.
Hi,
this solution is confirmed officially in Adobe documentation [0] (Invalidating Dispatcher Cache from a Publishing Instance).
[0] Invalidating Cached Pages From AEM
Thanks,
Antonio
Ideally, the flush agent should be configured on the publisher and most of the customer do it that way.
Under certain circumstances, performance gains can be made by transferring cache management from the authoring environment to a publishing instance. It will then be the publishing environment (not the AEM authoring environment) that sends a cache invalidation request to Dispatcher when a published page is received.
More details at [1]
Just to add to the thread, you can also use a very handy "Dispatcher Flush UI" from ACS Common tools: Dispatcher Flush UI
As folks already mentioned in this thread the flush agent should be configured on the publisher and most of the customer do it that way.
Still below are recommended approaches to set up dispatcher flush mechanism for AEM Applications -
1. Set up dispatcher flush agents on AEM Publisher instances. This can be enabled completely by following Adobe's documentation for setting up dispatcher flush agent in Publishers instance.
2. In case if your AEM application/sites have internal redirections/shortening the URLs etc., then you like to configure dispatcher flush rules (from ACS Commons) as part of your AEM project configs - Dispatcher Flush Rules
3. Now say you have a situation, where you need to clear full site cache but you don't have direct access to dispatcher servers but still you want to manage the dispatcher cache clear on your own without AEM admin help. In that case, you may like to configure dispatcher flush agent in AEM Author instance also and leverage Dispatcher Flush UI pages from ACS Commons - Dispatcher Flush UI to clear dispatcher cache from AEM Author instance.
Hope above recommendations help in your use cases. Thanks.
Views
Likes
Replies
Views
Likes
Replies