I'm following the instruction by Microsoft but I can't use BackgroundSocketProcessor . Do I miss any library ?
Program.cs
:
app.Run(async (context) =>
{
using var webSocket = await context.WebSockets.AcceptWebSocketAsync();
var socketFinishedTcs = new TaskCompletionSource<object>();
BackgroundSocketProcessor.AddSocket(webSocket, socketFinishedTcs);
await socketFinishedTcs.Task;
});
I'm really confused and trying to figure out why it doesn't work