From 3735aee7de886c254cf264c96f93e27a8b473217 Mon Sep 17 00:00:00 2001 From: Nick Mowen Date: Fri, 7 Jul 2023 13:39:44 -0600 Subject: [PATCH] Change name --- frigate/app.py | 10 +++++----- frigate/const.py | 2 +- frigate/util/builtin.py | 8 ++++++-- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/frigate/app.py b/frigate/app.py index b72c6bcdd..1b531b351 100644 --- a/frigate/app.py +++ b/frigate/app.py @@ -26,7 +26,7 @@ from frigate.const import ( CLIPS_DIR, CONFIG_DIR, DEFAULT_DB_PATH, - DEFAULT_QUEUE_SIZE, + DEFAULT_QUEUE_BUFFER_SIZE, EXPORT_DIR, MODEL_CACHE_DIR, RECORD_DIR, @@ -191,8 +191,8 @@ class FrigateApp: def init_queues(self) -> None: # Queues for clip processing - self.event_queue: Queue = ff.Queue(DEFAULT_QUEUE_SIZE) - self.event_processed_queue: Queue = ff.Queue(DEFAULT_QUEUE_SIZE) + self.event_queue: Queue = ff.Queue(DEFAULT_QUEUE_BUFFER_SIZE) + self.event_processed_queue: Queue = ff.Queue(DEFAULT_QUEUE_BUFFER_SIZE) self.video_output_queue: Queue = LQueue( maxsize=len(self.config.cameras.keys()) * 2 ) @@ -203,10 +203,10 @@ class FrigateApp: ) # Queue for recordings info - self.recordings_info_queue: Queue = ff.Queue(DEFAULT_QUEUE_SIZE) + self.recordings_info_queue: Queue = ff.Queue(DEFAULT_QUEUE_BUFFER_SIZE) # Queue for timeline events - self.timeline_queue: Queue = ff.Queue(DEFAULT_QUEUE_SIZE) + self.timeline_queue: Queue = ff.Queue(DEFAULT_QUEUE_BUFFER_SIZE) def init_database(self) -> None: def vacuum_db(db: SqliteExtDatabase) -> None: diff --git a/frigate/const.py b/frigate/const.py index 4565cb115..c508a83bf 100644 --- a/frigate/const.py +++ b/frigate/const.py @@ -49,4 +49,4 @@ MAX_PLAYLIST_SECONDS = 7200 # support 2 hour segments for a single playlist to # Queue Values -DEFAULT_QUEUE_SIZE = 2000 * 1000 # 2MB \ No newline at end of file +DEFAULT_QUEUE_BUFFER_SIZE = 2000 * 1000 # 2MB diff --git a/frigate/util/builtin.py b/frigate/util/builtin.py index d85b6aca5..1dca9026e 100644 --- a/frigate/util/builtin.py +++ b/frigate/util/builtin.py @@ -20,7 +20,11 @@ import yaml from faster_fifo import Queue as FFQueue from ruamel.yaml import YAML -from frigate.const import DEFAULT_QUEUE_SIZE, REGEX_HTTP_CAMERA_USER_PASS, REGEX_RTSP_CAMERA_USER_PASS +from frigate.const import ( + DEFAULT_QUEUE_BUFFER_SIZE, + REGEX_HTTP_CAMERA_USER_PASS, + REGEX_RTSP_CAMERA_USER_PASS, +) logger = logging.getLogger(__name__) @@ -68,7 +72,7 @@ class LimitedQueue(FFQueue): def __init__( self, maxsize=0, - max_size_bytes=DEFAULT_QUEUE_SIZE, + max_size_bytes=DEFAULT_QUEUE_BUFFER_SIZE, loads=None, dumps=None, ):