Replace asyncio.to_thread with ThreadPoolExecutor.run_in_executor
- Add ThreadPoolExecutor with 3 max workers to SeriesApp - Replace all asyncio.to_thread calls with loop.run_in_executor - Add shutdown() method to properly cleanup executor - Integrate SeriesApp.shutdown() into FastAPI shutdown sequence - Ensures proper resource cleanup on Ctrl+C (SIGINT/SIGTERM)
This commit is contained in:
24
data/config_backups/config_backup_20260103_205109.json
Normal file
24
data/config_backups/config_backup_20260103_205109.json
Normal file
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"name": "Aniworld",
|
||||
"data_dir": "data",
|
||||
"scheduler": {
|
||||
"enabled": true,
|
||||
"interval_minutes": 60
|
||||
},
|
||||
"logging": {
|
||||
"level": "INFO",
|
||||
"file": null,
|
||||
"max_bytes": null,
|
||||
"backup_count": 3
|
||||
},
|
||||
"backup": {
|
||||
"enabled": false,
|
||||
"path": "data/backups",
|
||||
"keep_days": 30
|
||||
},
|
||||
"other": {
|
||||
"master_password_hash": "$pbkdf2-sha256$29000$X4uRMibE.N.bM.acs1ZKSQ$88em69lhlaLiS6vcF9oqf4pCC8KBbIj/O3h4cQFwM.I",
|
||||
"anime_directory": "/mnt/server/serien/Serien/"
|
||||
},
|
||||
"version": "1.0.0"
|
||||
}
|
||||
24
data/config_backups/config_backup_20260103_205117.json
Normal file
24
data/config_backups/config_backup_20260103_205117.json
Normal file
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"name": "Aniworld",
|
||||
"data_dir": "data",
|
||||
"scheduler": {
|
||||
"enabled": true,
|
||||
"interval_minutes": 60
|
||||
},
|
||||
"logging": {
|
||||
"level": "INFO",
|
||||
"file": null,
|
||||
"max_bytes": null,
|
||||
"backup_count": 3
|
||||
},
|
||||
"backup": {
|
||||
"enabled": false,
|
||||
"path": "data/backups",
|
||||
"keep_days": 30
|
||||
},
|
||||
"other": {
|
||||
"master_password_hash": "$pbkdf2-sha256$29000$TQlBSOndm1MKAWAMoTRGKA$a/q5miowGpjWSc71WDvqBpL9JJmuAO1FrZlCi3qwp2E",
|
||||
"anime_directory": "/mnt/server/serien/Serien/"
|
||||
},
|
||||
"version": "1.0.0"
|
||||
}
|
||||
Reference in New Issue
Block a user