shiro icon indicating copy to clipboard operation
shiro copied to clipboard

[Enhancement] Update ehcache to latest

Open 8502596 opened this issue 9 months ago • 2 comments

Search before asking

  • [x] I had searched in the issues and found no similar issues.

Enhancement Request

There seems to be no discussion on the issues of updating ehcache to ehcache3 I am not sure if branch 3. x is related to this task or if this project, which has not been maintained for a long time, can achieve this. ehcache-shiro

Describe the solution you'd like

It's been a long time since the release of ehcache 3, and it's time to adapt to ehcache 3.10.8

Are you willing to submit PR?

  • [ ] Yes I am willing to submit a PR!

8502596 avatar Apr 27 '25 09:04 8502596

There is JSR-107 JCache support instead (shiro-jcache), so you can use many providers by means of JCacheManager.

Note that for Ehcache 3 you should either ensure that your cache size is small or that you use a strong hash function in your key's hashCode(), or else it will degrade very poorly due to their unintended switch to an O(n) eviction policy (technical details).

ben-manes avatar Apr 28 '25 04:04 ben-manes

Exactly. EhCache module will go away in Shiro 3.0 in favor of JCache.

lprimak avatar Apr 28 '25 15:04 lprimak