public interface RedissonClient
Modifier and Type | Method and Description |
---|---|
RBatch |
createBatch()
Return batch object which executes group of
command in pipeline.
|
RAtomicDouble |
getAtomicDouble(String name)
Returns atomicDouble instance by name.
|
RAtomicLong |
getAtomicLong(String name)
Returns atomicLong instance by name.
|
RBinaryStream |
getBinaryStream(String name)
Returns binary stream holder instance by
name |
RBitSet |
getBitSet(String name)
Returns bitSet instance by name.
|
<V> RBlockingDeque<V> |
getBlockingDeque(String name)
Returns unbounded blocking deque instance by name.
|
<V> RBlockingDeque<V> |
getBlockingDeque(String name,
Codec codec)
Returns unbounded blocking deque instance by name
using provided codec for deque objects.
|
<V> RBlockingQueue<V> |
getBlockingQueue(String name)
Returns unbounded blocking queue instance by name.
|
<V> RBlockingQueue<V> |
getBlockingQueue(String name,
Codec codec)
Returns unbounded blocking queue instance by name
using provided codec for queue objects.
|
<V> RBloomFilter<V> |
getBloomFilter(String name)
Returns bloom filter instance by name.
|
<V> RBloomFilter<V> |
getBloomFilter(String name,
Codec codec)
Returns bloom filter instance by name
using provided codec for objects.
|
<V> RBoundedBlockingQueue<V> |
getBoundedBlockingQueue(String name)
Returns bounded blocking queue instance by name.
|
<V> RBoundedBlockingQueue<V> |
getBoundedBlockingQueue(String name,
Codec codec)
Returns bounded blocking queue instance by name
using provided codec for queue objects.
|
<V> RBucket<V> |
getBucket(String name)
Returns object holder instance by name.
|
<V> RBucket<V> |
getBucket(String name,
Codec codec)
Returns object holder instance by name
using provided codec for object.
|
RBuckets |
getBuckets()
Returns interface for mass operations with Bucket objects.
|
RBuckets |
getBuckets(Codec codec)
Returns interface for mass operations with Bucket objects
using provided codec for object.
|
ClusterNodesGroup |
getClusterNodesGroup()
Get Redis cluster nodes group for server operations
|
ReferenceCodecProvider |
getCodecProvider()
Returns the CodecProvider instance
|
Config |
getConfig()
Allows to get configuration provided
during Redisson instance creation.
|
RCountDownLatch |
getCountDownLatch(String name)
Returns countDownLatch instance by name.
|
<V> RDelayedQueue<V> |
getDelayedQueue(RQueue<V> destinationQueue)
Returns unbounded delayed queue instance by name.
|
<V> RDeque<V> |
getDeque(String name)
Returns unbounded deque instance by name.
|
<V> RDeque<V> |
getDeque(String name,
Codec codec)
Returns unbounded deque instance by name
using provided codec for deque objects.
|
RScheduledExecutorService |
getExecutorService(Codec codec,
String name)
Deprecated.
- use
getExecutorService(String, Codec) instead. |
RScheduledExecutorService |
getExecutorService(String name)
Returns ScheduledExecutorService by name
|
RScheduledExecutorService |
getExecutorService(String name,
Codec codec)
Returns ScheduledExecutorService by name
using provided codec for task, response and request serialization
|
RLock |
getFairLock(String name)
Returns lock instance by name.
|
<V> RGeo<V> |
getGeo(String name)
Returns geospatial items holder instance by
name . |
<V> RGeo<V> |
getGeo(String name,
Codec codec)
Returns geospatial items holder instance by
name
using provided codec for geospatial members. |
<V> RHyperLogLog<V> |
getHyperLogLog(String name)
Returns HyperLogLog instance by name.
|
<V> RHyperLogLog<V> |
getHyperLogLog(String name,
Codec codec)
Returns HyperLogLog instance by name
using provided codec for hll objects.
|
RKeys |
getKeys()
Returns interface with methods for Redis keys.
|
RLexSortedSet |
getLexSortedSet(String name)
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
|
<V> RList<V> |
getList(String name)
Returns list instance by name.
|
<V> RList<V> |
getList(String name,
Codec codec)
Returns list instance by name
using provided codec for list objects.
|
<K,V> RListMultimap<K,V> |
getListMultimap(String name)
Returns List based Multimap instance by name.
|
<K,V> RListMultimap<K,V> |
getListMultimap(String name,
Codec codec)
Returns List based Multimap instance by name
using provided codec for both map keys and values.
|
<K,V> RListMultimapCache<K,V> |
getListMultimapCache(String name)
Returns List based Multimap instance by name.
|
<K,V> RListMultimapCache<K,V> |
getListMultimapCache(String name,
Codec codec)
Returns List based Multimap instance by name
using provided codec for both map keys and values.
|
RLiveObjectService |
getLiveObjectService()
Returns RedissonAttachedLiveObjectService which can be used to
retrieve live REntity(s)
|
<K,V> RLocalCachedMap<K,V> |
getLocalCachedMap(String name,
Codec codec,
LocalCachedMapOptions<K,V> options)
Returns local cached map instance by name
using provided codec.
|
<K,V> RLocalCachedMap<K,V> |
getLocalCachedMap(String name,
LocalCachedMapOptions<K,V> options)
Returns local cached map instance by name.
|
RLock |
getLock(String name)
Returns lock instance by name.
|
<K,V> RMap<K,V> |
getMap(String name)
Returns map instance by name.
|
<K,V> RMap<K,V> |
getMap(String name,
Codec codec)
Returns map instance by name
using provided codec for both map keys and values.
|
<K,V> RMap<K,V> |
getMap(String name,
Codec codec,
MapOptions<K,V> options)
Returns map instance by name
using provided codec for both map keys and values.
|
<K,V> RMap<K,V> |
getMap(String name,
MapOptions<K,V> options)
Returns map instance by name.
|
<K,V> RMapCache<K,V> |
getMapCache(String name)
Returns map-based cache instance by name.
|
<K,V> RMapCache<K,V> |
getMapCache(String name,
Codec codec)
Returns map-based cache instance by
name
using provided codec for both cache keys and values. |
<K,V> RMapCache<K,V> |
getMapCache(String name,
Codec codec,
MapOptions<K,V> options)
Returns map-based cache instance by
name
using provided codec for both cache keys and values. |
<K,V> RMapCache<K,V> |
getMapCache(String name,
MapOptions<K,V> options)
Returns map-based cache instance by name.
|
NodesGroup<Node> |
getNodesGroup()
Get Redis nodes group for server operations
|
<M> RPatternTopic<M> |
getPatternTopic(String pattern)
Returns topic instance satisfies by pattern name.
|
<M> RPatternTopic<M> |
getPatternTopic(String pattern,
Codec codec)
Returns topic instance satisfies by pattern name
using provided codec for messages.
|
RPermitExpirableSemaphore |
getPermitExpirableSemaphore(String name)
Returns semaphore instance by name.
|
<V> RPriorityDeque<V> |
getPriorityDeque(String name)
Returns priority unbounded deque instance by name.
|
<V> RPriorityDeque<V> |
getPriorityDeque(String name,
Codec codec)
Returns priority unbounded deque instance by name
using provided codec for queue objects.
|
<V> RPriorityQueue<V> |
getPriorityQueue(String name)
Returns priority unbounded queue instance by name.
|
<V> RPriorityQueue<V> |
getPriorityQueue(String name,
Codec codec)
Returns priority unbounded queue instance by name
using provided codec for queue objects.
|
<V> RQueue<V> |
getQueue(String name)
Returns unbounded queue instance by name.
|
<V> RQueue<V> |
getQueue(String name,
Codec codec)
Returns unbounded queue instance by name
using provided codec for queue objects.
|
RReadWriteLock |
getReadWriteLock(String name)
Returns readWriteLock instance by name.
|
RRemoteService |
getRemoteService()
Returns object for remote operations prefixed with the default name (redisson_remote_service)
|
RRemoteService |
getRemoteService(Codec codec)
Returns object for remote operations prefixed with the default name (redisson_remote_service)
and uses provided codec for method arguments and result.
|
RRemoteService |
getRemoteService(String name)
Returns object for remote operations prefixed with the specified name
|
RRemoteService |
getRemoteService(String name,
Codec codec)
Returns object for remote operations prefixed with the specified name
and uses provided codec for method arguments and result.
|
<V> RScoredSortedSet<V> |
getScoredSortedSet(String name)
Returns Redis Sorted Set instance by name.
|
<V> RScoredSortedSet<V> |
getScoredSortedSet(String name,
Codec codec)
Returns Redis Sorted Set instance by name
using provided codec for sorted set objects.
|
RScript |
getScript()
Returns script operations object
|
RSemaphore |
getSemaphore(String name)
Returns semaphore instance by name
|
<V> RSet<V> |
getSet(String name)
Returns set instance by name.
|
<V> RSet<V> |
getSet(String name,
Codec codec)
Returns set instance by name
using provided codec for set objects.
|
<V> RSetCache<V> |
getSetCache(String name)
Returns set-based cache instance by
name . |
<V> RSetCache<V> |
getSetCache(String name,
Codec codec)
Returns set-based cache instance by
name . |
<K,V> RSetMultimap<K,V> |
getSetMultimap(String name)
Returns Set based Multimap instance by name.
|
<K,V> RSetMultimap<K,V> |
getSetMultimap(String name,
Codec codec)
Returns Set based Multimap instance by name
using provided codec for both map keys and values.
|
<K,V> RSetMultimapCache<K,V> |
getSetMultimapCache(String name)
Returns Set based Multimap instance by name.
|
<K,V> RSetMultimapCache<K,V> |
getSetMultimapCache(String name,
Codec codec)
Returns Set based Multimap instance by name
using provided codec for both map keys and values.
|
<V> RSortedSet<V> |
getSortedSet(String name)
Returns sorted set instance by name.
|
<V> RSortedSet<V> |
getSortedSet(String name,
Codec codec)
Returns sorted set instance by name
using provided codec for sorted set objects.
|
<M> RTopic<M> |
getTopic(String name)
Returns topic instance by name.
|
<M> RTopic<M> |
getTopic(String name,
Codec codec)
Returns topic instance by name
using provided codec for messages.
|
boolean |
isShutdown()
Returns
true if this Redisson instance has been shut down. |
boolean |
isShuttingDown()
Returns
true if this Redisson instance was started to be shutdown
or was shutdown isShutdown() already. |
void |
shutdown()
Shutdown Redisson instance but NOT Redis server
This equates to invoke shutdown(2, 15, TimeUnit.SECONDS);
|
void |
shutdown(long quietPeriod,
long timeout,
TimeUnit unit)
Shuts down Redisson instance NOT Redis server
Shutdown ensures that no tasks are submitted for 'the quiet period'
(usually a couple seconds) before it shuts itself down.
|
RBinaryStream getBinaryStream(String name)
name
name
- of binary stream<V> RGeo<V> getGeo(String name)
name
.V
- type of valuename
- - name of object<V> RGeo<V> getGeo(String name, Codec codec)
name
using provided codec for geospatial members.V
- type of valuename
- - name of objectcodec
- - codec for value<V> RSetCache<V> getSetCache(String name)
name
.
Supports value eviction with a given TTL value.
If eviction is not required then it's better to use regular map getSet(String, Codec)
.
V
- type of valuename
- - name of object<V> RSetCache<V> getSetCache(String name, Codec codec)
name
.
Supports value eviction with a given TTL value.
If eviction is not required then it's better to use regular map getSet(String, Codec)
.
V
- type of valuename
- - name of objectcodec
- - codec for values<K,V> RMapCache<K,V> getMapCache(String name, Codec codec)
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 getMap(String, Codec)
.
K
- type of keyV
- type of valuename
- - object namecodec
- - codec for keys and values<K,V> RMapCache<K,V> getMapCache(String name, Codec codec, MapOptions<K,V> options)
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 getMap(String, Codec)
.
K
- type of keyV
- type of valuename
- - object namecodec
- - codec for keys and valuesoptions
- - map options<K,V> RMapCache<K,V> getMapCache(String name)
If eviction is not required then it's better to use regular map getMap(String)
.
K
- type of keyV
- type of valuename
- - name of object<K,V> RMapCache<K,V> getMapCache(String name, MapOptions<K,V> options)
If eviction is not required then it's better to use regular map getMap(String)
.
K
- type of keyV
- type of valuename
- - name of objectoptions
- - map options<V> RBucket<V> getBucket(String name)
V
- type of valuename
- - name of object<V> RBucket<V> getBucket(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for valuesRBuckets getBuckets()
RBuckets getBuckets(Codec codec)
codec
- - codec for bucket objects<V> RHyperLogLog<V> getHyperLogLog(String name)
V
- type of valuename
- - name of object<V> RHyperLogLog<V> getHyperLogLog(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for values<V> RList<V> getList(String name)
V
- type of valuename
- - name of object<V> RList<V> getList(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for values<K,V> RListMultimap<K,V> getListMultimap(String name)
K
- type of keyV
- type of valuename
- - name of object<K,V> RListMultimap<K,V> getListMultimap(String name, Codec codec)
K
- type of keyV
- type of valuename
- - name of objectcodec
- - codec for keys and values<K,V> RListMultimapCache<K,V> getListMultimapCache(String name)
If eviction is not required then it's better to use regular map getSetMultimap(String)
.
K
- type of keyV
- type of valuename
- - name of object<K,V> RListMultimapCache<K,V> getListMultimapCache(String name, Codec codec)
If eviction is not required then it's better to use regular map getSetMultimap(String, Codec)
.
K
- type of keyV
- type of valuename
- - name of objectcodec
- - codec for keys and values<K,V> RLocalCachedMap<K,V> getLocalCachedMap(String name, LocalCachedMapOptions<K,V> options)
K
- type of keyV
- type of valuename
- - name of objectoptions
- - local map options<K,V> RLocalCachedMap<K,V> getLocalCachedMap(String name, Codec codec, LocalCachedMapOptions<K,V> options)
K
- type of keyV
- type of valuename
- - name of objectcodec
- - codec for keys and valuesoptions
- - local map options<K,V> RMap<K,V> getMap(String name)
K
- type of keyV
- type of valuename
- - name of object<K,V> RMap<K,V> getMap(String name, MapOptions<K,V> options)
K
- type of keyV
- type of valuename
- - name of objectoptions
- - map options<K,V> RMap<K,V> getMap(String name, Codec codec)
K
- type of keyV
- type of valuename
- - name of objectcodec
- - codec for keys and values<K,V> RMap<K,V> getMap(String name, Codec codec, MapOptions<K,V> options)
K
- type of keyV
- type of valuename
- - name of objectcodec
- - codec for keys and valuesoptions
- - map options<K,V> RSetMultimap<K,V> getSetMultimap(String name)
K
- type of keyV
- type of valuename
- - name of object<K,V> RSetMultimap<K,V> getSetMultimap(String name, Codec codec)
K
- type of keyV
- type of valuename
- - name of objectcodec
- - codec for keys and values<K,V> RSetMultimapCache<K,V> getSetMultimapCache(String name)
If eviction is not required then it's better to use regular map getSetMultimap(String)
.
K
- type of keyV
- type of valuename
- - name of object<K,V> RSetMultimapCache<K,V> getSetMultimapCache(String name, Codec codec)
If eviction is not required then it's better to use regular map getSetMultimap(String, Codec)
.
K
- type of keyV
- type of valuename
- - name of objectcodec
- - codec for keys and valuesRSemaphore getSemaphore(String name)
name
- - name of objectRPermitExpirableSemaphore getPermitExpirableSemaphore(String name)
name
- - name of objectRLock getLock(String name)
Implements a non-fair locking so doesn't guarantees an acquire order by threads.
name
- - name of objectRLock getFairLock(String name)
Implements a fair locking so it guarantees an acquire order by threads.
name
- - name of objectRReadWriteLock getReadWriteLock(String name)
name
- - name of object<V> RSet<V> getSet(String name)
V
- type of valuename
- - name of object<V> RSet<V> getSet(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for values<V> RSortedSet<V> getSortedSet(String name)
V
- type of valuename
- - name of object<V> RSortedSet<V> getSortedSet(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for values<V> RScoredSortedSet<V> getScoredSortedSet(String name)
V
- type of valuename
- - name of object<V> RScoredSortedSet<V> getScoredSortedSet(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for valuesRLexSortedSet getLexSortedSet(String name)
name
- - name of object<M> RTopic<M> getTopic(String name)
M
- type of messagename
- - name of object<M> RTopic<M> getTopic(String name, Codec codec)
M
- type of messagename
- - name of objectcodec
- - codec for message<M> RPatternTopic<M> getPatternTopic(String pattern)
M
- type of messagepattern
- of the topic<M> RPatternTopic<M> getPatternTopic(String pattern, Codec codec)
M
- type of messagepattern
- of the topiccodec
- - codec for message<V> RQueue<V> getQueue(String name)
V
- type of valuename
- of object<V> RDelayedQueue<V> getDelayedQueue(RQueue<V> destinationQueue)
Could be attached to destination queue only. All elements are inserted with transfer delay to destination queue.
V
- type of valuedestinationQueue
- - destination queue<V> RQueue<V> getQueue(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for message<V> RPriorityQueue<V> getPriorityQueue(String name)
V
- type of valuename
- of object<V> RPriorityQueue<V> getPriorityQueue(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for message<V> RPriorityDeque<V> getPriorityDeque(String name)
V
- type of valuename
- of object<V> RPriorityDeque<V> getPriorityDeque(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for message<V> RBlockingQueue<V> getBlockingQueue(String name)
V
- type of valuename
- - name of object<V> RBlockingQueue<V> getBlockingQueue(String name, Codec codec)
V
- type of valuename
- - name of queuecodec
- - queue objects codec<V> RBoundedBlockingQueue<V> getBoundedBlockingQueue(String name)
V
- type of valuename
- of queue<V> RBoundedBlockingQueue<V> getBoundedBlockingQueue(String name, Codec codec)
V
- type of valuename
- - name of queuecodec
- - codec for values<V> RDeque<V> getDeque(String name)
V
- type of valuename
- - name of object<V> RDeque<V> getDeque(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for values<V> RBlockingDeque<V> getBlockingDeque(String name)
V
- type of valuename
- - name of object<V> RBlockingDeque<V> getBlockingDeque(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - deque objects codecRAtomicLong getAtomicLong(String name)
name
- - name of objectRAtomicDouble getAtomicDouble(String name)
name
- - name of objectRCountDownLatch getCountDownLatch(String name)
name
- - name of objectRBitSet getBitSet(String name)
name
- - name of object<V> RBloomFilter<V> getBloomFilter(String name)
V
- type of valuename
- - name of object<V> RBloomFilter<V> getBloomFilter(String name, Codec codec)
V
- type of valuename
- - name of objectcodec
- - codec for valuesRScript getScript()
RScheduledExecutorService getExecutorService(String name)
name
- - name of object@Deprecated RScheduledExecutorService getExecutorService(Codec codec, String name)
getExecutorService(String, Codec)
instead.name
- - name of objectcodec
- - codec for task, response and requestRScheduledExecutorService getExecutorService(String name, Codec codec)
name
- - name of objectcodec
- - codec for task, response and requestRRemoteService getRemoteService()
RRemoteService getRemoteService(Codec codec)
codec
- - codec for response and requestRRemoteService getRemoteService(String name)
name
- - the name used as the Redis key prefix for the servicesRRemoteService getRemoteService(String name, Codec codec)
name
- - the name used as the Redis key prefix for the servicescodec
- - codec for response and requestRBatch createBatch()
RKeys getKeys()
RLiveObjectService getLiveObjectService()
void shutdown()
void shutdown(long quietPeriod, long timeout, TimeUnit unit)
quietPeriod
- the quiet period as described in the documentationtimeout
- the maximum amount of time to wait until the executor is shutdown()
regardless if a task was submitted during the quiet periodunit
- the unit of quietPeriod
and timeout
Config getConfig()
ReferenceCodecProvider getCodecProvider()
NodesGroup<Node> getNodesGroup()
ClusterNodesGroup getClusterNodesGroup()
boolean isShutdown()
true
if this Redisson instance has been shut down.false
boolean isShuttingDown()
true
if this Redisson instance was started to be shutdown
or was shutdown isShutdown()
already.true
if this Redisson instance was started to be shutdown
or was shutdown isShutdown()
already.Copyright © 2014–2017 The Redisson Project. All rights reserved.