[ 
https://issues.apache.org/jira/browse/TAJO-1670?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14632979#comment-14632979
 ] 

ASF GitHub Bot commented on TAJO-1670:
--------------------------------------

Github user hyunsik commented on the pull request:

    https://github.com/apache/tajo/pull/621#issuecomment-122719079
  
    Thank you for your comments.
    
    Duplicate and ambiguous are clearly distinguished. Duplicate error will 
occur in only add or creation command. For example, ALTER ADD, CREATE TABLE, 
CREATE DATABASE will incur duplicate name. Ambiguous occurs in getter method 
like ```SELECT FROM...``` and getFunction(). So, there are only three cases 
(table, column, and function) for ambiguous errors. Especially, JDBC 
specification distinguish both kinds of errors. So, we need them all too.
    
    All methods in ExceptionUtil seems to be used. CatalogExceptionUtil 
includes four unused methods.
    I'll remove them.
    
    Currently, Tajo is assumed to have only one default database through 
planning. So, we should prohibit the removal of ``DEFAULT`` database. To handle 
them, in the current implementation, I regard default database and information 
schema database as read-only things. So, the attempt to remove ``DEFAULT`` or 
``INFORMATION_SCHEMA`` cause ```INSUFFICIENT_PRIVILEGE```. In addition, It can 
be easily matched with JDBC errors. Otherwise, we make our own SQLState code.


> Refactor client errors and exceptions
> -------------------------------------
>
>                 Key: TAJO-1670
>                 URL: https://issues.apache.org/jira/browse/TAJO-1670
>             Project: Tajo
>          Issue Type: Sub-task
>          Components: Java Client, TajoMaster, Worker
>            Reporter: Hyunsik Choi
>            Assignee: Hyunsik Choi
>             Fix For: 0.11.0
>
>
> The main objective is to refactor the error and exception system in client 
> side and its connected parts like TajoMaster.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to