diff --git a/container.go b/container.go index a22463780..6d681ac12 100644 --- a/container.go +++ b/container.go @@ -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) } diff --git a/linux_container.go b/linux_container.go index 07f08aee4..50df5ba7c 100644 --- a/linux_container.go +++ b/linux_container.go @@ -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()) } diff --git a/nsinit/oom.go b/nsinit/oom.go index eabe0b2bd..c1b4c8051 100644 --- a/nsinit/oom.go +++ b/nsinit/oom.go @@ -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) }