Update README.md
This commit is contained in:
14
README.md
14
README.md
@@ -33,6 +33,7 @@ All of the following redis features are supported:
|
||||
- Key-tags for sharding
|
||||
- Sharding with pipelining
|
||||
- Scripting with pipelining
|
||||
- Redis Cluster
|
||||
|
||||
## How do I use it?
|
||||
|
||||
@@ -65,6 +66,19 @@ Please check the [wiki](http://github.com/xetorthio/jedis/wiki "wiki"). There ar
|
||||
|
||||
And you are done!
|
||||
|
||||
## Jedis Cluster
|
||||
|
||||
Redis cluster [specification](http://redis.io/topics/cluster-spec) (still under development) is implemented
|
||||
|
||||
```java
|
||||
Set<HostAndPort> jedisClusterNodes = new HashSet<HostAndPort>();
|
||||
//Jedis Cluster will attempt to discover cluster nodes automatically
|
||||
jedisClusterNode.add(new HostAndPort("127.0.0.1", 7379));
|
||||
JedisCluster jc = new JedisCluster(jedisClusterNode);
|
||||
jc.set("foo", "bar");
|
||||
String value = jc.get("foo");
|
||||
```
|
||||
|
||||
## I want to contribute!
|
||||
|
||||
That is great! Just fork the project in github. Create a topic branch, write some code, and add some tests for your new code.
|
||||
|
||||
Reference in New Issue
Block a user