public async Task <ReAnalysisResults> ReAnalyzeExistingAsync()
        {
            var pageSize           = 100;
            var currentPage        = 0;
            var recordsLastFetched = 0;
            var reAnalysisResults  = new ReAnalysisResults();

            do
            {
                logger.LogDebug($"Reading batch of {pageSize} repositories from the database");

                var currentRepositoryBatch = await repositoryManager.ReadMultipleAsync(null, currentPage, pageSize);

                logger.LogDebug($"Successfully read {currentRepositoryBatch.Count} repositories");

                if (currentRepositoryBatch.Count > 0)
                {
                    foreach (var repository in currentRepositoryBatch)
                    {
                        var existingTypeAndImplementations = repository.Snapshot.TypesAndImplementations;

                        var reCalculatedTypeAndImplementations = await ScrapeRepositoryTypeAndImplementation(
                            repository.CurrentState.Name,
                            repository.Snapshot.Files,
                            repository.Snapshot.Dependencies,
                            repository.CurrentState.Topics?.Select(topic => topic.Name),
                            new BacklogInfo { HasIssues = repository.CurrentState.HasIssues ?? false },
                            null).ConfigureAwait(false);

                        // Sort both collections so when comparing we don't get false differences if the list order is different
                        var sortedExistingTypeAndImplemetnations     = existingTypeAndImplementations.OrderBy(typeAndImpl => typeAndImpl.TypeName);
                        var sortedReCalculatedTypeAndImplementations = reCalculatedTypeAndImplementations.OrderBy(typeAndImpl => typeAndImpl.TypeName);

                        var compareLogic     = new CompareLogic();
                        var comparisonResult = compareLogic.Compare(sortedExistingTypeAndImplemetnations, sortedReCalculatedTypeAndImplementations);

                        if (!comparisonResult.AreEqual)
                        {
                            repository.Snapshot.TypesAndImplementations = reCalculatedTypeAndImplementations;

                            logger.LogDebug($"Updating TypeAndImplementations information for repository {repository.CurrentState.Name}");

                            // TODO: Have this go through the manager and bypass existing logic ... there aren't any snapshot window
                            // updates needed here
                            await repositorySnapshotRepository.UpsertAsync(repository.Snapshot).ConfigureAwait(false);

                            reAnalysisResults.RecordsUpdated++;
                        }

                        reAnalysisResults.RecordsAnalyized++;
                    }
                }

                recordsLastFetched = currentRepositoryBatch.Count;
                currentPage++;
            } while (recordsLastFetched == pageSize);

            return(reAnalysisResults);
        }
        public async Task <ReAnalysisResults> ReAnalyzeExistingAsync()
        {
            var pageSize           = 100;
            var currentPage        = 0;
            var recordsLastFetched = 0;
            var reAnalysisResults  = new ReAnalysisResults();

            do
            {
                var currentRepositoryBatch = await repositoryManager.ReadMultipleAsync(null, currentPage, pageSize);

                if (currentRepositoryBatch.Count > 0)
                {
                    foreach (var repository in currentRepositoryBatch)
                    {
                        var existingTypeAndImplementations = repository.Snapshot.TypesAndImplementations;

                        var reCalculatedTypeAndImplementations = await ScrapeRepositoryTypeAndImplementation(
                            repository.CurrentState.Name,
                            repository.Snapshot.Files,
                            repository.Snapshot.Dependencies,
                            repository.CurrentState.Topics?.Select(topic => topic.Name),
                            new BacklogInfo { HasIssues = repository.CurrentState.HasIssues ?? false },
                            null).ConfigureAwait(false);

                        var compareLogic     = new CompareLogic();
                        var comparisonResult = compareLogic.Compare(existingTypeAndImplementations, reCalculatedTypeAndImplementations);

                        if (!comparisonResult.AreEqual)
                        {
                            repository.Snapshot.TypesAndImplementations = reCalculatedTypeAndImplementations;

                            // TODO: Have this go through the manager and bypass existing logic ... there aren't any snapshot window
                            // updates needed here
                            await repositorySnapshotRepository.UpsertAsync(repository.Snapshot).ConfigureAwait(false);

                            reAnalysisResults.RecordsUpdated++;
                        }

                        reAnalysisResults.RecordsAnalyized++;
                    }
                }

                recordsLastFetched = currentRepositoryBatch.Count;
                currentPage++;
            } while (recordsLastFetched == pageSize);

            return(reAnalysisResults);
        }