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

Na Li commented on SENTRY-2046:
-------------------------------

We should get full snapshot when sentryStore.isAuthzPathsMappingEmpty() only if 
HDFS is enabled. Otherwise (i.e. HDFS sync is disabled), we will have issue 
stated in SENTRY-1890 "However, when data store is empty, we decide to get full 
snapshot. Therefore, every run, we get full snapshot from HMS. This causes big 
overhead."

The reason is that when HDFS sync is disabled, we don't save full snapshot. and 
 sentryStore.isAuthzPathsMappingEmpty() is always true

> Create a full snapshot if AUTHZ_PATHS_SNAPSHOT_ID is empty, even if HMS and 
> Sentry Notifications are in sync
> ------------------------------------------------------------------------------------------------------------
>
>                 Key: SENTRY-2046
>                 URL: https://issues.apache.org/jira/browse/SENTRY-2046
>             Project: Sentry
>          Issue Type: Bug
>          Components: Sentry
>    Affects Versions: 2.0.0
>            Reporter: Arjun Mishra
>            Assignee: Arjun Mishra
>              Labels: bite-sized, mewbi
>
> AUTHZ_PATHS_SNAPSHOT_ID is only populated when a full HMS snapshot is 
> persisted. If for some reason this does not occur and 
> SENTRY_HMS_NOTIFICATION_ID table gets populated with newer values, a full 
> snapshot will not occur unless until HMS and Sentry are out of sync. This 
> will result in ACL's not being applied unless until HMS and Sentry are out of 
> sync, since we only send NN snapshots if AUTHZ_PATHS_SNAPSHOT_ID has values 
> greater than 0
> We should create a full snapshot if hdfsSync is enabled, and 
> AUTHZ_PATHS_SNAPSHOT_ID is empty



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to