HasSynced returns true if the shared informer's store has been informed by at least one full LIST of the authoritative state of the informer's object collection. This is unrelated to "resync".
// HasSynced returns true if an Add/Update/Delete/AddIfNotPresent are called first,
// or an Update called first but the first batch of items inserted by Replace() has been popped
func(f*DeltaFIFO)HasSynced()bool{f.lock.Lock()deferf.lock.Unlock()returnf.populated&&f.initialPopulationCount==0}
func(p*processorListener)pop(){deferutilruntime.HandleCrash()deferclose(p.nextCh)// Tell .run() to stop
varnextChchan<-interface{}varnotificationinterface{}for{select{casenextCh<-notification:// Notification dispatched
varokboolnotification,ok=p.pendingNotifications.ReadOne()if!ok{// Nothing to pop
nextCh=nil// Disable this select case
}casenotificationToAdd,ok:=<-p.addCh:if!ok{return}ifnotification==nil{// No notification to pop (and pendingNotifications is empty)
// Optimize the case - skip adding to pendingNotifications
notification=notificationToAddnextCh=p.nextCh}else{// There is already a notification waiting to be dispatched
p.pendingNotifications.WriteOne(notificationToAdd)}}}}