Skip to content

Commit 3c5cf52

Browse files
author
Mat Ryer
committed
added NoWait helper
1 parent 86e1b88 commit 3c5cf52

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

stop/stop.go

+4
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ import "time"
55
// Signal is the type that gets sent down the stop channel.
66
type Signal struct{}
77

8+
// NoWait represents a time.Duration with zero value.
9+
// Logically meaning no grace wait period when stopping.
10+
var NoWait time.Duration = 0
11+
812
// Stopper represents types that implement
913
// the stop channel pattern.
1014
type Stopper interface {

0 commit comments

Comments
 (0)