signalr

How can i Add SignalR to my WCF Service and MVC 4 Client Application?

跟風遠走 提交于 2019-12-07 15:12:24
I am Developing a project for ASp.net MVC 4 client Application with WCF Service. I created a controller inside the MVC and added a view in it. and Also,i passed the data from view with ajax and jquery..after response from service,the result data value is stored in a html element.like that i am implemented.One part is completed.And the Second Part is I have an idea to add functionality ok SignalR in WCF and MVC4 Service? I thought SignalR is an Self-Hosted? How do i create a api for signalR in WCF and MVC4..below is my code are. MVC Controller:- using System; using System.Collections.Generic;

connet to asp.net core signalR server from a javascript client

蓝咒 提交于 2019-12-07 15:10:41
I have asp.net core web api server that is streaming a signalr, And it works for asp.net client , I am trying to make a connection with the code showen beelow but it only connects to a none core servers it wouldnt work for the core servers. //the hub class in the server code [EnableCors("AllowAllOrigins")] [HubName("LogNotifierHub")] public class LogNotifierHub : Hub { //methods defined here } startup code for the routing : app.UseSignalR(routes => { routes.MapHub<LogNotifierHub>("/NotifierHub"); }); javascript code for making the connection var hubUrl ="http://localhost:52273/logNotifierHub";

Implementing Signal R in android

我是研究僧i 提交于 2019-12-07 13:48:19
问题 I have tried in following way, import java.util.concurrent.ExecutionException; import microsoft.aspnet.signalr.client.LogLevel; import microsoft.aspnet.signalr.client.Logger; import microsoft.aspnet.signalr.client.Platform; import microsoft.aspnet.signalr.client.SignalRFuture; import microsoft.aspnet.signalr.client.http.android.AndroidPlatformComponent; import microsoft.aspnet.signalr.client.hubs.HubConnection; import microsoft.aspnet.signalr.client.hubs.HubProxy; import android.app.Activity;

Installing Asp.Net SignalR error while installing

*爱你&永不变心* 提交于 2019-12-07 10:52:43
问题 I am trying to install SignalR in Visual Studio 2010 professional project. But I am getting this error: Could not install package 'Microsoft.Owin.Security 2.1.0'. You are trying to install this package into a project that targets ' .NETFramework,Version=v4.0', but the package does not contain any assembly references or content files that are compatible with that framework. F or more information, contact the package author. 回答1: Try installing a different version of signal r with this command

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 connect to multiple servers

岁酱吖の 提交于 2019-12-07 09:53:43
问题 Is possible to connect using Javascript client to more than one SignalR servers? For example: <script type="text/javascript"> $.connection.hub.url = 'http://server1.net/signalr'; var server1Hub = $.connection.server1Hub; $.connection.hub.start().done(function () { }); // i need to connect to server2 $.connection.hub.url = 'http://server2.net/signalr'; var server2Hub = $.connection.server2Hub; $.connection.hub.start().done(function () { }); </script> Trying to connect (again) the second time

How to implement SignalR if there is more than one iis server?

删除回忆录丶 提交于 2019-12-07 09:53:32
问题 Is there support for a cluster of iis nodes when using SignalR? Or do I need some third party message bus? 回答1: Not yet, but they are working on it. It's planned for the 0.4 release. When ready, more information will probably be published in the wiki: SignalR and Webfarms on the wiki Edit2: Azure, SQL-Server and Redis are implemented. 回答2: We just implemented this addon in our application and so far it works flawlessly. It uses a RabbitMq instance to distribute the messages to other servers

SignalR and WinRT client: Don't call Wait() on Start()

折月煮酒 提交于 2019-12-07 09:38:29
问题 I have a question regarding SignalR's official documentation - Hubs API Guide - .NET Client. In the section - How to establish a connection . It has been written the following thing: The Start method executes asynchronously. To make sure that subsequent lines of code don't execute until after the connection is established, use await in an ASP.NET 4.5 asynchronous method or .Wait() in a synchronous method. Don't use .Wait() in a WinRT client. Does anyone know what is the specific reason not to

Android client for SignalR does not receive but JS does

家住魔仙堡 提交于 2019-12-07 08:45:51
问题 This is a "hello world" app but I can't find the solution. This is the code on the client: public class MainActivity extends ActionBarActivity { HubProxy proxy; EditText messageText; TextView resultText; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); Platform.loadPlatformComponent(new AndroidPlatformComponent()); //Setup connection String server = "http://10.0.2.2:8081/"; HubConnection connection = new

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 = $