From b4ebf34728dc4dea0d9260334e6616ec0a0f091e Mon Sep 17 00:00:00 2001 From: liangxu Date: Tue, 23 Jun 2026 01:20:38 +0800 Subject: [PATCH] fix: apply monitoring lease recovery interval migration --- ...1500_set_monitoring_lease_recovery_interval_10m.down.sql | 5 +++++ ...111500_set_monitoring_lease_recovery_interval_10m.up.sql | 6 ++++++ 2 files changed, 11 insertions(+) create mode 100644 server/migrations_ops/20260623111500_set_monitoring_lease_recovery_interval_10m.down.sql create mode 100644 server/migrations_ops/20260623111500_set_monitoring_lease_recovery_interval_10m.up.sql diff --git a/server/migrations_ops/20260623111500_set_monitoring_lease_recovery_interval_10m.down.sql b/server/migrations_ops/20260623111500_set_monitoring_lease_recovery_interval_10m.down.sql new file mode 100644 index 0000000..5299f11 --- /dev/null +++ b/server/migrations_ops/20260623111500_set_monitoring_lease_recovery_interval_10m.down.sql @@ -0,0 +1,5 @@ +UPDATE ops.scheduler_jobs +SET interval_seconds = 60, + config = COALESCE(config, '{}'::jsonb) - 'suppress_empty_success_runs' - 'empty_success_metric_keys', + updated_at = NOW() +WHERE job_key = 'monitoring_lease_recovery'; diff --git a/server/migrations_ops/20260623111500_set_monitoring_lease_recovery_interval_10m.up.sql b/server/migrations_ops/20260623111500_set_monitoring_lease_recovery_interval_10m.up.sql new file mode 100644 index 0000000..ea9fcd1 --- /dev/null +++ b/server/migrations_ops/20260623111500_set_monitoring_lease_recovery_interval_10m.up.sql @@ -0,0 +1,6 @@ +UPDATE ops.scheduler_jobs +SET interval_seconds = 600, + description = '按过期租约索引限批回收超过租约时间仍未回调的监控任务,并释放卡住的桌面监控任务。', + config = COALESCE(config, '{}'::jsonb) || '{"suppress_empty_success_runs":true,"empty_success_metric_keys":["expired_task_count","failed_desktop_monitor_count"]}'::jsonb, + updated_at = NOW() +WHERE job_key = 'monitoring_lease_recovery';