Repository navigation
Share Redis fixtures across Lettuce tests - #13692
gh-worker-dd-mergequeue-cf854d[bot] merged 3 commits into
Conversation
🟢 Java Benchmark SLOs — All performance SLOs passed
PR vs. master results
Commit: Load and DaCapo benchmarks can be triggered manually in the GitLab pipeline. Results will appear in the Benchmarking Platform UI after completion. |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
More details
The static assessment found that per-test connections, Redis data resets, and server/client replacement after destructive commands preserve isolation when sharing fixtures.
🤖 Bits Code Review · Commit 45f6fa8
There was a problem hiding this comment.
The PR reduces repeated Redis startup and Lettuce shutdown work through shared fixtures while retaining per-test connections and data resets. One issue remains: failed replacement startup after a destructive test can make subsequent tests fail without retrying startup; there were no earlier findings requiring fixes.
🤖 Bits Code Review · Commit ad1d794
There was a problem hiding this comment.
More details
The PR shares Redis containers and Lettuce clients while retaining per-test connections and resetting standalone data. The update fixes the startup recovery issue by starting Redis before each test accesses its URI and deferring replacement until needed; no findings remain open.
🤖 Bits Code Review · Commit 6bae499
Reusing the client avoids repeated shutdowns. Each shutdown has a configured one-second quiet period. In the 11-test sync spec, the shared fixture went from 11 client shutdowns to 2. Each test still gets a fresh connection. On the matched Java 17 CI runs, that spec took 25.9s on master and 10.1s on this PR. That measures client and container reuse together. The logs don’t time client shutdown separately. flowchart TD
subgraph Before
A[Create a client for each test] --> B[Run test with a fresh connection]
B --> C[Shut down client with a one-second quiet period]
end
subgraph After
D[Create a shared client when needed] --> E[Run test with a fresh connection]
E --> F{Did the test stop Redis or finish the suite?}
F -->|No| E
F -->|Yes| G[Shut down the shared client]
G -->|Another test needs Redis| D
end
|
|
/merge |
|
View all feedbacks in Devflow UI.
The expected merge time in
|
What Does This Do
Shares Redis containers and Lettuce clients across the standalone specs and cluster tests. Each test still opens its own connection and runs the same instrumentation assertions.
Motivation
Starting a container and shutting down a client for every test repeats work across all Lettuce versions and forked suites. Sharing the fixtures cuts repeated startup and shutdown work while keeping each test's connection state isolated.
Additional Notes
SHUTDOWNandDEBUG SEGFAULTcases replace the server afterward, and the next test creates a client for the new mapped port.latestDep(8.0.0.BETA1). All 696 test executions passed locally.CI timing
Each row compares fresh runs of the same affected Lettuce test classes on master and this PR. Times sum JUnit class durations within one Gradle task. Parallel classes can overlap.
Java 8
testforkedTestlettuce51Testlettuce51ForkedTestlettuce60Testlettuce60ForkedTestlettuce61Testlettuce61ForkedTestlettuce62Testlettuce62ForkedTestlatestDepTestlatestDepForkedTestJava 11
testforkedTestlettuce51Testlettuce51ForkedTestlettuce60Testlettuce60ForkedTestlettuce61Testlettuce61ForkedTestlettuce62Testlettuce62ForkedTestThe
latestDepCI matrix omits Java 11.Contributor Checklist
type:and (comp:orinst:) labels in addition to any other useful labelsclose,fix, or any linking keywords when referencing an issueUse
solvesinstead, and assign the PR milestone to the issueJira ticket: N/A