public override void ExecuteCommand()
 {
     thresholdValues = new JavaScriptSerializer().Deserialize<AlertThresholds>(ReportHelpers.Load(StorageAccount, "Configuration.AlertThresholds.json", ContainerName));         
     //Check last activity in DB and last activity in catalog doesn't vary more than allowed threshold.
     CheckLagBetweenDBAndCatalog();
     //Check all newly uploaded packages in DB are present in catalog.
     DoIntegrityCheckBetweenDBAndCatalog();
 }
 public override void ExecuteCommand()
 {
     sqlQueryForDbAge = string.Format("select create_date from sys.databases where name = '{0}'", DbName);
     thresholdValues = new JavaScriptSerializer().Deserialize<AlertThresholds>(ReportHelpers.Load(StorageAccount, "Configuration.AlertThresholds.json", ContainerName));
     List<Tuple<string, string>> jobOutputs = new List<Tuple<string, string>>();
     jobOutputs.Add(new Tuple<string,string>("SyncPackagesToFailoverDC", CheckLagBetweenDBAndBlob()));
     jobOutputs.Add(new Tuple<string, string>("ImportCompletionStatus", CheckForInCompleteDBImport()));
     JArray reportObject = ReportHelpers.GetJson(jobOutputs);
     ReportHelpers.CreateBlob(StorageAccount, "RunBackgroundCheckForFailoverDCReport.json", ContainerName, "application/json", ReportHelpers.ToStream(reportObject));        
 }
 public override void ExecuteCommand()
 {
     thresholdValues = new JavaScriptSerializer().Deserialize<AlertThresholds>(ReportHelpers.Load(StorageAccount, "Configuration.AlertThresholds.json", ContainerName));
     List<Tuple<string, string>> jobOutputs = new List<Tuple<string, string>>();
     jobOutputs.Add(new Tuple<string, string>("PackageStatics", CheckoutForPackageStatics()));
     //jobOutputs.Add(new Tuple<string, string>("PurgePackageStatistics", CheckForPurgePackagStatisticsJob()));
     jobOutputs.Add(new Tuple<string, string>("HandleQueuedPackageEdits", CheckForHandleQueuedPackageEditJob()));
     // jobOutputs.Add(new Tuple<string, string>("BackupPackages", CheckForBackupPackagesJob())); commenting out this check temporarily as ListBlobs on ng-backups container is giving error.
     JArray reportObject = ReportHelpers.GetJson(jobOutputs);
     ReportHelpers.CreateBlob(StorageAccount, "RunBackGroundChecksForWorkerJobsReport.json", ContainerName, "application/json", ReportHelpers.ToStream(reportObject));              
 }
 public override void ExecuteCommand()
 {
     thresholdValues = new JavaScriptSerializer().Deserialize<AlertThresholds>(ReportHelpers.Load(StorageAccount, "Configuration.AlertThresholds.json", ContainerName));                  
     CheckLagBetweenCatalogAndLucene();
     DoIntegrityCheckBetweenCatalogAndLucene();
 }