{"action":"created","comment":{"url":"https://api.github.com/repos/docker/docker/pulls/comments/104274227","pull_request_review_id":25103593,"id":104274227,"diff_hunk":"@@ -50,3 +50,51 @@ func (s *DockerSwarmSuite) TestSwarmVolumePlugin(c *check.C) {\n \tc.Assert(mounts[0].Name, checker.Equals, \"my-volume\")\n \tc.Assert(mounts[0].Driver, checker.Equals, \"customvolumedriver\")\n }\n+\n+// Test network plugin filter in swarm\n+func (s *DockerSwarmSuite) TestSwarmNetworkPluginV2(c *check.C) {\n+\td1 := s.AddDaemon(c, true, true)\n+\td2 := s.AddDaemon(c, true, false)\n+\n+\t// install plugin on d1 and d2\n+\tpluginName := \"aragunathan/global-net-plugin:latest\"\n+\n+\t_, err := d1.Cmd(\"plugin\", \"install\", pluginName, \"--grant-all-permissions\")\n+\tc.Assert(err, checker.IsNil)\n+\n+\t_, err = d2.Cmd(\"plugin\", \"install\", pluginName, \"--grant-all-permissions\")\n+\tc.Assert(err, checker.IsNil)\n+\n+\t// create network\n+\tnetworkName := \"globalnet\"\n+\t_, err = d1.Cmd(\"network\", \"create\", \"--driver\", pluginName, networkName)\n+\tc.Assert(err, checker.IsNil)\n+\n+\t// create a global service to ensure that both nodes will have an instance\n+\tserviceName := \"my-service\"\n+\t_, err = d1.Cmd(\"service\", \"create\", \"--name\", serviceName, \"--mode=global\", \"--network\", networkName, \"busybox\", \"top\")\n+\tc.Assert(err, checker.IsNil)\n+\n+\t// wait for tasks ready\n+\twaitAndAssert(c, defaultReconciliationTimeout, reducedCheck(sumAsIntegers, d1.CheckActiveContainerCount, d2.CheckActiveContainerCount), checker.Equals, 2)\n+\n+\t// remove service\n+\t_, err = d1.Cmd(\"service\", \"rm\", serviceName)\n+\tc.Assert(err, checker.IsNil)\n+\n+\t// wait to ensure all containers have exited before removing the plugin. Else there's a\n+\t// possibility of container exits erroring out due to plugins being unavailable.\n+\twaitAndAssert(c, defaultReconciliationTimeout, reducedCheck(sumAsIntegers, d1.CheckActiveContainerCount, d2.CheckActiveContainerCount), checker.Equals, 0)\n+\n+\t// disable plugin on worker\n+\t_, err = d2.Cmd(\"plugin\", \"disable\", \"-f\", pluginName)\n+\tc.Assert(err, checker.IsNil)\n+","path":"integration-cli/docker_cli_swarm_unix_test.go","position":51,"original_position":43,"commit_id":"80ad85ebed2a4750a4932ec965922dfaa2f254eb","original_commit_id":"5914c062886663e768c6b565e8b0e215cb2c3005","user":{"login":"anusha-ragunathan","id":14184178,"avatar_url":"https://avatars3.githubusercontent.com/u/14184178?v=3","gravatar_id":"","url":"https://api.github.com/users/anusha-ragunathan","html_url":"https://github.com/anusha-ragunathan","followers_url":"https://api.github.com/users/anusha-ragunathan/followers","following_url":"https://api.github.com/users/anusha-ragunathan/following{/other_user}","gists_url":"https://api.github.com/users/anusha-ragunathan/gists{/gist_id}","starred_url":"https://api.github.com/users/anusha-ragunathan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anusha-ragunathan/subscriptions","organizations_url":"https://api.github.com/users/anusha-ragunathan/orgs","repos_url":"https://api.github.com/users/anusha-ragunathan/repos","events_url":"https://api.github.com/users/anusha-ragunathan/events{/privacy}","received_events_url":"https://api.github.com/users/anusha-ragunathan/received_events","type":"User","site_admin":false},"body":"I updated the test to sleep for agentUpdatePeriod (20s) after plugin remove and create a new global service. Strangely, this service still continues to schedule 2 tasks instead of the expected 1 and hence the test fails. \r\nPotential swarm scheduler bug @aaronlehmann ? ","created_at":"2017-03-04T01:45:16Z","updated_at":"2017-03-04T01:45:16Z","html_url":"https://github.com/docker/docker/pull/31340#discussion_r104274227","pull_request_url":"https://api.github.com/repos/docker/docker/pulls/31340","_links":{"self":{"href":"https://api.github.com/repos/docker/docker/pulls/comments/104274227"},"html":{"href":"https://github.com/docker/docker/pull/31340#discussion_r104274227"},"pull_request":{"href":"https://api.github.com/repos/docker/docker/pulls/31340"}}},"pull_request":{"url":"https://api.github.com/repos/docker/docker/pulls/31340","id":107872687,"html_url":"https://github.com/docker/docker/pull/31340","diff_url":"https://github.com/docker/docker/pull/31340.diff","patch_url":"https://github.com/docker/docker/pull/31340.patch","issue_url":"https://api.github.com/repos/docker/docker/issues/31340","number":31340,"state":"open","locked":false,"title":"Add network plugin filter test","user":{"login":"anusha-ragunathan","id":14184178,"avatar_url":"https://avatars3.githubusercontent.com/u/14184178?v=3","gravatar_id":"","url":"https://api.github.com/users/anusha-ragunathan","html_url":"https://github.com/anusha-ragunathan","followers_url":"https://api.github.com/users/anusha-ragunathan/followers","following_url":"https://api.github.com/users/anusha-ragunathan/following{/other_user}","gists_url":"https://api.github.com/users/anusha-ragunathan/gists{/gist_id}","starred_url":"https://api.github.com/users/anusha-ragunathan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anusha-ragunathan/subscriptions","organizations_url":"https://api.github.com/users/anusha-ragunathan/orgs","repos_url":"https://api.github.com/users/anusha-ragunathan/repos","events_url":"https://api.github.com/users/anusha-ragunathan/events{/privacy}","received_events_url":"https://api.github.com/users/anusha-ragunathan/received_events","type":"User","site_admin":false},"body":"Swarm test to verify network pluginv2 filters. Goes in hand with doc PR 31071.\r\n\r\nSigned-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>\r\n\r\n","created_at":"2017-02-24T17:26:56Z","updated_at":"2017-03-04T01:45:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"87d0ff7e593510acc686a2904077116a78cd1815","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/docker/docker/pulls/31340/commits","review_comments_url":"https://api.github.com/repos/docker/docker/pulls/31340/comments","review_comment_url":"https://api.github.com/repos/docker/docker/pulls/comments{/number}","comments_url":"https://api.github.com/repos/docker/docker/issues/31340/comments","statuses_url":"https://api.github.com/repos/docker/docker/statuses/80ad85ebed2a4750a4932ec965922dfaa2f254eb","head":{"label":"anusha-ragunathan:plugin_nw_filter","ref":"plugin_nw_filter","sha":"80ad85ebed2a4750a4932ec965922dfaa2f254eb","user":{"login":"anusha-ragunathan","id":14184178,"avatar_url":"https://avatars3.githubusercontent.com/u/14184178?v=3","gravatar_id":"","url":"https://api.github.com/users/anusha-ragunathan","html_url":"https://github.com/anusha-ragunathan","followers_url":"https://api.github.com/users/anusha-ragunathan/followers","following_url":"https://api.github.com/users/anusha-ragunathan/following{/other_user}","gists_url":"https://api.github.com/users/anusha-ragunathan/gists{/gist_id}","starred_url":"https://api.github.com/users/anusha-ragunathan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anusha-ragunathan/subscriptions","organizations_url":"https://api.github.com/users/anusha-ragunathan/orgs","repos_url":"https://api.github.com/users/anusha-ragunathan/repos","events_url":"https://api.github.com/users/anusha-ragunathan/events{/privacy}","received_events_url":"https://api.github.com/users/anusha-ragunathan/received_events","type":"User","site_admin":false},"repo":{"id":42128270,"name":"docker","full_name":"anusha-ragunathan/docker","owner":{"login":"anusha-ragunathan","id":14184178,"avatar_url":"https://avatars3.githubusercontent.com/u/14184178?v=3","gravatar_id":"","url":"https://api.github.com/users/anusha-ragunathan","html_url":"https://github.com/anusha-ragunathan","followers_url":"https://api.github.com/users/anusha-ragunathan/followers","following_url":"https://api.github.com/users/anusha-ragunathan/following{/other_user}","gists_url":"https://api.github.com/users/anusha-ragunathan/gists{/gist_id}","starred_url":"https://api.github.com/users/anusha-ragunathan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anusha-ragunathan/subscriptions","organizations_url":"https://api.github.com/users/anusha-ragunathan/orgs","repos_url":"https://api.github.com/users/anusha-ragunathan/repos","events_url":"https://api.github.com/users/anusha-ragunathan/events{/privacy}","received_events_url":"https://api.github.com/users/anusha-ragunathan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/anusha-ragunathan/docker","description":"Docker - the open-source application container engine","fork":true,"url":"https://api.github.com/repos/anusha-ragunathan/docker","forks_url":"https://api.github.com/repos/anusha-ragunathan/docker/forks","keys_url":"https://api.github.com/repos/anusha-ragunathan/docker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/anusha-ragunathan/docker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/anusha-ragunathan/docker/teams","hooks_url":"https://api.github.com/repos/anusha-ragunathan/docker/hooks","issue_events_url":"https://api.github.com/repos/anusha-ragunathan/docker/issues/events{/number}","events_url":"https://api.github.com/repos/anusha-ragunathan/docker/events","assignees_url":"https://api.github.com/repos/anusha-ragunathan/docker/assignees{/user}","branches_url":"https://api.github.com/repos/anusha-ragunathan/docker/branches{/branch}","tags_url":"https://api.github.com/repos/anusha-ragunathan/docker/tags","blobs_url":"https://api.github.com/repos/anusha-ragunathan/docker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/anusha-ragunathan/docker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/anusha-ragunathan/docker/git/refs{/sha}","trees_url":"https://api.github.com/repos/anusha-ragunathan/docker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/anusha-ragunathan/docker/statuses/{sha}","languages_url":"https://api.github.com/repos/anusha-ragunathan/docker/languages","stargazers_url":"https://api.github.com/repos/anusha-ragunathan/docker/stargazers","contributors_url":"https://api.github.com/repos/anusha-ragunathan/docker/contributors","subscribers_url":"https://api.github.com/repos/anusha-ragunathan/docker/subscribers","subscription_url":"https://api.github.com/repos/anusha-ragunathan/docker/subscription","commits_url":"https://api.github.com/repos/anusha-ragunathan/docker/commits{/sha}","git_commits_url":"https://api.github.com/repos/anusha-ragunathan/docker/git/commits{/sha}","comments_url":"https://api.github.com/repos/anusha-ragunathan/docker/comments{/number}","issue_comment_url":"https://api.github.com/repos/anusha-ragunathan/docker/issues/comments{/number}","contents_url":"https://api.github.com/repos/anusha-ragunathan/docker/contents/{+path}","compare_url":"https://api.github.com/repos/anusha-ragunathan/docker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/anusha-ragunathan/docker/merges","archive_url":"https://api.github.com/repos/anusha-ragunathan/docker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/anusha-ragunathan/docker/downloads","issues_url":"https://api.github.com/repos/anusha-ragunathan/docker/issues{/number}","pulls_url":"https://api.github.com/repos/anusha-ragunathan/docker/pulls{/number}","milestones_url":"https://api.github.com/repos/anusha-ragunathan/docker/milestones{/number}","notifications_url":"https://api.github.com/repos/anusha-ragunathan/docker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/anusha-ragunathan/docker/labels{/name}","releases_url":"https://api.github.com/repos/anusha-ragunathan/docker/releases{/id}","deployments_url":"https://api.github.com/repos/anusha-ragunathan/docker/deployments","created_at":"2015-09-08T17:34:24Z","updated_at":"2015-09-08T17:34:32Z","pushed_at":"2017-03-04T01:42:55Z","git_url":"git://github.com/anusha-ragunathan/docker.git","ssh_url":"git@github.com:anusha-ragunathan/docker.git","clone_url":"https://github.com/anusha-ragunathan/docker.git","svn_url":"https://github.com/anusha-ragunathan/docker","homepage":"http://www.docker.com","size":120713,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"docker:master","ref":"master","sha":"94d1a5b366152e5384a4bb925a40bf0a8c554a72","user":{"login":"docker","id":5429470,"avatar_url":"https://avatars2.githubusercontent.com/u/5429470?v=3","gravatar_id":"","url":"https://api.github.com/users/docker","html_url":"https://github.com/docker","followers_url":"https://api.github.com/users/docker/followers","following_url":"https://api.github.com/users/docker/following{/other_user}","gists_url":"https://api.github.com/users/docker/gists{/gist_id}","starred_url":"https://api.github.com/users/docker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/docker/subscriptions","organizations_url":"https://api.github.com/users/docker/orgs","repos_url":"https://api.github.com/users/docker/repos","events_url":"https://api.github.com/users/docker/events{/privacy}","received_events_url":"https://api.github.com/users/docker/received_events","type":"Organization","site_admin":false},"repo":{"id":7691631,"name":"docker","full_name":"docker/docker","owner":{"login":"docker","id":5429470,"avatar_url":"https://avatars2.githubusercontent.com/u/5429470?v=3","gravatar_id":"","url":"https://api.github.com/users/docker","html_url":"https://github.com/docker","followers_url":"https://api.github.com/users/docker/followers","following_url":"https://api.github.com/users/docker/following{/other_user}","gists_url":"https://api.github.com/users/docker/gists{/gist_id}","starred_url":"https://api.github.com/users/docker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/docker/subscriptions","organizations_url":"https://api.github.com/users/docker/orgs","repos_url":"https://api.github.com/users/docker/repos","events_url":"https://api.github.com/users/docker/events{/privacy}","received_events_url":"https://api.github.com/users/docker/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/docker/docker","description":"Docker - the open-source application container engine","fork":false,"url":"https://api.github.com/repos/docker/docker","forks_url":"https://api.github.com/repos/docker/docker/forks","keys_url":"https://api.github.com/repos/docker/docker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/docker/docker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/docker/docker/teams","hooks_url":"https://api.github.com/repos/docker/docker/hooks","issue_events_url":"https://api.github.com/repos/docker/docker/issues/events{/number}","events_url":"https://api.github.com/repos/docker/docker/events","assignees_url":"https://api.github.com/repos/docker/docker/assignees{/user}","branches_url":"https://api.github.com/repos/docker/docker/branches{/branch}","tags_url":"https://api.github.com/repos/docker/docker/tags","blobs_url":"https://api.github.com/repos/docker/docker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/docker/docker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/docker/docker/git/refs{/sha}","trees_url":"https://api.github.com/repos/docker/docker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/docker/docker/statuses/{sha}","languages_url":"https://api.github.com/repos/docker/docker/languages","stargazers_url":"https://api.github.com/repos/docker/docker/stargazers","contributors_url":"https://api.github.com/repos/docker/docker/contributors","subscribers_url":"https://api.github.com/repos/docker/docker/subscribers","subscription_url":"https://api.github.com/repos/docker/docker/subscription","commits_url":"https://api.github.com/repos/docker/docker/commits{/sha}","git_commits_url":"https://api.github.com/repos/docker/docker/git/commits{/sha}","comments_url":"https://api.github.com/repos/docker/docker/comments{/number}","issue_comment_url":"https://api.github.com/repos/docker/docker/issues/comments{/number}","contents_url":"https://api.github.com/repos/docker/docker/contents/{+path}","compare_url":"https://api.github.com/repos/docker/docker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/docker/docker/merges","archive_url":"https://api.github.com/repos/docker/docker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/docker/docker/downloads","issues_url":"https://api.github.com/repos/docker/docker/issues{/number}","pulls_url":"https://api.github.com/repos/docker/docker/pulls{/number}","milestones_url":"https://api.github.com/repos/docker/docker/milestones{/number}","notifications_url":"https://api.github.com/repos/docker/docker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/docker/docker/labels{/name}","releases_url":"https://api.github.com/repos/docker/docker/releases{/id}","deployments_url":"https://api.github.com/repos/docker/docker/deployments","created_at":"2013-01-18T18:10:57Z","updated_at":"2017-03-04T01:19:32Z","pushed_at":"2017-03-04T01:42:58Z","git_url":"git://github.com/docker/docker.git","ssh_url":"git@github.com:docker/docker.git","clone_url":"https://github.com/docker/docker.git","svn_url":"https://github.com/docker/docker","homepage":"http://www.docker.com","size":125226,"stargazers_count":40252,"watchers_count":40252,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12099,"mirror_url":null,"open_issues_count":2386,"forks":12099,"open_issues":2386,"watchers":40252,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/docker/docker/pulls/31340"},"html":{"href":"https://github.com/docker/docker/pull/31340"},"issue":{"href":"https://api.github.com/repos/docker/docker/issues/31340"},"comments":{"href":"https://api.github.com/repos/docker/docker/issues/31340/comments"},"review_comments":{"href":"https://api.github.com/repos/docker/docker/pulls/31340/comments"},"review_comment":{"href":"https://api.github.com/repos/docker/docker/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/docker/docker/pulls/31340/commits"},"statuses":{"href":"https://api.github.com/repos/docker/docker/statuses/80ad85ebed2a4750a4932ec965922dfaa2f254eb"}}}}
{"actor":{"display_login":"anusha-ragunathan"}}