server: Don't register director interrupt handler
This commit is contained in:
@ -20,7 +20,6 @@ import (
|
|||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"go.etcd.io/etcd/pkg/v3/osutil"
|
|
||||||
"go.uber.org/zap"
|
"go.uber.org/zap"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -45,7 +44,6 @@ func newDirector(lg *zap.Logger, urlsFunc GetProxyURLs, failureWait time.Duratio
|
|||||||
stopc: make(chan struct{}),
|
stopc: make(chan struct{}),
|
||||||
donec: make(chan struct{}),
|
donec: make(chan struct{}),
|
||||||
}
|
}
|
||||||
osutil.RegisterInterruptHandler(d.stop)
|
|
||||||
d.refresh()
|
d.refresh()
|
||||||
go func() {
|
go func() {
|
||||||
defer close(d.donec)
|
defer close(d.donec)
|
||||||
|
Reference in New Issue
Block a user