spring-projects / spring-data-redis

Provides support to increase developer productivity in Java when using Redis, a key-value store. Uses familiar Spring concepts such as a template classes for core API usage and lightweight repository style data access.
https://spring.io/projects/spring-data-redis/
Apache License 2.0
1.77k stars 1.17k forks source link

Add builder customizer for `DefaultJedisClientConfig.Builder` #3007

Closed bshain-vtinfo closed 1 month ago

bshain-vtinfo commented 1 month ago

I would like to request the addition of a means to set / configure the JedisClientConfig.clientSetInfoConfig property.

As of right now, there is not a clear path to set clientSetInfoConfig on the JedisClientConfig instance within the JedisConnectionFactory. This property is already present on currently released Jedis artifacts Jedis v5.1.5 Example.

The use case for this request is that in some instances, it would be useful to set this property to disabled, (ClientSetInfoConfig.DISABLED) instead of the ClientSetInfoConfig.DEFAULT value.

mp911de commented 1 month ago

Looking at the configuration, we're creating JedisClientConfig in several places so it would be best to introduce a customizer for DefaultJedisClientConfig.Builder that allows you to control additional properties on the client config.

bshain-vtinfo commented 1 month ago

Thanks! Agree your suggested solution sounds like a better fit for this scenario & would help with future-proofing.

This seems like it could also potentially address issue 2972 as well. (Or at least as a temporary measure until new config options are explicitly added)