Closed juliusl closed 5 years ago
Ok I figured it out, it needs to be:
connection.On<object>("newMessage", (dynamic message) =>
{
Console.WriteLine($"{ message.sender} : {message.message}");
});
RE: those attributes are the bindings, but the confusing part is that in the generated function.json it doesn't list those bindings, but things appear to just work still.
I feel like I'm missing something really obvious. I have a .NET client using
Microsoft.AspNetCore.SignalR.Client (1.1.0)
My client code looks like this:
I'm using the C# version of the function code. They seem to be working because when I debug locally they are being hit and I'm seeing the connection is established from the portal. When I send a message from Postman I get a 204 and I can see it being processed on the function side by debugging locally.
1) I can't see any new messages hitting newMessage when I debug my client. 2) I don't see any messages sent in the portal with the graph.
Also, what's the point of the HubName for functions? I can't figure how that's used with respect to the .NET client. i.e.