From e9d194327addfa699d24d14d31c87b288647facb Mon Sep 17 00:00:00 2001 From: Bryan Boreham Date: Tue, 9 Jun 2015 15:19:55 +0100 Subject: [PATCH] Reduce level of noise in debug logs from containers dying --- ipam/allocator.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ipam/allocator.go b/ipam/allocator.go index 80a3ae73..7ab81b31 100644 --- a/ipam/allocator.go +++ b/ipam/allocator.go @@ -214,8 +214,11 @@ func (alloc *Allocator) Claim(ident string, addr address.Address, cancelChan <-c // ContainerDied is provided to satisfy the updater interface; does a 'Delete' underneath. Sync. func (alloc *Allocator) ContainerDied(ident string) error { - alloc.debugln("Container", ident, "died; releasing addresses") - return alloc.Delete(ident) + err := alloc.Delete(ident) + if err == nil { + alloc.debugln("Container", ident, "died; released addresses") + } + return err } // Delete (Sync) - release all IP addresses for container with given name