Questions tagged [jedis]

Jedis is a small free client for Redis, written in and for Java.

From its GitHub repository:

Jedis is a Java client for Redis designed for performance and ease of use.

Resources

868 questions
18
votes
2 answers

Redis Key expire notification with Jedis

I am trying to implement a expiry key notification with redis ,when my key expires in the redis data store. The redis website provides some description of how http://redis.io/topics/notifications, but Im unable to find any example how to do it using…
Rocky Ray
  • 257
  • 2
  • 3
  • 9
18
votes
3 answers

How can I set up a connection to Redis Sentinel using Jedis library?

How do I set up a connection to a Redis Sentinel server/cluster using the Jedis library?
ERNESTO ARROYO RON
  • 992
  • 1
  • 9
  • 22
18
votes
6 answers

Integration Testing with Redis

I've started using Redis in my project with the help of the Jedis library. All is working fine but now I have a problem that my functional tests requires Redis to be up which I want to avoid in my Continuous Integration. What is the best way to do…
Derek Organ
  • 8,323
  • 17
  • 56
  • 75
18
votes
3 answers

Configure Jedis timeout

I'm having problems completing an .hgetall(), here's what I've tried: Jedis jedis = new Jedis(REDIS_MASTER_NODE); jedis.connect(); jedis.configSet("timeout", "30"); Map alreadyStored = jedis.hgetAll(redisTargetHash); and here's…
dranxo
  • 3,348
  • 4
  • 35
  • 48
16
votes
2 answers

Does Redis only allow string representation but not numeric value

I am getting mixed answers on my research here. Can someone verify that the Redis Server can only store representation of any numerical values? For instance, if I use a Java client (Jedis) with a double type in lpush, do I need to convert it to…
heavy rocker dude
  • 2,271
  • 8
  • 33
  • 47
15
votes
2 answers

How to connect AWS Elasticache Redis cluster to Spring Boot app?

I have Spring Boot app which connects to Redis cluster, using Jedis Connection Factory: RedisClusterConfiguration redisClusterConfiguration = new…
15
votes
5 answers

Redis/Jedis - Delete by pattern?

Normally, I get the key set then use a look to delete each key/value pair. Is it possible to just delete all keys via pattern? ie: Del sample_pattern:*
iCodeLikeImDrunk
  • 17,085
  • 35
  • 108
  • 169
14
votes
3 answers

Using jedis How to cache Java object

Using Redis Java client Jedis How can I cache Java Object?
DP Dev
  • 201
  • 1
  • 2
  • 9
14
votes
3 answers

Best way to store a list of java objects in Redis

It would be great if someone could suggest me on what would be the best way to store a list of java objects in Redis. Currently, I'm converting the java objects into json strings and storing those strings in Redis and I have a set in Redis to keep…
user_ab
  • 225
  • 1
  • 3
  • 6
14
votes
5 answers

Spring Redis Error Handle

I am using Spring + Redis as my cache component in the new project. The spring config xml file is:
superleo
  • 319
  • 1
  • 2
  • 10
13
votes
4 answers

NoSuchMethodError: org.springframework.data.repository.config.RepositoryConfigurationSource.getAttribute

I am trying to use spring-data-redis in a spring-boot application to work with redis. I am creating JedisConnectionFactory as follows: RedisStandaloneConfiguration configuration = new…
user87407
  • 647
  • 3
  • 7
  • 24
13
votes
1 answer

jedis connection settings for high performance and reliablity

I am using Jedis client for connecting to my Redis server. The following are the settings I'm using for connecting with Jedis (using apache common pool): JedisPoolConfig poolConfig = new…
pjain
  • 1,149
  • 2
  • 14
  • 28
12
votes
1 answer

Unable to get result from the Redis using Crud Repository in Spring Boot?

I am developing Spring Boot + Redis example. I've taken a reference from link : https://www.baeldung.com/spring-data-redis-tutorial. In this example, I developed repository method Student findByNameAndGender(String name, Gender gender); and even…
Jeff Cook
  • 7,956
  • 36
  • 115
  • 186
12
votes
2 answers

How to enable auto reconnect of redis connection in Jedis client

I have an application that stores and reads date in Redis. When Redis goes down and then comes back up, the Jedis connection is not being recreated. Is there is a way to create a connection retry in Jedis?
Vigneshwaran
  • 782
  • 2
  • 7
  • 22
12
votes
3 answers

Jedis - When to use returnBrokenResource()

When exactly we should use this method. On JedisConnectionException, JedisDataException or for any JedisException. There is no good API documentation for Jedis to my knowledge. try { Jedis jedis = JedisFactory.getInstance(); Pipeline pipe =…
user1182253
  • 1,079
  • 2
  • 14
  • 26
1
2
3
57 58