{"action":"created","comment":{"url":"https://api.github.com/repos/m3db/m3storage/pulls/comments/73791251","id":73791251,"diff_hunk":"@@ -68,55 +63,50 @@ func NewClusterConfigChange(c Cluster) ClusterConfigChange {\n \t}\n }\n \n-// A Mapping is a set of rules mapping shards onto a storage cluster.\n-type Mapping interface {\n+// A ClusterMappingRuleProvider provides cluster mapping rules\n+type ClusterMappingRuleProvider interface {\n \t// RulesForShard returns the mapping rules that currently apply to the given shard, plus\n \t// a channel that can be used to receive new mapping rules\n-\tRulesForShard(n int) ([]MappingRule, <-chan []MappingRule, error)\n-\n-\t// Clusters returns all of the currently defined clusters, plus a channel\n-\t// that can be used to receive cluster changes (new clusters, changes to\n-\t// cluster configurations)\n-\tClusters() ([]Cluster, <-chan ClusterConfigChange, error)\n+\tRulesForShard(n int) ([]ClusterMappingRule, <-chan []ClusterMappingRule, error)","path":"cluster_mapping_rules.go","position":67,"original_position":67,"commit_id":"9cb14785a8b6bd01e9b11d3b8a9437818ddd6a07","original_commit_id":"9cb14785a8b6bd01e9b11d3b8a9437818ddd6a07","user":{"login":"mmihic","id":392793,"avatar_url":"https://avatars.githubusercontent.com/u/392793?v=3","gravatar_id":"","url":"https://api.github.com/users/mmihic","html_url":"https://github.com/mmihic","followers_url":"https://api.github.com/users/mmihic/followers","following_url":"https://api.github.com/users/mmihic/following{/other_user}","gists_url":"https://api.github.com/users/mmihic/gists{/gist_id}","starred_url":"https://api.github.com/users/mmihic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmihic/subscriptions","organizations_url":"https://api.github.com/users/mmihic/orgs","repos_url":"https://api.github.com/users/mmihic/repos","events_url":"https://api.github.com/users/mmihic/events{/privacy}","received_events_url":"https://api.github.com/users/mmihic/received_events","type":"User","site_admin":false},"body":"If the consumer of updates closed the channel, how does the provider know not to continue sending updates to the channel?\r\n\r\n","created_at":"2016-08-06T20:03:19Z","updated_at":"2016-08-06T20:03:19Z","html_url":"https://github.com/m3db/m3storage/pull/2#discussion_r73791251","pull_request_url":"https://api.github.com/repos/m3db/m3storage/pulls/2","_links":{"self":{"href":"https://api.github.com/repos/m3db/m3storage/pulls/comments/73791251"},"html":{"href":"https://github.com/m3db/m3storage/pull/2#discussion_r73791251"},"pull_request":{"href":"https://api.github.com/repos/m3db/m3storage/pulls/2"}}},"pull_request":{"url":"https://api.github.com/repos/m3db/m3storage/pulls/2","id":80290969,"html_url":"https://github.com/m3db/m3storage/pull/2","diff_url":"https://github.com/m3db/m3storage/pull/2.diff","patch_url":"https://github.com/m3db/m3storage/pull/2.patch","issue_url":"https://api.github.com/repos/m3db/m3storage/issues/2","number":2,"state":"open","locked":false,"title":"Retention period query planning","user":{"login":"mmihic","id":392793,"avatar_url":"https://avatars.githubusercontent.com/u/392793?v=3","gravatar_id":"","url":"https://api.github.com/users/mmihic","html_url":"https://github.com/mmihic","followers_url":"https://api.github.com/users/mmihic/followers","following_url":"https://api.github.com/users/mmihic/following{/other_user}","gists_url":"https://api.github.com/users/mmihic/gists{/gist_id}","starred_url":"https://api.github.com/users/mmihic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmihic/subscriptions","organizations_url":"https://api.github.com/users/mmihic/orgs","repos_url":"https://api.github.com/users/mmihic/repos","events_url":"https://api.github.com/users/mmihic/events{/privacy}","received_events_url":"https://api.github.com/users/mmihic/received_events","type":"User","site_admin":false},"body":"Adds RetentionPolicy and RetentionRules, which define how long a time series is retained at a given resolution.  Supports alterations to retention policies over time, and includes a retention query planner that determines which retention policies apply for a given timespan.\r\n\r\nThis is the first step in read/write routing - we first determine which retention policies apply for a query, then determine which storage backends and clusters to use when reading/writing a given time series at that retention policy.  The latter part (determining the concrete storage backends and clusters) will follow in a subsequent PR.\r\n\r\nR: @xichen2020 @robskillington @martin-mao ","created_at":"2016-08-05T18:59:35Z","updated_at":"2016-08-06T20:03:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d70671766585028f5f0c97e471a47687b64cbf30","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/m3db/m3storage/pulls/2/commits","review_comments_url":"https://api.github.com/repos/m3db/m3storage/pulls/2/comments","review_comment_url":"https://api.github.com/repos/m3db/m3storage/pulls/comments{/number}","comments_url":"https://api.github.com/repos/m3db/m3storage/issues/2/comments","statuses_url":"https://api.github.com/repos/m3db/m3storage/statuses/9cb14785a8b6bd01e9b11d3b8a9437818ddd6a07","head":{"label":"m3db:mmihic-initial-routing","ref":"mmihic-initial-routing","sha":"9cb14785a8b6bd01e9b11d3b8a9437818ddd6a07","user":{"login":"m3db","id":19937171,"avatar_url":"https://avatars.githubusercontent.com/u/19937171?v=3","gravatar_id":"","url":"https://api.github.com/users/m3db","html_url":"https://github.com/m3db","followers_url":"https://api.github.com/users/m3db/followers","following_url":"https://api.github.com/users/m3db/following{/other_user}","gists_url":"https://api.github.com/users/m3db/gists{/gist_id}","starred_url":"https://api.github.com/users/m3db/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/m3db/subscriptions","organizations_url":"https://api.github.com/users/m3db/orgs","repos_url":"https://api.github.com/users/m3db/repos","events_url":"https://api.github.com/users/m3db/events{/privacy}","received_events_url":"https://api.github.com/users/m3db/received_events","type":"Organization","site_admin":false},"repo":{"id":64314848,"name":"m3storage","full_name":"m3db/m3storage","owner":{"login":"m3db","id":19937171,"avatar_url":"https://avatars.githubusercontent.com/u/19937171?v=3","gravatar_id":"","url":"https://api.github.com/users/m3db","html_url":"https://github.com/m3db","followers_url":"https://api.github.com/users/m3db/followers","following_url":"https://api.github.com/users/m3db/following{/other_user}","gists_url":"https://api.github.com/users/m3db/gists{/gist_id}","starred_url":"https://api.github.com/users/m3db/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/m3db/subscriptions","organizations_url":"https://api.github.com/users/m3db/orgs","repos_url":"https://api.github.com/users/m3db/repos","events_url":"https://api.github.com/users/m3db/events{/privacy}","received_events_url":"https://api.github.com/users/m3db/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/m3db/m3storage","description":"Tiered storage manager","fork":false,"url":"https://api.github.com/repos/m3db/m3storage","forks_url":"https://api.github.com/repos/m3db/m3storage/forks","keys_url":"https://api.github.com/repos/m3db/m3storage/keys{/key_id}","collaborators_url":"https://api.github.com/repos/m3db/m3storage/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/m3db/m3storage/teams","hooks_url":"https://api.github.com/repos/m3db/m3storage/hooks","issue_events_url":"https://api.github.com/repos/m3db/m3storage/issues/events{/number}","events_url":"https://api.github.com/repos/m3db/m3storage/events","assignees_url":"https://api.github.com/repos/m3db/m3storage/assignees{/user}","branches_url":"https://api.github.com/repos/m3db/m3storage/branches{/branch}","tags_url":"https://api.github.com/repos/m3db/m3storage/tags","blobs_url":"https://api.github.com/repos/m3db/m3storage/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/m3db/m3storage/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/m3db/m3storage/git/refs{/sha}","trees_url":"https://api.github.com/repos/m3db/m3storage/git/trees{/sha}","statuses_url":"https://api.github.com/repos/m3db/m3storage/statuses/{sha}","languages_url":"https://api.github.com/repos/m3db/m3storage/languages","stargazers_url":"https://api.github.com/repos/m3db/m3storage/stargazers","contributors_url":"https://api.github.com/repos/m3db/m3storage/contributors","subscribers_url":"https://api.github.com/repos/m3db/m3storage/subscribers","subscription_url":"https://api.github.com/repos/m3db/m3storage/subscription","commits_url":"https://api.github.com/repos/m3db/m3storage/commits{/sha}","git_commits_url":"https://api.github.com/repos/m3db/m3storage/git/commits{/sha}","comments_url":"https://api.github.com/repos/m3db/m3storage/comments{/number}","issue_comment_url":"https://api.github.com/repos/m3db/m3storage/issues/comments{/number}","contents_url":"https://api.github.com/repos/m3db/m3storage/contents/{+path}","compare_url":"https://api.github.com/repos/m3db/m3storage/compare/{base}...{head}","merges_url":"https://api.github.com/repos/m3db/m3storage/merges","archive_url":"https://api.github.com/repos/m3db/m3storage/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/m3db/m3storage/downloads","issues_url":"https://api.github.com/repos/m3db/m3storage/issues{/number}","pulls_url":"https://api.github.com/repos/m3db/m3storage/pulls{/number}","milestones_url":"https://api.github.com/repos/m3db/m3storage/milestones{/number}","notifications_url":"https://api.github.com/repos/m3db/m3storage/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/m3db/m3storage/labels{/name}","releases_url":"https://api.github.com/repos/m3db/m3storage/releases{/id}","deployments_url":"https://api.github.com/repos/m3db/m3storage/deployments","created_at":"2016-07-27T14:22:03Z","updated_at":"2016-07-27T15:30:36Z","pushed_at":"2016-08-06T16:29:35Z","git_url":"git://github.com/m3db/m3storage.git","ssh_url":"git@github.com:m3db/m3storage.git","clone_url":"https://github.com/m3db/m3storage.git","svn_url":"https://github.com/m3db/m3storage","homepage":null,"size":60,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"m3db:master","ref":"master","sha":"e7175e1d72ef37fac71350828d402c277f48ad7f","user":{"login":"m3db","id":19937171,"avatar_url":"https://avatars.githubusercontent.com/u/19937171?v=3","gravatar_id":"","url":"https://api.github.com/users/m3db","html_url":"https://github.com/m3db","followers_url":"https://api.github.com/users/m3db/followers","following_url":"https://api.github.com/users/m3db/following{/other_user}","gists_url":"https://api.github.com/users/m3db/gists{/gist_id}","starred_url":"https://api.github.com/users/m3db/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/m3db/subscriptions","organizations_url":"https://api.github.com/users/m3db/orgs","repos_url":"https://api.github.com/users/m3db/repos","events_url":"https://api.github.com/users/m3db/events{/privacy}","received_events_url":"https://api.github.com/users/m3db/received_events","type":"Organization","site_admin":false},"repo":{"id":64314848,"name":"m3storage","full_name":"m3db/m3storage","owner":{"login":"m3db","id":19937171,"avatar_url":"https://avatars.githubusercontent.com/u/19937171?v=3","gravatar_id":"","url":"https://api.github.com/users/m3db","html_url":"https://github.com/m3db","followers_url":"https://api.github.com/users/m3db/followers","following_url":"https://api.github.com/users/m3db/following{/other_user}","gists_url":"https://api.github.com/users/m3db/gists{/gist_id}","starred_url":"https://api.github.com/users/m3db/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/m3db/subscriptions","organizations_url":"https://api.github.com/users/m3db/orgs","repos_url":"https://api.github.com/users/m3db/repos","events_url":"https://api.github.com/users/m3db/events{/privacy}","received_events_url":"https://api.github.com/users/m3db/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/m3db/m3storage","description":"Tiered storage manager","fork":false,"url":"https://api.github.com/repos/m3db/m3storage","forks_url":"https://api.github.com/repos/m3db/m3storage/forks","keys_url":"https://api.github.com/repos/m3db/m3storage/keys{/key_id}","collaborators_url":"https://api.github.com/repos/m3db/m3storage/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/m3db/m3storage/teams","hooks_url":"https://api.github.com/repos/m3db/m3storage/hooks","issue_events_url":"https://api.github.com/repos/m3db/m3storage/issues/events{/number}","events_url":"https://api.github.com/repos/m3db/m3storage/events","assignees_url":"https://api.github.com/repos/m3db/m3storage/assignees{/user}","branches_url":"https://api.github.com/repos/m3db/m3storage/branches{/branch}","tags_url":"https://api.github.com/repos/m3db/m3storage/tags","blobs_url":"https://api.github.com/repos/m3db/m3storage/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/m3db/m3storage/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/m3db/m3storage/git/refs{/sha}","trees_url":"https://api.github.com/repos/m3db/m3storage/git/trees{/sha}","statuses_url":"https://api.github.com/repos/m3db/m3storage/statuses/{sha}","languages_url":"https://api.github.com/repos/m3db/m3storage/languages","stargazers_url":"https://api.github.com/repos/m3db/m3storage/stargazers","contributors_url":"https://api.github.com/repos/m3db/m3storage/contributors","subscribers_url":"https://api.github.com/repos/m3db/m3storage/subscribers","subscription_url":"https://api.github.com/repos/m3db/m3storage/subscription","commits_url":"https://api.github.com/repos/m3db/m3storage/commits{/sha}","git_commits_url":"https://api.github.com/repos/m3db/m3storage/git/commits{/sha}","comments_url":"https://api.github.com/repos/m3db/m3storage/comments{/number}","issue_comment_url":"https://api.github.com/repos/m3db/m3storage/issues/comments{/number}","contents_url":"https://api.github.com/repos/m3db/m3storage/contents/{+path}","compare_url":"https://api.github.com/repos/m3db/m3storage/compare/{base}...{head}","merges_url":"https://api.github.com/repos/m3db/m3storage/merges","archive_url":"https://api.github.com/repos/m3db/m3storage/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/m3db/m3storage/downloads","issues_url":"https://api.github.com/repos/m3db/m3storage/issues{/number}","pulls_url":"https://api.github.com/repos/m3db/m3storage/pulls{/number}","milestones_url":"https://api.github.com/repos/m3db/m3storage/milestones{/number}","notifications_url":"https://api.github.com/repos/m3db/m3storage/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/m3db/m3storage/labels{/name}","releases_url":"https://api.github.com/repos/m3db/m3storage/releases{/id}","deployments_url":"https://api.github.com/repos/m3db/m3storage/deployments","created_at":"2016-07-27T14:22:03Z","updated_at":"2016-07-27T15:30:36Z","pushed_at":"2016-08-06T16:29:35Z","git_url":"git://github.com/m3db/m3storage.git","ssh_url":"git@github.com:m3db/m3storage.git","clone_url":"https://github.com/m3db/m3storage.git","svn_url":"https://github.com/m3db/m3storage","homepage":null,"size":60,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/m3db/m3storage/pulls/2"},"html":{"href":"https://github.com/m3db/m3storage/pull/2"},"issue":{"href":"https://api.github.com/repos/m3db/m3storage/issues/2"},"comments":{"href":"https://api.github.com/repos/m3db/m3storage/issues/2/comments"},"review_comments":{"href":"https://api.github.com/repos/m3db/m3storage/pulls/2/comments"},"review_comment":{"href":"https://api.github.com/repos/m3db/m3storage/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/m3db/m3storage/pulls/2/commits"},"statuses":{"href":"https://api.github.com/repos/m3db/m3storage/statuses/9cb14785a8b6bd01e9b11d3b8a9437818ddd6a07"}}}}
{"actor":{"display_login":"mmihic"}}