Package org.redisson

Class Redisson

  • All Implemented Interfaces:
    RedissonClient

    public class Redisson
    extends Object
    implements RedissonClient
    Main infrastructure class allows to get access to all Redisson objects on top of Redis server.
    Author:
    Nikita Koksharov
    • Constructor Detail

      • Redisson

        protected Redisson​(Config config)
    • Method Detail

      • create

        public static RedissonClient create()
        Create sync/async Redisson instance with default config
        Returns:
        Redisson instance
      • create

        public static RedissonClient create​(Config config)
        Create sync/async Redisson instance with provided config
        Parameters:
        config - for Redisson
        Returns:
        Redisson instance
      • createRx

        public static RedissonRxClient createRx()
        Create Reactive Redisson instance with default config
        Returns:
        Redisson instance
      • createRx

        public static RedissonRxClient createRx​(Config config)
        Create Reactive Redisson instance with provided config
        Parameters:
        config - for Redisson
        Returns:
        Redisson instance
      • createReactive

        public static RedissonReactiveClient createReactive()
        Create Reactive Redisson instance with default config
        Returns:
        Redisson instance
      • createReactive

        public static RedissonReactiveClient createReactive​(Config config)
        Create Reactive Redisson instance with provided config
        Parameters:
        config - for Redisson
        Returns:
        Redisson instance
      • getStream

        public <K,​V> RStream<K,​V> getStream​(String name)
        Description copied from interface: RedissonClient
        Returns stream instance by name

        Requires Redis 5.0.0 and higher.

        Specified by:
        getStream in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - of stream
        Returns:
        RStream object
      • getStream

        public <K,​V> RStream<K,​V> getStream​(String name,
                                                        Codec codec)
        Description copied from interface: RedissonClient
        Returns stream instance by name using provided codec for entries.

        Requires Redis 5.0.0 and higher.

        Specified by:
        getStream in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of stream
        codec - - codec for entry
        Returns:
        RStream object
      • getGeo

        public <V> RGeo<V> getGeo​(String name)
        Description copied from interface: RedissonClient
        Returns geospatial items holder instance by name.
        Specified by:
        getGeo in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        Geo object
      • getGeo

        public <V> RGeo<V> getGeo​(String name,
                                  Codec codec)
        Description copied from interface: RedissonClient
        Returns geospatial items holder instance by name using provided codec for geospatial members.
        Specified by:
        getGeo in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for value
        Returns:
        Geo object
      • getBucket

        public <V> RBucket<V> getBucket​(String name)
        Description copied from interface: RedissonClient
        Returns object holder instance by name.
        Specified by:
        getBucket in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        Bucket object
      • getBucket

        public <V> RBucket<V> getBucket​(String name,
                                        Codec codec)
        Description copied from interface: RedissonClient
        Returns object holder instance by name using provided codec for object.
        Specified by:
        getBucket in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        Bucket object
      • getBuckets

        public RBuckets getBuckets​(Codec codec)
        Description copied from interface: RedissonClient
        Returns interface for mass operations with Bucket objects using provided codec for object.
        Specified by:
        getBuckets in interface RedissonClient
        Parameters:
        codec - - codec for bucket objects
        Returns:
        Buckets
      • getHyperLogLog

        public <V> RHyperLogLog<V> getHyperLogLog​(String name)
        Description copied from interface: RedissonClient
        Returns HyperLogLog instance by name.
        Specified by:
        getHyperLogLog in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        HyperLogLog object
      • getHyperLogLog

        public <V> RHyperLogLog<V> getHyperLogLog​(String name,
                                                  Codec codec)
        Description copied from interface: RedissonClient
        Returns HyperLogLog instance by name using provided codec for hll objects.
        Specified by:
        getHyperLogLog in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        HyperLogLog object
      • getList

        public <V> RList<V> getList​(String name)
        Description copied from interface: RedissonClient
        Returns list instance by name.
        Specified by:
        getList in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        List object
      • getList

        public <V> RList<V> getList​(String name,
                                    Codec codec)
        Description copied from interface: RedissonClient
        Returns list instance by name using provided codec for list objects.
        Specified by:
        getList in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        List object
      • getListMultimap

        public <K,​V> RListMultimap<K,​V> getListMultimap​(String name)
        Description copied from interface: RedissonClient
        Returns List based Multimap instance by name.
        Specified by:
        getListMultimap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        ListMultimap object
      • getListMultimap

        public <K,​V> RListMultimap<K,​V> getListMultimap​(String name,
                                                                    Codec codec)
        Description copied from interface: RedissonClient
        Returns List based Multimap instance by name using provided codec for both map keys and values.
        Specified by:
        getListMultimap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for keys and values
        Returns:
        ListMultimap object
      • getLocalCachedMap

        public <K,​V> RLocalCachedMap<K,​V> getLocalCachedMap​(String name,
                                                                        LocalCachedMapOptions<K,​V> options)
        Description copied from interface: RedissonClient
        Returns local cached map instance by name. Configured by parameters of options-object.
        Specified by:
        getLocalCachedMap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        options - - local map options
        Returns:
        LocalCachedMap object
      • getLocalCachedMap

        public <K,​V> RLocalCachedMap<K,​V> getLocalCachedMap​(String name,
                                                                        Codec codec,
                                                                        LocalCachedMapOptions<K,​V> options)
        Description copied from interface: RedissonClient
        Returns local cached map instance by name using provided codec. Configured by parameters of options-object.
        Specified by:
        getLocalCachedMap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for keys and values
        options - - local map options
        Returns:
        LocalCachedMap object
      • getMap

        public <K,​V> RMap<K,​V> getMap​(String name)
        Description copied from interface: RedissonClient
        Returns map instance by name.
        Specified by:
        getMap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        Map object
      • getMap

        public <K,​V> RMap<K,​V> getMap​(String name,
                                                  MapOptions<K,​V> options)
        Description copied from interface: RedissonClient
        Returns map instance by name.
        Specified by:
        getMap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        options - - map options
        Returns:
        Map object
      • getSetMultimap

        public <K,​V> RSetMultimap<K,​V> getSetMultimap​(String name)
        Description copied from interface: RedissonClient
        Returns Set based Multimap instance by name.
        Specified by:
        getSetMultimap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        SetMultimap object
      • getSetMultimapCache

        public <K,​V> RSetMultimapCache<K,​V> getSetMultimapCache​(String name)
        Description copied from interface: RedissonClient
        Returns Set based Multimap instance by name. Supports key-entry eviction with a given TTL value.

        If eviction is not required then it's better to use regular map RedissonClient.getSetMultimap(String).

        Specified by:
        getSetMultimapCache in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        SetMultimapCache object
      • getSetMultimapCache

        public <K,​V> RSetMultimapCache<K,​V> getSetMultimapCache​(String name,
                                                                            Codec codec)
        Description copied from interface: RedissonClient
        Returns Set based Multimap instance by name using provided codec for both map keys and values. Supports key-entry eviction with a given TTL value.

        If eviction is not required then it's better to use regular map RedissonClient.getSetMultimap(String, Codec).

        Specified by:
        getSetMultimapCache in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for keys and values
        Returns:
        SetMultimapCache object
      • getListMultimapCache

        public <K,​V> RListMultimapCache<K,​V> getListMultimapCache​(String name,
                                                                              Codec codec)
        Description copied from interface: RedissonClient
        Returns List based Multimap instance by name using provided codec for both map keys and values. Supports key-entry eviction with a given TTL value.

        If eviction is not required then it's better to use regular map RedissonClient.getSetMultimap(String, Codec).

        Specified by:
        getListMultimapCache in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for keys and values
        Returns:
        ListMultimapCache object
      • getSetMultimap

        public <K,​V> RSetMultimap<K,​V> getSetMultimap​(String name,
                                                                  Codec codec)
        Description copied from interface: RedissonClient
        Returns Set based Multimap instance by name using provided codec for both map keys and values.
        Specified by:
        getSetMultimap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for keys and values
        Returns:
        SetMultimap object
      • getSetCache

        public <V> RSetCache<V> getSetCache​(String name)
        Description copied from interface: RedissonClient
        Returns set-based cache instance by name. Supports value eviction with a given TTL value.

        If eviction is not required then it's better to use regular map RedissonClient.getSet(String, Codec).

        Specified by:
        getSetCache in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        SetCache object
      • getSetCache

        public <V> RSetCache<V> getSetCache​(String name,
                                            Codec codec)
        Description copied from interface: RedissonClient
        Returns set-based cache instance by name. Supports value eviction with a given TTL value.

        If eviction is not required then it's better to use regular map RedissonClient.getSet(String, Codec).

        Specified by:
        getSetCache in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        SetCache object
      • getMapCache

        public <K,​V> RMapCache<K,​V> getMapCache​(String name)
        Description copied from interface: RedissonClient
        Returns map-based cache instance by name. Supports entry eviction with a given MaxIdleTime and TTL settings.

        If eviction is not required then it's better to use regular map RedissonClient.getMap(String).

        Specified by:
        getMapCache in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        MapCache object
      • getMapCache

        public <K,​V> RMapCache<K,​V> getMapCache​(String name,
                                                            MapOptions<K,​V> options)
        Description copied from interface: RedissonClient
        Returns map-based cache instance by name. Supports entry eviction with a given MaxIdleTime and TTL settings.

        If eviction is not required then it's better to use regular map RedissonClient.getMap(String).

        Specified by:
        getMapCache in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        options - - map options
        Returns:
        MapCache object
      • getMapCache

        public <K,​V> RMapCache<K,​V> getMapCache​(String name,
                                                            Codec codec)
        Description copied from interface: RedissonClient
        Returns map-based cache instance by name using provided codec for both cache keys and values. Supports entry eviction with a given MaxIdleTime and TTL settings.

        If eviction is not required then it's better to use regular map RedissonClient.getMap(String, Codec).

        Specified by:
        getMapCache in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - object name
        codec - - codec for keys and values
        Returns:
        MapCache object
      • getMapCache

        public <K,​V> RMapCache<K,​V> getMapCache​(String name,
                                                            Codec codec,
                                                            MapOptions<K,​V> options)
        Description copied from interface: RedissonClient
        Returns map-based cache instance by name using provided codec for both cache keys and values. Supports entry eviction with a given MaxIdleTime and TTL settings.

        If eviction is not required then it's better to use regular map RedissonClient.getMap(String, Codec).

        Specified by:
        getMapCache in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - object name
        codec - - codec for keys and values
        options - - map options
        Returns:
        MapCache object
      • getMap

        public <K,​V> RMap<K,​V> getMap​(String name,
                                                  Codec codec)
        Description copied from interface: RedissonClient
        Returns map instance by name using provided codec for both map keys and values.
        Specified by:
        getMap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for keys and values
        Returns:
        Map object
      • getMap

        public <K,​V> RMap<K,​V> getMap​(String name,
                                                  Codec codec,
                                                  MapOptions<K,​V> options)
        Description copied from interface: RedissonClient
        Returns map instance by name using provided codec for both map keys and values.
        Specified by:
        getMap in interface RedissonClient
        Type Parameters:
        K - type of key
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for keys and values
        options - - map options
        Returns:
        Map object
      • getLock

        public RLock getLock​(String name)
        Description copied from interface: RedissonClient
        Returns lock instance by name.

        Implements a non-fair locking so doesn't guarantees an acquire order by threads.

        Specified by:
        getLock in interface RedissonClient
        Parameters:
        name - - name of object
        Returns:
        Lock object
      • getFairLock

        public RLock getFairLock​(String name)
        Description copied from interface: RedissonClient
        Returns lock instance by name.

        Implements a fair locking so it guarantees an acquire order by threads.

        Specified by:
        getFairLock in interface RedissonClient
        Parameters:
        name - - name of object
        Returns:
        Lock object
      • getSet

        public <V> RSet<V> getSet​(String name)
        Description copied from interface: RedissonClient
        Returns set instance by name.
        Specified by:
        getSet in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        Set object
      • getSet

        public <V> RSet<V> getSet​(String name,
                                  Codec codec)
        Description copied from interface: RedissonClient
        Returns set instance by name using provided codec for set objects.
        Specified by:
        getSet in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        Set object
      • getScript

        public RScript getScript​(Codec codec)
        Description copied from interface: RedissonClient
        Returns script operations object using provided codec.
        Specified by:
        getScript in interface RedissonClient
        Parameters:
        codec - - codec for params and result
        Returns:
        Script object
      • getExecutorService

        @Deprecated
        public RScheduledExecutorService getExecutorService​(Codec codec,
                                                            String name)
        Deprecated.
        Description copied from interface: RedissonClient
        Returns ScheduledExecutorService by name using provided codec for task, response and request serialization Please use getExecutorService(String name, Codec codec) method instead.
        Specified by:
        getExecutorService in interface RedissonClient
        Parameters:
        codec - - codec for task, response and request
        name - - name of object
        Returns:
        ScheduledExecutorService object
      • getExecutorService

        public RScheduledExecutorService getExecutorService​(String name,
                                                            Codec codec)
        Description copied from interface: RedissonClient
        Returns ScheduledExecutorService by name using provided codec for task, response and request serialization
        Specified by:
        getExecutorService in interface RedissonClient
        Parameters:
        name - - name of object
        codec - - codec for task, response and request
        Returns:
        ScheduledExecutorService object
      • getExecutorService

        public RScheduledExecutorService getExecutorService​(String name,
                                                            Codec codec,
                                                            ExecutorOptions options)
        Description copied from interface: RedissonClient
        Returns ScheduledExecutorService by name using provided codec for task, response and request serialization
        Specified by:
        getExecutorService in interface RedissonClient
        Parameters:
        name - - name of object
        codec - - codec for task, response and request
        options - - options for executor
        Returns:
        ScheduledExecutorService object
      • getRemoteService

        public RRemoteService getRemoteService()
        Description copied from interface: RedissonClient
        Returns object for remote operations prefixed with the default name (redisson_remote_service)
        Specified by:
        getRemoteService in interface RedissonClient
        Returns:
        RemoteService object
      • getRemoteService

        public RRemoteService getRemoteService​(String name)
        Description copied from interface: RedissonClient
        Returns object for remote operations prefixed with the specified name
        Specified by:
        getRemoteService in interface RedissonClient
        Parameters:
        name - - the name used as the Redis key prefix for the services
        Returns:
        RemoteService object
      • getRemoteService

        public RRemoteService getRemoteService​(Codec codec)
        Description copied from interface: RedissonClient
        Returns object for remote operations prefixed with the default name (redisson_remote_service) and uses provided codec for method arguments and result.
        Specified by:
        getRemoteService in interface RedissonClient
        Parameters:
        codec - - codec for response and request
        Returns:
        RemoteService object
      • getRemoteService

        public RRemoteService getRemoteService​(String name,
                                               Codec codec)
        Description copied from interface: RedissonClient
        Returns object for remote operations prefixed with the specified name and uses provided codec for method arguments and result.
        Specified by:
        getRemoteService in interface RedissonClient
        Parameters:
        name - - the name used as the Redis key prefix for the services
        codec - - codec for response and request
        Returns:
        RemoteService object
      • getSortedSet

        public <V> RSortedSet<V> getSortedSet​(String name)
        Description copied from interface: RedissonClient
        Returns sorted set instance by name. This sorted set uses comparator to sort objects.
        Specified by:
        getSortedSet in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        SortedSet object
      • getSortedSet

        public <V> RSortedSet<V> getSortedSet​(String name,
                                              Codec codec)
        Description copied from interface: RedissonClient
        Returns sorted set instance by name using provided codec for sorted set objects. This sorted set sorts objects using comparator.
        Specified by:
        getSortedSet in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        SortedSet object
      • getScoredSortedSet

        public <V> RScoredSortedSet<V> getScoredSortedSet​(String name)
        Description copied from interface: RedissonClient
        Returns Redis Sorted Set instance by name. This sorted set sorts objects by object score.
        Specified by:
        getScoredSortedSet in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        ScoredSortedSet object
      • getScoredSortedSet

        public <V> RScoredSortedSet<V> getScoredSortedSet​(String name,
                                                          Codec codec)
        Description copied from interface: RedissonClient
        Returns Redis Sorted Set instance by name using provided codec for sorted set objects. This sorted set sorts objects by object score.
        Specified by:
        getScoredSortedSet in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        ScoredSortedSet object
      • getLexSortedSet

        public RLexSortedSet getLexSortedSet​(String name)
        Description copied from interface: RedissonClient
        Returns String based Redis Sorted Set instance by name All elements are inserted with the same score during addition, in order to force lexicographical ordering
        Specified by:
        getLexSortedSet in interface RedissonClient
        Parameters:
        name - - name of object
        Returns:
        LexSortedSet object
      • getTopic

        public RTopic getTopic​(String name)
        Description copied from interface: RedissonClient
        Returns topic instance by name.
        Specified by:
        getTopic in interface RedissonClient
        Parameters:
        name - - name of object
        Returns:
        Topic object
      • getTopic

        public RTopic getTopic​(String name,
                               Codec codec)
        Description copied from interface: RedissonClient
        Returns topic instance by name using provided codec for messages.
        Specified by:
        getTopic in interface RedissonClient
        Parameters:
        name - - name of object
        codec - - codec for message
        Returns:
        Topic object
      • getPatternTopic

        public RPatternTopic getPatternTopic​(String pattern)
        Description copied from interface: RedissonClient
        Returns topic instance satisfies by pattern name. Supported glob-style patterns: h?llo subscribes to hello, hallo and hxllo h*llo subscribes to hllo and heeeello h[ae]llo subscribes to hello and hallo, but not hillo
        Specified by:
        getPatternTopic in interface RedissonClient
        Parameters:
        pattern - of the topic
        Returns:
        PatterTopic object
      • getPatternTopic

        public RPatternTopic getPatternTopic​(String pattern,
                                             Codec codec)
        Description copied from interface: RedissonClient
        Returns topic instance satisfies by pattern name using provided codec for messages. Supported glob-style patterns: h?llo subscribes to hello, hallo and hxllo h*llo subscribes to hllo and heeeello h[ae]llo subscribes to hello and hallo, but not hillo
        Specified by:
        getPatternTopic in interface RedissonClient
        Parameters:
        pattern - of the topic
        codec - - codec for message
        Returns:
        PatterTopic object
      • getDelayedQueue

        public <V> RDelayedQueue<V> getDelayedQueue​(RQueue<V> destinationQueue)
        Description copied from interface: RedissonClient
        Returns unbounded delayed queue instance by name.

        Could be attached to destination queue only. All elements are inserted with transfer delay to destination queue.

        Specified by:
        getDelayedQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        destinationQueue - - destination queue
        Returns:
        Delayed queue object
      • getQueue

        public <V> RQueue<V> getQueue​(String name)
        Description copied from interface: RedissonClient
        Returns unbounded queue instance by name.
        Specified by:
        getQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - of object
        Returns:
        queue object
      • getQueue

        public <V> RQueue<V> getQueue​(String name,
                                      Codec codec)
        Description copied from interface: RedissonClient
        Returns unbounded queue instance by name using provided codec for queue objects.
        Specified by:
        getQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for message
        Returns:
        Queue object
      • getBlockingQueue

        public <V> RBlockingQueue<V> getBlockingQueue​(String name)
        Description copied from interface: RedissonClient
        Returns unbounded blocking queue instance by name.
        Specified by:
        getBlockingQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        BlockingQueue object
      • getBlockingQueue

        public <V> RBlockingQueue<V> getBlockingQueue​(String name,
                                                      Codec codec)
        Description copied from interface: RedissonClient
        Returns unbounded blocking queue instance by name using provided codec for queue objects.
        Specified by:
        getBlockingQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of queue
        codec - - queue objects codec
        Returns:
        BlockingQueue object
      • getBoundedBlockingQueue

        public <V> RBoundedBlockingQueue<V> getBoundedBlockingQueue​(String name,
                                                                    Codec codec)
        Description copied from interface: RedissonClient
        Returns bounded blocking queue instance by name using provided codec for queue objects.
        Specified by:
        getBoundedBlockingQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of queue
        codec - - codec for values
        Returns:
        BoundedBlockingQueue object
      • getDeque

        public <V> RDeque<V> getDeque​(String name)
        Description copied from interface: RedissonClient
        Returns unbounded deque instance by name.
        Specified by:
        getDeque in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        Deque object
      • getDeque

        public <V> RDeque<V> getDeque​(String name,
                                      Codec codec)
        Description copied from interface: RedissonClient
        Returns unbounded deque instance by name using provided codec for deque objects.
        Specified by:
        getDeque in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        Deque object
      • getBlockingDeque

        public <V> RBlockingDeque<V> getBlockingDeque​(String name)
        Description copied from interface: RedissonClient
        Returns unbounded blocking deque instance by name.
        Specified by:
        getBlockingDeque in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        BlockingDeque object
      • getBlockingDeque

        public <V> RBlockingDeque<V> getBlockingDeque​(String name,
                                                      Codec codec)
        Description copied from interface: RedissonClient
        Returns unbounded blocking deque instance by name using provided codec for deque objects.
        Specified by:
        getBlockingDeque in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - deque objects codec
        Returns:
        BlockingDeque object
      • getBitSet

        public RBitSet getBitSet​(String name)
        Description copied from interface: RedissonClient
        Returns bitSet instance by name.
        Specified by:
        getBitSet in interface RedissonClient
        Parameters:
        name - - name of object
        Returns:
        BitSet object
      • getBloomFilter

        public <V> RBloomFilter<V> getBloomFilter​(String name)
        Description copied from interface: RedissonClient
        Returns bloom filter instance by name.
        Specified by:
        getBloomFilter in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        Returns:
        BloomFilter object
      • getBloomFilter

        public <V> RBloomFilter<V> getBloomFilter​(String name,
                                                  Codec codec)
        Description copied from interface: RedissonClient
        Returns bloom filter instance by name using provided codec for objects.
        Specified by:
        getBloomFilter in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for values
        Returns:
        BloomFilter object
      • getKeys

        public RKeys getKeys()
        Description copied from interface: RedissonClient
        Returns interface with methods for Redis keys. Each of Redis/Redisson object associated with own key
        Specified by:
        getKeys in interface RedissonClient
        Returns:
        Keys object
      • shutdown

        public void shutdown()
        Description copied from interface: RedissonClient
        Shutdown Redisson instance but NOT Redis server This equates to invoke shutdown(0, 2, TimeUnit.SECONDS);
        Specified by:
        shutdown in interface RedissonClient
      • shutdown

        public void shutdown​(long quietPeriod,
                             long timeout,
                             TimeUnit unit)
        Description copied from interface: RedissonClient
        Shuts down Redisson instance but NOT Redis server Shutdown ensures that no tasks are submitted for 'the quiet period' (usually a couple seconds) before it shuts itself down. If a task is submitted during the quiet period, it is guaranteed to be accepted and the quiet period will start over.
        Specified by:
        shutdown in interface RedissonClient
        Parameters:
        quietPeriod - the quiet period as described in the documentation
        timeout - the maximum amount of time to wait until the executor is RedissonClient.shutdown() regardless if a task was submitted during the quiet period
        unit - the unit of quietPeriod and timeout
      • getConfig

        public Config getConfig()
        Description copied from interface: RedissonClient
        Allows to get configuration provided during Redisson instance creation. Further changes on this object not affect Redisson instance.
        Specified by:
        getConfig in interface RedissonClient
        Returns:
        Config object
      • isShutdown

        public boolean isShutdown()
        Description copied from interface: RedissonClient
        Returns true if this Redisson instance has been shut down.
        Specified by:
        isShutdown in interface RedissonClient
        Returns:
        true if this Redisson instance has been shut down overwise false
      • enableRedissonReferenceSupport

        protected void enableRedissonReferenceSupport()
      • getPriorityQueue

        public <V> RPriorityQueue<V> getPriorityQueue​(String name)
        Description copied from interface: RedissonClient
        Returns priority unbounded queue instance by name. It uses comparator to sort objects.
        Specified by:
        getPriorityQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - of object
        Returns:
        Queue object
      • getPriorityQueue

        public <V> RPriorityQueue<V> getPriorityQueue​(String name,
                                                      Codec codec)
        Description copied from interface: RedissonClient
        Returns priority unbounded queue instance by name using provided codec for queue objects. It uses comparator to sort objects.
        Specified by:
        getPriorityQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for message
        Returns:
        Queue object
      • getPriorityBlockingQueue

        public <V> RPriorityBlockingQueue<V> getPriorityBlockingQueue​(String name)
        Description copied from interface: RedissonClient
        Returns unbounded priority blocking queue instance by name. It uses comparator to sort objects.
        Specified by:
        getPriorityBlockingQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - of object
        Returns:
        Queue object
      • getPriorityBlockingQueue

        public <V> RPriorityBlockingQueue<V> getPriorityBlockingQueue​(String name,
                                                                      Codec codec)
        Description copied from interface: RedissonClient
        Returns unbounded priority blocking queue instance by name using provided codec for queue objects. It uses comparator to sort objects.
        Specified by:
        getPriorityBlockingQueue in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for message
        Returns:
        Queue object
      • getPriorityBlockingDeque

        public <V> RPriorityBlockingDeque<V> getPriorityBlockingDeque​(String name)
        Description copied from interface: RedissonClient
        Returns unbounded priority blocking deque instance by name. It uses comparator to sort objects.
        Specified by:
        getPriorityBlockingDeque in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - of object
        Returns:
        Queue object
      • getPriorityBlockingDeque

        public <V> RPriorityBlockingDeque<V> getPriorityBlockingDeque​(String name,
                                                                      Codec codec)
        Description copied from interface: RedissonClient
        Returns unbounded priority blocking deque instance by name using provided codec for queue objects. It uses comparator to sort objects.
        Specified by:
        getPriorityBlockingDeque in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for message
        Returns:
        Queue object
      • getPriorityDeque

        public <V> RPriorityDeque<V> getPriorityDeque​(String name)
        Description copied from interface: RedissonClient
        Returns priority unbounded deque instance by name. It uses comparator to sort objects.
        Specified by:
        getPriorityDeque in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - of object
        Returns:
        Queue object
      • getPriorityDeque

        public <V> RPriorityDeque<V> getPriorityDeque​(String name,
                                                      Codec codec)
        Description copied from interface: RedissonClient
        Returns priority unbounded deque instance by name using provided codec for queue objects. It uses comparator to sort objects.
        Specified by:
        getPriorityDeque in interface RedissonClient
        Type Parameters:
        V - type of value
        Parameters:
        name - - name of object
        codec - - codec for message
        Returns:
        Queue object