{"action":"created","issue":{"url":"https://api.github.com/repos/bitfinexcom/bitfinex-api-go/issues/102","repository_url":"https://api.github.com/repos/bitfinexcom/bitfinex-api-go","labels_url":"https://api.github.com/repos/bitfinexcom/bitfinex-api-go/issues/102/labels{/name}","comments_url":"https://api.github.com/repos/bitfinexcom/bitfinex-api-go/issues/102/comments","events_url":"https://api.github.com/repos/bitfinexcom/bitfinex-api-go/issues/102/events","html_url":"https://github.com/bitfinexcom/bitfinex-api-go/pull/102","id":299538286,"number":102,"title":"Book subscriptions, improved heartbeats","user":{"login":"brobits","id":1591028,"avatar_url":"https://avatars0.githubusercontent.com/u/1591028?v=4","gravatar_id":"","url":"https://api.github.com/users/brobits","html_url":"https://github.com/brobits","followers_url":"https://api.github.com/users/brobits/followers","following_url":"https://api.github.com/users/brobits/following{/other_user}","gists_url":"https://api.github.com/users/brobits/gists{/gist_id}","starred_url":"https://api.github.com/users/brobits/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brobits/subscriptions","organizations_url":"https://api.github.com/users/brobits/orgs","repos_url":"https://api.github.com/users/brobits/repos","events_url":"https://api.github.com/users/brobits/events{/privacy}","received_events_url":"https://api.github.com/users/brobits/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-02-22T22:52:42Z","updated_at":"2018-03-06T21:37:04Z","closed_at":"2018-02-22T23:54:19Z","author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/bitfinexcom/bitfinex-api-go/pulls/102","html_url":"https://github.com/bitfinexcom/bitfinex-api-go/pull/102","diff_url":"https://github.com/bitfinexcom/bitfinex-api-go/pull/102.diff","patch_url":"https://github.com/bitfinexcom/bitfinex-api-go/pull/102.patch"},"body":"- add Len parameter to book subscriptions in API\r\n- simplify heartbeat threading model\r\n- improve test runtime speed\r\n- increased default shutdown timeout to 3 seconds (only affects process exit)"},"comment":{"url":"https://api.github.com/repos/bitfinexcom/bitfinex-api-go/issues/comments/370937146","html_url":"https://github.com/bitfinexcom/bitfinex-api-go/pull/102#issuecomment-370937146","issue_url":"https://api.github.com/repos/bitfinexcom/bitfinex-api-go/issues/102","id":370937146,"user":{"login":"mlensment","id":604295,"avatar_url":"https://avatars3.githubusercontent.com/u/604295?v=4","gravatar_id":"","url":"https://api.github.com/users/mlensment","html_url":"https://github.com/mlensment","followers_url":"https://api.github.com/users/mlensment/followers","following_url":"https://api.github.com/users/mlensment/following{/other_user}","gists_url":"https://api.github.com/users/mlensment/gists{/gist_id}","starred_url":"https://api.github.com/users/mlensment/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mlensment/subscriptions","organizations_url":"https://api.github.com/users/mlensment/orgs","repos_url":"https://api.github.com/users/mlensment/repos","events_url":"https://api.github.com/users/mlensment/events{/privacy}","received_events_url":"https://api.github.com/users/mlensment/received_events","type":"User","site_admin":false},"created_at":"2018-03-06T21:37:04Z","updated_at":"2018-03-06T21:37:04Z","author_association":"NONE","body":"I see that you improved heartbeats, but what's the best way to recover from HB timeouts / other potential errors that might influence the socket? I'm  currently thinking of setting the ReconnectAttempts parameter really high, but that does not seem too good of a solution. \r\n\r\nThe client is running in a separate goroutine and I tried to panic and recover (start the same goroutine again) when the socket closes. It works, but I encountered a dramatic increase in CPU usage. I traced the problem to be related with this line: https://github.com/bitfinexcom/bitfinex-api-go/blob/master/v2/websocket/transport.go#L56."}}
{"actor":{"display_login":"mlensment"}}