mirror of
https://git.ianrenton.com/ian/spothole.git
synced 2026-09-20 06:17:41 +00:00
Extract webserver metrics into a separate class to avoid passing it into every API call. Change the display to requests per hour rather than just last request time. Add SSE and telnet client connected count.
This commit is contained in:
@@ -101,6 +101,10 @@ class TelnetServer:
|
||||
logger.debug("Stopping telnet server...")
|
||||
self._loop.call_soon_threadsafe(self._shutdown_event.set)
|
||||
|
||||
@property
|
||||
def client_count(self) -> int:
|
||||
return len(self._clients)
|
||||
|
||||
async def _stop_internal(self):
|
||||
"""Stops the telnet server"""
|
||||
|
||||
|
||||
Reference in New Issue
Block a user