-
Notifications
You must be signed in to change notification settings - Fork 190
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prevent concurrent runs of the encoder by using a lock file with time…
…stamp - Added a lock file mechanism to prevent the `run` function from executing concurrently. - The lock file includes a timestamp to ensure it is valid only for 10 seconds. - If the lock file is older than 10 seconds, it will be removed before creating a new one. - Ensured the lock file is removed before every return statement to avoid stale locks. - This change helps avoid issues caused by concurrent executions of the encoder. This commit addresses the need to ensure only one instance of the encoder function runs at any given time, improving stability and reliability.
- Loading branch information
Daniel Neto
committed
Jul 18, 2024
1 parent
b8b50a1
commit a899045
Showing
1 changed file
with
56 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters