Skip to content

Commit

Permalink
Move a few vars to const.
Browse files Browse the repository at this point in the history
  • Loading branch information
wi1dcard committed Feb 22, 2024
1 parent 27c481d commit 61a6455
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions fingerproxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,14 @@ import (

const logFlags = log.LstdFlags | log.Lshortfile | log.Lmsgprefix

const (
// TODO: expose these values in CLI flags
HTTPIdleTimeout = 180 * time.Second
HTTPReadTimeout = 60 * time.Second
HTTPWriteTimeout = 60 * time.Second
ReverseProxyFlushInterval = 100 * time.Millisecond
)

var (
ProxyServerLog = log.New(os.Stderr, "[proxyserver] ", logFlags)
HTTPServerLog = log.New(os.Stderr, "[http] ", logFlags)
Expand All @@ -33,12 +41,6 @@ var (

PrometheusRegistry = prometheus.NewRegistry()

HTTPIdleTimeout = 180 * time.Second
HTTPReadTimeout = 60 * time.Second
HTTPWriteTimeout = 60 * time.Second

ReverseProxyFlushInterval = 100 * time.Millisecond

GetHeaderInjectors = DefaultHeaderInjectors

BuildCommit = "GIT_COMMIT_PLACEHOLDER"
Expand Down

0 comments on commit 61a6455

Please sign in to comment.