public void SendEvent(EventMessage message) { var eventMessageDto = Mapper.Map<EventMessage, EventMessageDto>(message); RedisPersistence.Store(eventMessageDto); Clients.All.eventReceived(message); }
public static void Send(EventMessage eventMessage) { // locking this operation so that it's thread safe lock (connectionLock) { if (!connected) { ConnectEventHub(); } if (hubConnection.State == ConnectionState.Connected) proxy.Invoke("SendEvent", eventMessage); else { ConnectEventHub(); proxy.Invoke("SendEvent", eventMessage); } } }
internal void Send(EventMessage eventMessage) { SignalRProxyConnection.Send(eventMessage); }