-
Notifications
You must be signed in to change notification settings - Fork 127
Enable Windows integration test in workflow through WSL #5112
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
Open
affonsov
wants to merge
9
commits into
main
Choose a base branch
from
affonsov/wsl-workflow-main
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Due to the limited resources available on GitHub Windows runners and the additional overhead of running through WSL, several optimizations were implemented: Reduced Replica Count: Windows CI uses 0 replicas instead of the standard 1-4 replicas to minimize resource usage and avoid replica synchronization issues that can occur in resource-constrained environments Increased Timeouts: Test timeouts were increased across multiple test classes: Request timeouts: 10s → 20s for better stability under WSL Test class timeouts: 10s → 15s/20s to account for WSL overhead Reduced Data Sizes: Large data tests reduced from 1 << 16 (64KB) to 1 << 15 (32KB) to prevent memory pressure on Windows runners WSL Overhead Considerations: The virtualization layer adds latency and resource overhead, requiring these adjustments for reliable test execution Signed-off-by: affonsov <[email protected]>
- Add platform check to skip test_az_affinity_replicas_and_primary_prioritizes_replicas_over_primary on Windows - Windows integration tests have replicas set to zero due to GitHub Actions WSL resource constraints - Server initialization hangs with replica configuration on Windows runner - Prevents flaky test failures on Windows CI/CD pipeline Signed-off-by: affonsov <[email protected]>
…lide tests - Prevents timeout issues during integration test execution with large payloads Signed-off-by: affonsov <[email protected]>
Signed-off-by: affonsov <[email protected]>
…/Mac" Signed-off-by: affonsov <[email protected]>
…ry nodes instead of all nodes" This reverts commit df2256a. Signed-off-by: affonsov <[email protected]>
ed21687 to
4bd7753
Compare
4bd7753 to
31a6329
Compare
…n GitHub Actions WSL environment Signed-off-by: affonsov <[email protected]>
31a6329 to
ec6a3a7
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR enables Java integration tests to run on Windows using WSL (Windows Subsystem for Linux), removing the previous Windows exclusion from CI workflows. It adds WSL support for cluster management, test execution, and process cleanup.
Due to the limited resources available on GitHub Windows runners and the additional overhead of running through WSL, several optimizations were implemented:
Changes Made
CI/CD Workflow Updates
.github/workflows/install-shared-dependencies/action.yml: Added WSL setup with Ubuntu 22.04 and direct Valkey installation in WSL for Windows runners.github/workflows/install-engine/action.yml: Addedx86_64-pc-windows-msvctarget support.github/workflows/java-cd.yml: Removed Windows exclusion from integration tests (previously skipped with-x :integTest:test).github/workflows/java.yml: Enabled integration tests on Windows and excluded only Redis 6.2 on WindowsJava Integration Test Infrastructure
java/integTest/build.gradle:getClusterCommand()helper to wrap commands withwslprefix on Windowsgradle.buildFinishedto kill orphaned Valkey/Redis processesjava/integTest/src/test/java/glide/cluster/ValkeyCluster.java:getScriptPath()method to convert Windows paths to WSL format (C:\path→/mnt/c/path)wslprefix on WindowsTest Adjustments for Windows
java/integTest/src/test/java/glide/TestUtilities.java: Added validation for empty host strings and improved error messages for invalid host formatsjava/integTest/src/test/java/glide/ConnectionTests.java: Adjusted AZ affinity test to expect 0 replicas on Windows WSL CIjava/integTest/src/test/java/glide/SharedCommandTests.java: UpdatedwaitTestandwait_timeout_checkto handle 0 replicas on Windows WSL CIjava/integTest/src/test/java/glide/ErrorHandlingTests.java: Increased timeout from 10s to 15sjava/integTest/src/test/java/glide/standalone/BatchTests.java: Increased timeout from 10s to 20sIssue link
This Pull Request is linked to issue (URL): [REPLACE ME]
Checklist
Before submitting the PR make sure the following are checked: