{"action":"created","comment":{"url":"https://api.github.com/repos/pingcap/tidb/pulls/comments/231848975","pull_request_review_id":172906643,"id":231848975,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMTg0ODk3NQ==","diff_hunk":"@@ -0,0 +1,147 @@\n+# Proposal: Table Partition\n+\n+- Author(s):     [tiancaiamao](https://github.com/tiancaiamao)\n+- Last updated:  2018-10-19\n+- Discussion at: https://github.com/pingcap/tidb/issues/7907\n+\n+## Abstract\n+\n+This proposal proposes to support the table partition feature.\n+\n+## Background\n+\n+MySQL has the [table partition](https://dev.mysql.com/doc/refman/8.0/en/partitioning.html) feature. If this feature is supported in TiDB, many issues could be addressed. For example, drop ranged partitions could be used to remove old data; partition by hash could address the hot data issue thus improve the write performance; query on partitioned table could be faster than on manual sharding tables because of the partition pruning.\n+\n+## Proposal\n+\n+Implement the table partition feature step by step. Partition by range first, then partition by hash.\n+\n+For current implementation in this proposal, subpartition is not considered. Reorganize partition involving data movement remains unsupported.\n+\n+## Rationale\n+\n+The new table partition feature should be problem-solving oriented, and it may not cover all MySQL counterpart at first.\n+\n+The syntax should be always MySQL compatible, as TiDB's promise from the beginning.\n+\n+For those partitioned tables which contain unimplemented features, TiDB parses the SQL but ignores its partition attributes, regards the table as a normal one.","path":"docs/design/2018-10-19-table-partition.md","position":27,"original_position":27,"commit_id":"581919c3c5d82d6b26619a1a6c9179c97863c636","original_commit_id":"581919c3c5d82d6b26619a1a6c9179c97863c636","user":{"login":"CaitinChen","id":34535727,"node_id":"MDQ6VXNlcjM0NTM1NzI3","avatar_url":"https://avatars2.githubusercontent.com/u/34535727?v=4","gravatar_id":"","url":"https://api.github.com/users/CaitinChen","html_url":"https://github.com/CaitinChen","followers_url":"https://api.github.com/users/CaitinChen/followers","following_url":"https://api.github.com/users/CaitinChen/following{/other_user}","gists_url":"https://api.github.com/users/CaitinChen/gists{/gist_id}","starred_url":"https://api.github.com/users/CaitinChen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CaitinChen/subscriptions","organizations_url":"https://api.github.com/users/CaitinChen/orgs","repos_url":"https://api.github.com/users/CaitinChen/repos","events_url":"https://api.github.com/users/CaitinChen/events{/privacy}","received_events_url":"https://api.github.com/users/CaitinChen/received_events","type":"User","site_admin":false},"body":"```suggestion\r\nFor those partitioned tables which contain unimplemented features, TiDB parses the SQL statements but ignores its partition attributes, and regards the table as a normal one.\r\n```","created_at":"2018-11-08T11:13:29Z","updated_at":"2018-11-08T11:32:12Z","html_url":"https://github.com/pingcap/tidb/pull/7969#discussion_r231848975","pull_request_url":"https://api.github.com/repos/pingcap/tidb/pulls/7969","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/pingcap/tidb/pulls/comments/231848975"},"html":{"href":"https://github.com/pingcap/tidb/pull/7969#discussion_r231848975"},"pull_request":{"href":"https://api.github.com/repos/pingcap/tidb/pulls/7969"}}},"pull_request":{"url":"https://api.github.com/repos/pingcap/tidb/pulls/7969","id":224360435,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI0MzYwNDM1","html_url":"https://github.com/pingcap/tidb/pull/7969","diff_url":"https://github.com/pingcap/tidb/pull/7969.diff","patch_url":"https://github.com/pingcap/tidb/pull/7969.patch","issue_url":"https://api.github.com/repos/pingcap/tidb/issues/7969","number":7969,"state":"open","locked":false,"title":"docs/design: add the table partition proposal","user":{"login":"tiancaiamao","id":1420062,"node_id":"MDQ6VXNlcjE0MjAwNjI=","avatar_url":"https://avatars2.githubusercontent.com/u/1420062?v=4","gravatar_id":"","url":"https://api.github.com/users/tiancaiamao","html_url":"https://github.com/tiancaiamao","followers_url":"https://api.github.com/users/tiancaiamao/followers","following_url":"https://api.github.com/users/tiancaiamao/following{/other_user}","gists_url":"https://api.github.com/users/tiancaiamao/gists{/gist_id}","starred_url":"https://api.github.com/users/tiancaiamao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tiancaiamao/subscriptions","organizations_url":"https://api.github.com/users/tiancaiamao/orgs","repos_url":"https://api.github.com/users/tiancaiamao/repos","events_url":"https://api.github.com/users/tiancaiamao/events{/privacy}","received_events_url":"https://api.github.com/users/tiancaiamao/received_events","type":"User","site_admin":false},"body":"\r\n\r\n### What problem does this PR solve? <!--add issue link with summary if exists-->\r\n\r\nAdd a table partition design proposal document  https://github.com/pingcap/tidb/issues/7907\r\n\r\n@CaitinChen @shenli \r\n\r\n","created_at":"2018-10-19T17:38:40Z","updated_at":"2018-11-08T11:32:11Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d0d0b861b7544f7a847282cad7e353146c53db31","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":660746213,"node_id":"MDU6TGFiZWw2NjA3NDYyMTM=","url":"https://api.github.com/repos/pingcap/tidb/labels/component/docs","name":"component/docs","color":"e99695","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/pingcap/tidb/pulls/7969/commits","review_comments_url":"https://api.github.com/repos/pingcap/tidb/pulls/7969/comments","review_comment_url":"https://api.github.com/repos/pingcap/tidb/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pingcap/tidb/issues/7969/comments","statuses_url":"https://api.github.com/repos/pingcap/tidb/statuses/581919c3c5d82d6b26619a1a6c9179c97863c636","head":{"label":"tiancaiamao:proposal","ref":"proposal","sha":"581919c3c5d82d6b26619a1a6c9179c97863c636","user":{"login":"tiancaiamao","id":1420062,"node_id":"MDQ6VXNlcjE0MjAwNjI=","avatar_url":"https://avatars2.githubusercontent.com/u/1420062?v=4","gravatar_id":"","url":"https://api.github.com/users/tiancaiamao","html_url":"https://github.com/tiancaiamao","followers_url":"https://api.github.com/users/tiancaiamao/followers","following_url":"https://api.github.com/users/tiancaiamao/following{/other_user}","gists_url":"https://api.github.com/users/tiancaiamao/gists{/gist_id}","starred_url":"https://api.github.com/users/tiancaiamao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tiancaiamao/subscriptions","organizations_url":"https://api.github.com/users/tiancaiamao/orgs","repos_url":"https://api.github.com/users/tiancaiamao/repos","events_url":"https://api.github.com/users/tiancaiamao/events{/privacy}","received_events_url":"https://api.github.com/users/tiancaiamao/received_events","type":"User","site_admin":false},"repo":{"id":63065396,"node_id":"MDEwOlJlcG9zaXRvcnk2MzA2NTM5Ng==","name":"tidb","full_name":"tiancaiamao/tidb","private":false,"owner":{"login":"tiancaiamao","id":1420062,"node_id":"MDQ6VXNlcjE0MjAwNjI=","avatar_url":"https://avatars2.githubusercontent.com/u/1420062?v=4","gravatar_id":"","url":"https://api.github.com/users/tiancaiamao","html_url":"https://github.com/tiancaiamao","followers_url":"https://api.github.com/users/tiancaiamao/followers","following_url":"https://api.github.com/users/tiancaiamao/following{/other_user}","gists_url":"https://api.github.com/users/tiancaiamao/gists{/gist_id}","starred_url":"https://api.github.com/users/tiancaiamao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tiancaiamao/subscriptions","organizations_url":"https://api.github.com/users/tiancaiamao/orgs","repos_url":"https://api.github.com/users/tiancaiamao/repos","events_url":"https://api.github.com/users/tiancaiamao/events{/privacy}","received_events_url":"https://api.github.com/users/tiancaiamao/received_events","type":"User","site_admin":false},"html_url":"https://github.com/tiancaiamao/tidb","description":"TiDB is a distributed NewSQL database compatible with MySQL protocol ","fork":true,"url":"https://api.github.com/repos/tiancaiamao/tidb","forks_url":"https://api.github.com/repos/tiancaiamao/tidb/forks","keys_url":"https://api.github.com/repos/tiancaiamao/tidb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tiancaiamao/tidb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tiancaiamao/tidb/teams","hooks_url":"https://api.github.com/repos/tiancaiamao/tidb/hooks","issue_events_url":"https://api.github.com/repos/tiancaiamao/tidb/issues/events{/number}","events_url":"https://api.github.com/repos/tiancaiamao/tidb/events","assignees_url":"https://api.github.com/repos/tiancaiamao/tidb/assignees{/user}","branches_url":"https://api.github.com/repos/tiancaiamao/tidb/branches{/branch}","tags_url":"https://api.github.com/repos/tiancaiamao/tidb/tags","blobs_url":"https://api.github.com/repos/tiancaiamao/tidb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tiancaiamao/tidb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tiancaiamao/tidb/git/refs{/sha}","trees_url":"https://api.github.com/repos/tiancaiamao/tidb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tiancaiamao/tidb/statuses/{sha}","languages_url":"https://api.github.com/repos/tiancaiamao/tidb/languages","stargazers_url":"https://api.github.com/repos/tiancaiamao/tidb/stargazers","contributors_url":"https://api.github.com/repos/tiancaiamao/tidb/contributors","subscribers_url":"https://api.github.com/repos/tiancaiamao/tidb/subscribers","subscription_url":"https://api.github.com/repos/tiancaiamao/tidb/subscription","commits_url":"https://api.github.com/repos/tiancaiamao/tidb/commits{/sha}","git_commits_url":"https://api.github.com/repos/tiancaiamao/tidb/git/commits{/sha}","comments_url":"https://api.github.com/repos/tiancaiamao/tidb/comments{/number}","issue_comment_url":"https://api.github.com/repos/tiancaiamao/tidb/issues/comments{/number}","contents_url":"https://api.github.com/repos/tiancaiamao/tidb/contents/{+path}","compare_url":"https://api.github.com/repos/tiancaiamao/tidb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tiancaiamao/tidb/merges","archive_url":"https://api.github.com/repos/tiancaiamao/tidb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tiancaiamao/tidb/downloads","issues_url":"https://api.github.com/repos/tiancaiamao/tidb/issues{/number}","pulls_url":"https://api.github.com/repos/tiancaiamao/tidb/pulls{/number}","milestones_url":"https://api.github.com/repos/tiancaiamao/tidb/milestones{/number}","notifications_url":"https://api.github.com/repos/tiancaiamao/tidb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tiancaiamao/tidb/labels{/name}","releases_url":"https://api.github.com/repos/tiancaiamao/tidb/releases{/id}","deployments_url":"https://api.github.com/repos/tiancaiamao/tidb/deployments","created_at":"2016-07-11T12:20:13Z","updated_at":"2018-08-26T07:21:52Z","pushed_at":"2018-11-08T11:04:23Z","git_url":"git://github.com/tiancaiamao/tidb.git","ssh_url":"git@github.com:tiancaiamao/tidb.git","clone_url":"https://github.com/tiancaiamao/tidb.git","svn_url":"https://github.com/tiancaiamao/tidb","homepage":"","size":62537,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"pingcap:master","ref":"master","sha":"25118db843ac31f66a2a910699868585f8d59cb2","user":{"login":"pingcap","id":11855343,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExODU1MzQz","avatar_url":"https://avatars3.githubusercontent.com/u/11855343?v=4","gravatar_id":"","url":"https://api.github.com/users/pingcap","html_url":"https://github.com/pingcap","followers_url":"https://api.github.com/users/pingcap/followers","following_url":"https://api.github.com/users/pingcap/following{/other_user}","gists_url":"https://api.github.com/users/pingcap/gists{/gist_id}","starred_url":"https://api.github.com/users/pingcap/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pingcap/subscriptions","organizations_url":"https://api.github.com/users/pingcap/orgs","repos_url":"https://api.github.com/users/pingcap/repos","events_url":"https://api.github.com/users/pingcap/events{/privacy}","received_events_url":"https://api.github.com/users/pingcap/received_events","type":"Organization","site_admin":false},"repo":{"id":41986369,"node_id":"MDEwOlJlcG9zaXRvcnk0MTk4NjM2OQ==","name":"tidb","full_name":"pingcap/tidb","private":false,"owner":{"login":"pingcap","id":11855343,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExODU1MzQz","avatar_url":"https://avatars3.githubusercontent.com/u/11855343?v=4","gravatar_id":"","url":"https://api.github.com/users/pingcap","html_url":"https://github.com/pingcap","followers_url":"https://api.github.com/users/pingcap/followers","following_url":"https://api.github.com/users/pingcap/following{/other_user}","gists_url":"https://api.github.com/users/pingcap/gists{/gist_id}","starred_url":"https://api.github.com/users/pingcap/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pingcap/subscriptions","organizations_url":"https://api.github.com/users/pingcap/orgs","repos_url":"https://api.github.com/users/pingcap/repos","events_url":"https://api.github.com/users/pingcap/events{/privacy}","received_events_url":"https://api.github.com/users/pingcap/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/pingcap/tidb","description":"TiDB is a distributed HTAP database compatible with the MySQL protocol ","fork":false,"url":"https://api.github.com/repos/pingcap/tidb","forks_url":"https://api.github.com/repos/pingcap/tidb/forks","keys_url":"https://api.github.com/repos/pingcap/tidb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pingcap/tidb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pingcap/tidb/teams","hooks_url":"https://api.github.com/repos/pingcap/tidb/hooks","issue_events_url":"https://api.github.com/repos/pingcap/tidb/issues/events{/number}","events_url":"https://api.github.com/repos/pingcap/tidb/events","assignees_url":"https://api.github.com/repos/pingcap/tidb/assignees{/user}","branches_url":"https://api.github.com/repos/pingcap/tidb/branches{/branch}","tags_url":"https://api.github.com/repos/pingcap/tidb/tags","blobs_url":"https://api.github.com/repos/pingcap/tidb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pingcap/tidb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pingcap/tidb/git/refs{/sha}","trees_url":"https://api.github.com/repos/pingcap/tidb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pingcap/tidb/statuses/{sha}","languages_url":"https://api.github.com/repos/pingcap/tidb/languages","stargazers_url":"https://api.github.com/repos/pingcap/tidb/stargazers","contributors_url":"https://api.github.com/repos/pingcap/tidb/contributors","subscribers_url":"https://api.github.com/repos/pingcap/tidb/subscribers","subscription_url":"https://api.github.com/repos/pingcap/tidb/subscription","commits_url":"https://api.github.com/repos/pingcap/tidb/commits{/sha}","git_commits_url":"https://api.github.com/repos/pingcap/tidb/git/commits{/sha}","comments_url":"https://api.github.com/repos/pingcap/tidb/comments{/number}","issue_comment_url":"https://api.github.com/repos/pingcap/tidb/issues/comments{/number}","contents_url":"https://api.github.com/repos/pingcap/tidb/contents/{+path}","compare_url":"https://api.github.com/repos/pingcap/tidb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pingcap/tidb/merges","archive_url":"https://api.github.com/repos/pingcap/tidb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pingcap/tidb/downloads","issues_url":"https://api.github.com/repos/pingcap/tidb/issues{/number}","pulls_url":"https://api.github.com/repos/pingcap/tidb/pulls{/number}","milestones_url":"https://api.github.com/repos/pingcap/tidb/milestones{/number}","notifications_url":"https://api.github.com/repos/pingcap/tidb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pingcap/tidb/labels{/name}","releases_url":"https://api.github.com/repos/pingcap/tidb/releases{/id}","deployments_url":"https://api.github.com/repos/pingcap/tidb/deployments","created_at":"2015-09-06T04:01:52Z","updated_at":"2018-11-08T10:21:55Z","pushed_at":"2018-11-08T11:26:06Z","git_url":"git://github.com/pingcap/tidb.git","ssh_url":"git@github.com:pingcap/tidb.git","clone_url":"https://github.com/pingcap/tidb.git","svn_url":"https://github.com/pingcap/tidb","homepage":"https://pingcap.com","size":87297,"stargazers_count":15720,"watchers_count":15720,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2223,"mirror_url":null,"archived":false,"open_issues_count":599,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":2223,"open_issues":599,"watchers":15720,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pingcap/tidb/pulls/7969"},"html":{"href":"https://github.com/pingcap/tidb/pull/7969"},"issue":{"href":"https://api.github.com/repos/pingcap/tidb/issues/7969"},"comments":{"href":"https://api.github.com/repos/pingcap/tidb/issues/7969/comments"},"review_comments":{"href":"https://api.github.com/repos/pingcap/tidb/pulls/7969/comments"},"review_comment":{"href":"https://api.github.com/repos/pingcap/tidb/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pingcap/tidb/pulls/7969/commits"},"statuses":{"href":"https://api.github.com/repos/pingcap/tidb/statuses/581919c3c5d82d6b26619a1a6c9179c97863c636"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"CaitinChen"}}