Commit ba5a1113 authored by deads2k's avatar deads2k

don't queue namespaces for deletion if the namespace isn't deleted

parent 6f7eac63
......@@ -107,6 +107,13 @@ func (nm *NamespaceController) enqueueNamespace(obj interface{}) {
utilruntime.HandleError(fmt.Errorf("Couldn't get key for object %+v: %v", obj, err))
return
}
namespace := obj.(*v1.Namespace)
// don't queue if we aren't deleted
if namespace.DeletionTimestamp == nil || namespace.DeletionTimestamp.IsZero() {
return
}
// delay processing namespace events to allow HA api servers to observe namespace deletion,
// and HA etcd servers to observe last minute object creations inside the namespace
nm.queue.AddAfter(key, namespaceDeletionGracePeriod)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment