code: func NewJobController(labelmap map[string]string, config *common.RuntimeConfig) (JobController, error) {
  	namespace := config.Namespace
  	queue := workqueue.NewRateLimitingQueue(workqueue.DefaultControllerRateLimiter())
  	labelset := labels.Set(labelmap)
  	optionsModifier := func(options *meta_v1.ListOptions) {
  		options.LabelSelector = labels.SelectorFromSet(labelset).String()
  	}
  
  	informer := config.InformerFactory.InformerFor(&batch_v1.Job{}, func(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
  		return cache.NewSharedIndexInformer(
  			cache.NewFilteredListWatchFromClient(client.BatchV1().RESTClient(), "jobs", namespace, optionsModifier),
  			&batch_v1.Job{},
  			resyncPeriod,
  			cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc},
  		)
  	})
  
  	informer.AddEventHandler(cache.ResourceEventHandlerFuncs{
  		AddFunc: func(obj interface{}) {
  			key, err := cache.MetaNamespaceKeyFunc(obj)
  			if err == nil {
  				queue.Add(key)
  			}
  			return
  		},
  		UpdateFunc: func(oldObj, newObj interface{}) {
  			key, err := cache.MetaNamespaceKeyFunc(newObj)
  			if err == nil {
  				glog.Infof("Got update notification for %s", key)
  				queue.Add(key)
  			}
  			return
  		},
  		DeleteFunc: func(obj interface{}) {
  			key, err := cache.DeletionHandlingMetaNamespaceKeyFunc(obj)
  			if err == nil {
  				glog.Infof("Got delete notification for %s", key)
  				queue.Add(key)
  			}
  		},
  	})
  
  	return &jobController{
  		RuntimeConfig: config,
  		namespace:     namespace,
  		queue:         queue,
  		jobLister:     batchlisters.NewJobLister(informer.GetIndexer()),
  	}, nil
  
  }
docs: // NewJobController instantiates  a new job controller.