pinned cadvisor to a latest commit

Signed-off-by: Tarun Pothulapati <tarunpothulapati@outlook.com>
This commit is contained in:
Tarun Pothulapati
2019-08-08 17:56:37 +05:30
parent 6d49d69c91
commit ce31366baf
28 changed files with 165 additions and 525 deletions

View File

@@ -70,7 +70,7 @@ type InMemoryCache struct {
lock sync.RWMutex
containerCacheMap map[string]*containerCache
maxAge time.Duration
backend storage.StorageDriver
backend []storage.StorageDriver
}
func (self *InMemoryCache) AddStats(cInfo *info.ContainerInfo, stats *info.ContainerStats) error {
@@ -86,11 +86,11 @@ func (self *InMemoryCache) AddStats(cInfo *info.ContainerInfo, stats *info.Conta
}
}()
if self.backend != nil {
for _, backend := range self.backend {
// TODO(monnand): To deal with long delay write operations, we
// may want to start a pool of goroutines to do write
// operations.
if err := self.backend.AddStats(cInfo, stats); err != nil {
if err := backend.AddStats(cInfo, stats); err != nil {
klog.Error(err)
}
}
@@ -131,7 +131,7 @@ func (self *InMemoryCache) RemoveContainer(containerName string) error {
func New(
maxAge time.Duration,
backend storage.StorageDriver,
backend []storage.StorageDriver,
) *InMemoryCache {
ret := &InMemoryCache{
containerCacheMap: make(map[string]*containerCache, 32),