I am currently trying out the RC2
release of ASP.NET Core
and I am running into an issue with SignalR
. I need to be able to send messa
Another possibility is to inject your HubContext into your controller like:
public VarDesignCommController(IHubContext hubcontext)
{
HubContext = hubcontext;
...
}
private IHubContext HubContext
{
get;
set;
}
Then you can also call
await this.HubContext.Clients.All.InvokeAsync("Completed", id);
But then you will direct call methods on all clients.
See also Call SignalR Core Hub method from Controller for an other possibility