signalr

Does SignalR or websockets works with ASP.NET CORE 1.0?

不羁岁月 提交于 2019-12-24 17:07:50
问题 I need to implement realtime data sharing push based to my asp.net core 1.0 web application. i.e. If any new data is available I want to push it to all the connected clients/logged in users. I was considering SignalR & websockets for it but SignalR works on .net core 2.0 and websockets works on .net core 1.1 version. Here is the configuration in my csproj file <PropertyGroup> <TargetFramework>netcoreapp1.0</TargetFramework> <RuntimeFrameworkVersion>1.0.4</RuntimeFrameworkVersion>

Same Android app who runs on Debug mode, crashes on release mode

こ雲淡風輕ζ 提交于 2019-12-24 17:00:02
问题 I've written a simple app using Xamarin for Visual Studio and C# language. The code is: HubConnection hubConnection; IHubProxy chatHubProxy; async void btnConnect_Click(object sender, EventArgs e) { try { TextView log = FindViewById<TextView>(Resource.Id.txtLog); base.OnResume(); hubConnection = new HubConnection("http://192.168.1.3:2010/signalr"); chatHubProxy = hubConnection.CreateHubProxy("MyHub"); chatHubProxy.On<string>("AddMessage", (message) => { TextView text = FindViewById<TextView>

SignalR groups not invoked

房东的猫 提交于 2019-12-24 16:51:51
问题 I am doing my first tests with SignalR. I am toying with chat messages, but that's only a first step to replace all the polling from client to server which I have today on my site. I have a lot of scenarios where I want to notify certain users either by their login or by their ID. The idea is that I am adding each user to two groups as soon as he connects. I do this in OnConnected and that event is called. When I send a chat message, I have two modes: either public or personal. If it is

Push Notifications in SignalR from multiple Databases

 ̄綄美尐妖づ 提交于 2019-12-24 16:25:19
问题 I am relatively new to SignalR, What I have done so far are example chat applications on it to get started. We have a project that includes multiple databases, it's a machine data collection app. I have created a web control in ASP.NET MVC to view data of multiple machines at one place. We have multiple users and they can access machines related to their projects. The current solution have a jQuery observer on the mvc page which refreshes the machine controls in a specific time. I am thinking

StructureMap and SignalR - IMessageBus, no default instance defined

丶灬走出姿态 提交于 2019-12-24 13:02:52
问题 I used nuget to update my project to signalr 2.2 and structure map 2.6.4. Now when my program attempts to use SignalR, structure map is throwing this error: StructureMap.StructureMapException was unhandled by user code HResult=-2146232832 Message=StructureMap Exception Code: 202 No Default Instance defined for PluginFamily Microsoft.AspNet.SignalR.Messaging.IMessageBus, Microsoft.AspNet.SignalR.Core, Version=2.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 Source=StructureMap My code

StructureMap and SignalR - IMessageBus, no default instance defined

回眸只為那壹抹淺笑 提交于 2019-12-24 12:55:27
问题 I used nuget to update my project to signalr 2.2 and structure map 2.6.4. Now when my program attempts to use SignalR, structure map is throwing this error: StructureMap.StructureMapException was unhandled by user code HResult=-2146232832 Message=StructureMap Exception Code: 202 No Default Instance defined for PluginFamily Microsoft.AspNet.SignalR.Messaging.IMessageBus, Microsoft.AspNet.SignalR.Core, Version=2.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 Source=StructureMap My code

SignalR Update Panel Only Works First Time

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-24 12:37:32
问题 I have the following code inside of an update panel. When the screen loads, the SignalR code works fine. However, after the first time, once I click a button, the SignalR code does not fire anymore until I cause a redirect back to the page. Basically what I am doing is when the user clicks the preview button, it fires off the reporting process. An Ajax modal popup is displayed with a progress indicator and a cancel button. If the user clicks the cancel button, the cancelation token is set,

SignalR & SqlDependency Query performance

Deadly 提交于 2019-12-24 11:37:30
问题 I have a Table, it has around 1 million rows. This table is updated by web services, CMS applications and other sources. I want to Monitor few columns within this table. I read about SignalR and SqlDependency . However it seems like SqlDependency will re-scan the entire table on every change ?? My table is pretty large and I cant afford to rescan the DB upon every change. is the only solution is to use Trigger or something? I really want to stay away from Triggers. Here is the code: public

SignalR user is not registered in Client.Users

我只是一个虾纸丫 提交于 2019-12-24 11:35:05
问题 I am creating a chat between 2 users. Here's my hub and hub client: public class ConversationHub : Hub<IConversationHubClient> { public override Task OnConnected() { var id = this.Context.User.Identity.GetUserId(); //when I breakpoint here, I can see the id of my connected user. return base.OnConnected(); } } public interface IConversationHubClient { void MessageReceived(string conversationId, string userId, string text, DateTime date, bool isUser); } And from the mvc controller, I am calling

Multiple SignalR hubs with different configurations

我怕爱的太早我们不能终老 提交于 2019-12-24 10:48:02
问题 I've run into a situation where I need multiple SignalR hubs (at least 2) with different configurations. Currently with v1.1.0 I can only do things like the following which configures all hubs: GlobalHost.Configuration.ConnectionTimeout = TimeSpan.FromSeconds(30); Is it possible to set different configurations for multiple hubs? 回答1: All hubs share the same connection object therefore they all share the same configuration. If you want to have 1 server but multiple connection configurations