code: func (s *Scheduler) ScheduleAllQueries(ctx context.Context, accessTokens map[string]string) {
  	cr.Stop()
  
  	trackerQueries := fetchTrackerQueries(s.db)
  	for _, tq := range trackerQueries {
  		cr.AddFunc(tq.Schedule, func() {
  			tr := lookupProvider(tq)
  			authToken := accessTokens[tq.TrackerType]
  
  			// In case of Jira, no auth token is needed hence the map wouldnt
  			// return anything. So effectively the authToken is optional.
  
  			for i := range tr.Fetch(authToken) {
  				models.Transactional(s.db, func(tx *gorm.DB) error {
  					// Save the remote items in a 'temporary' table.
  					err := Upload(tx, tq.TrackerID, i)
  					if err != nil {
  						return errors.WithStack(err)
  					}
  					// Convert the remote item into a local work item and persist in the DB.
  					_, err = ConvertToWorkItemModel(ctx, tx, i, tq)
  					return errors.WithStack(err)
  				})
  			}
  		})
  	}
  	cr.Start()
  }
docs: // ScheduleAllQueries fetch and import of remote tracker items