mirror of
https://github.com/SoPat712/allstarr.git
synced 2026-02-10 07:58:39 -05:00
websocket stuff
This commit is contained in:
@@ -22,10 +22,21 @@ public class WebSocketProxyMiddleware
|
||||
_next = next;
|
||||
_settings = settings.Value;
|
||||
_logger = logger;
|
||||
|
||||
_logger.LogInformation("🔧 WebSocketProxyMiddleware initialized - Jellyfin URL: {Url}", _settings.Url);
|
||||
}
|
||||
|
||||
public async Task InvokeAsync(HttpContext context)
|
||||
{
|
||||
// Log ALL requests to /socket path for debugging
|
||||
if (context.Request.Path.StartsWithSegments("/socket", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
_logger.LogInformation("📡 Request to /socket path - IsWebSocketRequest: {IsWs}, Method: {Method}, Headers: {Headers}",
|
||||
context.WebSockets.IsWebSocketRequest,
|
||||
context.Request.Method,
|
||||
string.Join(", ", context.Request.Headers.Select(h => $"{h.Key}={h.Value}")));
|
||||
}
|
||||
|
||||
// Check if this is a WebSocket request to /socket
|
||||
if (context.Request.Path.StartsWithSegments("/socket", StringComparison.OrdinalIgnoreCase) &&
|
||||
context.WebSockets.IsWebSocketRequest)
|
||||
|
||||
Reference in New Issue
Block a user