func (s *StateStore) JobsByGC(ws memdb.WatchSet, gc bool) (memdb.ResultIterator, error) {
	txn := s.db.Txn(false)

	iter, err := txn.Get("jobs", "gc", gc)
	if err != nil {
		return nil, err
	}

	ws.Add(iter.WatchCh())

	return iter, nil
}
// JobsByGC returns an iterator over all jobs eligible or uneligible for garbage
// collection.
JobsByGC returns an iterator over all jobs eligible or uneligible for garbage
collection.
// JobsByGC returns an iterator over all jobs eligible or uneligible for garbage // collection .
func (s *StateStore) JobsByGC(ws memdb.WatchSet, gc bool) (memdb.ResultIterator, error) {
	txn := s.db.Txn(false)
	iter, err := txn.Get("jobs", "gc", gc)
	if err != nil {
		return nil, err
	}
	ws.Add(iter.WatchCh())
	return iter, nil
}
func ( s * StateStore ) JobsByGC ( ws memdb . WatchSet , gc bool ) ( memdb . ResultIterator , error ) { txn := s . db . Txn ( false ) iter , err := txn . Get ( " " , " " , gc ) if err != nil { return nil , err } ws . Add ( iter . WatchCh ( ) ) return iter , nil }
JobsByGC returns an iterator over all jobs eligible or uneligible for garbage
collection.
JobsByGC returns an iterator over all jobs eligible or uneligible for garbage collection .