-
Notifications
You must be signed in to change notification settings - Fork 372
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
use 30 secs timeout for put vmagent log api #2662
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #2662 +/- ##
========================================
Coverage 71.96% 71.96%
========================================
Files 103 103
Lines 15679 15679
Branches 2486 2486
========================================
Hits 11283 11283
Misses 3879 3879
Partials 517 517
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 comment
@@ -310,7 +310,7 @@ def redact_sas_tokens_in_urls(url): | |||
|
|||
|
|||
def _http_request(method, host, rel_uri, port=None, data=None, secure=False, | |||
headers=None, proxy_host=None, proxy_port=None, redact_data=False): | |||
headers=None, proxy_host=None, proxy_port=None, redact_data=False, timeout=10): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We defining the default timeout in multiple places. We should probably do that on the higher level functions (e.g. http_put) and make a mandatory parameter in the other methods (http_request, _http_request)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would force us to change every http_* API call (GET, POST, etc). I'm okay to do that too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, I think that is a better API interface (which requires more code changes, but hey...) :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Unless you think otherwise)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sometimes better things come with price. I'm gonna pay for it if things are clean :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for the update
Description
exercise 30 secs timeout to reduce latency failure rates on PUT VMagent log api.
Issue #
PR information
Quality of Code and Contribution Guidelines