Commit a9c95052 authored by Yu-Ju Hong's avatar Yu-Ju Hong

Use VirtualSize of the docker image as the image size

parent 3599d81e
......@@ -55,6 +55,6 @@ func toRuntimeImage(image *docker.APIImages) (*kubecontainer.Image, error) {
return &kubecontainer.Image{
ID: image.ID,
Tags: image.RepoTags,
Size: image.Size,
Size: image.VirtualSize,
}, nil
}
......@@ -51,9 +51,9 @@ func TestToRuntimeContainer(t *testing.T) {
func TestToRuntimeImage(t *testing.T) {
original := &docker.APIImages{
ID: "aeeea",
RepoTags: []string{"abc", "def"},
Size: 1234,
ID: "aeeea",
RepoTags: []string{"abc", "def"},
VirtualSize: 1234,
}
expected := &kubecontainer.Image{
ID: "aeeea",
......
......@@ -1173,7 +1173,7 @@ func (kl *Kubelet) SyncPods(allPods []*api.Pod, podSyncTypes map[types.UID]metri
}
// Note that we just killed the unwanted pods. This may not have reflected
// in the cache. We need to bypass the cach to get the latest set of
// in the cache. We need to bypass the cache to get the latest set of
// running pods to clean up the volumes.
// TODO: Evaluate the performance impact of bypassing the runtime cache.
runningPods, err = kl.containerRuntime.GetPods(false)
......
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