private void ExecuteFullSync(CancellationToken cancellationToken) { _logService.Warn($"ExecuteFullSync on {_vacancyApplicationsUpdater.CollectionName} collection with LastCreatedDate: {_vacancyApplicationsUpdater.VacancyApplicationLastCreatedDate} LastUpdatedDate: {_vacancyApplicationsUpdater.VacancyApplicationLastUpdatedDate}"); _logService.Info("Loading Vacancy Ids"); var vacancyIds = _vacancyRepository.GetAllVacancyIds(); _logService.Info($"Completed loading {vacancyIds.Count} Vacancy Ids"); _logService.Info("Loading candidates"); var candidateIds = _candidateRepository.GetAllCandidateIds(); _logService.Info($"Completed loading {candidateIds.Count} candidates"); var expectedCount = _vacancyApplicationsRepository.GetVacancyApplicationsCount(cancellationToken).Result; var cursor = _vacancyApplicationsRepository.GetAllVacancyApplications(cancellationToken).Result; ProcessApplications(cursor, expectedCount, vacancyIds, candidateIds, SyncType.Full, cancellationToken); }