[
https://issues.apache.org/jira/browse/SENTRY-458?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Dapeng Sun resolved SENTRY-458.
-------------------------------
Resolution: Won't Fix
Won't fix since JDO upgraded.
> Enable optimistic locking for SENTRY high availability
> ------------------------------------------------------
>
> Key: SENTRY-458
> URL: https://issues.apache.org/jira/browse/SENTRY-458
> Project: Sentry
> Issue Type: Sub-task
> Reporter: Dapeng Sun
> Assignee: Dapeng Sun
> Attachments: SENTRY-458.patch
>
>
> JDO has lock mechanism, as HA design doc SENTRY-427 has discuss , we use
> optimistic lock in HA mode, the patch will enable it
> * the code changed in SentryStore and MSentryPrivilege will make sure version
> auto-increment per operation, (Quote the design doc: Privilege and Role is
> M-N relationship, the grant/revoke will do add/remove in Role_Privilege_MAP,
> the version should be added to Role_Privilege_MAP, but currently we use jdo
> auto-generate the Role_Privilege_MAP, so the version could only be added to
> Role.)
> * Add version in package.jdo
> * Add @VisibleForTesting CommitContext alterSentryRoleGrantPrivilege(String
> grantorPrincipal, MSentryRole mRole, TSentryPrivilege privilege) throws
> SentryUserException for test, it will help reproduce makePersistent a lower
> version MSentryRole and get a JDOOptimisticVerificationException
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)