Multi-country, multi-language invalidating dispatcher cache from publisher | Community
Skip to main content
Level 4
Jun 20, 2017 12:58 PM UTC
Solved

Multi-country, multi-language invalidating dispatcher cache from publisher

I am having issues trying to get the automatic invalidating dispatcher cache from publisher to work. Our setup is a bit complicated, we have a multi-country, multi-language site, I replaced our real domain name by sample.com:

Dispatcher (/var/www/html/content/):

  • www-sample-com
    • be-en
    • be-en.html
    • be-fr
    • be-fr.html
    • be-nl
    • be-nl.html
    • fr
    • fr.html
    • lu
    • lu.html
    • nl
    • nl.html
    • uk
    • uk.html

Here is the issues, when the publisher receives an updates and wants to invalidate the caches there is a mismatch in directory structure, example:

com.day.cq.replication.Agent.flushsample-aem-dispatcher >> Handle: /content/www-sample-com_nl/nl

As you can see it uses the livecopy name to flush the dispatcher directory structure but those don't match:

  • /content/www-sample-com_nl/nl (livecopy)
  • /content/www-sample-com/nl (dispatcher)

Is there a way to make this work? Thanks in advance!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
JeroenDruweAccepted solution
Level 4
Jul 3, 2017 8:47 AM UTC

We fixed this by using: Dispatcher Flush Rules from aem commons

5 replies

JeroenDruweAuthorAccepted solution
Level 4
Jul 3, 2017 8:47 AM UTC

We fixed this by using: Dispatcher Flush Rules from aem commons

Translate
joerghoh
Employee
Jun 26, 2017 7:26 PM UTC

Please update to the latest available version, IIRC it's 4.2.1 now. This feature has been introduced in the version range you are in, maybe your version is a bit too old.

Translate
Level 4
Jun 26, 2017 12:27 PM UTC

Hey Jörg Hoh​

On the following documentation page: Configuring Dispatcher - docs.adobe.com  I found the section about 'USING CUSTOM INVALIDATION SCRIPTS'. I configured this for our setup and also used a simple logging script as shown in the example but it doesn't seem to work. What dispatcher version do you need to have '/invalidateHandler' working? We currently run a dispatcher version 4.1.10.

Thanks in advance, greetings

Jeroen

Translate
joerghoh
Employee
Jun 23, 2017 6:26 AM UTC

Hi,

ok, looks like that there is no direct match from your content structure do your site structure (in terms of multi-site and multi-language). Which is and will ever be a problem and one of the biggest reasons why the content structure should not evolve by accident, but should a well-thought decision considering also implications like cache invalidation.

In your case I would strongly suggest to consider if redoing the content structure might not only solve this but a bunch of other problems as well.

Of course you can avoid that, but it requires additional work (and complexity). In your case I would implement a custom invalidation script; this invalidation script can translate the repository path into cache path and then do the proper invalidation. See Configuring Dispatcher - docs.adobe.com  for the documentation of this.

Jörg

Translate
kautuk_sahni
Employee
Jun 22, 2017 7:02 AM UTC

Jörg Hoh​ Your dispatcher wisdom is needed here.

~kautuk

Translate
Kautuk Sahni