{"action":"created","comment":{"url":"https://api.github.com/repos/uber/ringpop-common/pulls/comments/60377814","id":60377814,"diff_hunk":"@@ -47,6 +48,107 @@ test2('bidirectional full sync test', getClusterSizes(5), 20000,\n \t})\n );\n \n+test2('bidirectional full sync throttling test', getClusterSizes(3), 20000,\n+    prepareCluster(function(t, tc, n) {\n+        return [\n+            dsl.assertStats(t, tc, n+1, 0, 0),\n+            dsl.waitForEmptyPing(t, tc),\n+\n+            assertReverseFullSyncThrottling(t, tc, 0, n*3, 5),\n+\n+            dsl.assertStats(t, tc, n+1, 0, 0),\n+        ];\n+    })\n+);\n+\n+// assert if the number of joins is throttled.\n+function assertReverseFullSyncThrottling(t, tc, idx, count, expectedJoins) {\n+    var functions = [];","path":"test/bidir-full-sync-tests.js","position":30,"original_position":30,"commit_id":"804759e919dd5111e38c1d5eb6bc35a047d26c57","original_commit_id":"804759e919dd5111e38c1d5eb6bc35a047d26c57","user":{"login":"CorgiMan","id":2640140,"avatar_url":"https://avatars.githubusercontent.com/u/2640140?v=3","gravatar_id":"","url":"https://api.github.com/users/CorgiMan","html_url":"https://github.com/CorgiMan","followers_url":"https://api.github.com/users/CorgiMan/followers","following_url":"https://api.github.com/users/CorgiMan/following{/other_user}","gists_url":"https://api.github.com/users/CorgiMan/gists{/gist_id}","starred_url":"https://api.github.com/users/CorgiMan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CorgiMan/subscriptions","organizations_url":"https://api.github.com/users/CorgiMan/orgs","repos_url":"https://api.github.com/users/CorgiMan/repos","events_url":"https://api.github.com/users/CorgiMan/events{/privacy}","received_events_url":"https://api.github.com/users/CorgiMan/received_events","type":"User","site_admin":false},"body":"I prefer if all the functions are just declared within the [] brackets, since I think it improves readability and is more in line with the rest of the integration tests.","created_at":"2016-04-20T09:36:45Z","updated_at":"2016-04-20T09:36:45Z","html_url":"https://github.com/uber/ringpop-common/pull/47#discussion_r60377814","pull_request_url":"https://api.github.com/repos/uber/ringpop-common/pulls/47","_links":{"self":{"href":"https://api.github.com/repos/uber/ringpop-common/pulls/comments/60377814"},"html":{"href":"https://github.com/uber/ringpop-common/pull/47#discussion_r60377814"},"pull_request":{"href":"https://api.github.com/repos/uber/ringpop-common/pulls/47"}}},"pull_request":{"url":"https://api.github.com/repos/uber/ringpop-common/pulls/47","id":67139258,"html_url":"https://github.com/uber/ringpop-common/pull/47","diff_url":"https://github.com/uber/ringpop-common/pull/47.diff","patch_url":"https://github.com/uber/ringpop-common/pull/47.patch","issue_url":"https://api.github.com/repos/uber/ringpop-common/issues/47","number":47,"state":"open","locked":false,"title":"Add throttle test for bidirectional full syncs","user":{"login":"mennopruijssers","id":831983,"avatar_url":"https://avatars.githubusercontent.com/u/831983?v=3","gravatar_id":"","url":"https://api.github.com/users/mennopruijssers","html_url":"https://github.com/mennopruijssers","followers_url":"https://api.github.com/users/mennopruijssers/followers","following_url":"https://api.github.com/users/mennopruijssers/following{/other_user}","gists_url":"https://api.github.com/users/mennopruijssers/gists{/gist_id}","starred_url":"https://api.github.com/users/mennopruijssers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mennopruijssers/subscriptions","organizations_url":"https://api.github.com/users/mennopruijssers/orgs","repos_url":"https://api.github.com/users/mennopruijssers/repos","events_url":"https://api.github.com/users/mennopruijssers/events{/privacy}","received_events_url":"https://api.github.com/users/mennopruijssers/received_events","type":"User","site_admin":false},"body":"As a safety check, both the ringpop-go and ringpop-node limit the number (defaults to 5) of concurrent bidirectional full syncs. \r\nA bidirectional full sync is triggered by a ping to a node without outstanding membership changes where the checksum in the ping doesn't match the node's checksum. This results in the node sending it's full membership. At the same time, the node will send a join to the source of the ping request to get it's full membership list.\r\nThis test pauses responding to the join request to make sure there are multiple joins happening at the same time. If the throttling is working, there should never be more than 5 joins in the queue.","created_at":"2016-04-20T07:20:56Z","updated_at":"2016-04-20T09:36:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ebb07d3c51b5473d9c676223e21cafb4cf767801","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/uber/ringpop-common/pulls/47/commits","review_comments_url":"https://api.github.com/repos/uber/ringpop-common/pulls/47/comments","review_comment_url":"https://api.github.com/repos/uber/ringpop-common/pulls/comments{/number}","comments_url":"https://api.github.com/repos/uber/ringpop-common/issues/47/comments","statuses_url":"https://api.github.com/repos/uber/ringpop-common/statuses/804759e919dd5111e38c1d5eb6bc35a047d26c57","head":{"label":"uber:menno/reverse-sync-throttling","ref":"menno/reverse-sync-throttling","sha":"804759e919dd5111e38c1d5eb6bc35a047d26c57","user":{"login":"uber","id":538264,"avatar_url":"https://avatars.githubusercontent.com/u/538264?v=3","gravatar_id":"","url":"https://api.github.com/users/uber","html_url":"https://github.com/uber","followers_url":"https://api.github.com/users/uber/followers","following_url":"https://api.github.com/users/uber/following{/other_user}","gists_url":"https://api.github.com/users/uber/gists{/gist_id}","starred_url":"https://api.github.com/users/uber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/uber/subscriptions","organizations_url":"https://api.github.com/users/uber/orgs","repos_url":"https://api.github.com/users/uber/repos","events_url":"https://api.github.com/users/uber/events{/privacy}","received_events_url":"https://api.github.com/users/uber/received_events","type":"Organization","site_admin":false},"repo":{"id":41671989,"name":"ringpop-common","full_name":"uber/ringpop-common","owner":{"login":"uber","id":538264,"avatar_url":"https://avatars.githubusercontent.com/u/538264?v=3","gravatar_id":"","url":"https://api.github.com/users/uber","html_url":"https://github.com/uber","followers_url":"https://api.github.com/users/uber/followers","following_url":"https://api.github.com/users/uber/following{/other_user}","gists_url":"https://api.github.com/users/uber/gists{/gist_id}","starred_url":"https://api.github.com/users/uber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/uber/subscriptions","organizations_url":"https://api.github.com/users/uber/orgs","repos_url":"https://api.github.com/users/uber/repos","events_url":"https://api.github.com/users/uber/events{/privacy}","received_events_url":"https://api.github.com/users/uber/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/uber/ringpop-common","description":"Cross-language compatible tools and documentation for Ringpop","fork":false,"url":"https://api.github.com/repos/uber/ringpop-common","forks_url":"https://api.github.com/repos/uber/ringpop-common/forks","keys_url":"https://api.github.com/repos/uber/ringpop-common/keys{/key_id}","collaborators_url":"https://api.github.com/repos/uber/ringpop-common/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/uber/ringpop-common/teams","hooks_url":"https://api.github.com/repos/uber/ringpop-common/hooks","issue_events_url":"https://api.github.com/repos/uber/ringpop-common/issues/events{/number}","events_url":"https://api.github.com/repos/uber/ringpop-common/events","assignees_url":"https://api.github.com/repos/uber/ringpop-common/assignees{/user}","branches_url":"https://api.github.com/repos/uber/ringpop-common/branches{/branch}","tags_url":"https://api.github.com/repos/uber/ringpop-common/tags","blobs_url":"https://api.github.com/repos/uber/ringpop-common/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/uber/ringpop-common/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/uber/ringpop-common/git/refs{/sha}","trees_url":"https://api.github.com/repos/uber/ringpop-common/git/trees{/sha}","statuses_url":"https://api.github.com/repos/uber/ringpop-common/statuses/{sha}","languages_url":"https://api.github.com/repos/uber/ringpop-common/languages","stargazers_url":"https://api.github.com/repos/uber/ringpop-common/stargazers","contributors_url":"https://api.github.com/repos/uber/ringpop-common/contributors","subscribers_url":"https://api.github.com/repos/uber/ringpop-common/subscribers","subscription_url":"https://api.github.com/repos/uber/ringpop-common/subscription","commits_url":"https://api.github.com/repos/uber/ringpop-common/commits{/sha}","git_commits_url":"https://api.github.com/repos/uber/ringpop-common/git/commits{/sha}","comments_url":"https://api.github.com/repos/uber/ringpop-common/comments{/number}","issue_comment_url":"https://api.github.com/repos/uber/ringpop-common/issues/comments{/number}","contents_url":"https://api.github.com/repos/uber/ringpop-common/contents/{+path}","compare_url":"https://api.github.com/repos/uber/ringpop-common/compare/{base}...{head}","merges_url":"https://api.github.com/repos/uber/ringpop-common/merges","archive_url":"https://api.github.com/repos/uber/ringpop-common/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/uber/ringpop-common/downloads","issues_url":"https://api.github.com/repos/uber/ringpop-common/issues{/number}","pulls_url":"https://api.github.com/repos/uber/ringpop-common/pulls{/number}","milestones_url":"https://api.github.com/repos/uber/ringpop-common/milestones{/number}","notifications_url":"https://api.github.com/repos/uber/ringpop-common/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/uber/ringpop-common/labels{/name}","releases_url":"https://api.github.com/repos/uber/ringpop-common/releases{/id}","deployments_url":"https://api.github.com/repos/uber/ringpop-common/deployments","created_at":"2015-08-31T11:32:45Z","updated_at":"2016-04-12T12:23:09Z","pushed_at":"2016-04-20T07:20:56Z","git_url":"git://github.com/uber/ringpop-common.git","ssh_url":"git@github.com:uber/ringpop-common.git","clone_url":"https://github.com/uber/ringpop-common.git","svn_url":"https://github.com/uber/ringpop-common","homepage":"http://uber.github.io/ringpop/","size":230,"stargazers_count":4,"watchers_count":4,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":5,"forks":2,"open_issues":5,"watchers":4,"default_branch":"master"}},"base":{"label":"uber:master","ref":"master","sha":"a1e7f86a117ed9391812769127f2b9d084e961be","user":{"login":"uber","id":538264,"avatar_url":"https://avatars.githubusercontent.com/u/538264?v=3","gravatar_id":"","url":"https://api.github.com/users/uber","html_url":"https://github.com/uber","followers_url":"https://api.github.com/users/uber/followers","following_url":"https://api.github.com/users/uber/following{/other_user}","gists_url":"https://api.github.com/users/uber/gists{/gist_id}","starred_url":"https://api.github.com/users/uber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/uber/subscriptions","organizations_url":"https://api.github.com/users/uber/orgs","repos_url":"https://api.github.com/users/uber/repos","events_url":"https://api.github.com/users/uber/events{/privacy}","received_events_url":"https://api.github.com/users/uber/received_events","type":"Organization","site_admin":false},"repo":{"id":41671989,"name":"ringpop-common","full_name":"uber/ringpop-common","owner":{"login":"uber","id":538264,"avatar_url":"https://avatars.githubusercontent.com/u/538264?v=3","gravatar_id":"","url":"https://api.github.com/users/uber","html_url":"https://github.com/uber","followers_url":"https://api.github.com/users/uber/followers","following_url":"https://api.github.com/users/uber/following{/other_user}","gists_url":"https://api.github.com/users/uber/gists{/gist_id}","starred_url":"https://api.github.com/users/uber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/uber/subscriptions","organizations_url":"https://api.github.com/users/uber/orgs","repos_url":"https://api.github.com/users/uber/repos","events_url":"https://api.github.com/users/uber/events{/privacy}","received_events_url":"https://api.github.com/users/uber/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/uber/ringpop-common","description":"Cross-language compatible tools and documentation for Ringpop","fork":false,"url":"https://api.github.com/repos/uber/ringpop-common","forks_url":"https://api.github.com/repos/uber/ringpop-common/forks","keys_url":"https://api.github.com/repos/uber/ringpop-common/keys{/key_id}","collaborators_url":"https://api.github.com/repos/uber/ringpop-common/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/uber/ringpop-common/teams","hooks_url":"https://api.github.com/repos/uber/ringpop-common/hooks","issue_events_url":"https://api.github.com/repos/uber/ringpop-common/issues/events{/number}","events_url":"https://api.github.com/repos/uber/ringpop-common/events","assignees_url":"https://api.github.com/repos/uber/ringpop-common/assignees{/user}","branches_url":"https://api.github.com/repos/uber/ringpop-common/branches{/branch}","tags_url":"https://api.github.com/repos/uber/ringpop-common/tags","blobs_url":"https://api.github.com/repos/uber/ringpop-common/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/uber/ringpop-common/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/uber/ringpop-common/git/refs{/sha}","trees_url":"https://api.github.com/repos/uber/ringpop-common/git/trees{/sha}","statuses_url":"https://api.github.com/repos/uber/ringpop-common/statuses/{sha}","languages_url":"https://api.github.com/repos/uber/ringpop-common/languages","stargazers_url":"https://api.github.com/repos/uber/ringpop-common/stargazers","contributors_url":"https://api.github.com/repos/uber/ringpop-common/contributors","subscribers_url":"https://api.github.com/repos/uber/ringpop-common/subscribers","subscription_url":"https://api.github.com/repos/uber/ringpop-common/subscription","commits_url":"https://api.github.com/repos/uber/ringpop-common/commits{/sha}","git_commits_url":"https://api.github.com/repos/uber/ringpop-common/git/commits{/sha}","comments_url":"https://api.github.com/repos/uber/ringpop-common/comments{/number}","issue_comment_url":"https://api.github.com/repos/uber/ringpop-common/issues/comments{/number}","contents_url":"https://api.github.com/repos/uber/ringpop-common/contents/{+path}","compare_url":"https://api.github.com/repos/uber/ringpop-common/compare/{base}...{head}","merges_url":"https://api.github.com/repos/uber/ringpop-common/merges","archive_url":"https://api.github.com/repos/uber/ringpop-common/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/uber/ringpop-common/downloads","issues_url":"https://api.github.com/repos/uber/ringpop-common/issues{/number}","pulls_url":"https://api.github.com/repos/uber/ringpop-common/pulls{/number}","milestones_url":"https://api.github.com/repos/uber/ringpop-common/milestones{/number}","notifications_url":"https://api.github.com/repos/uber/ringpop-common/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/uber/ringpop-common/labels{/name}","releases_url":"https://api.github.com/repos/uber/ringpop-common/releases{/id}","deployments_url":"https://api.github.com/repos/uber/ringpop-common/deployments","created_at":"2015-08-31T11:32:45Z","updated_at":"2016-04-12T12:23:09Z","pushed_at":"2016-04-20T07:20:56Z","git_url":"git://github.com/uber/ringpop-common.git","ssh_url":"git@github.com:uber/ringpop-common.git","clone_url":"https://github.com/uber/ringpop-common.git","svn_url":"https://github.com/uber/ringpop-common","homepage":"http://uber.github.io/ringpop/","size":230,"stargazers_count":4,"watchers_count":4,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":5,"forks":2,"open_issues":5,"watchers":4,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/uber/ringpop-common/pulls/47"},"html":{"href":"https://github.com/uber/ringpop-common/pull/47"},"issue":{"href":"https://api.github.com/repos/uber/ringpop-common/issues/47"},"comments":{"href":"https://api.github.com/repos/uber/ringpop-common/issues/47/comments"},"review_comments":{"href":"https://api.github.com/repos/uber/ringpop-common/pulls/47/comments"},"review_comment":{"href":"https://api.github.com/repos/uber/ringpop-common/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/uber/ringpop-common/pulls/47/commits"},"statuses":{"href":"https://api.github.com/repos/uber/ringpop-common/statuses/804759e919dd5111e38c1d5eb6bc35a047d26c57"}}}}