You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
redisson/README.md

220 lines
11 KiB
Markdown

11 years ago
##Redisson - distributed and scalable Java data structures on top of Redis server. Advanced Redis client
11 years ago
11 years ago
Use familiar Java data structures with power of [Redis](http://redis.io).
10 years ago
Based on high-performance async and lock-free Redis client and [Netty 4](http://netty.io) framework.
10 years ago
Redis 2.8+ and JDK 1.6+ compatible
11 years ago
11 years ago
Read [wiki](https://github.com/mrniko/redisson/wiki) for more Redisson usage details
11 years ago
Licensed under the Apache License 2.0.
Features
================================
10 years ago
* Cluster servers mode:
1. automatic master discovery
2. automatic new master server discovery
3. automatic slots change discovery
11 years ago
* Sentinel servers mode:
11 years ago
1. automatic master and slave servers discovery
2. automatic new master server discovery
3. automatic new slave servers discovery
4. automatic slave servers offline/online discovery
11 years ago
5. read data using slave servers, write data using master server
* Master with Slave servers mode: read data using slave servers, write data using master server
11 years ago
* Single server mode: read and write data using single server
11 years ago
* Distributed implementation of `java.util.List`
* Distributed implementation of `java.util.Set`
11 years ago
* Distributed implementation of `java.util.SortedSet`
11 years ago
* Distributed implementation of `java.util.Queue`
10 years ago
* Distributed implementation of `java.util.concurrent.BlockingQueue`
11 years ago
* Distributed implementation of `java.util.Deque`
11 years ago
* Distributed implementation of `java.util.Map`
* Distributed implementation of `java.util.concurrent.ConcurrentMap`
11 years ago
* Distributed implementation of reentrant `java.util.concurrent.locks.Lock` with TTL support
11 years ago
* Distributed alternative to the `java.util.concurrent.atomic.AtomicLong`
* Distributed alternative to the `java.util.concurrent.CountDownLatch`
11 years ago
* Distributed publish/subscribe messaging via `org.redisson.core.RTopic`
* Distributed HyperLogLog via `org.redisson.core.RHyperLogLog`
10 years ago
* Thread-safe implementation
* Support Redis pipeline (command batches)
11 years ago
* Supports OSGi
10 years ago
* With over 210 unit tests
11 years ago
10 years ago
Projects using Redisson
================================
10 years ago
Setronica: [setronica.com](http://setronica.com/)
10 years ago
Monits: [monits.com](http://monits.com/)
10 years ago
Brookhaven National Laboratory: [bnl.gov](http://bnl.gov/)
10 years ago
Netflix Dyno client: [dyno] (https://github.com/Netflix/dyno)
11 years ago
Recent Releases
================================
####Please Note: trunk is current development branch.
10 years ago
####26-Jul-2015 - version 2.0.0 released
Starting from 2.0.0 version Redisson has a new own async and lock-free Redis client under the hood. Thanks to the new architecture pipline (command batches) support has been implemented and a lot of code has gone.
10 years ago
10 years ago
Feature - new async interfaces - `RAsyncMap`, `RAtomicLongAsync`, `RBlockingQueueAsync`, `RCollectionAsync`, `RDequeAsync`, `RExpirableAsync`, `RHyperLogLogAsync`, `RListAsync`, `RObjectAsync`, `RQueueAsync`, `RScriptAsync`, `RSetAsync`, `RTopicAsync`
10 years ago
Feature - command batches (Redis pipeline) support via `Redisson.createBatch` method
10 years ago
Feature - new methods `flushall`, `deleteAsync`, `delete`, `deleteByPatternAsync`, `deleteByPattern`, `findKeysByPatternAsync`, `findKeysByPattern` added to `RedissonClient` interface
10 years ago
10 years ago
####22-Jul-2015 - version 1.3.1 released
Fixed - requests state sync during shutdown
Fixed - netty-transport-native-epoll is now has a provided scope
Fixed - NPE during `BlockingQueue.poll` invocation
10 years ago
####04-Jul-2015 - version 1.3.0 released
10 years ago
Feature - `RQueue.pollLastAndOfferFirstTo` method added
Feature - `RObject.rename`, `RObject.renameAsync`, `RObject.renamenx`, `RObject.renamenxAsync` methods added
Feature - `RList.getAsync`, `RList.addAsync`, `RList.addAllAsync` methods added
Feature - `RObject.deleteAsync` method added
Feature - unix sockets support via `Configuration.useLinuxNativeEpoll` setting
10 years ago
Feature - `Redisson.getTopicPattern` method added (thanks to alex-sherwin)
10 years ago
Improvement - `RLock` auto-unlock then client lock-owner is gone (thanks to AndrewKolpakov)
10 years ago
Improvement - lua scripts used instead of multi/exec commands to avoid connection errors during execution (thanks to AndrewKolpakov)
Improvement - `RObject.delete` method now returns `boolean` status
Improvement - propagate Command processing exceptions to ConnectionManager (thanks to marko-stankovic)
Improvement - KryoCodec classes registration ability added
Fixed - slave status handling in Sentinel mode
Fixed - String codec
Fixed - Cluster ASKING command support
Fixed - `RedissonBlockingQueue#drainTo` method (thanks to Sergey Poletaev)
Fixed - Cluster.STATE.HANDSHAKE enum added
Fixed - `RedissonClient.getScript` method added
Fixed - `BlockingQueue.poll` method
Fixed - Incorrect map key encoding makes hmget return no fields when string keys are used (thanks to sammiq)
10 years ago
####02-Apr-2015 - version 1.2.1 released
Feature - all redis-script commands via 'RScript' object
10 years ago
Feature - implementation of `java.util.concurrent.BlockingQueue` (thanks to pdeschen)
Feature - buckets load by pattern (thanks to mathieucarbou)
Improvement - IPv6 support
10 years ago
Improvement - `isEmpty` checks for added collections
10 years ago
Fixed - KryoCodec keys decoding (thanks to mathieucarbou)
Fixed - `RMap.addAndGet()` data format
10 years ago
Fixed - timeout support in cluster, sentinel and single connections configurations
10 years ago
Fixed - ClassCastException in `RedissonCountDownLatch.trySetCount`
10 years ago
Fixed - `RMap.replace` concurrency issue (thanks to AndrewKolpakov)
Fixed - `RLock` subscription timeout units fixed (thanks to AndrewKolpakov)
10 years ago
Fixed - Re-throw async exceptions (thanks to AndrewKolpakov)
10 years ago
10 years ago
####09-Jan-2015 - version 1.2.0 released
10 years ago
Feature - cluster mode support
Fixed - `RList` iterator race conditions
10 years ago
Fixed - `RDeque.addFirst` `RDeque.addLast` methods
10 years ago
Fixed - OSGi support
10 years ago
####16-Dec-2014 - version 1.1.7 released
Improvement - `RAtomicLong` optimization
Fixed - `RMap.fastRemove` and `RMap.getAll` methods
Fixed - `RTopic` listeners re-subscribing in sentinel mode
Fixed - `RSet.toArray` and `RSet.iterator` values order
Fixed - keys iteration in `RMap.getAll`
Fixed - `RSet` iteration
Fixed - `RAtomicLong` NPE
Fixed - infinity loop during master/slave connection acquiring
Fixed - `RedissonList.addAll` result
10 years ago
####18-Nov-2014 - version 1.1.6 released
Feature - `RBucket.exists` and `RBucket.existsAsync` methods added
Feature - `RMap.addAndGet` method added
Feature - database index via `database` and operation timeout via `timeout` config params added
Improvement - `RLock` optimization
10 years ago
__Breaking api change__ - Redisson now uses `RedissonClient` interface
10 years ago
Fixed - NPE in `CommandOutput`
Fixed - unsubscribing during `RTopic.removeListener`
Fixed - all object names encoding, no more quotes
Fixed - HashedWheelTimer shutdown
Fixed - `RLock` race conditions (thanks to jsotuyod and AndrewKolpakov)
Fixed - `RCountDownLatch` race conditions
11 years ago
####23-Jul-2014 - version 1.1.5 released
11 years ago
Feature - operations auto-retry. `retryAttempts` and `retryInterval` params added for each connection type
11 years ago
Feature - `RMap.filterEntries`, `RMap.getAll`, `RMap.filterKeys`, `RMap.filterValues` methods added
11 years ago
Feature - `RMap.fastRemove`, `RMap.fastRemoveAsync`, `RMap.fastPut` & `RMap.fastPutAsync` methods added
Fixed - async operations timeout handling
Fixed - sorting algorithm used in `RSortedSet`.
11 years ago
####15-Jul-2014 - version 1.1.4 released
11 years ago
Feature - new `RLock.lockInterruptibly`, `RLock.tryLock`, `RLock.lock` methods with TTL support
11 years ago
Fixed - pub/sub connections reattach then slave/master down
Fixed - turn off connection watchdog then slave/master down
Fixed - sentinel master switch
Fixed - slave down connection closing
11 years ago
####13-Jul-2014 - version 1.1.3 released
Improvement - RedissonCountDownLatch optimization
Improvement - RedissonLock optimization
Fixed - RedissonLock thread-safety
Fixed - master/slave auth using Sentinel servers
Fixed - slave down handling using Sentinel servers
11 years ago
####03-Jul-2014 - version 1.1.2 released
Improvement - RedissonSet.iterator implemented with sscan
Improvement - RedissonSortedSet.iterator optimization
11 years ago
Feature - `RSortedSet.removeAsync`, `RSortedSet.addAsync`, `RSet.removeAsync`, RSet.addAsync methods added
11 years ago
Feature - slave up/down detection in Sentinel servers connection mode
Feature - new-slave automatic discovery in Sentinel servers connection mode
11 years ago
####17-June-2014 - version 1.1.1 released
Feature - sentinel servers support
Fixed - connection leak in `RTopic`
Fixed - setted password not used in single server connection
11 years ago
####07-June-2014 - version 1.1.0 released
11 years ago
Feature - master/slave connection management
11 years ago
Feature - simple set/get object support via `org.redisson.core.RBucket`
Feature - hyperloglog support via `org.redisson.core.RHyperLogLog`
Feature - new methods `getAsync`, `putAsync` and `removeAsync` added to `org.redisson.core.RMap`
Feature - new method `publishAsync` added to `org.redisson.core.RTopic`
Feature - [Kryo](https://github.com/EsotericSoftware/kryo) codec added (thanks to mathieucarbou)
11 years ago
__Breaking api change__ - `org.redisson.Config` model changed
11 years ago
Fixed - score calucaltion algorithm used in `RSortedSet`.
11 years ago
Fixed - `RMap.put` & `RMap.remove` result consistency fixed.
Fixed - `RTopic.publish` now returns the number of clients that received the message
Fixed - reconnection handling (thanks to renzihui)
Improvement - `org.redisson.core.RTopic` now use lazy apporach for subscribe/unsubscribe
11 years ago
####04-May-2014 - version 1.0.4 released
Feature - distributed implementation of `java.util.Deque`
Feature - some objects implements `org.redisson.core.RExpirable`
Fixed - JsonJacksonCodec lazy init
11 years ago
####26-Mar-2014 - version 1.0.3 released
Fixed - RedissonAtomicLong state format
Fixed - Long serialization in JsonJacksonCodec
11 years ago
####05-Feb-2014 - version 1.0.2 released
11 years ago
Feature - distributed implementation of `java.util.SortedSet`
Fixed - OSGi compability
11 years ago
####17-Jan-2014 - version 1.0.1 released
11 years ago
Improvement - forceUnlock, isLocked, isHeldByCurrentThread and getHoldCount methods added to RLock
Feature - connection load balancer to use multiple Redis servers
Feature - published in maven central repo
11 years ago
11 years ago
####11-Jan-2014 - version 1.0.0 released
First stable release.
11 years ago
### Maven
Include the following to your dependency list:
11 years ago
<dependency>
<groupId>org.redisson</groupId>
<artifactId>redisson</artifactId>
<version>1.3.0</version>
11 years ago
</dependency>
10 years ago
### Supported by
YourKit is kindly supporting this open source project with its full-featured Java Profiler.
YourKit, LLC is the creator of innovative and intelligent tools for profiling
Java and .NET applications. Take a look at YourKit's leading software products:
<a href="http://www.yourkit.com/java/profiler/index.jsp">YourKit Java Profiler</a> and
<a href="http://www.yourkit.com/.net/profiler/index.jsp">YourKit .NET Profiler</a>.