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

140 lines
8.5 KiB
Markdown

8 years ago
Redisson: Redis based In-Memory Data Grid for Java.
9 years ago
====
8 years ago
[Quick start](https://github.com/redisson/redisson#quick-start) | [Documentation](https://github.com/redisson/redisson/wiki) | [Javadocs](http://www.javadoc.io/doc/org.redisson/redisson/3.4.1) | [Changelog](https://github.com/redisson/redisson/blob/master/CHANGELOG.md) | [Code examples](https://github.com/redisson/redisson-examples) | [Support chat](https://gitter.im/mrniko/redisson) | **[Ultra-fast version](https://redisson.pro)**
9 years ago
9 years ago
Based on high-performance async and lock-free Java Redis client and [Netty](http://netty.io) framework.
8 years ago
## Please take part in [Redisson survey](https://www.surveymonkey.com/r/QXQZH5D)
8 years ago
| Stable Release Version | JDK Version compatibility | Release Date |
| ------------- | ------------- | ------------|
8 years ago
| 3.4.3 | 1.8+ | 10.06.2017 |
| 2.9.3 | 1.6, 1.7, 1.8 and Android | 10.06.2017 |
8 years ago
8 years ago
__NOTE__: Both version lines have same features except `CompletionStage` interface added in 3.x.x
11 years ago
9 years ago
11 years ago
Features
================================
8 years ago
* Replicated servers mode (also supports [AWS ElastiCache](http://docs.aws.amazon.com/AmazonElastiCache/latest/UserGuide/Replication.html) and [Azure Redis Cache](https://azure.microsoft.com/en-us/services/cache/)):
8 years ago
1. automatic master server change discovery
8 years ago
* Cluster servers mode (also supports [AWS ElastiCache Cluster](http://docs.aws.amazon.com/AmazonElastiCache/latest/UserGuide/Clusters.html) and [Azure Redis Cache](https://azure.microsoft.com/en-us/services/cache/)):
8 years ago
1. automatic master and slave servers discovery
8 years ago
2. automatic status and topology update
3. automatic slots change discovery
11 years ago
* Sentinel servers mode:
8 years ago
1. automatic master, slave and sentinel servers discovery
2. automatic status and topology update
9 years ago
* Master with Slave servers mode
* Single server mode
10 years ago
* Thread-safe implementation
8 years ago
* [Reactive Streams](https://github.com/redisson/redisson/wiki/3.-operations-execution#32-reactive-way) API
* [Asynchronous](https://github.com/redisson/redisson/wiki/3.-operations-execution#31-async-way) API
* Asynchronous connection pool
9 years ago
* Lua scripting
8 years ago
* [Distributed objects](https://github.com/redisson/redisson/wiki/6.-Distributed-objects)
8 years ago
Object holder, Binary stream holder, Geospatial holder, BitSet, AtomicLong, AtomicDouble, PublishSubscribe,
Bloom filter, HyperLogLog
8 years ago
* [Distributed collections](https://github.com/redisson/redisson/wiki/7.-Distributed-collections)
Map, Multimap, Set, List, SortedSet, ScoredSortedSet, LexSortedSet, Queue, Deque, Blocking Queue, Bounded Blocking Queue, Blocking Deque, Delayed Queue, Priority Queue, Priority Deque
8 years ago
* [Distributed locks and synchronizers](https://github.com/redisson/redisson/wiki/8.-Distributed-locks-and-synchronizers)
8 years ago
Lock, FairLock, MultiLock, RedLock, ReadWriteLock, Semaphore, PermitExpirableSemaphore, CountDownLatch
8 years ago
* [Distributed services](https://github.com/redisson/redisson/wiki/9.-distributed-services)
8 years ago
Remote service, Live Object service, Executor service, Scheduler service, MapReduce service
* [Spring Cache](https://github.com/redisson/redisson/wiki/14.-Integration%20with%20frameworks/#141-spring-cache) implementation  
* [Hibernate Cache](https://github.com/redisson/redisson/wiki/14.-Integration%20with%20frameworks/#142-hibernate-cache) implementation
8 years ago
* [JCache API (JSR-107)](https://github.com/redisson/redisson/wiki/14.-Integration%20with%20frameworks/#143-jcache-api-jsr-107-implementation) implementation
8 years ago
* [Tomcat Session Manager](https://github.com/redisson/redisson/wiki/14.-Integration%20with%20frameworks#144-tomcat-redis-session-manager) implementation
* [Spring Session](https://github.com/redisson/redisson/wiki/14.-Integration%20with%20frameworks/#145-spring-session) implementation
8 years ago
* [Redis pipelining](https://github.com/redisson/redisson/wiki/10.-additional-features#102-execution-batches-of-commands) (command batches)
9 years ago
* Supports Android platform
8 years ago
* Supports auto-reconnection
9 years ago
* Supports failed to send command auto-retry
11 years ago
* Supports OSGi
8 years ago
* Supports SSL
8 years ago
* Supports many popular codecs ([Jackson JSON](https://github.com/FasterXML/jackson), [Avro](http://avro.apache.org/), [Smile](http://wiki.fasterxml.com/SmileFormatSpec), [CBOR](http://cbor.io/), [MsgPack](http://msgpack.org/), [Kryo](https://github.com/EsotericSoftware/kryo), [Amazon Ion](https://amzn.github.io/ion-docs/), [FST](https://github.com/RuedigerMoeller/fast-serialization), [LZ4](https://github.com/jpountz/lz4-java), [Snappy](https://github.com/xerial/snappy-java) and JDK Serialization)
8 years ago
* With over 1000 unit tests
11 years ago
8 years ago
Who uses Redisson
10 years ago
================================
8 years ago
[Electronic Arts](http://ea.com), [Baidu](http://baidu.com), [New Relic Synthetics](https://newrelic.com/synthetics), [Brookhaven National Laboratory](http://bnl.gov/), [Singtel](http://singtel.com), [Infor](http://www.infor.com/), [Netflix Dyno client](https://github.com/Netflix/dyno), [Ocous](http://www.ocous.com/), [Invaluable](http://www.invaluable.com/), [Clover](https://www.clover.com/) , [Apache Karaf Decanter](https://karaf.apache.org/projects.html#decanter), [Atmosphere Framework](http://async-io.org/), [BrandsEye](http://brandseye.com), [Datorama](http://datorama.com/), [BrightCloud](http://brightcloud.com/), [Azar](http://azarlive.com/), [Snapfish](http://snapfish.com), [Crimson Hexagon](http://www.crimsonhexagon.com), [Quby](http://quby.com/), [Base CRM](http://getbase.com)
10 years ago
9 years ago
Articles
================================
9 years ago
8 years ago
[Java data structures powered by Redis. Introduction to Redisson (pdf)](https://redisson.org/Redisson.pdf)
8 years ago
[Redisson PRO vs. Jedis: Which Is Faster?](https://dzone.com/articles/redisson-pro-vs-jedis-which-is-faster)
8 years ago
[A Look at the Java Distributed In-Memory Data Model (Powered by Redis)](https://dzone.com/articles/java-distributed-in-memory-data-model-powered-by-r)
8 years ago
[Distributed tasks Execution and Scheduling in Java, powered by Redis](https://dzone.com/articles/distributed-tasks-execution-and-scheduling-in-java)
9 years ago
[Introducing Redisson Live Objects (Object Hash Mapping)](https://dzone.com/articles/introducing-redisson-live-object-object-hash-mappi)
[Java Remote Method Invocation with Redisson](https://dzone.com/articles/java-remote-method-invocation-with-redisson)
[Java Multimaps With Redis](https://dzone.com/articles/multimaps-with-redis)
8 years ago
[Distributed lock with Redis](https://evuvatech.com/2016/02/05/distributed-lock-with-redis/)
9 years ago
8 years ago
Success stories
================================
[Moving from Hazelcast to Redis](https://engineering.datorama.com/moving-from-hazelcast-to-redis-b90a0769d1cb)
9 years ago
Quick start
9 years ago
===============================
11 years ago
9 years ago
#### Maven
8 years ago
<!-- JDK 1.8+ compatible -->
<dependency>
<groupId>org.redisson</groupId>
<artifactId>redisson</artifactId>
8 years ago
<version>3.4.3</version>
8 years ago
</dependency>
11 years ago
8 years ago
<!-- JDK 1.6+ compatible -->
11 years ago
<dependency>
<groupId>org.redisson</groupId>
<artifactId>redisson</artifactId>
8 years ago
<version>2.9.3</version>
11 years ago
</dependency>
10 years ago
8 years ago
9 years ago
#### Gradle
8 years ago
// JDK 1.8+ compatible
8 years ago
compile 'org.redisson:redisson:3.4.3'
8 years ago
// JDK 1.6+ compatible
8 years ago
compile 'org.redisson:redisson:2.9.3'
10 years ago
9 years ago
#### Java
```java
// 1. Create config object
Config = ...
// 2. Create Redisson instance
RedissonClient redisson = Redisson.create(config);
// 3. Get object you need
RMap<MyKey, MyValue> map = redisson.getMap("myMap");
9 years ago
RLock lock = redisson.getLock("myLock");
9 years ago
9 years ago
RExecutorService executor = redisson.getExecutorService("myExecutorService");
9 years ago
9 years ago
// over 30 different objects and services ...
```
9 years ago
9 years ago
Downloads
===============================
9 years ago
8 years ago
[Redisson 3.4.3](https://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=org.redisson&a=redisson&v=3.4.3&e=jar),
[Redisson node 3.4.3](https://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=org.redisson&a=redisson-all&v=3.4.3&e=jar)
8 years ago
8 years ago
[Redisson 2.9.3](https://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=org.redisson&a=redisson&v=2.9.3&e=jar),
[Redisson node 2.9.3](https://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=org.redisson&a=redisson-all&v=2.9.3&e=jar)
10 years ago
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>.