0

I have ASP.NET Core 2.2 app that hosts SignalR hub. I would like to use my WPF application (.NET Framework 4.7.2) to connect this hub. If I add NuGet package Microsoft.AspNetCore.SignalR.Client then I have many DLL files inclued into application references. Adding Microsoft.AspNet.SignalR.Client is much more cleaner but I cannot use it for connection. Is there a workaround for this?

4
  • I suppose you could obtain the source and mash all of the code together into a single DLL. But why bother? Commented Jan 14, 2019 at 16:11
  • Why does it matter if it has a lot of dependencies? What problem is it causing you? Commented Jan 14, 2019 at 16:16
  • @mason, when WPF app published via ClickOnce I get too many DLL files and this increases size of deployment package. Commented Jan 14, 2019 at 16:26
  • So? [ClickOnce] you'll have a one time download for the DLL's. They won't have to redownload them unless they change. The bottom line is that if you want to consume ASP.NET Core SignalR, then you need all of its dependencies unless you want to take on the massive undertaking of combing the source for it and all its dependencies into a single assembly. Then good luck handling updates to SignalR or any of its dependencies. You could also look into other tools that merge assemblies, but it's too broad of a question for Stack Overflow. Commented Jan 14, 2019 at 16:32

1 Answer 1

1

You cannot use the ASP.NET CORE SignalR (Hub or Client) with the ASP.NET SignalR (Hub or Client). You have to use a CORE client to connect to a CORE hub.

You are probably getting a 405 method not allowed error when you try.

See my response here that references the documentation.

SignalR version compatability (StatusCode: 405 'Method Not Allowed')

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.