Merge branch '6.1.x'

This commit is contained in:
Simon Baslé
2024-09-30 10:19:36 +02:00
2 changed files with 36 additions and 2 deletions

View File

@@ -1155,7 +1155,8 @@ public abstract class CacheAspectSupport extends AbstractCacheInvoker
.onErrorResume(RuntimeException.class, ex -> {
try {
getErrorHandler().handleCacheGetError((RuntimeException) ex, cache, key);
return evaluate(null, invoker, method, contexts);
Object e = evaluate(null, invoker, method, contexts);
return (e != null ? e : Flux.error((RuntimeException) ex));
}
catch (RuntimeException exception) {
return Flux.error(exception);
@@ -1169,7 +1170,8 @@ public abstract class CacheAspectSupport extends AbstractCacheInvoker
.onErrorResume(RuntimeException.class, ex -> {
try {
getErrorHandler().handleCacheGetError((RuntimeException) ex, cache, key);
return evaluate(null, invoker, method, contexts);
Object e = evaluate(null, invoker, method, contexts);
return (e != null ? e : Mono.error((RuntimeException) ex));
}
catch (RuntimeException exception) {
return Mono.error(exception);