{"action":"created","comment":{"url":"https://api.github.com/repos/apache/tajo/pulls/comments/34954142","id":34954142,"diff_hunk":"@@ -0,0 +1,327 @@\n+/**\n+ * Licensed to the Apache Software Foundation (ASF) under one\n+ * or more contributor license agreements.  See the NOTICE file\n+ * distributed with this work for additional information\n+ * regarding copyright ownership.  The ASF licenses this file\n+ * to you under the Apache License, Version 2.0 (the\n+ * \"License\"); you may not use this file except in compliance\n+ * with the License.  You may obtain a copy of the License at\n+ *\n+ *     http://www.apache.org/licenses/LICENSE-2.0\n+ *\n+ * Unless required by applicable law or agreed to in writing, software\n+ * distributed under the License is distributed on an \"AS IS\" BASIS,\n+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+ * See the License for the specific language governing permissions and\n+ * limitations under the License.\n+ */\n+\n+package tajo.error;\n+option java_package = \"org.apache.tajo.error\";\n+\n+import \"stacktrace.proto\";\n+\n+// Unstable - this is still evolving.\n+\n+enum ResultCode {\n+  // Class\n+  // 00 - Successful Completion\n+  OK                            = 0;\n+\n+  WARNING                       = 100; // Warning\n+\n+  // General Errors\n+  INTERNAL_ERROR                = 201; // Error caused by internal bugs (See also TajoInternalException.java)\n+  NOT_IMPLEMENTED               = 202; // Planned, but not implemented yet.\n+  FEATURE_NOT_SUPPORTED         = 203; // SQLState: 0A000 - Unsupported feature (usually for unreasonable feature)\n+  INVALID_RPC_CALL              = 204; // When invalid RPC call is invoked (e.g., wrong message and absent fields)\n+\n+  // Query Management and Scheduler\n+  NO_SUCH_QUERYID               = 300; // No query id in TajoMaster\n+  NO_DATA                       = 301; // No data due to query fail or error\n+  INCOMPLETE_QUERY              = 302; // It occurs when a client requests something of a completed query.\n+\n+  // Session\n+  INVALID_SESSION               = 401; // Session already was invalid\n+  NO_SUCH_SESSION_VARIABLE      = 402; // Session variable not found\n+  INVALID_SESSION_VARIABLE      = 403; // Session variable is invalid (type mismatch or out of range)\n+\n+  // Data Exception (SQLState Class - 22)\n+  DIVISION_BY_ZERO              = 451; // SQLState: 22012 - Division by zero\n+\n+\n+  // Section: Class 42 - Syntax Error or Access Rule Violation\n+  SYNTAX_ERROR_OR_ACCESS_RULE_VIOLATION = 601; // SQLState: 42000\n+  SYNTAX_ERROR                          = 602; // SQLState: 42601\n+  INSUFFICIENT_PRIVILEGE                = 603; // SQLState: 42501\n+\n+  UNDEFINED_TABLESPACE                  = 500; // ?","path":"tajo-common/src/main/proto/errors.proto","position":58,"original_position":58,"commit_id":"7cd6ff13e514d127266b37002ae32f48a62a6224","original_commit_id":"7cd6ff13e514d127266b37002ae32f48a62a6224","user":{"login":"jihoonson","id":2322288,"avatar_url":"https://avatars.githubusercontent.com/u/2322288?v=3","gravatar_id":"","url":"https://api.github.com/users/jihoonson","html_url":"https://github.com/jihoonson","followers_url":"https://api.github.com/users/jihoonson/followers","following_url":"https://api.github.com/users/jihoonson/following{/other_user}","gists_url":"https://api.github.com/users/jihoonson/gists{/gist_id}","starred_url":"https://api.github.com/users/jihoonson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jihoonson/subscriptions","organizations_url":"https://api.github.com/users/jihoonson/orgs","repos_url":"https://api.github.com/users/jihoonson/repos","events_url":"https://api.github.com/users/jihoonson/events{/privacy}","received_events_url":"https://api.github.com/users/jihoonson/received_events","type":"User","site_admin":false},"body":"For consistency, the error id of this section seems to start from 501.","created_at":"2015-07-19T03:07:52Z","updated_at":"2015-07-19T03:07:52Z","html_url":"https://github.com/apache/tajo/pull/621#discussion_r34954142","pull_request_url":"https://api.github.com/repos/apache/tajo/pulls/621","_links":{"self":{"href":"https://api.github.com/repos/apache/tajo/pulls/comments/34954142"},"html":{"href":"https://github.com/apache/tajo/pull/621#discussion_r34954142"},"pull_request":{"href":"https://api.github.com/repos/apache/tajo/pulls/621"}}},"pull_request":{"url":"https://api.github.com/repos/apache/tajo/pulls/621","id":39074814,"html_url":"https://github.com/apache/tajo/pull/621","diff_url":"https://github.com/apache/tajo/pull/621.diff","patch_url":"https://github.com/apache/tajo/pull/621.patch","issue_url":"https://api.github.com/repos/apache/tajo/issues/621","number":621,"state":"open","locked":false,"title":"TAJO-1670: Refactor client errors and exceptions. ","user":{"login":"hyunsik","id":225941,"avatar_url":"https://avatars.githubusercontent.com/u/225941?v=3","gravatar_id":"","url":"https://api.github.com/users/hyunsik","html_url":"https://github.com/hyunsik","followers_url":"https://api.github.com/users/hyunsik/followers","following_url":"https://api.github.com/users/hyunsik/following{/other_user}","gists_url":"https://api.github.com/users/hyunsik/gists{/gist_id}","starred_url":"https://api.github.com/users/hyunsik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hyunsik/subscriptions","organizations_url":"https://api.github.com/users/hyunsik/orgs","repos_url":"https://api.github.com/users/hyunsik/repos","events_url":"https://api.github.com/users/hyunsik/events{/privacy}","received_events_url":"https://api.github.com/users/hyunsik/received_events","type":"User","site_admin":false},"body":"\n\n<!-- Reviewable:start -->\n[<img src=\"https://reviewable.io/review_button.png\" height=40 alt=\"Review on Reviewable\"/>](https://reviewable.io/reviews/apache/tajo/621)\n<!-- Reviewable:end -->\n","created_at":"2015-07-02T11:56:28Z","updated_at":"2015-07-19T03:07:52Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d47dcafd673659a7ddde078066cdf5810d8ed875","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/apache/tajo/pulls/621/commits","review_comments_url":"https://api.github.com/repos/apache/tajo/pulls/621/comments","review_comment_url":"https://api.github.com/repos/apache/tajo/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apache/tajo/issues/621/comments","statuses_url":"https://api.github.com/repos/apache/tajo/statuses/7cd6ff13e514d127266b37002ae32f48a62a6224","head":{"label":"hyunsik:TAJO-1670","ref":"TAJO-1670","sha":"7cd6ff13e514d127266b37002ae32f48a62a6224","user":{"login":"hyunsik","id":225941,"avatar_url":"https://avatars.githubusercontent.com/u/225941?v=3","gravatar_id":"","url":"https://api.github.com/users/hyunsik","html_url":"https://github.com/hyunsik","followers_url":"https://api.github.com/users/hyunsik/followers","following_url":"https://api.github.com/users/hyunsik/following{/other_user}","gists_url":"https://api.github.com/users/hyunsik/gists{/gist_id}","starred_url":"https://api.github.com/users/hyunsik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hyunsik/subscriptions","organizations_url":"https://api.github.com/users/hyunsik/orgs","repos_url":"https://api.github.com/users/hyunsik/repos","events_url":"https://api.github.com/users/hyunsik/events{/privacy}","received_events_url":"https://api.github.com/users/hyunsik/received_events","type":"User","site_admin":false},"repo":{"id":17972237,"name":"tajo","full_name":"hyunsik/tajo","owner":{"login":"hyunsik","id":225941,"avatar_url":"https://avatars.githubusercontent.com/u/225941?v=3","gravatar_id":"","url":"https://api.github.com/users/hyunsik","html_url":"https://github.com/hyunsik","followers_url":"https://api.github.com/users/hyunsik/followers","following_url":"https://api.github.com/users/hyunsik/following{/other_user}","gists_url":"https://api.github.com/users/hyunsik/gists{/gist_id}","starred_url":"https://api.github.com/users/hyunsik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hyunsik/subscriptions","organizations_url":"https://api.github.com/users/hyunsik/orgs","repos_url":"https://api.github.com/users/hyunsik/repos","events_url":"https://api.github.com/users/hyunsik/events{/privacy}","received_events_url":"https://api.github.com/users/hyunsik/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/hyunsik/tajo","description":"Mirror of Apache Tajo","fork":true,"url":"https://api.github.com/repos/hyunsik/tajo","forks_url":"https://api.github.com/repos/hyunsik/tajo/forks","keys_url":"https://api.github.com/repos/hyunsik/tajo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hyunsik/tajo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hyunsik/tajo/teams","hooks_url":"https://api.github.com/repos/hyunsik/tajo/hooks","issue_events_url":"https://api.github.com/repos/hyunsik/tajo/issues/events{/number}","events_url":"https://api.github.com/repos/hyunsik/tajo/events","assignees_url":"https://api.github.com/repos/hyunsik/tajo/assignees{/user}","branches_url":"https://api.github.com/repos/hyunsik/tajo/branches{/branch}","tags_url":"https://api.github.com/repos/hyunsik/tajo/tags","blobs_url":"https://api.github.com/repos/hyunsik/tajo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hyunsik/tajo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hyunsik/tajo/git/refs{/sha}","trees_url":"https://api.github.com/repos/hyunsik/tajo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hyunsik/tajo/statuses/{sha}","languages_url":"https://api.github.com/repos/hyunsik/tajo/languages","stargazers_url":"https://api.github.com/repos/hyunsik/tajo/stargazers","contributors_url":"https://api.github.com/repos/hyunsik/tajo/contributors","subscribers_url":"https://api.github.com/repos/hyunsik/tajo/subscribers","subscription_url":"https://api.github.com/repos/hyunsik/tajo/subscription","commits_url":"https://api.github.com/repos/hyunsik/tajo/commits{/sha}","git_commits_url":"https://api.github.com/repos/hyunsik/tajo/git/commits{/sha}","comments_url":"https://api.github.com/repos/hyunsik/tajo/comments{/number}","issue_comment_url":"https://api.github.com/repos/hyunsik/tajo/issues/comments{/number}","contents_url":"https://api.github.com/repos/hyunsik/tajo/contents/{+path}","compare_url":"https://api.github.com/repos/hyunsik/tajo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hyunsik/tajo/merges","archive_url":"https://api.github.com/repos/hyunsik/tajo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hyunsik/tajo/downloads","issues_url":"https://api.github.com/repos/hyunsik/tajo/issues{/number}","pulls_url":"https://api.github.com/repos/hyunsik/tajo/pulls{/number}","milestones_url":"https://api.github.com/repos/hyunsik/tajo/milestones{/number}","notifications_url":"https://api.github.com/repos/hyunsik/tajo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hyunsik/tajo/labels{/name}","releases_url":"https://api.github.com/repos/hyunsik/tajo/releases{/id}","created_at":"2014-03-21T07:53:46Z","updated_at":"2015-04-07T06:07:49Z","pushed_at":"2015-07-17T09:49:05Z","git_url":"git://github.com/hyunsik/tajo.git","ssh_url":"git@github.com:hyunsik/tajo.git","clone_url":"https://github.com/hyunsik/tajo.git","svn_url":"https://github.com/hyunsik/tajo","homepage":null,"size":21789,"stargazers_count":1,"watchers_count":1,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"apache:master","ref":"master","sha":"3dba8c7e6bc539b07b136b959aa91dc4402be380","user":{"login":"apache","id":47359,"avatar_url":"https://avatars.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"repo":{"id":17971138,"name":"tajo","full_name":"apache/tajo","owner":{"login":"apache","id":47359,"avatar_url":"https://avatars.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apache/tajo","description":"Mirror of Apache Tajo","fork":false,"url":"https://api.github.com/repos/apache/tajo","forks_url":"https://api.github.com/repos/apache/tajo/forks","keys_url":"https://api.github.com/repos/apache/tajo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apache/tajo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apache/tajo/teams","hooks_url":"https://api.github.com/repos/apache/tajo/hooks","issue_events_url":"https://api.github.com/repos/apache/tajo/issues/events{/number}","events_url":"https://api.github.com/repos/apache/tajo/events","assignees_url":"https://api.github.com/repos/apache/tajo/assignees{/user}","branches_url":"https://api.github.com/repos/apache/tajo/branches{/branch}","tags_url":"https://api.github.com/repos/apache/tajo/tags","blobs_url":"https://api.github.com/repos/apache/tajo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apache/tajo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apache/tajo/git/refs{/sha}","trees_url":"https://api.github.com/repos/apache/tajo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apache/tajo/statuses/{sha}","languages_url":"https://api.github.com/repos/apache/tajo/languages","stargazers_url":"https://api.github.com/repos/apache/tajo/stargazers","contributors_url":"https://api.github.com/repos/apache/tajo/contributors","subscribers_url":"https://api.github.com/repos/apache/tajo/subscribers","subscription_url":"https://api.github.com/repos/apache/tajo/subscription","commits_url":"https://api.github.com/repos/apache/tajo/commits{/sha}","git_commits_url":"https://api.github.com/repos/apache/tajo/git/commits{/sha}","comments_url":"https://api.github.com/repos/apache/tajo/comments{/number}","issue_comment_url":"https://api.github.com/repos/apache/tajo/issues/comments{/number}","contents_url":"https://api.github.com/repos/apache/tajo/contents/{+path}","compare_url":"https://api.github.com/repos/apache/tajo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apache/tajo/merges","archive_url":"https://api.github.com/repos/apache/tajo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apache/tajo/downloads","issues_url":"https://api.github.com/repos/apache/tajo/issues{/number}","pulls_url":"https://api.github.com/repos/apache/tajo/pulls{/number}","milestones_url":"https://api.github.com/repos/apache/tajo/milestones{/number}","notifications_url":"https://api.github.com/repos/apache/tajo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apache/tajo/labels{/name}","releases_url":"https://api.github.com/repos/apache/tajo/releases{/id}","created_at":"2014-03-21T07:00:07Z","updated_at":"2015-06-30T15:19:18Z","pushed_at":"2015-07-19T01:27:16Z","git_url":"git://github.com/apache/tajo.git","ssh_url":"git@github.com:apache/tajo.git","clone_url":"https://github.com/apache/tajo.git","svn_url":"https://github.com/apache/tajo","homepage":null,"size":40936,"stargazers_count":54,"watchers_count":54,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":66,"mirror_url":"git://git.apache.org/tajo.git","open_issues_count":65,"forks":66,"open_issues":65,"watchers":54,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/apache/tajo/pulls/621"},"html":{"href":"https://github.com/apache/tajo/pull/621"},"issue":{"href":"https://api.github.com/repos/apache/tajo/issues/621"},"comments":{"href":"https://api.github.com/repos/apache/tajo/issues/621/comments"},"review_comments":{"href":"https://api.github.com/repos/apache/tajo/pulls/621/comments"},"review_comment":{"href":"https://api.github.com/repos/apache/tajo/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apache/tajo/pulls/621/commits"},"statuses":{"href":"https://api.github.com/repos/apache/tajo/statuses/7cd6ff13e514d127266b37002ae32f48a62a6224"}}}}