AWS: Only warn about nameless instances if they are running

Otherwise this is just confusing logspam.

Fix #20912
This commit is contained in:
Justin Santa Barbara 2016-02-22 10:24:56 -05:00
parent d089fa8030
commit 7e69426b8b

View File

@ -2344,7 +2344,9 @@ func (a *AWSCloud) getInstancesByNodeNames(nodeNames []string) ([]*ec2.Instance,
for _, instance := range allInstances {
nodeName := aws.StringValue(instance.PrivateDnsName)
if nodeName == "" {
glog.V(2).Infof("ignoring ec2 instance with no PrivateDnsName: %q", aws.StringValue(instance.InstanceId))
if isAlive(instance) {
glog.V(2).Infof("ignoring ec2 instance with no PrivateDnsName: %q", aws.StringValue(instance.InstanceId))
}
continue
}
i, found := nodeNamesMap[nodeName]