Refactor event loop with types
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
This commit is contained in:
parent
510c9c852b
commit
779cb69e6d
11 changed files with 194 additions and 119 deletions
|
@ -10,6 +10,7 @@ var (
|
|||
ErrContainerExists = errors.New("containerd: container already exists")
|
||||
ErrProcessNotFound = errors.New("containerd: processs not found for container")
|
||||
ErrUnknownContainerStatus = errors.New("containerd: unknown container status ")
|
||||
ErrUnknownEvent = errors.New("containerd: unknown event type")
|
||||
|
||||
// Internal errors
|
||||
errShutdown = errors.New("containerd: supervisor is shutdown")
|
||||
|
@ -17,4 +18,9 @@ var (
|
|||
errNoContainerForPid = errors.New("containerd: pid not registered for any container")
|
||||
errInvalidContainerType = errors.New("containerd: invalid container type for runtime")
|
||||
errNotChildProcess = errors.New("containerd: not a child process for container")
|
||||
// internal error where the handler will defer to another for the final response
|
||||
//
|
||||
// TODO: we could probably do a typed error with another error channel for this to make it
|
||||
// less like magic
|
||||
errDeferedResponse = errors.New("containerd: defered response")
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue