Fang-Yu Rao has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/20742 )

Change subject: IMPALA-11501: Add flag to allow catalog-cache operations on 
masked tables
......................................................................


Patch Set 2: Code-Review+1

(2 comments)

Thanks for working on this Quanlong! I only have one additional minor question 
regarding whether we should add getTableIfPresent() to 
CatalogdMetaProvider.java only.

http://gerrit.cloudera.org:8080/#/c/20742/1/fe/src/main/java/org/apache/impala/authorization/BaseAuthorizationChecker.java
File 
fe/src/main/java/org/apache/impala/authorization/BaseAuthorizationChecker.java:

http://gerrit.cloudera.org:8080/#/c/20742/1/fe/src/main/java/org/apache/impala/authorization/BaseAuthorizationChecker.java@222
PS1, Line 222: (request.getPrivilege() != Privilege.REFRESH
             :           || 
!BackendConfig.INSTANCE.allowCatalogCacheOpFromMaskedUsers())
> This is just for my own understanding.
I am trying to answer my questions above.

It looks like db.getTable(authorizableTable.getTableName()) at 
https://gerrit.cloudera.org/c/20742/1/fe/src/main/java/org/apache/impala/authorization/BaseAuthorizationChecker.java#231
 will fully load the table metadata only in the local catalog mode.

Therefore, I think this additional condition is to prevent fully loading the 
table metadata in the local catalog mode.


http://gerrit.cloudera.org:8080/#/c/20742/2/fe/src/main/java/org/apache/impala/catalog/local/MetaProvider.java
File fe/src/main/java/org/apache/impala/catalog/local/MetaProvider.java:

http://gerrit.cloudera.org:8080/#/c/20742/2/fe/src/main/java/org/apache/impala/catalog/local/MetaProvider.java@81
PS2, Line 81:   Pair<Table, TableMetaRef> getTableIfPresent(String dbName, 
String tableName);
Should we add this method to CatalogdMetaProvider.java only? I am asking this 
because I saw at 
https://github.com/apache/impala/blob/master/fe/src/main/java/org/apache/impala/catalog/local/DirectMetaProvider.java#L76-L79
 that DirectMetaProvider.java is a provider that calls out to the source 
systems without caching.



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I45935654cbf05a55d740f1b04781022c271f7678
Gerrit-Change-Number: 20742
Gerrit-PatchSet: 2
Gerrit-Owner: Quanlong Huang <[email protected]>
Gerrit-Reviewer: Csaba Ringhofer <[email protected]>
Gerrit-Reviewer: Fang-Yu Rao <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Quanlong Huang <[email protected]>
Gerrit-Comment-Date: Mon, 11 Dec 2023 05:42:21 +0000
Gerrit-HasComments: Yes

Reply via email to