forked from kenzuya/unshackle
feat(serve): forward per-session service logs to remote-dl clients
Mirror each remote session's self.log into a bounded buffer, drained by the client via GET /api/session/{id}/logs and re-emitted locally. Server-account sessions get no relay. Also namespace service CLI options under service_params so a transport key (profile) no longer collides with a service's own option, on both the session and download-job paths.
This commit is contained in:
@@ -65,7 +65,7 @@ async def stats_middleware(request: web.Request, handler: Any) -> web.StreamResp
|
||||
else:
|
||||
stats.requests_by_key[mask_key(request_secret_key(request))] += 1
|
||||
session_id = request.match_info.get("session_id")
|
||||
if session_id and request.method != "OPTIONS":
|
||||
if session_id and request.method != "OPTIONS" and not request.path.endswith("/logs"):
|
||||
from unshackle.core.api.session_store import get_session_store
|
||||
|
||||
get_session_store().record_action(
|
||||
|
||||
Reference in New Issue
Block a user