Win a copy of Pro Spring MVC with WebFlux: Web Development in Spring Framework 5 and Spring Boot 2 this week in the Spring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Jeanne Boyarsky
  • Liutauras Vilda
Sheriffs:
  • Rob Spoor
  • Bear Bibeault
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:
  • Frits Walraven
  • Himai Minh

Refreshing cache in ForumRepository

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Rafael,

We are having issues with the cache object in ForumRepository.java. The cache somehow sometimes gets invalidated and the categories don't show even if they exist in the database. To eliminate these problems, each time the getAllCategories method is called, we would like to invalidate the cache and execute the start method again, so the cache is refreshed from the database. Is there any easy way to invalidate the entire cache at one time? I noticed that it does not suffice to refresh just the CATEGORIES_SET..which is why it probably makes sense to invalidate the cache and invoke the start method once again. Thank you.

Regards,
Mallika
[originally posted on jforum.net by mallikamt]
reply
    Bookmark Topic Watch Topic
  • New Topic