Merge branch '6.1.x'
# Conflicts: # spring-aop/src/main/java/org/springframework/aop/aspectj/AspectJExpressionPointcut.java
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
* Copyright 2002-2024 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -606,9 +606,9 @@ class CacheReproTests {
|
||||
return CompletableFuture.completedFuture(item);
|
||||
}
|
||||
|
||||
@CacheEvict(cacheNames = "itemCache", allEntries = true)
|
||||
public CompletableFuture<Void> clear() {
|
||||
return CompletableFuture.completedFuture(null);
|
||||
@CacheEvict(cacheNames = "itemCache", allEntries = true, condition = "#result > 0")
|
||||
public CompletableFuture<Integer> clear() {
|
||||
return CompletableFuture.completedFuture(1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -655,9 +655,9 @@ class CacheReproTests {
|
||||
return Mono.just(item);
|
||||
}
|
||||
|
||||
@CacheEvict(cacheNames = "itemCache", allEntries = true)
|
||||
public Mono<Void> clear() {
|
||||
return Mono.empty();
|
||||
@CacheEvict(cacheNames = "itemCache", allEntries = true, condition = "#result > 0")
|
||||
public Mono<Integer> clear() {
|
||||
return Mono.just(1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -706,9 +706,9 @@ class CacheReproTests {
|
||||
return Flux.fromIterable(item);
|
||||
}
|
||||
|
||||
@CacheEvict(cacheNames = "itemCache", allEntries = true)
|
||||
public Flux<Void> clear() {
|
||||
return Flux.empty();
|
||||
@CacheEvict(cacheNames = "itemCache", allEntries = true, condition = "#result > 0")
|
||||
public Flux<Integer> clear() {
|
||||
return Flux.just(1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
* Copyright 2002-2024 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -51,7 +51,9 @@ class ReactiveCachingTests {
|
||||
LateCacheHitDeterminationConfig.class,
|
||||
LateCacheHitDeterminationWithValueWrapperConfig.class})
|
||||
void cacheHitDetermination(Class<?> configClass) {
|
||||
AnnotationConfigApplicationContext ctx = new AnnotationConfigApplicationContext(configClass, ReactiveCacheableService.class);
|
||||
|
||||
AnnotationConfigApplicationContext ctx =
|
||||
new AnnotationConfigApplicationContext(configClass, ReactiveCacheableService.class);
|
||||
ReactiveCacheableService service = ctx.getBean(ReactiveCacheableService.class);
|
||||
|
||||
Object key = new Object();
|
||||
@@ -117,7 +119,9 @@ class ReactiveCachingTests {
|
||||
LateCacheHitDeterminationConfig.class,
|
||||
LateCacheHitDeterminationWithValueWrapperConfig.class})
|
||||
void fluxCacheDoesntDependOnFirstRequest(Class<?> configClass) {
|
||||
AnnotationConfigApplicationContext ctx = new AnnotationConfigApplicationContext(configClass, ReactiveCacheableService.class);
|
||||
|
||||
AnnotationConfigApplicationContext ctx =
|
||||
new AnnotationConfigApplicationContext(configClass, ReactiveCacheableService.class);
|
||||
ReactiveCacheableService service = ctx.getBean(ReactiveCacheableService.class);
|
||||
|
||||
Object key = new Object();
|
||||
@@ -135,6 +139,7 @@ class ReactiveCachingTests {
|
||||
ctx.close();
|
||||
}
|
||||
|
||||
|
||||
@CacheConfig(cacheNames = "first")
|
||||
static class ReactiveCacheableService {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user