-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
REST server: http log filtering and request read timeout (#102)
* REST server: http log filtering and request read timeout 1) Standard http library writes error and warning messages like "TLS handshake error" to staderr, which gets forwarded to syslog. It can flood the syslog during stress tests. Added an error log writer to the REST http server to capture all such messages and filter out trivial messages. Only accept failures and handler panics are treated as non-trivial. All other messages are logged only if glog verbose level 2 is enabled. 2) Added a configurable 'read timeout' to REST server which is the deadline for reading a full http request (TLS+header+body) after a new connection is accepted. Connection is dropped if it was left idle for more than this duration or client takes longer to push the request. Default vale is 15s; can be changed via '-readtimeout T' command line flag. Value 0 disables this timeout. * Change startup settings log to a verbose log
- Loading branch information
1 parent
1303b05
commit c36f6e1
Showing
3 changed files
with
58 additions
and
4 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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