Class RedisCache.RedisAsyncCache

java.lang.Object
io.micronaut.configuration.lettuce.cache.RedisCache.RedisAsyncCache
All Implemented Interfaces:
io.micronaut.cache.AsyncCache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>, io.micronaut.cache.Cache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
Enclosing class:
RedisCache

protected class RedisCache.RedisAsyncCache extends Object implements io.micronaut.cache.AsyncCache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
Redis Async cache implementation.
  • Constructor Details

    • RedisAsyncCache

      protected RedisAsyncCache()
  • Method Details

    • get

      public <T> CompletableFuture<Optional<T>> get(Object key, io.micronaut.core.type.Argument<T> requiredType)
      Specified by:
      get in interface io.micronaut.cache.AsyncCache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
    • get

      public <T> CompletableFuture<T> get(Object key, io.micronaut.core.type.Argument<T> requiredType, Supplier<T> supplier)
      Specified by:
      get in interface io.micronaut.cache.AsyncCache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
    • putIfAbsent

      public <T> CompletableFuture<Optional<T>> putIfAbsent(Object key, T value)
      Specified by:
      putIfAbsent in interface io.micronaut.cache.AsyncCache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
    • put

      public CompletableFuture<Boolean> put(Object key, Object value)
      Specified by:
      put in interface io.micronaut.cache.AsyncCache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
    • invalidate

      public CompletableFuture<Boolean> invalidate(Object key)
      Specified by:
      invalidate in interface io.micronaut.cache.AsyncCache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
    • invalidateAll

      public CompletableFuture<Boolean> invalidateAll()
      Specified by:
      invalidateAll in interface io.micronaut.cache.AsyncCache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
    • getName

      public String getName()
      Specified by:
      getName in interface io.micronaut.cache.Cache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>
    • getNativeCache

      public io.lettuce.core.api.StatefulConnection<byte[],byte[]> getNativeCache()
      Specified by:
      getNativeCache in interface io.micronaut.cache.Cache<io.lettuce.core.api.StatefulConnection<byte[],byte[]>>