signalr-hub

“Value cannot be null” when passing null arguments to SignalR client-side proxy

天涯浪子 提交于 2019-12-08 17:05:48
问题 Using SignalR (v2.0.2) I'm getting this exception: Value cannot be null. Parameter name: o at Newtonsoft.Json.Utilities.ValidationUtils.ArgumentNotNull(Object value, String parameterName) at Newtonsoft.Json.Linq.JToken.FromObjectInternal(Object o, JsonSerializer jsonSerializer) at Newtonsoft.Json.Linq.JToken.FromObject(Object o, JsonSerializer jsonSerializer) at Microsoft.AspNet.SignalR.Client.Hubs.HubProxy.Invoke[T](String method, Object[] args) I'm calling the HubProxy with reflection, and

Signalr Owin simple example javascript client not being called

断了今生、忘了曾经 提交于 2019-12-08 12:42:07
问题 I have a 5.3.0 version of signalr self hosting that is being upgraded to a newer version of signalr. Using https://github.com/SignalR/SignalR/wiki/Self-host example i have created a simple example, but i can’t get it to work. I can get a connection to the hub on the server and call methods on the hub, but i can’t get the hub to call the javascript client. When looking at it in fiddler I never see a response come back from the hub. Here is the code using System; using Microsoft.AspNet.SignalR;

Connect to SignalR server in dotnet core from .NET client

一曲冷凌霜 提交于 2019-12-08 08:39:05
问题 I have a signalR server implemented in Dotnet Core 2.0, below is the code for the server Startup.cs public void ConfigureServices(IServiceCollection services) { services.AddMvc(); services.AddSignalR (); } public void Configure(IApplicationBuilder app, IHostingEnvironment env) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } app.UseMvc(); app.UseSignalR (routes => { routes.MapHub <NotificationsHub> ("notificationshub"); }); } NotificationsHub.cs public class NotificationsHub :

SignalR, Server side methods can be called, but client side methods cannot, only in production environment

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-08 07:48:29
I have successfully developed an hub for my newsletter sending function in a .net website. The server procedure is called by the hub, then during the sending routine, I send a client methods to report the progress status, and finally another client method to report ending of the routine. My dev environment is win10 with IIS 10, VS2013, .NET 4.5 SignalR 2.2.0. I can use websocket in my dev and work fine, but my production server is win 2008r2 (IIS 7.5), so I must use serverSentEvents, working as well on dev. Here my client code: $.connection.hub.logging = true; hubConn = $.connection

SignalR Hub connectivity from Windows Phone 8

最后都变了- 提交于 2019-12-08 07:17:23
问题 What I'm trying should be basic; but must be missing something. Have couple of SignalR Hubs defined inside an MVC3 app running locally. Same solution has a Windows Phone 8 & a Windows Store app, both talking to the SignalR hubs for real-time communication. SignalR server uses latest bits & clients use latest .NET nuget. On the client side, this is what I'm used to writing: IHubProxy SignalRChatHub; HubConnection chatConnection = new HubConnection("http://localhost:53478/"); SignalRChatHub =

SignalR and large number of groups

对着背影说爱祢 提交于 2019-12-08 05:06:36
问题 I'm using SignalR's latest version and it's great. However, I've recently hit an interesting scaling issue: it seems that SignalR sends all the client's groups from the client in the query string. My system requires that a person join numerous groups, which represent all the projects that the user is subscribed to, and receive notifications on any of them. this large number of groups (and me using GUIDs for ids) has caused the querystring to reach its maximum size, and SignalR to stop working

SignalR, Server side methods can be called, but client side methods cannot, only in production environment

不羁岁月 提交于 2019-12-08 03:52:28
问题 I have successfully developed an hub for my newsletter sending function in a .net website. The server procedure is called by the hub, then during the sending routine, I send a client methods to report the progress status, and finally another client method to report ending of the routine. My dev environment is win10 with IIS 10, VS2013, .NET 4.5 SignalR 2.2.0. I can use websocket in my dev and work fine, but my production server is win 2008r2 (IIS 7.5), so I must use serverSentEvents, working

SignalR 2.2.0 WebSocket error connecting to hub

霸气de小男生 提交于 2019-12-08 02:14:47
问题 I have an ASP.Net MVC application that I have added SignalR to. After following the "Getting Started" tutorial (with modifications of course since it's going in my application) I got it working on localhost. However once it's in the production environment, I get the following error: WebSocket connection to 'ws://xxxxx/signalr/connect?transport=webSockets&clientProtocol=1.5&connectionToken=xxxxx' failed: Connection closed before receiving a handshake response. I can access /signalr/hubs (I get

SignalR 2 long polling “protocol” request times out when not ran locally

百般思念 提交于 2019-12-07 10:01:27
问题 Currently I have an app that is very chatty and needs to be supported by a Singleton(See Code below). I upgraded to SignalR 2.0 and I followed the upgrade guide, but after I deploy it out to an environment, sometimes all requests for every "protocol" fail, and signalr breaks, and when it doesn't break then it is terribly slow to push notifications down to the client from the server, Maybe this has something to do with it using long polling? Here is what my server side code looks like.

Signalr Close Connection

半世苍凉 提交于 2019-12-07 07:28:34
问题 I am trying to create a stop button in my webapp. The webapp creates bulk shortcuts to different files. I have tried using $.connection.shortcutHub.stop() however this comes up with an error saying Cannot read property 'shortcutHub' of undefined(anonymous function) The code is below. I need the connection to be stopped once the stop button has been clicked. The stop button's id is stopButton . $(document).ready(function () { // initialize the connection to the server var progressNotifier = $