-
Notifications
You must be signed in to change notification settings - Fork 3.9k
[automatic failover] Replace EchoStrategy with PingStrategy #4313
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
[automatic failover] Replace EchoStrategy with PingStrategy #4313
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR replaces the default health check strategy EchoStrategy with PingStrategy across the entire codebase, updating both implementation and documentation to reflect this change.
Key changes:
- Replace
EchoStrategyclass withPingStrategyclass that uses Redis PING command instead of ECHO - Update all test files to use the new strategy name and expected behavior
- Update documentation to reflect the new default strategy
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/main/java/redis/clients/jedis/mcf/PingStrategy.java | Renamed class from EchoStrategy to PingStrategy and changed health check from ECHO to PING command |
| src/main/java/redis/clients/jedis/MultiDbConfig.java | Updated imports, documentation, and default strategy references to use PingStrategy |
| src/test/java/redis/clients/jedis/mcf/PingStrategyIntegrationTest.java | Renamed test class and updated all test methods to use PingStrategy |
| src/test/java/redis/clients/jedis/mcf/HealthCheckTest.java | Updated test methods and comments to reference PingStrategy instead of EchoStrategy |
| src/test/java/redis/clients/jedis/mcf/HealthCheckIntegrationTest.java | Updated test implementation to use PING command and expect PONG response |
| src/test/java/redis/clients/jedis/mcf/MultiDbConnectionProviderInitializationTest.java | Updated test to use PingStrategy.DEFAULT |
| src/test/java/redis/clients/jedis/mcf/DefaultValuesTest.java | Updated test assertions and comments to reference PingStrategy |
| docs/failover.md | Updated documentation to describe PingStrategy as the default instead of EchoStrategy |
| .github/wordlist.txt | Removed EchoStrategy and added PingStrategy to the wordlist |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
…4317) * [automatic failover] Replace EchoStrategy with PingStrategy (#4313) * - replace EchoStrategy with PingStrategy * - fix doc * [automatic failover] Remove UnifiedJedis experimental constructor accepting MultiDbConnectionProvider (#4316) * Remove UnifiedJedis(MultiDbConnectionProvider) experimental constructor The recommended way to create MultiDbClient is using MultiDbClient.builder(). Update all tests to use the builder pattern. Fixes #4307 * revert unintentional change in MultiDbClientBuilder * Squashed commit of the following: commit 297279e Author: Igor Malinovskiy <u.glide@gmail.com> Date: Thu Oct 9 13:06:10 2025 +0200 Add v6 and v7 migration guides (#4315) * Add migration guide for v7 * Move all migration guides to subfolder * Update readme: - Bump client version - Update list of supported Redis versions - Remove references to JedisPool - Remove reference to Google Group * Remove duplicated content in the migration guide * Update README.md Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Add missing v5 to v6 migration guide * Fix broken link * Update outdated modules section in README --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> commit 3645601 Author: Ivo Gaydazhiev <ivo.gaydazhiev@redis.com> Date: Thu Oct 9 13:53:02 2025 +0300 Dedicated profile for running Scenario tests (#4312) * Dedicated profile for running Scenario tests to run only scenario tests mvn -Pscenario-tests clean verify * format * remove import after rebase conflict * fix RedisRestAPIIT scenario test - increase expected bdb's count to account for additional db added to test env - fix incorrect bdbid used for lag-aware availablity checks now using bdb of'"re-active-active" * fix LagAwareStrategySslIT scenario test - Now exception is propagated in case of ssl connection errors instead of returning UNHEALTHY - updated the test to current expectations - Enhanced test to ensure untrusted default certificate * java 8 compatibility * remove @tag("integration") from IntegrationTest* to avoid multiple runs of same test --------- Co-authored-by: Igor Malinovskiy <u.glide@gmail.com> commit 07bf3b0 Author: Igor Malinovskiy <u.glide@gmail.com> Date: Thu Oct 9 12:00:36 2025 +0200 [automatic failover] Update failover docs (#4314) Update failover docs - Add migration guide from 6.x to 7.0 - Add instructions on optional deps - Clean up wording to refer to multiDbClient instead of connection provider commit 158e726 Author: Igor Malinovskiy <u.glide@gmail.com> Date: Thu Oct 9 11:14:28 2025 +0200 Remove deprecated constructors, classes and JedisSharding (#4311) * Remove JedisSharding * Remove deprecated constructors in UnifiedJedis * Clean up UnifiedJedisConstructorReflectionTest * Remove remaining ShardedCommandArguments * Remove deprecated PipelineBase * Remove deprecated TransactionBase * Remove unused attr in MultiDbTransaction commit 5db1a39 Author: Igor Malinovskiy <u.glide@gmail.com> Date: Thu Oct 9 10:04:06 2025 +0200 Remove spellcheck (#4309) Nowadays, AI reviewing tools like CoPilot catch spellcheck issues better than pyspelling without a burden of maintaining wordlist.txt --------- Co-authored-by: Ivo Gaydazhiev <ivo.gaydazhiev@redis.com>
The default strategy,
EchoStrategyis replaced withPingStrategyand dropped.