tech: move cron tab to specific time
This commit is contained in:
parent
390844c92b
commit
7c1b26930b
25 changed files with 25 additions and 25 deletions
|
@ -1,5 +1,5 @@
|
|||
class Cron::AdministrateurActivateBeforeExpirationJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at 8 am"
|
||||
self.schedule_expression = "every day at 08:00"
|
||||
|
||||
def perform(*args)
|
||||
Administrateur
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::AccountByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 4:30"
|
||||
FILE_NAME = "nb_comptes_crees_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::ExportAndPublishDemarchesPubliquesJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 4:00"
|
||||
self.schedule_expression = "every month at 4:10"
|
||||
|
||||
def perform(*args)
|
||||
gzip_filepath = [
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::FileByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 3:15"
|
||||
FILE_NAME = "nb_dossiers_crees_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::FileDeposeByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 5:00"
|
||||
FILE_NAME = "nb_dossiers_deposes_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::InstructeurByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 4:00"
|
||||
FILE_NAME = "nb_instructeurs_crees_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::InstructeurConnectedByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 4:45"
|
||||
FILE_NAME = "nb_instructeurs_connectes_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::ProcedureByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 4:15"
|
||||
FILE_NAME = "nb_procedures_creees_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::ProcedureClosedByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 4:00"
|
||||
FILE_NAME = "nb_procedures_closes_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::ProcedureDeletedByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 3:30"
|
||||
FILE_NAME = "nb_procedures_supprimees_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
class Cron::Datagouv::UserConnectedWithFranceConnectByMonthJob < Cron::CronJob
|
||||
include DatagouvCronSchedulableConcern
|
||||
self.schedule_expression = "every month at 3:00"
|
||||
self.schedule_expression = "every month at 3:45"
|
||||
FILE_NAME = "nb_utilisateurs_connectes_france_connect_par_mois"
|
||||
|
||||
def perform(*args)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::DiscardedDossiersDeletionJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at 2 am"
|
||||
self.schedule_expression = "every day at 02:00"
|
||||
|
||||
def perform
|
||||
Dossier.purge_discarded
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::DiscardedProceduresDeletionJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at 1 am"
|
||||
self.schedule_expression = "every day at 00:45"
|
||||
|
||||
def perform
|
||||
Procedure.purge_discarded
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::DossierOperationLogMoveToColdStorageJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at 1 am"
|
||||
self.schedule_expression = "every day at 10:00"
|
||||
|
||||
def perform
|
||||
DossierOperationLog
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::FixMissingAntivirusAnalysisJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at 2 am"
|
||||
self.schedule_expression = "every day at 01:45"
|
||||
|
||||
def perform
|
||||
ActiveStorage::Blob.where(virus_scan_result: ActiveStorage::VirusScanner::PENDING).find_each do |blob|
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::OperationsSignatureJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at 6 am"
|
||||
self.schedule_expression = "every day at 06:00"
|
||||
|
||||
def perform(*args)
|
||||
start_date = DossierOperationLog.where(bill_signature: nil).order(:executed_at).pick(:executed_at).beginning_of_day
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::ProcedureExternalURLCheckJob < Cron::CronJob
|
||||
self.schedule_expression = "every week on monday at 1 am"
|
||||
self.schedule_expression = "every week on monday at 01:00"
|
||||
|
||||
def perform
|
||||
Procedure.with_external_urls.find_each { ::ProcedureExternalURLCheckJob.perform_later(_1) }
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::ProcedureProcessSVASVRJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at 1:00"
|
||||
self.schedule_expression = "every day at 01:15"
|
||||
|
||||
def perform
|
||||
Procedure.sva_svr.find_each do |procedure|
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::PurgeManagerAdministrateurSessionsJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at 3 am"
|
||||
self.schedule_expression = "every day at 02:45"
|
||||
|
||||
def perform
|
||||
# TODO: add id column to administrateurs_procedures and use destroy_all
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::PurgeOldSibMailsJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at midnight"
|
||||
self.schedule_expression = "every day at 00:15"
|
||||
|
||||
def perform
|
||||
sib = Sendinblue::API.new
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::PurgeStaleTransfersJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at midnight"
|
||||
self.schedule_expression = "every day at 00:00"
|
||||
|
||||
def perform
|
||||
DossierTransfer.destroy_stale
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::PurgeUnattachedBlobsJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at midnight"
|
||||
self.schedule_expression = "every day at 00:30"
|
||||
|
||||
def perform
|
||||
# .in_batches { _1.each... } is more efficient in this case that in_batches.each_record or find_each
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::PurgeUnusedAdminJob < Cron::CronJob
|
||||
self.schedule_expression = "every monday at 5 am"
|
||||
self.schedule_expression = "every monday at 5:15"
|
||||
|
||||
def perform(*args)
|
||||
Administrateur.unused.destroy_all
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::SendAPITokenExpirationNoticeJob < Cron::CronJob
|
||||
self.schedule_expression = "every day at midnight"
|
||||
self.schedule_expression = "every day at 23:45"
|
||||
|
||||
def perform
|
||||
windows = [
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
class Cron::WeeklyOverviewJob < Cron::CronJob
|
||||
self.schedule_expression = "every monday at 4 am"
|
||||
self.schedule_expression = "every monday at 04:05"
|
||||
|
||||
def perform
|
||||
# Feature flipped to avoid mails in staging due to unprocessed dossier
|
||||
|
|
Loading…
Reference in a new issue