0

I was trying to find some examples and evidence if Spring 4.0.3 version support caffeine cache integration? If yes, what caffeine cache version is supported for Spring 4.0.3?

Sam
  • 127
  • 2
  • 15

1 Answers1

0

Support was added in Spring Framework 4.3 and in Spring Boot 1.4. Previously you could use the Guava provider, which was the baseline for Caffeine's. That will likely be a good approach until you are ready to upgrade. If you really need to use Caffeine for performance reasons then you might try this alternative integration.

Ben Manes
  • 9,178
  • 3
  • 35
  • 39
  • Thanks for your response. I heard about coffee boots does it integrate or gels with Spring 4.0.3 version? Additionally, can i use this as the first level cache as a local cache and then use redis pub/sub for syncing with the remote secondary cache that will be redis? – Sam Nov 16 '21 at 03:22
  • @Sam I don't know since I do not currently work with Spring. Since the cache provider apis have existed for years it seems likely, but you'd have to ask the author. You can certainly use tiered caching with the native APIs, but how to do that in Spring is beyond my limited knowledge. There are some alternative providers like [jetcache](https://github.com/alibaba/jetcache) and [multilevel-cache](https://github.com/SuppieRK/spring-boot-multilevel-cache-starter) that might be helpful, but may have moved beyond your Spring version. – Ben Manes Nov 16 '21 at 03:52