From 79ac7cf6d41ea7ab68861cc9b8d6c1f89e49e000 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Fern=C3=A1ndez=20Poyatos?= Date: Mon, 15 Dec 2025 17:13:08 +0100 Subject: [PATCH] fix(beat): Increase scheduled scans countdown to 5 seconds (#9558) --- api/CHANGELOG.md | 7 +++++++ api/src/backend/tasks/beat.py | 2 +- api/src/backend/tasks/tests/test_beat.py | 2 +- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/api/CHANGELOG.md b/api/CHANGELOG.md index 80414684a2..6b30d8ba02 100644 --- a/api/CHANGELOG.md +++ b/api/CHANGELOG.md @@ -14,6 +14,13 @@ All notable changes to the **Prowler API** are documented in this file. --- +## [1.16.2] (Prowler v5.15.2) + +### Changed +- Increased execution delay for the first scheduled scan tasks to 5 seconds[(#9558)](https://github.com/prowler-cloud/prowler/pull/9558) + +--- + ## [1.16.1] (Prowler v5.15.1) ### Fixed diff --git a/api/src/backend/tasks/beat.py b/api/src/backend/tasks/beat.py index a12002ac1a..262d47496a 100644 --- a/api/src/backend/tasks/beat.py +++ b/api/src/backend/tasks/beat.py @@ -61,5 +61,5 @@ def schedule_provider_scan(provider_instance: Provider): "tenant_id": str(provider_instance.tenant_id), "provider_id": provider_id, }, - countdown=1, # Avoid race conditions between the worker and the database + countdown=5, # Avoid race conditions between the worker and the database ) diff --git a/api/src/backend/tasks/tests/test_beat.py b/api/src/backend/tasks/tests/test_beat.py index e231e17f6a..5c25e97340 100644 --- a/api/src/backend/tasks/tests/test_beat.py +++ b/api/src/backend/tasks/tests/test_beat.py @@ -28,7 +28,7 @@ class TestScheduleProviderScan: "tenant_id": str(provider_instance.tenant_id), "provider_id": str(provider_instance.id), }, - countdown=1, + countdown=5, ) task_name = f"scan-perform-scheduled-{provider_instance.id}"