Merge branch 'v1.6' into master
This commit is contained in:
commit
bddb4cc33c
4 changed files with 44 additions and 1 deletions
|
@ -11,6 +11,7 @@ import (
|
|||
stdlog "log"
|
||||
"net"
|
||||
"net/http"
|
||||
"net/http/httputil"
|
||||
"net/url"
|
||||
"os"
|
||||
"os/signal"
|
||||
|
@ -77,6 +78,7 @@ type Server struct {
|
|||
provider provider.Provider
|
||||
configurationListeners []func(types.Configuration)
|
||||
entryPoints map[string]EntryPoint
|
||||
bufferPool httputil.BufferPool
|
||||
}
|
||||
|
||||
// EntryPoint entryPoint information (configuration + internalRouter)
|
||||
|
@ -117,6 +119,8 @@ func NewServer(globalConfiguration configuration.GlobalConfiguration, provider p
|
|||
server.globalConfiguration.API.CurrentConfigurations = &server.currentConfigurations
|
||||
}
|
||||
|
||||
server.bufferPool = newBufferPool()
|
||||
|
||||
server.routinesPool = safe.NewPool(context.Background())
|
||||
server.defaultForwardingRoundTripper = createHTTPTransport(globalConfiguration)
|
||||
|
||||
|
@ -988,6 +992,7 @@ func (s *Server) loadConfig(configurations types.Configurations, globalConfigura
|
|||
forward.ErrorHandler(errorHandler),
|
||||
forward.Rewriter(rewriter),
|
||||
forward.ResponseModifier(responseModifier),
|
||||
forward.BufferPool(s.bufferPool),
|
||||
)
|
||||
|
||||
if err != nil {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue