INNER CODE UNIT · Go
oldTunnel
inlets/inlets-operator · controller.go:133
oldTunnel := old.(*inletsv1alpha1.Tunnel)
if newTunnel.ResourceVersion == oldTunnel.ResourceVersion {
// Periodic resync with no changes - only skip if the
// tunnel is fully provisioned: host is active and the
// client deployment has been created.
if newTunnel.Status.HostStatus == provision.ActiveStatus &&
newTunnel.Status.ClientDeploymentRef != nil &&
newTunnel.Status.ClientDeploymentRef.Name != "" {
return
}
}
controller.enqueueTunnel(new)
},
DeleteFunc: func(old interface{}) {
r, ok := checkCustomResourceType(old)
klog.Infof("Deleting Tunnel: %s.%s, references: %v", r.Name, r.Namespace, r.OwnerReferences)