mirror of
https://github.com/opencontainers/runc.git
synced 2026-07-11 06:03:57 +08:00
Rename OOM to NotifyOOM
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
This commit is contained in:
+2
-2
@@ -113,9 +113,9 @@ type Container interface {
|
||||
// Systemerror - System error.
|
||||
Signal(signal os.Signal) error
|
||||
|
||||
// OOM returns a read-only channel signaling when the container receives an OOM notification.
|
||||
// NotifyOOM returns a read-only channel signaling when the container receives an OOM notification.
|
||||
//
|
||||
// errors:
|
||||
// Systemerror - System error.
|
||||
OOM() (<-chan struct{}, error)
|
||||
NotifyOOM() (<-chan struct{}, error)
|
||||
}
|
||||
|
||||
+1
-1
@@ -275,6 +275,6 @@ func (c *linuxContainer) Signal(signal os.Signal) error {
|
||||
}
|
||||
|
||||
// TODO: rename to be more descriptive
|
||||
func (c *linuxContainer) OOM() (<-chan struct{}, error) {
|
||||
func (c *linuxContainer) NotifyOOM() (<-chan struct{}, error) {
|
||||
return NotifyOnOOM(c.cgroupManager.GetPaths())
|
||||
}
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@ var oomCommand = cli.Command{
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
n, err := container.OOM()
|
||||
n, err := container.NotifyOOM()
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user