User687406232 posted
Trying the Owin examples with Asp.net core on 4.61 and i get the following running from the console and VS . Any ideas ?
il: Microsoft.AspNetCore.Server.WebListener.MessagePump[0]
ProcessRequestAsync
System.NotSupportedException: The invoked member is not supported in a dynamic assembly.
at System.Reflection.Emit.InternalAssemblyBuilder.get_Location()
at Microsoft.AspNet.SignalR.Hubs.ReflectedHubDescriptorProvider.GetTypesSafe(Assembly a)
at System.Linq.Enumerable.<SelectManyIterator>d__16`2.MoveNext()
at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
at Microsoft.AspNet.SignalR.Hubs.ReflectedHubDescriptorProvider.BuildHubsCache()
at System.Lazy`1.CreateValue()
at System.Lazy`1.LazyInitValue()
at Microsoft.AspNet.SignalR.Hubs.ReflectedHubDescriptorProvider.TryGetHub(String hubName, HubDescriptor& descriptor)
at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
at Microsoft.AspNet.SignalR.Hubs.DefaultHubManager.GetHub(String hubName)
at Microsoft.AspNet.SignalR.Hubs.HubManagerExtensions.EnsureHub(IHubManager hubManager, String hubName, IPerformanceCounter[] counters)
at Microsoft.AspNet.SignalR.Infrastructure.ConnectionManager.GetHubContext(String hubName)
at SignalRChat.ChatHub.SendAll(String name, String message) in C:\src\cosmos\cosmos-livehole\Cosmos.LiveHoles.Read.WebApi\SignalR\ChatHub.cs:line 25
### Steps to reproduce
public class ChatHub : Hub
{
public void Send(string name, string message)
{
// Call the broadcastMessage method to update clients.
Clients.All.broadcastMessage(name, message);
}
static public void SendAll(string name, string message)
{
// Call the broadcastMessage method to update clients.
// Clients.All.broadcastMessage(name, message);
IHubContext context = GlobalHost.ConnectionManager.GetHubContext<ChatHub>();
context.Clients.All.displayPoll();
}
}
Call SendAll , GlobalHost.ConnectionManager.GetHubContext fails.