Enum and field renames.

This commit is contained in:
Jay
2026-04-20 17:43:40 -04:00
parent fd806c0231
commit aaf8571b9f
9 changed files with 47 additions and 47 deletions
+7 -7
View File
@@ -12,18 +12,18 @@ import (
// Types
type PoolEventKind string
type PoolEventKind int
const (
EventPeerDisconnected PoolEventKind = "disconnected"
EventPeerDropped PoolEventKind = "dropped"
EventPeerEvicted PoolEventKind = "evicted"
EventDisconnected PoolEventKind = iota
EventDropped
EventEvicted
)
var workerToPoolEvent = map[WorkerExitKind]PoolEventKind{
ExitCleanDisconnect: EventPeerDisconnected,
ExitUnexpectedDrop: EventPeerDropped,
ExitInactive: EventPeerEvicted,
ExitDisconnected: EventDisconnected,
ExitError: EventDropped,
ExitPolicy: EventEvicted,
}
type OnExitFunction func(kind WorkerExitKind)