Caching with EhCache in AEM | Community
Skip to main content
New Participant
June 27, 2022
Solved

Caching with EhCache in AEM

  • June 27, 2022
  • 2 replies
  • 3162 views

Hi, I'm trying to use EhCache for In memory caching in AEM, but I have problems with setup, i cant seem to find how to add it to AEM.

Does anyone have any experience with using EhCache and can help with the setup.

I've seen this: http://blog.atish.me/2016/12/25/AEM-Ehcache/ but its not working for me.

Thanks!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by milind_bachani

Hi @ediši ,

 

EH cache is purely server side caching and you can simply use the java EH cache implementation to get it working in AEM by creating a service for it :

References you can use :

  1. https://www.baeldung.com/ehcache
  2. https://github.com/ehcache
  3. https://mkyong.com/ehcache/ehcache-hello-world-example/

Hope this helps, thanks.

2 replies

arunpatidar
New Participant
June 27, 2022

Hi,

You can probably explore ACS commons HTTP memory cache

https://adobe-consulting-services.github.io/acs-aem-commons/features/http-cache/index.html 

 

This will provide you all the interface to check, rebuild and clear the cache.

Arun Patidar
milind_bachani
milind_bachaniAccepted solution
Employee
June 27, 2022

Hi @ediši ,

 

EH cache is purely server side caching and you can simply use the java EH cache implementation to get it working in AEM by creating a service for it :

References you can use :

  1. https://www.baeldung.com/ehcache
  2. https://github.com/ehcache
  3. https://mkyong.com/ehcache/ehcache-hello-world-example/

Hope this helps, thanks.

New Participant
February 3, 2023

@milind_bachani 

For AEM cloud service Ehcache is not working. Can you help with any documentation or any solution it fix it on AEM cloud service.