spolavarpau1 commented on code in PR #516:
URL: https://github.com/apache/ranger/pull/516#discussion_r4126289359
##########
ugsync/src/main/java/org/apache/ranger/unixusersync/process/PolicyMgrUserGroupBuilder.java:
##########
@@ -294,6 +294,13 @@ public void addOrUpdateUsersGroups(Map<String, Map<String,
String>> sourceGroups
if (!isStartupFlag && computeDeletes) {
LOG.info("Computing deleted users/groups");
+ userCache.clear();
Review Comment:
Clearing cache and rebuilding the cache from Ranger Admin is a considerable
performance overhead.
##########
ugsync/src/main/java/org/apache/ranger/unixusersync/process/PolicyMgrUserGroupBuilder.java:
##########
@@ -747,16 +752,6 @@ private void computeGroupDelta(Map<String, Map<String,
String>> sourceGroups) {
noOfModifiedGroups++;
groupNameMap.put(groupDN, groupName);
} else {
- if (MapUtils.isNotEmpty(curGroupAttrs) &&
!StringUtils.equalsIgnoreCase(groupDN, curGroupDN)) { // skip update
Review Comment:
This will introduce regressions and change in behavior for existing
customers when they upgrade. Instead, please take a look at the below PR where
a new flag is introduced for updating DN of the user/group
https://github.com/apache/ranger/pull/1162
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]