Skip to content

EhCacheManagerFactoryBean should share per cacheManagerName and only call shutdown if it originally created its CacheManager [SPR-11178] #15804

@spring-projects-issues

Description

@spring-projects-issues

Raul Kripalani opened SPR-11178 and commented

The shared=true option instructs the EhCacheManagerFactoryBean that the CacheManager is shared across several contexts.

Unfortunately, the destroy() method is oblivious to this fact and shuts down the CacheManager unconditionally.

EhCacheManagerFactoryBean should keep track of the contexts that are using the CacheManager through a static counter, and only shut down the CacheManager if no more contexts are using it.


Affects: 3.2.5

Referenced from: commits a9605a1

Metadata

Metadata

Assignees

Labels

in: coreIssues in core modules (aop, beans, core, context, expression)type: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions