Skip to content

Commit

Permalink
Fix misapplication of time.Duration that somehow resulted in continuo…
Browse files Browse the repository at this point in the history
…us pings

Also remove nprocs from the startup script. A single instance is needed
in order for rate limits to work correctly, and multi-process isn't all
that necessary anyway.

Eventually einhorn will be removed and the unit file will go back to
being a plain socket-activated unit.
  • Loading branch information
mtharp committed Jul 5, 2018
1 parent c8a81ed commit a30bc1d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion distro/linux/relic-einhorn
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ case "$1" in
-d $sock \
-e /run/relic/einhorn.pid \
-f /run/relic/einhorn.lock \
-n $(nproc) \
-m manual \
-q \
-b 0.0.0.0:6300,r \
Expand Down
2 changes: 1 addition & 1 deletion server/view_health.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (s *Server) healthCheckLoop() {
select {
case <-t.C:
s.healthCheck()
t.Reset(time.Second * time.Duration(interval))
t.Reset(interval)
case <-s.Closed:
break
}
Expand Down

0 comments on commit a30bc1d

Please sign in to comment.