From 765136a4d9d5c1e937c7246bd939b1dc8b536e6a Mon Sep 17 00:00:00 2001 From: Nick Craver Date: Tue, 29 Jul 2025 08:29:51 -0400 Subject: [PATCH 1/3] Tests: Improve stability for AbortOnConnectFailTests These had a lot timeout for runtime due to a shared method for faster test execution but in the day but the success case _should_ be fast but worst case it should not fail - we'd much rather it occasionally take a second than fail the test suite and add noise to the process. --- .../StackExchange.Redis.Tests/AbortOnConnectFailTests.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/StackExchange.Redis.Tests/AbortOnConnectFailTests.cs b/tests/StackExchange.Redis.Tests/AbortOnConnectFailTests.cs index b68e57c9e..25033fa1a 100644 --- a/tests/StackExchange.Redis.Tests/AbortOnConnectFailTests.cs +++ b/tests/StackExchange.Redis.Tests/AbortOnConnectFailTests.cs @@ -81,16 +81,16 @@ public async Task DisconnectAndNoReconnectThrowsConnectionExceptionAsync() } private ConnectionMultiplexer GetFailFastConn() => - ConnectionMultiplexer.Connect(GetOptions(BacklogPolicy.FailFast, 400).Apply(o => o.EndPoints.Add($"doesnot.exist.{Guid.NewGuid():N}:6379")), Writer); + ConnectionMultiplexer.Connect(GetOptions(BacklogPolicy.FailFast, duration: 400, connectTimeout: 500).Apply(o => o.EndPoints.Add($"doesnot.exist.{Guid.NewGuid():N}:6379")), Writer); private ConnectionMultiplexer GetWorkingBacklogConn() => - ConnectionMultiplexer.Connect(GetOptions(BacklogPolicy.Default, 1000).Apply(o => o.EndPoints.Add(GetConfiguration())), Writer); + ConnectionMultiplexer.Connect(GetOptions(BacklogPolicy.Default).Apply(o => o.EndPoints.Add(GetConfiguration())), Writer); - private static ConfigurationOptions GetOptions(BacklogPolicy policy, int duration) => new ConfigurationOptions() + private static ConfigurationOptions GetOptions(BacklogPolicy policy, int duration = 1000, int connectTimeout = 2000) => new ConfigurationOptions() { AbortOnConnectFail = false, BacklogPolicy = policy, - ConnectTimeout = 500, + ConnectTimeout = connectTimeout, SyncTimeout = duration, KeepAlive = duration, AllowAdmin = true, From 90c1c3e67cfd79361365949daa3683dd8bf288f8 Mon Sep 17 00:00:00 2001 From: Nick Craver Date: Tue, 29 Jul 2025 08:47:44 -0400 Subject: [PATCH 2/3] Use Vampire/setup-wsl@v6 Fixes a few issues and transitions us to WSL2 underneath - let's see how this works --- .github/workflows/CI.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 1796710a7..d5b19ea50 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -58,7 +58,7 @@ jobs: uses: actions/checkout@v4 with: fetch-depth: 0 # Fetch the full history - - uses: Vampire/setup-wsl@v2 + - uses: Vampire/setup-wsl@v6 with: distribution: Ubuntu-22.04 - name: Install Redis From 75683f971905593403421c3256feeecd8ea0aa88 Mon Sep 17 00:00:00 2001 From: Nick Craver Date: Tue, 29 Jul 2025 09:09:42 -0400 Subject: [PATCH 3/3] Revert "Use Vampire/setup-wsl@v6" This reverts commit 90c1c3e67cfd79361365949daa3683dd8bf288f8. --- .github/workflows/CI.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index d5b19ea50..1796710a7 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -58,7 +58,7 @@ jobs: uses: actions/checkout@v4 with: fetch-depth: 0 # Fetch the full history - - uses: Vampire/setup-wsl@v6 + - uses: Vampire/setup-wsl@v2 with: distribution: Ubuntu-22.04 - name: Install Redis