{"action":"created","issue":{"url":"https://api.github.com/repos/spotify/helios/issues/793","labels_url":"https://api.github.com/repos/spotify/helios/issues/793/labels{/name}","comments_url":"https://api.github.com/repos/spotify/helios/issues/793/comments","events_url":"https://api.github.com/repos/spotify/helios/issues/793/events","html_url":"https://github.com/spotify/helios/pull/793","id":122412977,"number":793,"title":"fix infinite loop if masters return 502 Bad Gateway","user":{"login":"mattnworb","id":113840,"avatar_url":"https://avatars.githubusercontent.com/u/113840?v=3","gravatar_id":"","url":"https://api.github.com/users/mattnworb","html_url":"https://github.com/mattnworb","followers_url":"https://api.github.com/users/mattnworb/followers","following_url":"https://api.github.com/users/mattnworb/following{/other_user}","gists_url":"https://api.github.com/users/mattnworb/gists{/gist_id}","starred_url":"https://api.github.com/users/mattnworb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mattnworb/subscriptions","organizations_url":"https://api.github.com/users/mattnworb/orgs","repos_url":"https://api.github.com/users/mattnworb/repos","events_url":"https://api.github.com/users/mattnworb/events{/privacy}","received_events_url":"https://api.github.com/users/mattnworb/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-12-16T02:25:59Z","updated_at":"2015-12-16T02:27:11Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/spotify/helios/pulls/793","html_url":"https://github.com/spotify/helios/pull/793","diff_url":"https://github.com/spotify/helios/pull/793.diff","patch_url":"https://github.com/spotify/helios/pull/793.patch"},"body":"AuthenticatingHttpConnector handles a 502 Bad Gateway response by just\ntrying another iteration of the `while (true)`.\n\nIf for some reason the endpoints always return 502 (for example, the\nservice behind nginx is down) then this means the\nAuthenticatingHttpConnector will loop forever (as long as the endpoints are\nreturning 502) with no way to interrupt.\n\nThis check for 502 Bad Gateway is better made in the DefaultHttpConnector\nas it has nothing to do with authentication. A response with this status\ncode will have an exception thrown so that it is caught by\nRetryingRequestDispatcher (and a new request is scheduled).\n\nAlso: broke out the separate \"authentication flows\" in\nAuthenticatingHttpConnector to make it easier to follow the various flows for\ndifferent authentication types and avoid the hairy `while true` loop."},"comment":{"url":"https://api.github.com/repos/spotify/helios/issues/comments/164966622","html_url":"https://github.com/spotify/helios/pull/793#issuecomment-164966622","issue_url":"https://api.github.com/repos/spotify/helios/issues/793","id":164966622,"user":{"login":"mattnworb","id":113840,"avatar_url":"https://avatars.githubusercontent.com/u/113840?v=3","gravatar_id":"","url":"https://api.github.com/users/mattnworb","html_url":"https://github.com/mattnworb","followers_url":"https://api.github.com/users/mattnworb/followers","following_url":"https://api.github.com/users/mattnworb/following{/other_user}","gists_url":"https://api.github.com/users/mattnworb/gists{/gist_id}","starred_url":"https://api.github.com/users/mattnworb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mattnworb/subscriptions","organizations_url":"https://api.github.com/users/mattnworb/orgs","repos_url":"https://api.github.com/users/mattnworb/repos","events_url":"https://api.github.com/users/mattnworb/events{/privacy}","received_events_url":"https://api.github.com/users/mattnworb/received_events","type":"User","site_admin":false},"created_at":"2015-12-16T02:27:11Z","updated_at":"2015-12-16T02:27:11Z","body":"This is a better version of #792 "}}