go fmt
This commit is contained in:
parent
a27e5ea92e
commit
e523deb15c
10
conn.go
10
conn.go
@ -107,8 +107,8 @@ func (wa websocketAddr) String() string {
|
||||
}
|
||||
|
||||
type rateLimiter struct {
|
||||
C <-chan struct{}
|
||||
ticker *time.Ticker
|
||||
C <-chan struct{}
|
||||
ticker *time.Ticker
|
||||
stopped chan struct{}
|
||||
}
|
||||
|
||||
@ -135,8 +135,8 @@ func newRateLimiter(delay time.Duration, burst int) *rateLimiter {
|
||||
}
|
||||
}()
|
||||
return &rateLimiter{
|
||||
C: ch,
|
||||
ticker: ticker,
|
||||
C: ch,
|
||||
ticker: ticker,
|
||||
stopped: stopped,
|
||||
}
|
||||
}
|
||||
@ -147,7 +147,7 @@ func (rl *rateLimiter) Stop() {
|
||||
}
|
||||
|
||||
type connOptions struct {
|
||||
Logger Logger
|
||||
Logger Logger
|
||||
RateLimitDelay time.Duration
|
||||
RateLimitBurst int
|
||||
}
|
||||
|
@ -164,7 +164,7 @@ func connectToUpstream(network *network) (*upstreamConn, error) {
|
||||
}
|
||||
|
||||
options := connOptions{
|
||||
Logger: logger,
|
||||
Logger: logger,
|
||||
RateLimitDelay: upstreamMessageDelay,
|
||||
RateLimitBurst: upstreamMessageBurst,
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user