mirror of
https://github.com/fnproject/fn.git
synced 2022-10-28 21:29:17 +03:00
Idle Hot Container Freeze/Preempt Support (#733)
* fn: freeze/unfreeze and eject idle under resource contention
This commit is contained in:
@@ -34,6 +34,12 @@ type Cookie interface {
|
||||
// Run() MUST monitor the context. task cancellation is indicated by
|
||||
// cancelling the context.
|
||||
Run(ctx context.Context) (WaitResult, error)
|
||||
|
||||
// Freeze the container to pause running processes
|
||||
Freeze(ctx context.Context) error
|
||||
|
||||
// Unfreeze a frozen container to unpause frozen processes
|
||||
Unfreeze(ctx context.Context) error
|
||||
}
|
||||
|
||||
type WaitResult interface {
|
||||
|
||||
Reference in New Issue
Block a user