{"action":"created","issue":{"url":"https://api.github.com/repos/aspnet/SignalR/issues/2489","repository_url":"https://api.github.com/repos/aspnet/SignalR","labels_url":"https://api.github.com/repos/aspnet/SignalR/issues/2489/labels{/name}","comments_url":"https://api.github.com/repos/aspnet/SignalR/issues/2489/comments","events_url":"https://api.github.com/repos/aspnet/SignalR/issues/2489/events","html_url":"https://github.com/aspnet/SignalR/issues/2489","id":332259275,"node_id":"MDU6SXNzdWUzMzIyNTkyNzU=","number":2489,"title":"waiting in console client for received messages","user":{"login":"kofifus","id":3926071,"node_id":"MDQ6VXNlcjM5MjYwNzE=","avatar_url":"https://avatars1.githubusercontent.com/u/3926071?v=4","gravatar_id":"","url":"https://api.github.com/users/kofifus","html_url":"https://github.com/kofifus","followers_url":"https://api.github.com/users/kofifus/followers","following_url":"https://api.github.com/users/kofifus/following{/other_user}","gists_url":"https://api.github.com/users/kofifus/gists{/gist_id}","starred_url":"https://api.github.com/users/kofifus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kofifus/subscriptions","organizations_url":"https://api.github.com/users/kofifus/orgs","repos_url":"https://api.github.com/users/kofifus/repos","events_url":"https://api.github.com/users/kofifus/events{/privacy}","received_events_url":"https://api.github.com/users/kofifus/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-06-14T05:46:19Z","updated_at":"2018-06-14T15:21:31Z","closed_at":null,"author_association":"NONE","body":"Looking at the [HubSample.cs](https://github.com/aspnet/SignalR/blob/dev/samples/ClientSample/HubSample.cs)\r\n\r\nThe sample client is waiting on console input and sending it to the hub.\r\n\r\nA more common scenario is where you want the client to send some messages and then wait for any incoming messages from the hub, and only exit when the hub disconnected.\r\n\r\nWhat is the correct way to wait in the console client for messages when Console.ReadLine() etc are not relevant ?\r\n"},"comment":{"url":"https://api.github.com/repos/aspnet/SignalR/issues/comments/397334430","html_url":"https://github.com/aspnet/SignalR/issues/2489#issuecomment-397334430","issue_url":"https://api.github.com/repos/aspnet/SignalR/issues/2489","id":397334430,"node_id":"MDEyOklzc3VlQ29tbWVudDM5NzMzNDQzMA==","user":{"login":"BrennanConroy","id":7574801,"node_id":"MDQ6VXNlcjc1NzQ4MDE=","avatar_url":"https://avatars0.githubusercontent.com/u/7574801?v=4","gravatar_id":"","url":"https://api.github.com/users/BrennanConroy","html_url":"https://github.com/BrennanConroy","followers_url":"https://api.github.com/users/BrennanConroy/followers","following_url":"https://api.github.com/users/BrennanConroy/following{/other_user}","gists_url":"https://api.github.com/users/BrennanConroy/gists{/gist_id}","starred_url":"https://api.github.com/users/BrennanConroy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BrennanConroy/subscriptions","organizations_url":"https://api.github.com/users/BrennanConroy/orgs","repos_url":"https://api.github.com/users/BrennanConroy/repos","events_url":"https://api.github.com/users/BrennanConroy/events{/privacy}","received_events_url":"https://api.github.com/users/BrennanConroy/received_events","type":"User","site_admin":false},"created_at":"2018-06-14T15:21:31Z","updated_at":"2018-06-14T15:21:31Z","author_association":"CONTRIBUTOR","body":"Waiting is very application specific. If you really just want to sit around doing nothing and wait for messages to be received you could do something like:\r\n```\r\nwhile (some condition)\r\n{\r\n    // wake up every 5 seconds\r\n    await Task.Delay(5000);\r\n}\r\n```"}}
{"actor":{"display_login":"BrennanConroy"}}