We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8fe5e8b commit d9e4de9Copy full SHA for d9e4de9
reverseproxy_option.go
@@ -51,6 +51,7 @@ func defaultBuildOption() *buildOption {
51
tlsConfig: nil,
52
timeout: 0,
53
disablePathNormalizing: false,
54
+ maxConnDuration: 0,
55
}
56
57
@@ -123,9 +124,10 @@ func WithDisablePathNormalizing(isDisablePathNormalizing bool) Option {
123
124
})
125
126
-// WithTimeout specify the timeout of each request
127
+// WithMaxConnDuration sets maxConnDuration of hostClient, which
128
+// means keep-alive connections are closed after this duration.
129
func WithMaxConnDuration(d time.Duration) Option {
130
return newFuncBuildOption(func(o *buildOption) {
131
o.maxConnDuration = d
132
-}
133
+}
0 commit comments