signalr

SignalR net45 gives 401 Unauthorized on specific user/machine combinations

末鹿安然 提交于 2019-12-12 01:19:41
问题 We recently updated a WPF app and all of its NuGet dependencies to .NET 4.5.2 and find that some users are receiving HTTP 401 Unauthorized errors from SignalR. The is using Windows Authentication via PrincipalUserIdProvider. I receive the 401 error on the first POST to SignalR after connecting to SignalR but here are many reasons why this is a strange issue: It works when I have Fiddler running It works when I run the app on Citrix It works when I run the app with a Run As on another person's

SignalR fails on IIS

泪湿孤枕 提交于 2019-12-12 01:13:01
问题 SignalR has a nice example for using a Persistent Connection which works just fine when I use IIS Express. It fails when I use the same on the regular IIS that is installed on my Windows 7 system. And it fails silently too, except for the Chrome console telling me: "Failed to load resource: the server responded with a status of 404 (Not Found) ". It is looking for http*:*//localhost:80/echo/negotiate?_=1371821713975 which it can't find for whatever reason. And to make it even more complex:

SignalR 2.2.0 MVC 4 error client undefined

不打扰是莪最后的温柔 提交于 2019-12-12 00:54:56
问题 It's almost 12 hrs no success, I have tried this code in Web Project and it worked but when integrating with my MVC application it is giving me errors GET http://localhost:50843/signalr/Hubs DashBoard:553 Uncaught TypeError: Cannot read property 'client' of undefined(anonymous function) @ DashBoard:553 This error occurs usually when the hub script is not found I have tried many fixes but no luck here is my code. Project structure References ChatHub.cs (I have omitted the method implementation

SignalR Hub Connection Error

对着背影说爱祢 提交于 2019-12-11 21:21:47
问题 I've just started using a bit of SignalR and am trying to set it up so a windows service can send messages to a web page. I have the hub all setup and this seems to work fine within the website. Namespace SignalR Public Class SignalRHub Inherits Hub Public Sub Send(name As String, message As String) Clients.All.broadcastMessage(name, message) End Sub End Class End Namespace However I can't get my windows service to connect to the hub in any shape or form. The code below correctly gets an auth

How to get feedback from a Web API Process in order to update Front-End

做~自己de王妃 提交于 2019-12-11 19:48:53
问题 I have a Web API built in ASPNET Web API application that has a Method that runs a lot of processes, like follows: File processed Inserting records to DB Applying rules to records Validating results I would like to have a RealTime feedback from my server to my client in order to know what is the actual process that is being executed. I would like something like the Dropbox upload screen: I was reading that SignalR is a library for building RealTime applications. Any clue or sample on how can

Detecting when signalR hub is ready after hub.start()

血红的双手。 提交于 2019-12-11 19:34:45
问题 I have a parent and child viewModel. The parent viewmodel starts the signalR connection: $.connection.hub.start() The child viewmodel - one that loads only when the user accesses chat - does the following: chat.server.addUserToChat(self.currentUsername()).done(function() { alert('added'); }); The problem is, the child call is happening before the parent call. I can fix this with a setTimeOut of 1 second, but ideally I could do something like this: $.connection.hub.ready(function(){chat.server

SignalR stops after negotiate, doesn't ping, connect or make any long polling XHR requests

偶尔善良 提交于 2019-12-11 19:22:00
问题 I am using SignalR 1.1.2 with SQL as backplane, and frequently (like 70% of page loads), SignalR fires of negotiate request which suceedes (doesn't fail) and just halts and nothing happens anymore. I found out that there is some conflict with jquery.validation.js so I updated: jquery, jquery validation and jquery unobtrusive ajax to latest available versions, but it still happens,, Other times when it works correctly I can see few XHR requests made: negotiate connect ping long polling

Can not debug my Hub method after upgrading to SignalR 1-alpha2

為{幸葍}努か 提交于 2019-12-11 19:15:04
问题 I just upgraded to SignalR 1.0.0-Alpha2. After i did it, I can not debug my hub methods. It never reaches to the breakpoint. here is code Reference: <script src="../../Scripts/jquery.signalR-1.0.0-alpha2.min.js" type="text/javascript"></script> <script src="<%:Url.Content("~/signalr/hubs")%>" type="text/javascript"></script> Client: $(document).ready(function () { con = $.connection.messagingHub; $.connection.hub.start(function () { var myClientId = $.connection.hub.id; con.connectToHub('<%

Unable to get property 'client' of undefined in SignalR

点点圈 提交于 2019-12-11 19:05:40
问题 I'm getting the error Unable to get property 'client' of undefined while accessing the hub method clientside. My code is as below: I have my hub like this: [HubName("command")] public class CommandHub : Hub { public void TrackStatusCommand(string serialNumber) { Groups.Add(Context.ConnectionId, serialNumber); } public void StatusCompleted(string serialNumber, bool status) { Clients.Group(serialNumber).statusCompleted(serialNumber, status); } } var hubProxy = $.connection.command,

JQuery blocking for an asynch initialization

江枫思渺然 提交于 2019-12-11 18:06:02
问题 I'm writing an AngularJS service for a SignalR hub. Here's my factory for the service: .factory('gameManager', [function () { $.connection.hub.start(); var manager = $.connection.gameManager; return manager; }]) That code would be perfect, except that that .start() call is asynchronous, and the hub has not completed starting by the time the manager is returned. Basically, I want to block until the start is complete before returning the manager. The .start() method returns a Jquery deferred