{"action":"created","comment":{"url":"https://api.github.com/repos/docker/docker/pulls/comments/111609285","pull_request_review_id":32868061,"id":111609285,"diff_hunk":"@@ -103,6 +88,23 @@ func (c *Cluster) resolveAdvertiseAddr(advertiseAddr, listenAddrPort string) (st\n \treturn systemAddr.String(), listenAddrPort, nil\n }\n \n+func resolveDataPathAddr(dataPathAddr string) (string, error) {\n+\t// Approach:\n+\t// - If a data path flag is specified try to resolve the IP address.\n+\tif dataPathAddr != \"\" {","path":"daemon/cluster/listen_addr.go","position":104,"original_position":104,"commit_id":"ace2ed5c4e9b7912f5ce971471266367019dbf11","original_commit_id":"ace2ed5c4e9b7912f5ce971471266367019dbf11","user":{"login":"aboch","id":10080882,"avatar_url":"https://avatars2.githubusercontent.com/u/10080882?v=3","gravatar_id":"","url":"https://api.github.com/users/aboch","html_url":"https://github.com/aboch","followers_url":"https://api.github.com/users/aboch/followers","following_url":"https://api.github.com/users/aboch/following{/other_user}","gists_url":"https://api.github.com/users/aboch/gists{/gist_id}","starred_url":"https://api.github.com/users/aboch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aboch/subscriptions","organizations_url":"https://api.github.com/users/aboch/orgs","repos_url":"https://api.github.com/users/aboch/repos","events_url":"https://api.github.com/users/aboch/events{/privacy}","received_events_url":"https://api.github.com/users/aboch/received_events","type":"User","site_admin":false},"body":"I would handle the empty case right away and avoid the extra indentation here with \r\n```\r\nif dataPathAddr == \"\" {\r\n    return \"\", nil\r\n}\r\n```","created_at":"2017-04-14T17:49:43Z","updated_at":"2017-04-14T17:49:43Z","html_url":"https://github.com/docker/docker/pull/32615#discussion_r111609285","pull_request_url":"https://api.github.com/repos/docker/docker/pulls/32615","_links":{"self":{"href":"https://api.github.com/repos/docker/docker/pulls/comments/111609285"},"html":{"href":"https://github.com/docker/docker/pull/32615#discussion_r111609285"},"pull_request":{"href":"https://api.github.com/repos/docker/docker/pulls/32615"}}},"pull_request":{"url":"https://api.github.com/repos/docker/docker/pulls/32615","id":115865667,"html_url":"https://github.com/docker/docker/pull/32615","diff_url":"https://github.com/docker/docker/pull/32615.diff","patch_url":"https://github.com/docker/docker/pull/32615.patch","issue_url":"https://api.github.com/repos/docker/docker/issues/32615","number":32615,"state":"open","locked":false,"title":"Data path traffic separation option in swarm mode","user":{"login":"fcrisciani","id":1823625,"avatar_url":"https://avatars0.githubusercontent.com/u/1823625?v=3","gravatar_id":"","url":"https://api.github.com/users/fcrisciani","html_url":"https://github.com/fcrisciani","followers_url":"https://api.github.com/users/fcrisciani/followers","following_url":"https://api.github.com/users/fcrisciani/following{/other_user}","gists_url":"https://api.github.com/users/fcrisciani/gists{/gist_id}","starred_url":"https://api.github.com/users/fcrisciani/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fcrisciani/subscriptions","organizations_url":"https://api.github.com/users/fcrisciani/orgs","repos_url":"https://api.github.com/users/fcrisciani/repos","events_url":"https://api.github.com/users/fcrisciani/events{/privacy}","received_events_url":"https://api.github.com/users/fcrisciani/received_events","type":"User","site_admin":false},"body":"<!--\r\nPlease make sure you've read and understood our contributing guidelines;\r\nhttps://github.com/docker/docker/blob/master/CONTRIBUTING.md\r\n\r\n** Make sure all your commits include a signature generated with `git commit -s` **\r\n\r\nFor additional information on our contributing process, read our contributing\r\nguide https://docs.docker.com/opensource/code/\r\n\r\nIf this is a bug fix, make sure your description includes \"fixes #xxxx\", or\r\n\"closes #xxxx\"\r\n\r\nPlease provide the following information:\r\n-->\r\n\r\n**- What I did**\r\nIn SWARM mode is now possible to pass a new flag to specify which is the interface to use for data path traffic. This will allow to separate data traffic (container to container pkts) from control traffic (grpc between workers and managers)\r\n\r\n**- How I did it**\r\nIntroduced a new flag --datapath-addr in the docker swarm init and docker swarm join\r\n\r\n**- How to verify it**\r\nCreate a swarm cluster on hosts with at least 2 interfaces, one will be dedicated for the management and will be the one that will be used in the --advertise-addr, the other instead will be the one for the --datapath-addr flag.\r\nSecond step is to create an overlay network\r\nThird step is to launch containers on different workers using the overlay network.\r\nAt this point the traffic between the containers on different workers will happen on the interface identified by the --datapath-addr\r\n\r\n**- Description for the changelog**\r\n<!--\r\nWrite a short (one line) summary that describes the changes in this\r\npull request for inclusion in the changelog:\r\n-->\r\nData path traffic separation option in swarm mode\r\n\r\n**- A picture of a cute animal (not mandatory but encouraged)**\r\n![hqdefault](https://cloud.githubusercontent.com/assets/1823625/25028793/d4446166-206b-11e7-9283-19ee34c26f2b.jpg)\r\n\r\n","created_at":"2017-04-14T00:08:48Z","updated_at":"2017-04-14T17:49:43Z","closed_at":null,"merged_at":null,"merge_commit_sha":"cf0ef32d07507c035e66b365351fa3d589471a3a","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/docker/docker/pulls/32615/commits","review_comments_url":"https://api.github.com/repos/docker/docker/pulls/32615/comments","review_comment_url":"https://api.github.com/repos/docker/docker/pulls/comments{/number}","comments_url":"https://api.github.com/repos/docker/docker/issues/32615/comments","statuses_url":"https://api.github.com/repos/docker/docker/statuses/ace2ed5c4e9b7912f5ce971471266367019dbf11","head":{"label":"fcrisciani:data_path","ref":"data_path","sha":"ace2ed5c4e9b7912f5ce971471266367019dbf11","user":{"login":"fcrisciani","id":1823625,"avatar_url":"https://avatars0.githubusercontent.com/u/1823625?v=3","gravatar_id":"","url":"https://api.github.com/users/fcrisciani","html_url":"https://github.com/fcrisciani","followers_url":"https://api.github.com/users/fcrisciani/followers","following_url":"https://api.github.com/users/fcrisciani/following{/other_user}","gists_url":"https://api.github.com/users/fcrisciani/gists{/gist_id}","starred_url":"https://api.github.com/users/fcrisciani/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fcrisciani/subscriptions","organizations_url":"https://api.github.com/users/fcrisciani/orgs","repos_url":"https://api.github.com/users/fcrisciani/repos","events_url":"https://api.github.com/users/fcrisciani/events{/privacy}","received_events_url":"https://api.github.com/users/fcrisciani/received_events","type":"User","site_admin":false},"repo":{"id":87845106,"name":"docker","full_name":"fcrisciani/docker","owner":{"login":"fcrisciani","id":1823625,"avatar_url":"https://avatars0.githubusercontent.com/u/1823625?v=3","gravatar_id":"","url":"https://api.github.com/users/fcrisciani","html_url":"https://github.com/fcrisciani","followers_url":"https://api.github.com/users/fcrisciani/followers","following_url":"https://api.github.com/users/fcrisciani/following{/other_user}","gists_url":"https://api.github.com/users/fcrisciani/gists{/gist_id}","starred_url":"https://api.github.com/users/fcrisciani/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fcrisciani/subscriptions","organizations_url":"https://api.github.com/users/fcrisciani/orgs","repos_url":"https://api.github.com/users/fcrisciani/repos","events_url":"https://api.github.com/users/fcrisciani/events{/privacy}","received_events_url":"https://api.github.com/users/fcrisciani/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/fcrisciani/docker","description":"Docker - the open-source application container engine","fork":true,"url":"https://api.github.com/repos/fcrisciani/docker","forks_url":"https://api.github.com/repos/fcrisciani/docker/forks","keys_url":"https://api.github.com/repos/fcrisciani/docker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fcrisciani/docker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fcrisciani/docker/teams","hooks_url":"https://api.github.com/repos/fcrisciani/docker/hooks","issue_events_url":"https://api.github.com/repos/fcrisciani/docker/issues/events{/number}","events_url":"https://api.github.com/repos/fcrisciani/docker/events","assignees_url":"https://api.github.com/repos/fcrisciani/docker/assignees{/user}","branches_url":"https://api.github.com/repos/fcrisciani/docker/branches{/branch}","tags_url":"https://api.github.com/repos/fcrisciani/docker/tags","blobs_url":"https://api.github.com/repos/fcrisciani/docker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fcrisciani/docker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fcrisciani/docker/git/refs{/sha}","trees_url":"https://api.github.com/repos/fcrisciani/docker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fcrisciani/docker/statuses/{sha}","languages_url":"https://api.github.com/repos/fcrisciani/docker/languages","stargazers_url":"https://api.github.com/repos/fcrisciani/docker/stargazers","contributors_url":"https://api.github.com/repos/fcrisciani/docker/contributors","subscribers_url":"https://api.github.com/repos/fcrisciani/docker/subscribers","subscription_url":"https://api.github.com/repos/fcrisciani/docker/subscription","commits_url":"https://api.github.com/repos/fcrisciani/docker/commits{/sha}","git_commits_url":"https://api.github.com/repos/fcrisciani/docker/git/commits{/sha}","comments_url":"https://api.github.com/repos/fcrisciani/docker/comments{/number}","issue_comment_url":"https://api.github.com/repos/fcrisciani/docker/issues/comments{/number}","contents_url":"https://api.github.com/repos/fcrisciani/docker/contents/{+path}","compare_url":"https://api.github.com/repos/fcrisciani/docker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fcrisciani/docker/merges","archive_url":"https://api.github.com/repos/fcrisciani/docker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fcrisciani/docker/downloads","issues_url":"https://api.github.com/repos/fcrisciani/docker/issues{/number}","pulls_url":"https://api.github.com/repos/fcrisciani/docker/pulls{/number}","milestones_url":"https://api.github.com/repos/fcrisciani/docker/milestones{/number}","notifications_url":"https://api.github.com/repos/fcrisciani/docker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fcrisciani/docker/labels{/name}","releases_url":"https://api.github.com/repos/fcrisciani/docker/releases{/id}","deployments_url":"https://api.github.com/repos/fcrisciani/docker/deployments","created_at":"2017-04-10T18:39:04Z","updated_at":"2017-04-10T18:39:26Z","pushed_at":"2017-04-14T00:32:28Z","git_url":"git://github.com/fcrisciani/docker.git","ssh_url":"git@github.com:fcrisciani/docker.git","clone_url":"https://github.com/fcrisciani/docker.git","svn_url":"https://github.com/fcrisciani/docker","homepage":"https://www.docker.com","size":128488,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"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":"41f4c3cf7e270086bb2f6a6bd4622d9aeb8f741f","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-04-14T17:39:52Z","pushed_at":"2017-04-14T17:47:07Z","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":"https://www.docker.com","size":128585,"stargazers_count":41797,"watchers_count":41797,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12629,"mirror_url":null,"open_issues_count":2495,"forks":12629,"open_issues":2495,"watchers":41797,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/docker/docker/pulls/32615"},"html":{"href":"https://github.com/docker/docker/pull/32615"},"issue":{"href":"https://api.github.com/repos/docker/docker/issues/32615"},"comments":{"href":"https://api.github.com/repos/docker/docker/issues/32615/comments"},"review_comments":{"href":"https://api.github.com/repos/docker/docker/pulls/32615/comments"},"review_comment":{"href":"https://api.github.com/repos/docker/docker/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/docker/docker/pulls/32615/commits"},"statuses":{"href":"https://api.github.com/repos/docker/docker/statuses/ace2ed5c4e9b7912f5ce971471266367019dbf11"}}}}
{"actor":{"display_login":"aboch"}}