mirror of
https://github.com/pyMC-dev/pyMC_Repeater.git
synced 2026-06-26 21:11:34 +02:00
cd763e2cac
- Introduced a dedicated thread for broadcasting aggregate statistics to WebSocket clients, improving performance by offloading heavy queries from the packet write path. - Updated the _publish_packet_sync method to ensure only fast, per-packet operations are executed, while the stats are handled separately. - Added methods for broadcasting stats at intervals and managing the lifecycle of the stats thread. - Enhanced unit tests to validate the new stats broadcasting behavior and ensure correct functionality under various conditions.