Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Jedis maxTotalRetriesDuration in config #2389

Conversation

joshua5201
Copy link

@joshua5201 joshua5201 commented Aug 25, 2022

Hi team,
I want to use maxTotalRetriesDuraion option in JedisCluster introduced by this Jedis PR.

I created a draft. I don't know if I should use a new configuration class or just use RedisClusterConfiguration since this is a Jedis-only option.

Please kindly give me some directions then I can do further development and testing.

  • You have read the Spring Data contribution guidelines.
  • You use the code formatters provided here and have them applied to your changes. Don’t submit any formatting related changes.
  • You submit test cases (unit or integration tests) that back your changes.
  • You added yourself as author in the headers of the classes you touched. Amend the date range in the Apache license header if needed. For new types, add the license header (copy from another file and set the current year only).

@pivotal-cla
Copy link

@joshua5201 Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

@pivotal-cla
Copy link

@joshua5201 Thank you for signing the Contributor License Agreement!

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Aug 25, 2022
@joshua5201 joshua5201 changed the title Add Jedis maxTotalRetriesDuration in config Add support for Jedis maxTotalRetriesDuration in config Aug 25, 2022
@joshua5201 joshua5201 force-pushed the add-jedis-max-total-retries-duration branch 3 times, most recently from 3583b08 to 53a9757 Compare August 25, 2022 23:56
@joshua5201 joshua5201 marked this pull request as ready for review August 25, 2022 23:57
@joshua5201 joshua5201 force-pushed the add-jedis-max-total-retries-duration branch from 53a9757 to 41f1965 Compare August 26, 2022 00:00
@mp911de
Copy link
Member

mp911de commented Sep 21, 2022

Thanks for your pull request. The max-redirect duration isn't supported across all Redis clients and I don't see that Lettuce will ever support such a feature, therefore we cannot expose this configuration item into the ClusterConfiguration respective RedisClusterConfiguration API.

Additionally, Jedis has this bad habit of putting all sorts of arguments into constructors that make it difficult to provide customization hooks. It would be much easier to provide a Jedis-specific option if all cluster configuration would be encapsulated, something along the lines of the already existing JedisClientConfig design.

In its current form, we cannot accept your contribution because we don't have a good way to make it work.

As a workaround, please subclass JedisConnectionFactory and override the createCluster(…) method.

@mp911de mp911de closed this Sep 21, 2022
@mp911de mp911de added status: declined A suggestion or change that we don't feel we should currently apply and removed status: waiting-for-triage An issue we've not yet triaged labels Sep 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: declined A suggestion or change that we don't feel we should currently apply
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants