Issue with cached html files while using versioned clientlibs
Hi,
We have tried the versioned clientlibs provided by ACS AEM Commons, it is working as per documentation. We are getting the hashcoded JS/CSS files generated post every deployment (if there are changes related to JS/CSS)
All the pages[.html] which are not cached are picking the latest hash coded js/css files.
It’s not picking the latest hash coded js/css files for the pages[.html] which are cached in dispatcher.
Scenario:
Let’s consider three pages
- Home page (Cached in Dispatcher)
- Search (Not Cached in Dispatcher)
- About us (Not Cached in Dispatcher)
Expected Result:
Whenever there is a deployment all the three pages has to pick the latest hash coded JS/CSS files without clearing the dispatcher cache.
Actual Result:
But in our case post every deployment, when there is a request for home page, it is picking the cached html file (which has reference to old hash coded JS file), since we are caching the home page[.html].
Options we tried are,
- If we delete the old cached JS/CSS file, then the cached HTML pages are throwing 404 error. (To resolve this we need to clear the cached html files also)
- It is working fine for the pages that are not cached [.html]
Source link:
https://adobe-consulting-services.github.io/acs-aem-commons/features/versioned-clientlibs/index.html
Note: We are using AEM 6.2 SP1 CFP4 with IIS 8 dispatcher
Regards
Teja G