{"action":"created","comment":{"url":"https://api.github.com/repos/docker/swarm/pulls/comments/52695787","id":52695787,"diff_hunk":"@@ -14,6 +15,9 @@ type Filter interface {\n \n \t// Return a subset of nodes that were accepted by the filtering policy.\n \tFilter(*cluster.ContainerConfig, []*node.Node, bool) ([]*node.Node, error)\n+\n+\t// Return a list of constraints/filters provided\n+\tGetAllFilters(*cluster.ContainerConfig) ([]string, error)","path":"scheduler/filter/filter.go","position":null,"original_position":14,"commit_id":"0e292add0dbe447c938c46003aa9356996709691","original_commit_id":"5dedc5fab9f3e993ebb46ac115fc7905286dd2fb","user":{"login":"dongluochen","id":14985073,"avatar_url":"https://avatars.githubusercontent.com/u/14985073?v=3","gravatar_id":"","url":"https://api.github.com/users/dongluochen","html_url":"https://github.com/dongluochen","followers_url":"https://api.github.com/users/dongluochen/followers","following_url":"https://api.github.com/users/dongluochen/following{/other_user}","gists_url":"https://api.github.com/users/dongluochen/gists{/gist_id}","starred_url":"https://api.github.com/users/dongluochen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dongluochen/subscriptions","organizations_url":"https://api.github.com/users/dongluochen/orgs","repos_url":"https://api.github.com/users/dongluochen/repos","events_url":"https://api.github.com/users/dongluochen/events{/privacy}","received_events_url":"https://api.github.com/users/dongluochen/received_events","type":"User","site_admin":false},"body":"I feel `All` is not necessary. Another reason is you are calling `GetAllFilters` in `ApplyFilters` and `listAllFilters`. For me it reduces readability. ","created_at":"2016-02-12T01:28:34Z","updated_at":"2016-02-12T01:28:34Z","html_url":"https://github.com/docker/swarm/pull/1796#discussion_r52695787","pull_request_url":"https://api.github.com/repos/docker/swarm/pulls/1796","_links":{"self":{"href":"https://api.github.com/repos/docker/swarm/pulls/comments/52695787"},"html":{"href":"https://github.com/docker/swarm/pull/1796#discussion_r52695787"},"pull_request":{"href":"https://api.github.com/repos/docker/swarm/pulls/1796"}}},"pull_request":{"url":"https://api.github.com/repos/docker/swarm/pulls/1796","id":58999003,"html_url":"https://github.com/docker/swarm/pull/1796","diff_url":"https://github.com/docker/swarm/pull/1796.diff","patch_url":"https://github.com/docker/swarm/pull/1796.patch","issue_url":"https://api.github.com/repos/docker/swarm/issues/1796","number":1796,"state":"open","locked":false,"title":"Print all constraints when container can't be scheduled","user":{"login":"nishanttotla","id":1872537,"avatar_url":"https://avatars.githubusercontent.com/u/1872537?v=3","gravatar_id":"","url":"https://api.github.com/users/nishanttotla","html_url":"https://github.com/nishanttotla","followers_url":"https://api.github.com/users/nishanttotla/followers","following_url":"https://api.github.com/users/nishanttotla/following{/other_user}","gists_url":"https://api.github.com/users/nishanttotla/gists{/gist_id}","starred_url":"https://api.github.com/users/nishanttotla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nishanttotla/subscriptions","organizations_url":"https://api.github.com/users/nishanttotla/orgs","repos_url":"https://api.github.com/users/nishanttotla/repos","events_url":"https://api.github.com/users/nishanttotla/events{/privacy}","received_events_url":"https://api.github.com/users/nishanttotla/received_events","type":"User","site_admin":false},"body":"Fixes #1785.\r\n\r\nSpecial case when no healthy node is found, in which case nothing else is printed. The logic is in `scheduler/filter/filter.go`","created_at":"2016-02-11T07:36:08Z","updated_at":"2016-02-12T01:28:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0d049f8ea4a6c1343c7f679bbe40ab008737d034","assignee":null,"milestone":{"url":"https://api.github.com/repos/docker/swarm/milestones/8","html_url":"https://github.com/docker/swarm/milestones/1.2.0","labels_url":"https://api.github.com/repos/docker/swarm/milestones/8/labels","id":1507569,"number":8,"title":"1.2.0","description":"","creator":{"login":"vieux","id":1032519,"avatar_url":"https://avatars.githubusercontent.com/u/1032519?v=3","gravatar_id":"","url":"https://api.github.com/users/vieux","html_url":"https://github.com/vieux","followers_url":"https://api.github.com/users/vieux/followers","following_url":"https://api.github.com/users/vieux/following{/other_user}","gists_url":"https://api.github.com/users/vieux/gists{/gist_id}","starred_url":"https://api.github.com/users/vieux/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vieux/subscriptions","organizations_url":"https://api.github.com/users/vieux/orgs","repos_url":"https://api.github.com/users/vieux/repos","events_url":"https://api.github.com/users/vieux/events{/privacy}","received_events_url":"https://api.github.com/users/vieux/received_events","type":"User","site_admin":false},"open_issues":35,"closed_issues":2,"state":"open","created_at":"2016-01-14T19:31:45Z","updated_at":"2016-02-11T19:02:57Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/docker/swarm/pulls/1796/commits","review_comments_url":"https://api.github.com/repos/docker/swarm/pulls/1796/comments","review_comment_url":"https://api.github.com/repos/docker/swarm/pulls/comments{/number}","comments_url":"https://api.github.com/repos/docker/swarm/issues/1796/comments","statuses_url":"https://api.github.com/repos/docker/swarm/statuses/0e292add0dbe447c938c46003aa9356996709691","head":{"label":"nishanttotla:list-conflicting-constraints","ref":"list-conflicting-constraints","sha":"0e292add0dbe447c938c46003aa9356996709691","user":{"login":"nishanttotla","id":1872537,"avatar_url":"https://avatars.githubusercontent.com/u/1872537?v=3","gravatar_id":"","url":"https://api.github.com/users/nishanttotla","html_url":"https://github.com/nishanttotla","followers_url":"https://api.github.com/users/nishanttotla/followers","following_url":"https://api.github.com/users/nishanttotla/following{/other_user}","gists_url":"https://api.github.com/users/nishanttotla/gists{/gist_id}","starred_url":"https://api.github.com/users/nishanttotla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nishanttotla/subscriptions","organizations_url":"https://api.github.com/users/nishanttotla/orgs","repos_url":"https://api.github.com/users/nishanttotla/repos","events_url":"https://api.github.com/users/nishanttotla/events{/privacy}","received_events_url":"https://api.github.com/users/nishanttotla/received_events","type":"User","site_admin":false},"repo":{"id":49611622,"name":"swarm","full_name":"nishanttotla/swarm","owner":{"login":"nishanttotla","id":1872537,"avatar_url":"https://avatars.githubusercontent.com/u/1872537?v=3","gravatar_id":"","url":"https://api.github.com/users/nishanttotla","html_url":"https://github.com/nishanttotla","followers_url":"https://api.github.com/users/nishanttotla/followers","following_url":"https://api.github.com/users/nishanttotla/following{/other_user}","gists_url":"https://api.github.com/users/nishanttotla/gists{/gist_id}","starred_url":"https://api.github.com/users/nishanttotla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nishanttotla/subscriptions","organizations_url":"https://api.github.com/users/nishanttotla/orgs","repos_url":"https://api.github.com/users/nishanttotla/repos","events_url":"https://api.github.com/users/nishanttotla/events{/privacy}","received_events_url":"https://api.github.com/users/nishanttotla/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nishanttotla/swarm","description":"Swarm: a Docker-native clustering system","fork":true,"url":"https://api.github.com/repos/nishanttotla/swarm","forks_url":"https://api.github.com/repos/nishanttotla/swarm/forks","keys_url":"https://api.github.com/repos/nishanttotla/swarm/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nishanttotla/swarm/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nishanttotla/swarm/teams","hooks_url":"https://api.github.com/repos/nishanttotla/swarm/hooks","issue_events_url":"https://api.github.com/repos/nishanttotla/swarm/issues/events{/number}","events_url":"https://api.github.com/repos/nishanttotla/swarm/events","assignees_url":"https://api.github.com/repos/nishanttotla/swarm/assignees{/user}","branches_url":"https://api.github.com/repos/nishanttotla/swarm/branches{/branch}","tags_url":"https://api.github.com/repos/nishanttotla/swarm/tags","blobs_url":"https://api.github.com/repos/nishanttotla/swarm/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nishanttotla/swarm/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nishanttotla/swarm/git/refs{/sha}","trees_url":"https://api.github.com/repos/nishanttotla/swarm/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nishanttotla/swarm/statuses/{sha}","languages_url":"https://api.github.com/repos/nishanttotla/swarm/languages","stargazers_url":"https://api.github.com/repos/nishanttotla/swarm/stargazers","contributors_url":"https://api.github.com/repos/nishanttotla/swarm/contributors","subscribers_url":"https://api.github.com/repos/nishanttotla/swarm/subscribers","subscription_url":"https://api.github.com/repos/nishanttotla/swarm/subscription","commits_url":"https://api.github.com/repos/nishanttotla/swarm/commits{/sha}","git_commits_url":"https://api.github.com/repos/nishanttotla/swarm/git/commits{/sha}","comments_url":"https://api.github.com/repos/nishanttotla/swarm/comments{/number}","issue_comment_url":"https://api.github.com/repos/nishanttotla/swarm/issues/comments{/number}","contents_url":"https://api.github.com/repos/nishanttotla/swarm/contents/{+path}","compare_url":"https://api.github.com/repos/nishanttotla/swarm/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nishanttotla/swarm/merges","archive_url":"https://api.github.com/repos/nishanttotla/swarm/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nishanttotla/swarm/downloads","issues_url":"https://api.github.com/repos/nishanttotla/swarm/issues{/number}","pulls_url":"https://api.github.com/repos/nishanttotla/swarm/pulls{/number}","milestones_url":"https://api.github.com/repos/nishanttotla/swarm/milestones{/number}","notifications_url":"https://api.github.com/repos/nishanttotla/swarm/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nishanttotla/swarm/labels{/name}","releases_url":"https://api.github.com/repos/nishanttotla/swarm/releases{/id}","deployments_url":"https://api.github.com/repos/nishanttotla/swarm/deployments","created_at":"2016-01-14T00:34:36Z","updated_at":"2016-01-14T00:34:37Z","pushed_at":"2016-02-12T01:21:58Z","git_url":"git://github.com/nishanttotla/swarm.git","ssh_url":"git@github.com:nishanttotla/swarm.git","clone_url":"https://github.com/nishanttotla/swarm.git","svn_url":"https://github.com/nishanttotla/swarm","homepage":"","size":9239,"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":"d5033258a6f32c98b7e8aa0e23f1656ed6a67a1f","user":{"login":"docker","id":5429470,"avatar_url":"https://avatars.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":19360616,"name":"swarm","full_name":"docker/swarm","owner":{"login":"docker","id":5429470,"avatar_url":"https://avatars.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/swarm","description":"Swarm: a Docker-native clustering system","fork":false,"url":"https://api.github.com/repos/docker/swarm","forks_url":"https://api.github.com/repos/docker/swarm/forks","keys_url":"https://api.github.com/repos/docker/swarm/keys{/key_id}","collaborators_url":"https://api.github.com/repos/docker/swarm/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/docker/swarm/teams","hooks_url":"https://api.github.com/repos/docker/swarm/hooks","issue_events_url":"https://api.github.com/repos/docker/swarm/issues/events{/number}","events_url":"https://api.github.com/repos/docker/swarm/events","assignees_url":"https://api.github.com/repos/docker/swarm/assignees{/user}","branches_url":"https://api.github.com/repos/docker/swarm/branches{/branch}","tags_url":"https://api.github.com/repos/docker/swarm/tags","blobs_url":"https://api.github.com/repos/docker/swarm/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/docker/swarm/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/docker/swarm/git/refs{/sha}","trees_url":"https://api.github.com/repos/docker/swarm/git/trees{/sha}","statuses_url":"https://api.github.com/repos/docker/swarm/statuses/{sha}","languages_url":"https://api.github.com/repos/docker/swarm/languages","stargazers_url":"https://api.github.com/repos/docker/swarm/stargazers","contributors_url":"https://api.github.com/repos/docker/swarm/contributors","subscribers_url":"https://api.github.com/repos/docker/swarm/subscribers","subscription_url":"https://api.github.com/repos/docker/swarm/subscription","commits_url":"https://api.github.com/repos/docker/swarm/commits{/sha}","git_commits_url":"https://api.github.com/repos/docker/swarm/git/commits{/sha}","comments_url":"https://api.github.com/repos/docker/swarm/comments{/number}","issue_comment_url":"https://api.github.com/repos/docker/swarm/issues/comments{/number}","contents_url":"https://api.github.com/repos/docker/swarm/contents/{+path}","compare_url":"https://api.github.com/repos/docker/swarm/compare/{base}...{head}","merges_url":"https://api.github.com/repos/docker/swarm/merges","archive_url":"https://api.github.com/repos/docker/swarm/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/docker/swarm/downloads","issues_url":"https://api.github.com/repos/docker/swarm/issues{/number}","pulls_url":"https://api.github.com/repos/docker/swarm/pulls{/number}","milestones_url":"https://api.github.com/repos/docker/swarm/milestones{/number}","notifications_url":"https://api.github.com/repos/docker/swarm/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/docker/swarm/labels{/name}","releases_url":"https://api.github.com/repos/docker/swarm/releases{/id}","deployments_url":"https://api.github.com/repos/docker/swarm/deployments","created_at":"2014-05-01T23:15:17Z","updated_at":"2016-02-11T15:46:24Z","pushed_at":"2016-02-12T01:21:59Z","git_url":"git://github.com/docker/swarm.git","ssh_url":"git@github.com:docker/swarm.git","clone_url":"https://github.com/docker/swarm.git","svn_url":"https://github.com/docker/swarm","homepage":"","size":49380,"stargazers_count":3413,"watchers_count":3413,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":574,"mirror_url":null,"open_issues_count":159,"forks":574,"open_issues":159,"watchers":3413,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/docker/swarm/pulls/1796"},"html":{"href":"https://github.com/docker/swarm/pull/1796"},"issue":{"href":"https://api.github.com/repos/docker/swarm/issues/1796"},"comments":{"href":"https://api.github.com/repos/docker/swarm/issues/1796/comments"},"review_comments":{"href":"https://api.github.com/repos/docker/swarm/pulls/1796/comments"},"review_comment":{"href":"https://api.github.com/repos/docker/swarm/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/docker/swarm/pulls/1796/commits"},"statuses":{"href":"https://api.github.com/repos/docker/swarm/statuses/0e292add0dbe447c938c46003aa9356996709691"}}}}