code: func NewPodInformer(client clientset.Interface, resyncPeriod time.Duration) coreinformers.PodInformer {
  	selector := fields.ParseSelectorOrDie(
  		"status.phase!=" + string(v1.PodSucceeded) +
  			",status.phase!=" + string(v1.PodFailed))
  	lw := cache.NewListWatchFromClient(client.CoreV1().RESTClient(), string(v1.ResourcePods), metav1.NamespaceAll, selector)
  	return &podInformer{
  		informer: cache.NewSharedIndexInformer(lw, &v1.Pod{}, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}),
  	}
  }
docs: // NewPodInformer creates a shared index informer that returns only non-terminal pods.