@Endpoint(id="caches",
defaultEnabled=false)
public class CachesEndpoint
extends java.lang.Object
Endpoint
to manage caches.Modifier and Type | Field and Description |
---|---|
static java.lang.String |
NAME
Endpoint name.
|
Constructor and Description |
---|
CachesEndpoint(CacheManager<java.lang.Object> cacheManager) |
Modifier and Type | Method and Description |
---|---|
reactor.core.publisher.Mono<java.util.Map<java.lang.String,java.lang.Object>> |
getCache(@NotBlank java.lang.String name)
Returns the cache as a
Mono . |
reactor.core.publisher.Mono<java.util.Map<java.lang.String,java.lang.Object>> |
getCaches()
Returns the caches as a
Mono . |
reactor.core.publisher.Mono<java.lang.Boolean> |
invalidateCache(@NotBlank java.lang.String name)
Invalidates the cache.
|
reactor.core.publisher.Mono<java.lang.Boolean> |
invalidateCacheKey(@NotBlank java.lang.String name,
@NotBlank java.lang.String key)
Invalidates a key within the provided cache.
|
reactor.core.publisher.Mono<java.lang.Boolean> |
invalidateCaches()
Invalidates all the caches.
|
public static final java.lang.String NAME
public CachesEndpoint(CacheManager<java.lang.Object> cacheManager)
cacheManager
- The CacheManager
@Read public reactor.core.publisher.Mono<java.util.Map<java.lang.String,java.lang.Object>> getCaches()
Mono
.Mono
@Read public reactor.core.publisher.Mono<java.util.Map<java.lang.String,java.lang.Object>> getCache(@NotBlank @Selector @NotBlank java.lang.String name)
Mono
.name
- The name of the cache to retrieveMono
@Delete public reactor.core.publisher.Mono<java.lang.Boolean> invalidateCaches()
@Delete public reactor.core.publisher.Mono<java.lang.Boolean> invalidateCache(@NotBlank @Selector @NotBlank java.lang.String name)
name
- The name of the cache to invalidate@Delete public reactor.core.publisher.Mono<java.lang.Boolean> invalidateCacheKey(@NotBlank @Selector @NotBlank java.lang.String name, @NotBlank @Selector @NotBlank java.lang.String key)
name
- The name of the cachekey
- the key within the cache to invalidate