mirror of
https://github.com/Dispatcharr/Dispatcharr.git
synced 2026-07-18 00:55:50 +00:00
If ProxyServer() raises during singleton construction, _instance was left as _INITIALIZING permanently, causing all subsequent get_instance() callers to spin in an infinite gevent.sleep() loop. Wrap construction in try/except and reset _instance to None on failure so callers can retry. Also replace the non-atomic setnx() + expire() pair in try_acquire_ownership() with a single atomic SET NX EX call, consistent with the approach already used in extend_ownership() and eliminating the race window where a crash between the two calls could leave a key with no TTL (permanent ownership lock). |
||
|---|---|---|
| .. | ||
| hls_proxy | ||
| management/commands | ||
| ts_proxy | ||
| vod_proxy | ||
| __init__.py | ||
| apps.py | ||
| config.py | ||
| signals.py | ||
| tasks.py | ||
| urls.py | ||
| views.py | ||