Plugin/Forward - autotune the dialTimeout for connection (#1852)

* - implement an auto-tunable dialTimeout for fallback.

* - fix gofmt

* - factorized timeout computation with readTimeout / updated readme /

* - fix comment
This commit is contained in:
Francois Tur
2018-06-15 02:37:22 -04:00
committed by Miek Gieben
parent 6f865a9de7
commit 70c957d885
5 changed files with 84 additions and 52 deletions

View File

@@ -82,6 +82,10 @@ forward FROM TO... {
Also note the TLS config is "global" for the whole forwarding proxy if you need a different
`tls-name` for different upstreams you're out of luck.
On each endpoint, the timeouts of the communication are set by default and automatically tuned depending early results.
- dialTimeout by default is 30 sec, and can decrease automatically down to 100ms
- readTimeout by default is 2 sec, and can decrease automatically down to 10ms
## Metrics
If monitoring is enabled (via the *prometheus* directive) then the following metric are exported: