Browse Source

Improve exception message

Issue: SPR-12898
pull/776/head
Stephane Nicoll 10 years ago
parent
commit
e5b505224b
  1. 3
      spring-context/src/main/java/org/springframework/cache/interceptor/CacheAspectSupport.java

3
spring-context/src/main/java/org/springframework/cache/interceptor/CacheAspectSupport.java vendored

@ -184,7 +184,8 @@ public abstract class CacheAspectSupport extends AbstractCacheInvoker @@ -184,7 +184,8 @@ public abstract class CacheAspectSupport extends AbstractCacheInvoker
}
catch (NoUniqueBeanDefinitionException ex) {
throw new IllegalStateException("No CacheResolver specified, and no unique bean of type " +
"CacheManager found. Mark one as primary or declare a specific CacheManager to use.");
"CacheManager found. Mark one as primary (or give it the name 'cacheManager') or " +
"declare a specific CacheManager to use, that serves as the default one.");
}
catch (NoSuchBeanDefinitionException ex) {
throw new IllegalStateException("No CacheResolver specified, and no bean of type CacheManager found. " +

Loading…
Cancel
Save