I have a Windows Service that is bare-bones. I need it to be a SignalR Client. The SignalR startup code includes an await so I need an asynchronous method. I can't put it in the OnStart method, yet I need this to happen after the startup has occured.
The SignalR code would be something like:
var hubConnection = new HubConnection("http://www.contoso.com/");
IHubProxy stockTickerHubProxy = hubConnection.CreateHubProxy("StockTickerHub");
stockTickerHubProxy.On<Stock>("UpdateStockPrice", stock => Console.WriteLine("Stock update for {0} new price {1}", stock.Symbol, stock.Price));
await hubConnection.Start();
How do I this having it run after startup?