Revert "Gracefully delete pods from the Kubelet"

This commit is contained in:
Filip Grzadkowski
2015-06-02 23:40:05 +02:00
parent 52e5df7ebb
commit 98115facfd
66 changed files with 233 additions and 860 deletions

View File

@@ -21,7 +21,6 @@ import (
"fmt"
"sort"
"sync"
"time"
"github.com/coreos/go-etcd/etcd"
)
@@ -54,8 +53,6 @@ type FakeEtcdClient struct {
TestIndex bool
ChangeIndex uint64
LastSetTTL uint64
// Will avoid setting the expires header on objects to make comparison easier
HideExpires bool
Machines []string
// Will become valid after Watch is called; tester may write to it. Tester may
@@ -187,11 +184,6 @@ func (f *FakeEtcdClient) setLocked(key, value string, ttl uint64) (*etcd.Respons
prevResult := f.Data[key]
createdIndex := prevResult.R.Node.CreatedIndex
f.t.Logf("updating %v, index %v -> %v (ttl: %d)", key, createdIndex, i, ttl)
var expires *time.Time
if !f.HideExpires && ttl > 0 {
now := time.Now()
expires = &now
}
result := EtcdResponseWithError{
R: &etcd.Response{
Node: &etcd.Node{
@@ -199,7 +191,6 @@ func (f *FakeEtcdClient) setLocked(key, value string, ttl uint64) (*etcd.Respons
CreatedIndex: createdIndex,
ModifiedIndex: i,
TTL: int64(ttl),
Expiration: expires,
},
},
}