Dimitris Tsirogiannis has posted comments on this change.

Change subject: IMPALA-3711: Check privileges when necessary
......................................................................


Patch Set 6:

(7 comments)

http://gerrit.cloudera.org:8080/#/c/3371/6/fe/src/main/java/com/cloudera/impala/service/MetadataOp.java
File fe/src/main/java/com/cloudera/impala/service/MetadataOp.java:

PS6, Line 229: catalogName
private member should end with a '_'.


PS6, Line 230: private boolean ignoreAllDbs;
             :     private boolean ignoreAllTables;
             :     private boolean ignoreAllColumns;
             :     private boolean ignoreAllFunctions;
Instead of having the ignore* members, wouldn't be simpler if you had 
has[db|table|column|function]Pattern members instead? These would be false by 
default unless the corresponding set* function is called. i.e. setDbPattern 
wouldn't just set the dbPattern value but also set the hasDbPattern to true.


PS6, Line 246: this.
No need for 'this'. Plz remove.


PS6, Line 316: getDbsMetadataParams
I think we can just name it metadataParams for simplicity


PS6, Line 342: functionName != null
Why don't you just check if fnPatternMatcher is not null and remove L326?


PS6, Line 350: fe.getTableNames(
             :             db.getName(), "*", tablePatternMatcher, user)
I thought the interface would be:
Frontend.getTableNames(String dbName, PatternMatcher matcher, String user) and 
Frontend.getTableNames(String dbName, String pattern, Sring user);
Similarly for the Catalog.getTableNames().


Line 360: 
Also, why can't we check here if we have a non-null columnPatternMatcher and 
avoid block L361-369?


-- 
To view, visit http://gerrit.cloudera.org:8080/3371
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I17d8c5b9fb12483e4b01b819fba48b6849311a14
Gerrit-PatchSet: 6
Gerrit-Project: Impala
Gerrit-Branch: cdh5-trunk
Gerrit-Owner: Huaisi Xu <[email protected]>
Gerrit-Reviewer: Dimitris Tsirogiannis <[email protected]>
Gerrit-Reviewer: Huaisi Xu <[email protected]>
Gerrit-HasComments: Yes

Reply via email to