@@ -22,13 +22,14 @@ import (
22
22
"strings"
23
23
"time"
24
24
25
- "k8s.io/api/core/v1"
25
+ v1 "k8s.io/api/core/v1"
26
26
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
27
27
"k8s.io/apimachinery/pkg/util/sets"
28
28
"k8s.io/apimachinery/pkg/util/uuid"
29
29
"k8s.io/apimachinery/pkg/util/wait"
30
30
clientset "k8s.io/client-go/kubernetes"
31
31
"k8s.io/kubernetes/test/e2e/framework"
32
+ e2elog "k8s.io/kubernetes/test/e2e/framework/log"
32
33
"k8s.io/kubernetes/test/e2e/framework/volume"
33
34
testutils "k8s.io/kubernetes/test/utils"
34
35
imageutils "k8s.io/kubernetes/test/utils/image"
@@ -50,10 +51,10 @@ const (
50
51
// podNamePrefix and namespace.
51
52
func getPodMatches (c clientset.Interface , nodeName string , podNamePrefix string , namespace string ) sets.String {
52
53
matches := sets .NewString ()
53
- framework .Logf ("Checking pods on node %v via /runningpods endpoint" , nodeName )
54
+ e2elog .Logf ("Checking pods on node %v via /runningpods endpoint" , nodeName )
54
55
runningPods , err := framework .GetKubeletPods (c , nodeName )
55
56
if err != nil {
56
- framework .Logf ("Error checking running pods on %v: %v" , nodeName , err )
57
+ e2elog .Logf ("Error checking running pods on %v: %v" , nodeName , err )
57
58
return matches
58
59
}
59
60
for _ , pod := range runningPods .Items {
@@ -90,7 +91,7 @@ func waitTillNPodsRunningOnNodes(c clientset.Interface, nodeNames sets.String, p
90
91
if seen .Len () == targetNumPods {
91
92
return true , nil
92
93
}
93
- framework .Logf ("Waiting for %d pods to be running on the node; %d are currently running;" , targetNumPods , seen .Len ())
94
+ e2elog .Logf ("Waiting for %d pods to be running on the node; %d are currently running;" , targetNumPods , seen .Len ())
94
95
return false , nil
95
96
})
96
97
}
@@ -211,7 +212,7 @@ func checkPodCleanup(c clientset.Interface, pod *v1.Pod, expectClean bool) {
211
212
}
212
213
213
214
for _ , test := range tests {
214
- framework .Logf ("Wait up to %v for host's (%v) %q to be %v" , timeout , nodeIP , test .feature , condMsg )
215
+ e2elog .Logf ("Wait up to %v for host's (%v) %q to be %v" , timeout , nodeIP , test .feature , condMsg )
215
216
err = wait .Poll (poll , timeout , func () (bool , error ) {
216
217
result , err := framework .NodeExec (nodeIP , test .cmd )
217
218
Expect (err ).NotTo (HaveOccurred ())
@@ -229,9 +230,9 @@ func checkPodCleanup(c clientset.Interface, pod *v1.Pod, expectClean bool) {
229
230
}
230
231
231
232
if expectClean {
232
- framework .Logf ("Pod's host has been cleaned up" )
233
+ e2elog .Logf ("Pod's host has been cleaned up" )
233
234
} else {
234
- framework .Logf ("Pod's host has not been cleaned up (per expectation)" )
235
+ e2elog .Logf ("Pod's host has not been cleaned up (per expectation)" )
235
236
}
236
237
}
237
238
@@ -345,7 +346,7 @@ var _ = SIGDescribe("kubelet", func() {
345
346
start := time .Now ()
346
347
Expect (waitTillNPodsRunningOnNodes (f .ClientSet , nodeNames , rcName , ns , 0 ,
347
348
itArg .timeout )).NotTo (HaveOccurred ())
348
- framework .Logf ("Deleting %d pods on %d nodes completed in %v after the RC was deleted" , totalPods , len (nodeNames ),
349
+ e2elog .Logf ("Deleting %d pods on %d nodes completed in %v after the RC was deleted" , totalPods , len (nodeNames ),
349
350
time .Since (start ))
350
351
if resourceMonitor != nil {
351
352
resourceMonitor .LogCPUSummary ()
0 commit comments