public async Task Execute(IJobExecutionContext context) { _logger.LogInformation("Checking for any pending migrations"); await _dbContext.Migrate(context.CancellationToken); // Import any new flat data prior to registering ban parsing jobs _logger.LogInformation("Checking for any updates to flat file data"); await _importer.RunImports(); // Call register jobs after db migration to ensure that the DB is actually created on first run before doing any ops _logger.LogInformation("Registering ban parsing jobs"); await Program.RegisterJobs(); }
public async Task Execute(IJobExecutionContext context) { _logger.LogInformation("Checking for any pending migrations"); var appliedMigration = await _dbContext.Migrate(context.CancellationToken); if (appliedMigration) { _logger.LogInformation("Applied new migration"); } // Import any new flat data prior to registering ban parsing jobs _logger.LogInformation("Checking for any updates to flat file data"); await _importer.RunImports(); // Call register jobs after db migration to ensure that the DB is actually created on first run before doing any ops _logger.LogInformation("Registering ban parsing jobs"); await RegisterJobs(); if (_providerConfigs != null) { await RegisterStandardJobs(); } }