This is an automated email from the ASF dual-hosted git repository.

donalevans pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode-examples.git


The following commit(s) were added to refs/heads/develop by this push:
     new 488a43d  GEODE-9907: Add larger timeout to JedisCluster in Redis 
example (#113)
488a43d is described below

commit 488a43d14af80868dbe82e8ca9fecb14934fab55
Author: Donal Evans <doev...@vmware.com>
AuthorDate: Fri Jan 28 17:16:43 2022 -0800

    GEODE-9907: Add larger timeout to JedisCluster in Redis example (#113)
    
    Authored-by: Donal Evans <doev...@vmware.com>
---
 .../main/java/org/apache/geode_examples/geodeForRedis/Example.java    | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git 
a/geodeForRedis/src/main/java/org/apache/geode_examples/geodeForRedis/Example.java
 
b/geodeForRedis/src/main/java/org/apache/geode_examples/geodeForRedis/Example.java
index 956343d..e59f485 100644
--- 
a/geodeForRedis/src/main/java/org/apache/geode_examples/geodeForRedis/Example.java
+++ 
b/geodeForRedis/src/main/java/org/apache/geode_examples/geodeForRedis/Example.java
@@ -14,6 +14,7 @@
  */
 package org.apache.geode_examples.geodeForRedis;
 
+import java.time.Duration;
 import java.util.HashMap;
 import java.util.Map;
 import java.util.Random;
@@ -25,7 +26,8 @@ public class Example {
   public static final String SORTED_SET_KEY = "{tag}leaderboard";
 
   public static void main(String[] args) {
-    JedisCluster jedis = new JedisCluster(new HostAndPort("127.0.0.1", 6379));
+    JedisCluster jedis = new JedisCluster(new HostAndPort("127.0.0.1", 6379),
+        (int) Duration.ofMinutes(2).toMillis());
 
     populateSortedSet(jedis);
 

Reply via email to