@@ -247,7 +247,7 @@ func (c *Controller) syncPod(ctx context.Context, pod *corev1.Pod) error {
247
247
instanceID := awssdk .StringValue (instance .Id )
248
248
serviceName := awssdk .StringValue (instance .Attributes [ctrlaws .AttrK8sApp ])
249
249
250
- klog .V (4 ).Info ("Pod: %s is currently registered with the service: %s" , podName , serviceName )
250
+ klog .V (4 ).Infof ("Pod: %s is currently registered with the service: %s" , podName , serviceName )
251
251
serviceInstanceSummary [instanceID ] = true
252
252
}
253
253
@@ -266,14 +266,15 @@ func (c *Controller) syncPod(ctx context.Context, pod *corev1.Pod) error {
266
266
serviceInstanceSummary = serviceItem .instanceSummary
267
267
serviceInstanceSummary [pod .Status .PodIP ] = true
268
268
} else {
269
- klog .V (4 ).Info ("Instance already %s registered under service %s" , pod .Name , * cloudmapConfig .ServiceName )
269
+ klog .V (4 ).Infof ("Instance already %s registered under service %s" , pod .Name , * cloudmapConfig .ServiceName )
270
270
return nil
271
271
}
272
272
} else {
273
273
serviceInstanceSummary [pod .Status .PodIP ] = true
274
274
}
275
275
276
- klog .Info ("Registering instance %s under service %s" , pod .Name , * cloudmapConfig .ServiceName )
276
+ // FIXME emitting this log is confusing when we might short-circuit in RegisterInstance
277
+ klog .Infof ("Registering instance %s under service %s" , pod .Name , * cloudmapConfig .ServiceName )
277
278
err = c .cloud .RegisterInstance (ctx , instanceID , pod , cloudmapConfig )
278
279
if err != nil {
279
280
return err
@@ -298,7 +299,7 @@ func (c *Controller) getServiceInstancesFromCloudMap(ctx context.Context,
298
299
return instances , err
299
300
}
300
301
301
- klog .V (4 ).Info ("Reach out to CloudMap for service: %s. Current Instance Count: " ,
302
+ klog .V (4 ).Infof ("Reach out to CloudMap for service: %s. Current Instance Count: %d " ,
302
303
* appmeshCloudMapConfig .ServiceName , len (instances ))
303
304
return instances , nil
304
305
}
0 commit comments