Reduce LargeUriAndHeaders_Works test size on Android to fix timeout flakiness#126010
Open
Reduce LargeUriAndHeaders_Works test size on Android to fix timeout flakiness#126010
Conversation
Co-authored-by: danmoseley <6385855+danmoseley@users.noreply.github.com> Agent-Logs-Url: https://github.com/dotnet/runtime/sessions/180b1583-f9c5-4691-8785-f8875518a722
Copilot
AI
changed the title
[WIP] Fix timeout error in LargeUriAndHeaders test
Reduce LargeUriAndHeaders_Works test size on Android to fix timeout flakiness
Mar 24, 2026
Contributor
|
Tagging subscribers to this area: @karelz, @dotnet/ncl |
Contributor
There was a problem hiding this comment.
Pull request overview
Adjusts the LargeUriAndHeaders_Works functional test to avoid Android timeouts by reducing the size of the generated URI path and header strings on Android, while preserving the existing stress level on other platforms and the WinHTTP-specific cap.
Changes:
- Add an Android-specific
lengthcap for the test data to reduce runtime/memory pressure on Android. - Keep the existing WinHTTP cap (65,000) and the existing non-Android/non-WinHTTP size (10,000,000).
ManickaP
approved these changes
Mar 25, 2026
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
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.
SocketsHttpHandler_HttpClientHandlerTest.LargeUriAndHeaders_Workswas consistently timing out on Android because the test allocates 10M-character strings for the path, header name, and header value — too large for Android's HTTP stack within the allotted time.Changes
HttpClientHandlerTest.cs: Added Android-specific branch to thelengthcalculation:This mirrors the existing WinHTTP size cap pattern and keeps non-Android platforms at the original 10M limit.
Original prompt
This section details on the original issue you should resolve
<issue_title>[FAIL] System.Net.Http.Functional.Tests.SocketsHttpHandler_HttpClientHandlerTest.LargeUriAndHeaders_Works</issue_title>
<issue_description>```
02-16 16:47:52.072 10194 24326 I DOTNET : [FAIL] System.Net.Http.Functional.Tests.SocketsHttpHandler_HttpClientHandlerTest.LargeUriAndHeaders_Works
02-16 16:47:52.072 10194 24326 I DOTNET : System.TimeoutException : The operation has timed out.
02-16 16:47:52.072 10194 24326 I DOTNET : at System.Net.Http.Functional.Tests.HttpClientHandlerTest.LargeUriAndHeaders_Works()
Report
Summary
Known issue validation
Build: 🔎 https://dev.azure.com/dnceng-public/public/_build/results?buildId=1296274
Error message validated:
[[FAIL] System.Net.Http.Functional.Tests.SocketsHttpHandler_HttpClientHandlerTest.LargeUriAndHeaders_Works]Result validation: ✅ Known issue matched with the provided build.
Validation performed at: 2/25/2026 7:27:26 AM UTC
Report
⌨️ Start Copilot coding agent tasks without leaving your editor — available in VS Code, Visual Studio, JetBrains IDEs and Eclipse.