Is it possible to call a SignalR Hub from Postman
Now is possible with Postman version > 8.0 using WebSocket Request block. You can grab the information in their blog post https://blog.postman.com/postman-supports-websocket-apis/
Now is possible with Postman version > 8.0 using WebSocket Request block. You can grab the information in their blog post https://blog.postman.com/postman-supports-websocket-apis/
According to the statement here, you don’t need to remove connections from groups: You should not manually remove the user from the group when the user disconnects. This action is automatically performed by the SignalR framework. When a connection subscribes to a topic (which happens when you add the connection to a group), it receives … Read more
There is no easy way to set HTTP headers for SignalR requests using the JS or .NET client, but you can add parameters to the query string that will be sent as part of each SignalR request: JS Client $.connection.hub.qs = { “token” : tokenValue }; $.connection.hub.start().done(function() { /* … */ }); .NET Client var … Read more
IConnectionManager does not exist any more in SignalR for ASP.Net Core. I’ve been using HubContext for getting access to a hub. public class HomeController : Controller { private readonly IHubContext<LiveHub> _hubContext; public HomeController(IHubContext<LiveHub> hubContext) { _hubContext = hubContext; } public void SendToAll(string message) { _hubContext.Clients.All.InvokeAsync(“Send”, message); } } I’m using .net core 2.0.0 and SignalR … Read more
You need to use GetHubContext: var context = GlobalHost.ConnectionManager.GetHubContext<chatHub>(); context.Clients.All.Send(“Admin”, “stop the chat”); This is described in more detail at http://www.asp.net/signalr/overview/signalr-20/hubs-api/hubs-api-guide-server#callfromoutsidehub.
From what I see in the Connection and Hubs section it seems that Hubs provide a topic system overlaying the lower-level persistent connections. From the highly up-voted comment below: Partially correct. You can get topics or groups in persistent connections as well. The big difference is dispatching different types of messages. For example you have … Read more
No, SignalR is an abstraction over a connection. It gives you two programming models over that connection (hubs and persistent connections). SignalR has a concept of transports, each transport decides how data is sent/received and how it connects and disconnects. SignalR has a few built in transports: WebSockets Server Sent Events Forever Frame Long polling … Read more