[HttpClient][Curl] Use poll api to avoid select 1024 FD hard limit#1426
Open
lucianopa-msft wants to merge 1 commit intomicrosoft:mainfrom
Open
[HttpClient][Curl] Use poll api to avoid select 1024 FD hard limit#1426lucianopa-msft wants to merge 1 commit intomicrosoft:mainfrom
lucianopa-msft wants to merge 1 commit intomicrosoft:mainfrom
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
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.
Using
selectcauses a crash because of its implementation 1024 FD hard limit.This is crash happens depending on the application running if it has held other file descriptors around in the process.
So even though the number of request simultaneously is guarded here:
cpp_client_telemetry/lib/tpm/TransmissionPolicyManager.cpp
Line 120 in 1fd167f
It doesn't prevent application to have hold onto other file descriptors opened which is outside of control of this library.
How to repro:
Results:
Fix
Those changes fix it by not relying on
selecthard limit and bullet proving our SDK to not fail on conditions that we as SDK do not control such as those and make the library more resilient.Fixes #1060