From 46b75c7525079eea1d80c0642fd5b5f55db46867 Mon Sep 17 00:00:00 2001 From: Martin Date: Tue, 27 Jun 2023 14:55:50 +0200 Subject: [PATCH 1/2] tech(active-storage.queues.purge): place les jobs de purge ds low_priority --- config/application.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/config/application.rb b/config/application.rb index cf264ec08..36183bc48 100644 --- a/config/application.rb +++ b/config/application.rb @@ -58,6 +58,7 @@ module TPS # Set the queue name for the analysis jobs to 'active_storage_analysis' config.active_storage.queues.analysis = :active_storage_analysis + config.active_storage.queues.purge = :expires config.to_prepare do # Make main application helpers available in administrate From cc4d1240683a65391997d0623983286222320da8 Mon Sep 17 00:00:00 2001 From: Martin Date: Tue, 27 Jun 2023 15:54:36 +0200 Subject: [PATCH 2/2] tech(expires): pause car on est entrain de trop enqueue de jobs --- app/jobs/cron/expired_dossiers_termine_deletion_job.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/jobs/cron/expired_dossiers_termine_deletion_job.rb b/app/jobs/cron/expired_dossiers_termine_deletion_job.rb index ce47f3f5a..0d9e796f1 100644 --- a/app/jobs/cron/expired_dossiers_termine_deletion_job.rb +++ b/app/jobs/cron/expired_dossiers_termine_deletion_job.rb @@ -2,6 +2,7 @@ class Cron::ExpiredDossiersTermineDeletionJob < Cron::CronJob self.schedule_expression = "every day at 7 am" def perform(*args) - ExpiredDossiersDeletionService.new.process_expired_dossiers_termine + # ExpiredDossiersDeletionService.new.process_expired_dossiers_termine + return "until we purge stock" end end