{"action":"opened","number":9319,"pull_request":{"url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/9319","id":97448622,"html_url":"https://github.com/bitcoin/bitcoin/pull/9319","diff_url":"https://github.com/bitcoin/bitcoin/pull/9319.diff","patch_url":"https://github.com/bitcoin/bitcoin/pull/9319.patch","issue_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/9319","number":9319,"state":"open","locked":false,"title":"Break addnode out from the outbound connection limits.","user":{"login":"gmaxwell","id":858454,"avatar_url":"https://avatars.githubusercontent.com/u/858454?v=3","gravatar_id":"","url":"https://api.github.com/users/gmaxwell","html_url":"https://github.com/gmaxwell","followers_url":"https://api.github.com/users/gmaxwell/followers","following_url":"https://api.github.com/users/gmaxwell/following{/other_user}","gists_url":"https://api.github.com/users/gmaxwell/gists{/gist_id}","starred_url":"https://api.github.com/users/gmaxwell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gmaxwell/subscriptions","organizations_url":"https://api.github.com/users/gmaxwell/orgs","repos_url":"https://api.github.com/users/gmaxwell/repos","events_url":"https://api.github.com/users/gmaxwell/events{/privacy}","received_events_url":"https://api.github.com/users/gmaxwell/received_events","type":"User","site_admin":false},"body":"Previously addnodes were in competition with outbound connections\r\n for access to the eight outbound slots.\r\n\r\nOne result of this is that frequently a node with several addnode\r\n configured peers would end up connected to none of them, because\r\n while the addnode loop was in its two minute sleep the automatic\r\n connection logic would fill any free slots with random peers.\r\n This is particularly unwelcome to users trying to maintain links\r\n to specific nodes for fast block relay or purposes.\r\n\r\nAnother result is that a group of nine or more nodes which are\r\n have addnode configured towards each other can become partitioned\r\n from the public network.\r\n\r\nThis commit introduces a new limit of eight connections just for\r\n addnode peers which is not subject to any of the other connection\r\n limitations (including maxconnections).\r\n\r\nThe choice of eight is sufficient so that under no condition would\r\n a user find themselves connected to fewer addnoded peers than\r\n previously.  It is also low enough that users who are confused\r\n about the significance of more connections and have gotten too\r\n copy-and-paste happy will not consume more than twice the slot\r\n usage of a typical user.\r\n\r\nAny additional load on the network resulting from this will likely\r\n be offset by a reduction in users applying even more wasteful\r\n workaround for the prior behavior.\r\n\r\nThe retry delays are reduced to avoid nodes sitting around without\r\n their added peers up, but are still sufficient to prevent overly\r\n aggressive repeated connections.  The reduced delays also make\r\n the system much more responsive to the addnode RPC.\r\n\r\nBan-disconnects are also exempted for peers added via addnode since\r\n the outbound addnode logic ignores bans.  Previously it would ban\r\n an addnode then immediately reconnect to it.\r\n\r\nA minor change was also made to CSemaphoreGrant so that it is\r\n possible to re-acquire via an object whos grant was moved.\r\n","created_at":"2016-12-11T05:01:59Z","updated_at":"2016-12-11T05:01:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b90b5e2fdfc7d1c510836d2b1eac8908b374a673","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/9319/commits","review_comments_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/9319/comments","review_comment_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/9319/comments","statuses_url":"https://api.github.com/repos/bitcoin/bitcoin/statuses/3708f01e623b7c5e591b1d1e486e1c494853f5bf","head":{"label":"gmaxwell:addnode_own_count","ref":"addnode_own_count","sha":"3708f01e623b7c5e591b1d1e486e1c494853f5bf","user":{"login":"gmaxwell","id":858454,"avatar_url":"https://avatars.githubusercontent.com/u/858454?v=3","gravatar_id":"","url":"https://api.github.com/users/gmaxwell","html_url":"https://github.com/gmaxwell","followers_url":"https://api.github.com/users/gmaxwell/followers","following_url":"https://api.github.com/users/gmaxwell/following{/other_user}","gists_url":"https://api.github.com/users/gmaxwell/gists{/gist_id}","starred_url":"https://api.github.com/users/gmaxwell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gmaxwell/subscriptions","organizations_url":"https://api.github.com/users/gmaxwell/orgs","repos_url":"https://api.github.com/users/gmaxwell/repos","events_url":"https://api.github.com/users/gmaxwell/events{/privacy}","received_events_url":"https://api.github.com/users/gmaxwell/received_events","type":"User","site_admin":false},"repo":{"id":50618592,"name":"bitcoin","full_name":"gmaxwell/bitcoin","owner":{"login":"gmaxwell","id":858454,"avatar_url":"https://avatars.githubusercontent.com/u/858454?v=3","gravatar_id":"","url":"https://api.github.com/users/gmaxwell","html_url":"https://github.com/gmaxwell","followers_url":"https://api.github.com/users/gmaxwell/followers","following_url":"https://api.github.com/users/gmaxwell/following{/other_user}","gists_url":"https://api.github.com/users/gmaxwell/gists{/gist_id}","starred_url":"https://api.github.com/users/gmaxwell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gmaxwell/subscriptions","organizations_url":"https://api.github.com/users/gmaxwell/orgs","repos_url":"https://api.github.com/users/gmaxwell/repos","events_url":"https://api.github.com/users/gmaxwell/events{/privacy}","received_events_url":"https://api.github.com/users/gmaxwell/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/gmaxwell/bitcoin","description":"Bitcoin Core integration/staging tree","fork":true,"url":"https://api.github.com/repos/gmaxwell/bitcoin","forks_url":"https://api.github.com/repos/gmaxwell/bitcoin/forks","keys_url":"https://api.github.com/repos/gmaxwell/bitcoin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gmaxwell/bitcoin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gmaxwell/bitcoin/teams","hooks_url":"https://api.github.com/repos/gmaxwell/bitcoin/hooks","issue_events_url":"https://api.github.com/repos/gmaxwell/bitcoin/issues/events{/number}","events_url":"https://api.github.com/repos/gmaxwell/bitcoin/events","assignees_url":"https://api.github.com/repos/gmaxwell/bitcoin/assignees{/user}","branches_url":"https://api.github.com/repos/gmaxwell/bitcoin/branches{/branch}","tags_url":"https://api.github.com/repos/gmaxwell/bitcoin/tags","blobs_url":"https://api.github.com/repos/gmaxwell/bitcoin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gmaxwell/bitcoin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gmaxwell/bitcoin/git/refs{/sha}","trees_url":"https://api.github.com/repos/gmaxwell/bitcoin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gmaxwell/bitcoin/statuses/{sha}","languages_url":"https://api.github.com/repos/gmaxwell/bitcoin/languages","stargazers_url":"https://api.github.com/repos/gmaxwell/bitcoin/stargazers","contributors_url":"https://api.github.com/repos/gmaxwell/bitcoin/contributors","subscribers_url":"https://api.github.com/repos/gmaxwell/bitcoin/subscribers","subscription_url":"https://api.github.com/repos/gmaxwell/bitcoin/subscription","commits_url":"https://api.github.com/repos/gmaxwell/bitcoin/commits{/sha}","git_commits_url":"https://api.github.com/repos/gmaxwell/bitcoin/git/commits{/sha}","comments_url":"https://api.github.com/repos/gmaxwell/bitcoin/comments{/number}","issue_comment_url":"https://api.github.com/repos/gmaxwell/bitcoin/issues/comments{/number}","contents_url":"https://api.github.com/repos/gmaxwell/bitcoin/contents/{+path}","compare_url":"https://api.github.com/repos/gmaxwell/bitcoin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gmaxwell/bitcoin/merges","archive_url":"https://api.github.com/repos/gmaxwell/bitcoin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gmaxwell/bitcoin/downloads","issues_url":"https://api.github.com/repos/gmaxwell/bitcoin/issues{/number}","pulls_url":"https://api.github.com/repos/gmaxwell/bitcoin/pulls{/number}","milestones_url":"https://api.github.com/repos/gmaxwell/bitcoin/milestones{/number}","notifications_url":"https://api.github.com/repos/gmaxwell/bitcoin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gmaxwell/bitcoin/labels{/name}","releases_url":"https://api.github.com/repos/gmaxwell/bitcoin/releases{/id}","deployments_url":"https://api.github.com/repos/gmaxwell/bitcoin/deployments","created_at":"2016-01-28T22:29:23Z","updated_at":"2016-10-28T08:17:33Z","pushed_at":"2016-12-11T05:00:27Z","git_url":"git://github.com/gmaxwell/bitcoin.git","ssh_url":"git@github.com:gmaxwell/bitcoin.git","clone_url":"https://github.com/gmaxwell/bitcoin.git","svn_url":"https://github.com/gmaxwell/bitcoin","homepage":"https://bitcoin.org/en/download","size":74212,"stargazers_count":3,"watchers_count":3,"language":"C++","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":3,"default_branch":"master"}},"base":{"label":"bitcoin:master","ref":"master","sha":"76fcd9d5034143a5b041766552670d19f926097d","user":{"login":"bitcoin","id":528860,"avatar_url":"https://avatars.githubusercontent.com/u/528860?v=3","gravatar_id":"","url":"https://api.github.com/users/bitcoin","html_url":"https://github.com/bitcoin","followers_url":"https://api.github.com/users/bitcoin/followers","following_url":"https://api.github.com/users/bitcoin/following{/other_user}","gists_url":"https://api.github.com/users/bitcoin/gists{/gist_id}","starred_url":"https://api.github.com/users/bitcoin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bitcoin/subscriptions","organizations_url":"https://api.github.com/users/bitcoin/orgs","repos_url":"https://api.github.com/users/bitcoin/repos","events_url":"https://api.github.com/users/bitcoin/events{/privacy}","received_events_url":"https://api.github.com/users/bitcoin/received_events","type":"Organization","site_admin":false},"repo":{"id":1181927,"name":"bitcoin","full_name":"bitcoin/bitcoin","owner":{"login":"bitcoin","id":528860,"avatar_url":"https://avatars.githubusercontent.com/u/528860?v=3","gravatar_id":"","url":"https://api.github.com/users/bitcoin","html_url":"https://github.com/bitcoin","followers_url":"https://api.github.com/users/bitcoin/followers","following_url":"https://api.github.com/users/bitcoin/following{/other_user}","gists_url":"https://api.github.com/users/bitcoin/gists{/gist_id}","starred_url":"https://api.github.com/users/bitcoin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bitcoin/subscriptions","organizations_url":"https://api.github.com/users/bitcoin/orgs","repos_url":"https://api.github.com/users/bitcoin/repos","events_url":"https://api.github.com/users/bitcoin/events{/privacy}","received_events_url":"https://api.github.com/users/bitcoin/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/bitcoin/bitcoin","description":"Bitcoin Core integration/staging tree","fork":false,"url":"https://api.github.com/repos/bitcoin/bitcoin","forks_url":"https://api.github.com/repos/bitcoin/bitcoin/forks","keys_url":"https://api.github.com/repos/bitcoin/bitcoin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bitcoin/bitcoin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bitcoin/bitcoin/teams","hooks_url":"https://api.github.com/repos/bitcoin/bitcoin/hooks","issue_events_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/events{/number}","events_url":"https://api.github.com/repos/bitcoin/bitcoin/events","assignees_url":"https://api.github.com/repos/bitcoin/bitcoin/assignees{/user}","branches_url":"https://api.github.com/repos/bitcoin/bitcoin/branches{/branch}","tags_url":"https://api.github.com/repos/bitcoin/bitcoin/tags","blobs_url":"https://api.github.com/repos/bitcoin/bitcoin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bitcoin/bitcoin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bitcoin/bitcoin/git/refs{/sha}","trees_url":"https://api.github.com/repos/bitcoin/bitcoin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bitcoin/bitcoin/statuses/{sha}","languages_url":"https://api.github.com/repos/bitcoin/bitcoin/languages","stargazers_url":"https://api.github.com/repos/bitcoin/bitcoin/stargazers","contributors_url":"https://api.github.com/repos/bitcoin/bitcoin/contributors","subscribers_url":"https://api.github.com/repos/bitcoin/bitcoin/subscribers","subscription_url":"https://api.github.com/repos/bitcoin/bitcoin/subscription","commits_url":"https://api.github.com/repos/bitcoin/bitcoin/commits{/sha}","git_commits_url":"https://api.github.com/repos/bitcoin/bitcoin/git/commits{/sha}","comments_url":"https://api.github.com/repos/bitcoin/bitcoin/comments{/number}","issue_comment_url":"https://api.github.com/repos/bitcoin/bitcoin/issues/comments{/number}","contents_url":"https://api.github.com/repos/bitcoin/bitcoin/contents/{+path}","compare_url":"https://api.github.com/repos/bitcoin/bitcoin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bitcoin/bitcoin/merges","archive_url":"https://api.github.com/repos/bitcoin/bitcoin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bitcoin/bitcoin/downloads","issues_url":"https://api.github.com/repos/bitcoin/bitcoin/issues{/number}","pulls_url":"https://api.github.com/repos/bitcoin/bitcoin/pulls{/number}","milestones_url":"https://api.github.com/repos/bitcoin/bitcoin/milestones{/number}","notifications_url":"https://api.github.com/repos/bitcoin/bitcoin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bitcoin/bitcoin/labels{/name}","releases_url":"https://api.github.com/repos/bitcoin/bitcoin/releases{/id}","deployments_url":"https://api.github.com/repos/bitcoin/bitcoin/deployments","created_at":"2010-12-19T15:16:43Z","updated_at":"2016-12-11T04:10:21Z","pushed_at":"2016-12-11T05:01:59Z","git_url":"git://github.com/bitcoin/bitcoin.git","ssh_url":"git@github.com:bitcoin/bitcoin.git","clone_url":"https://github.com/bitcoin/bitcoin.git","svn_url":"https://github.com/bitcoin/bitcoin","homepage":"https://bitcoin.org/en/download","size":159289,"stargazers_count":10657,"watchers_count":10657,"language":"C++","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":7020,"mirror_url":null,"open_issues_count":546,"forks":7020,"open_issues":546,"watchers":10657,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/9319"},"html":{"href":"https://github.com/bitcoin/bitcoin/pull/9319"},"issue":{"href":"https://api.github.com/repos/bitcoin/bitcoin/issues/9319"},"comments":{"href":"https://api.github.com/repos/bitcoin/bitcoin/issues/9319/comments"},"review_comments":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/9319/comments"},"review_comment":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/bitcoin/bitcoin/pulls/9319/commits"},"statuses":{"href":"https://api.github.com/repos/bitcoin/bitcoin/statuses/3708f01e623b7c5e591b1d1e486e1c494853f5bf"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":0,"review_comments":0,"commits":2,"additions":57,"deletions":14,"changed_files":7}}
{"actor":{"display_login":"gmaxwell"}}