{"action":"created","comment":{"url":"https://api.github.com/repos/influxdata/platform/pulls/comments/212371398","pull_request_review_id":148989582,"id":212371398,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxMjM3MTM5OA==","diff_hunk":"@@ -0,0 +1,29 @@\n+package functions\n+\n+import (\n+\t\"testing\"\n+\t\"github.com/influxdata/platform/query/values\"\n+\t\"github.com/influxdata/platform/query\"\n+)\n+\n+// TestBucketAwareOperationSpec verifies that any functions with parameters\n+// named \"bucket\" or \"bucketID\" implement interface BucketAwareOperationSpec.\n+func TestBucketAwareOperationSpec(t *testing.T) {","path":"query/functions/function_test.go","position":11,"original_position":11,"commit_id":"8a707626b0b8590f1201da3f7fd4ff78d6ddf086","original_commit_id":"8a707626b0b8590f1201da3f7fd4ff78d6ddf086","user":{"login":"wolffcm","id":7902964,"node_id":"MDQ6VXNlcjc5MDI5NjQ=","avatar_url":"https://avatars1.githubusercontent.com/u/7902964?v=4","gravatar_id":"","url":"https://api.github.com/users/wolffcm","html_url":"https://github.com/wolffcm","followers_url":"https://api.github.com/users/wolffcm/followers","following_url":"https://api.github.com/users/wolffcm/following{/other_user}","gists_url":"https://api.github.com/users/wolffcm/gists{/gist_id}","starred_url":"https://api.github.com/users/wolffcm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wolffcm/subscriptions","organizations_url":"https://api.github.com/users/wolffcm/orgs","repos_url":"https://api.github.com/users/wolffcm/repos","events_url":"https://api.github.com/users/wolffcm/events{/privacy}","received_events_url":"https://api.github.com/users/wolffcm/received_events","type":"User","site_admin":false},"body":"I asked Nathaniel about this.  He suggested just making the OperationSpec have a `bucketsAccessed` method, which means more boilerplate but avoids this fragility.  I'll push another commit that does this.","created_at":"2018-08-23T16:17:30Z","updated_at":"2018-08-23T16:17:30Z","html_url":"https://github.com/influxdata/platform/pull/664#discussion_r212371398","pull_request_url":"https://api.github.com/repos/influxdata/platform/pulls/664","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/influxdata/platform/pulls/comments/212371398"},"html":{"href":"https://github.com/influxdata/platform/pull/664#discussion_r212371398"},"pull_request":{"href":"https://api.github.com/repos/influxdata/platform/pulls/664"}},"in_reply_to_id":212077960},"pull_request":{"url":"https://api.github.com/repos/influxdata/platform/pulls/664","id":209575563,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA5NTc1NTYz","html_url":"https://github.com/influxdata/platform/pull/664","diff_url":"https://github.com/influxdata/platform/pull/664.diff","patch_url":"https://github.com/influxdata/platform/pull/664.patch","issue_url":"https://api.github.com/repos/influxdata/platform/issues/664","number":664,"state":"open","locked":false,"title":"Add BucketsAccessed method to OperationSpec and Authorizer interface","user":{"login":"wolffcm","id":7902964,"node_id":"MDQ6VXNlcjc5MDI5NjQ=","avatar_url":"https://avatars1.githubusercontent.com/u/7902964?v=4","gravatar_id":"","url":"https://api.github.com/users/wolffcm","html_url":"https://github.com/wolffcm","followers_url":"https://api.github.com/users/wolffcm/followers","following_url":"https://api.github.com/users/wolffcm/following{/other_user}","gists_url":"https://api.github.com/users/wolffcm/gists{/gist_id}","starred_url":"https://api.github.com/users/wolffcm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wolffcm/subscriptions","organizations_url":"https://api.github.com/users/wolffcm/orgs","repos_url":"https://api.github.com/users/wolffcm/repos","events_url":"https://api.github.com/users/wolffcm/events{/privacy}","received_events_url":"https://api.github.com/users/wolffcm/received_events","type":"User","site_admin":false},"body":"Closes #565\r\n\r\n_Briefly describe your proposed changes:_\r\n\r\nAdd a method to OperationSpec to get the buckets accessed by an operation.\r\n\r\nAdd an Authorization interface that can verify user is authorized to access buckets read/written by query.\r\n\r\n_What was the problem?_\r\n_What was the solution?_\r\n\r\n  - [ ] CHANGELOG.md updated with a link to the PR (not the Issue)\r\n  - [x] Rebased/mergeable\r\n  - [ ] Tests pass\r\n  - [ ] swagger.json updated (if modified Go structs or API)\r\n  - [ ] Sign [CLA](https://influxdata.com/community/cla/) (if not already signed)","created_at":"2018-08-20T16:25:45Z","updated_at":"2018-08-23T16:17:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f2ad7c726d281587b8b20ee898cb0a49457ca3e7","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/influxdata/platform/pulls/664/commits","review_comments_url":"https://api.github.com/repos/influxdata/platform/pulls/664/comments","review_comment_url":"https://api.github.com/repos/influxdata/platform/pulls/comments{/number}","comments_url":"https://api.github.com/repos/influxdata/platform/issues/664/comments","statuses_url":"https://api.github.com/repos/influxdata/platform/statuses/8a707626b0b8590f1201da3f7fd4ff78d6ddf086","head":{"label":"influxdata:cmw-authorize-flux","ref":"cmw-authorize-flux","sha":"8a707626b0b8590f1201da3f7fd4ff78d6ddf086","user":{"login":"influxdata","id":5713248,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU3MTMyNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/5713248?v=4","gravatar_id":"","url":"https://api.github.com/users/influxdata","html_url":"https://github.com/influxdata","followers_url":"https://api.github.com/users/influxdata/followers","following_url":"https://api.github.com/users/influxdata/following{/other_user}","gists_url":"https://api.github.com/users/influxdata/gists{/gist_id}","starred_url":"https://api.github.com/users/influxdata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/influxdata/subscriptions","organizations_url":"https://api.github.com/users/influxdata/orgs","repos_url":"https://api.github.com/users/influxdata/repos","events_url":"https://api.github.com/users/influxdata/events{/privacy}","received_events_url":"https://api.github.com/users/influxdata/received_events","type":"Organization","site_admin":false},"repo":{"id":132783164,"node_id":"MDEwOlJlcG9zaXRvcnkxMzI3ODMxNjQ=","name":"platform","full_name":"influxdata/platform","owner":{"login":"influxdata","id":5713248,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU3MTMyNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/5713248?v=4","gravatar_id":"","url":"https://api.github.com/users/influxdata","html_url":"https://github.com/influxdata","followers_url":"https://api.github.com/users/influxdata/followers","following_url":"https://api.github.com/users/influxdata/following{/other_user}","gists_url":"https://api.github.com/users/influxdata/gists{/gist_id}","starred_url":"https://api.github.com/users/influxdata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/influxdata/subscriptions","organizations_url":"https://api.github.com/users/influxdata/orgs","repos_url":"https://api.github.com/users/influxdata/repos","events_url":"https://api.github.com/users/influxdata/events{/privacy}","received_events_url":"https://api.github.com/users/influxdata/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/influxdata/platform","description":"InfluxDB 2.0: The community version of the InfluxData Platform for Time Series","fork":false,"url":"https://api.github.com/repos/influxdata/platform","forks_url":"https://api.github.com/repos/influxdata/platform/forks","keys_url":"https://api.github.com/repos/influxdata/platform/keys{/key_id}","collaborators_url":"https://api.github.com/repos/influxdata/platform/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/influxdata/platform/teams","hooks_url":"https://api.github.com/repos/influxdata/platform/hooks","issue_events_url":"https://api.github.com/repos/influxdata/platform/issues/events{/number}","events_url":"https://api.github.com/repos/influxdata/platform/events","assignees_url":"https://api.github.com/repos/influxdata/platform/assignees{/user}","branches_url":"https://api.github.com/repos/influxdata/platform/branches{/branch}","tags_url":"https://api.github.com/repos/influxdata/platform/tags","blobs_url":"https://api.github.com/repos/influxdata/platform/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/influxdata/platform/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/influxdata/platform/git/refs{/sha}","trees_url":"https://api.github.com/repos/influxdata/platform/git/trees{/sha}","statuses_url":"https://api.github.com/repos/influxdata/platform/statuses/{sha}","languages_url":"https://api.github.com/repos/influxdata/platform/languages","stargazers_url":"https://api.github.com/repos/influxdata/platform/stargazers","contributors_url":"https://api.github.com/repos/influxdata/platform/contributors","subscribers_url":"https://api.github.com/repos/influxdata/platform/subscribers","subscription_url":"https://api.github.com/repos/influxdata/platform/subscription","commits_url":"https://api.github.com/repos/influxdata/platform/commits{/sha}","git_commits_url":"https://api.github.com/repos/influxdata/platform/git/commits{/sha}","comments_url":"https://api.github.com/repos/influxdata/platform/comments{/number}","issue_comment_url":"https://api.github.com/repos/influxdata/platform/issues/comments{/number}","contents_url":"https://api.github.com/repos/influxdata/platform/contents/{+path}","compare_url":"https://api.github.com/repos/influxdata/platform/compare/{base}...{head}","merges_url":"https://api.github.com/repos/influxdata/platform/merges","archive_url":"https://api.github.com/repos/influxdata/platform/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/influxdata/platform/downloads","issues_url":"https://api.github.com/repos/influxdata/platform/issues{/number}","pulls_url":"https://api.github.com/repos/influxdata/platform/pulls{/number}","milestones_url":"https://api.github.com/repos/influxdata/platform/milestones{/number}","notifications_url":"https://api.github.com/repos/influxdata/platform/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/influxdata/platform/labels{/name}","releases_url":"https://api.github.com/repos/influxdata/platform/releases{/id}","deployments_url":"https://api.github.com/repos/influxdata/platform/deployments","created_at":"2018-05-09T16:17:29Z","updated_at":"2018-08-23T14:23:20Z","pushed_at":"2018-08-23T16:13:16Z","git_url":"git://github.com/influxdata/platform.git","ssh_url":"git@github.com:influxdata/platform.git","clone_url":"https://github.com/influxdata/platform.git","svn_url":"https://github.com/influxdata/platform","homepage":"","size":22409,"stargazers_count":142,"watchers_count":142,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"archived":false,"open_issues_count":304,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":7,"open_issues":304,"watchers":142,"default_branch":"master"}},"base":{"label":"influxdata:master","ref":"master","sha":"be7a3e56dee504b5eaf61ce25e899aa4dc8578ba","user":{"login":"influxdata","id":5713248,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU3MTMyNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/5713248?v=4","gravatar_id":"","url":"https://api.github.com/users/influxdata","html_url":"https://github.com/influxdata","followers_url":"https://api.github.com/users/influxdata/followers","following_url":"https://api.github.com/users/influxdata/following{/other_user}","gists_url":"https://api.github.com/users/influxdata/gists{/gist_id}","starred_url":"https://api.github.com/users/influxdata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/influxdata/subscriptions","organizations_url":"https://api.github.com/users/influxdata/orgs","repos_url":"https://api.github.com/users/influxdata/repos","events_url":"https://api.github.com/users/influxdata/events{/privacy}","received_events_url":"https://api.github.com/users/influxdata/received_events","type":"Organization","site_admin":false},"repo":{"id":132783164,"node_id":"MDEwOlJlcG9zaXRvcnkxMzI3ODMxNjQ=","name":"platform","full_name":"influxdata/platform","owner":{"login":"influxdata","id":5713248,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU3MTMyNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/5713248?v=4","gravatar_id":"","url":"https://api.github.com/users/influxdata","html_url":"https://github.com/influxdata","followers_url":"https://api.github.com/users/influxdata/followers","following_url":"https://api.github.com/users/influxdata/following{/other_user}","gists_url":"https://api.github.com/users/influxdata/gists{/gist_id}","starred_url":"https://api.github.com/users/influxdata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/influxdata/subscriptions","organizations_url":"https://api.github.com/users/influxdata/orgs","repos_url":"https://api.github.com/users/influxdata/repos","events_url":"https://api.github.com/users/influxdata/events{/privacy}","received_events_url":"https://api.github.com/users/influxdata/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/influxdata/platform","description":"InfluxDB 2.0: The community version of the InfluxData Platform for Time Series","fork":false,"url":"https://api.github.com/repos/influxdata/platform","forks_url":"https://api.github.com/repos/influxdata/platform/forks","keys_url":"https://api.github.com/repos/influxdata/platform/keys{/key_id}","collaborators_url":"https://api.github.com/repos/influxdata/platform/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/influxdata/platform/teams","hooks_url":"https://api.github.com/repos/influxdata/platform/hooks","issue_events_url":"https://api.github.com/repos/influxdata/platform/issues/events{/number}","events_url":"https://api.github.com/repos/influxdata/platform/events","assignees_url":"https://api.github.com/repos/influxdata/platform/assignees{/user}","branches_url":"https://api.github.com/repos/influxdata/platform/branches{/branch}","tags_url":"https://api.github.com/repos/influxdata/platform/tags","blobs_url":"https://api.github.com/repos/influxdata/platform/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/influxdata/platform/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/influxdata/platform/git/refs{/sha}","trees_url":"https://api.github.com/repos/influxdata/platform/git/trees{/sha}","statuses_url":"https://api.github.com/repos/influxdata/platform/statuses/{sha}","languages_url":"https://api.github.com/repos/influxdata/platform/languages","stargazers_url":"https://api.github.com/repos/influxdata/platform/stargazers","contributors_url":"https://api.github.com/repos/influxdata/platform/contributors","subscribers_url":"https://api.github.com/repos/influxdata/platform/subscribers","subscription_url":"https://api.github.com/repos/influxdata/platform/subscription","commits_url":"https://api.github.com/repos/influxdata/platform/commits{/sha}","git_commits_url":"https://api.github.com/repos/influxdata/platform/git/commits{/sha}","comments_url":"https://api.github.com/repos/influxdata/platform/comments{/number}","issue_comment_url":"https://api.github.com/repos/influxdata/platform/issues/comments{/number}","contents_url":"https://api.github.com/repos/influxdata/platform/contents/{+path}","compare_url":"https://api.github.com/repos/influxdata/platform/compare/{base}...{head}","merges_url":"https://api.github.com/repos/influxdata/platform/merges","archive_url":"https://api.github.com/repos/influxdata/platform/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/influxdata/platform/downloads","issues_url":"https://api.github.com/repos/influxdata/platform/issues{/number}","pulls_url":"https://api.github.com/repos/influxdata/platform/pulls{/number}","milestones_url":"https://api.github.com/repos/influxdata/platform/milestones{/number}","notifications_url":"https://api.github.com/repos/influxdata/platform/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/influxdata/platform/labels{/name}","releases_url":"https://api.github.com/repos/influxdata/platform/releases{/id}","deployments_url":"https://api.github.com/repos/influxdata/platform/deployments","created_at":"2018-05-09T16:17:29Z","updated_at":"2018-08-23T14:23:20Z","pushed_at":"2018-08-23T16:13:16Z","git_url":"git://github.com/influxdata/platform.git","ssh_url":"git@github.com:influxdata/platform.git","clone_url":"https://github.com/influxdata/platform.git","svn_url":"https://github.com/influxdata/platform","homepage":"","size":22409,"stargazers_count":142,"watchers_count":142,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"archived":false,"open_issues_count":304,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":7,"open_issues":304,"watchers":142,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/influxdata/platform/pulls/664"},"html":{"href":"https://github.com/influxdata/platform/pull/664"},"issue":{"href":"https://api.github.com/repos/influxdata/platform/issues/664"},"comments":{"href":"https://api.github.com/repos/influxdata/platform/issues/664/comments"},"review_comments":{"href":"https://api.github.com/repos/influxdata/platform/pulls/664/comments"},"review_comment":{"href":"https://api.github.com/repos/influxdata/platform/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/influxdata/platform/pulls/664/commits"},"statuses":{"href":"https://api.github.com/repos/influxdata/platform/statuses/8a707626b0b8590f1201da3f7fd4ff78d6ddf086"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"wolffcm"}}