From f8fe5c8d4107d50ecdb8a0aaa9a5189d525b7148 Mon Sep 17 00:00:00 2001 From: dgtlmoon Date: Tue, 14 May 2024 13:20:38 +0200 Subject: [PATCH] Set min to 3 seconds --- changedetectionio/flask_app.py | 4 ++-- changedetectionio/model/Watch.py | 2 +- changedetectionio/templates/settings.html | 2 +- docker-compose.yml | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/changedetectionio/flask_app.py b/changedetectionio/flask_app.py index 945f268e..d389c1a5 100644 --- a/changedetectionio/flask_app.py +++ b/changedetectionio/flask_app.py @@ -855,7 +855,7 @@ def changedetection_app(config=None, datastore_o=None): emailprefix=os.getenv('NOTIFICATION_MAIL_BUTTON_PREFIX', False), form=form, hide_remove_pass=os.getenv("SALTED_PASS", False), - min_system_recheck_seconds=int(os.getenv('MINIMUM_SECONDS_RECHECK_TIME', 20)), + min_system_recheck_seconds=int(os.getenv('MINIMUM_SECONDS_RECHECK_TIME', 3)), settings_application=datastore.data['settings']['application'] ) @@ -1665,7 +1665,7 @@ def ticker_thread_check_time_launch_checks(): proxy_last_called_time = {} - recheck_time_minimum_seconds = int(os.getenv('MINIMUM_SECONDS_RECHECK_TIME', 20)) + recheck_time_minimum_seconds = int(os.getenv('MINIMUM_SECONDS_RECHECK_TIME', 3)) logger.debug(f"System env MINIMUM_SECONDS_RECHECK_TIME {recheck_time_minimum_seconds}") # Spin up Workers that do the fetching diff --git a/changedetectionio/model/Watch.py b/changedetectionio/model/Watch.py index efea88e7..e262ac4e 100644 --- a/changedetectionio/model/Watch.py +++ b/changedetectionio/model/Watch.py @@ -12,7 +12,7 @@ from loguru import logger # file:// is further checked by ALLOW_FILE_URI SAFE_PROTOCOL_REGEX='^(http|https|ftp|file):' -minimum_seconds_recheck_time = int(os.getenv('MINIMUM_SECONDS_RECHECK_TIME', 60)) +minimum_seconds_recheck_time = int(os.getenv('MINIMUM_SECONDS_RECHECK_TIME', 3)) mtable = {'seconds': 1, 'minutes': 60, 'hours': 3600, 'days': 86400, 'weeks': 86400 * 7} from changedetectionio.notification import ( diff --git a/changedetectionio/templates/settings.html b/changedetectionio/templates/settings.html index 72f1f638..e72c7818 100644 --- a/changedetectionio/templates/settings.html +++ b/changedetectionio/templates/settings.html @@ -31,7 +31,7 @@
{{ render_field(form.requests.form.time_between_check, class="time-check-widget") }} - Default recheck time for all watches, system minimum is {{min_system_recheck_seconds}} seconds. + Default recheck time for all watches, current system minimum is {{min_system_recheck_seconds}} seconds (more info).
{{ render_field(form.requests.form.jitter_seconds, class="jitter_seconds") }} diff --git a/docker-compose.yml b/docker-compose.yml index a69ab3e9..4cf17605 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -56,7 +56,7 @@ services: # - FETCH_WORKERS=10 # # Absolute minimum seconds to recheck, overrides any watch minimum, change to 0 to disable - # - MINIMUM_SECONDS_RECHECK_TIME=20 + # - MINIMUM_SECONDS_RECHECK_TIME=3 # Comment out ports: when using behind a reverse proxy , enable networks: etc. ports: - 5000:5000