This is an automated email from the ASF dual-hosted git repository.
madhan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ranger.git
The following commit(s) were added to refs/heads/master by this push:
new db665595f RANGER-4451: when the last service is removed from zone, the
zone should not be deleted
db665595f is described below
commit db665595f90949b79ed92e6d2a68e7e443e8958b
Author: Dineshkumar Yadav <[email protected]>
AuthorDate: Fri Oct 6 17:57:25 2023 +0530
RANGER-4451: when the last service is removed from zone, the zone should
not be deleted
Signed-off-by: Madhan Neethiraj <[email protected]>
---
.../src/main/java/org/apache/ranger/biz/ServiceDBStore.java | 5 -----
1 file changed, 5 deletions(-)
diff --git
a/security-admin/src/main/java/org/apache/ranger/biz/ServiceDBStore.java
b/security-admin/src/main/java/org/apache/ranger/biz/ServiceDBStore.java
index cfb7a6f23..cd92d92b4 100644
--- a/security-admin/src/main/java/org/apache/ranger/biz/ServiceDBStore.java
+++ b/security-admin/src/main/java/org/apache/ranger/biz/ServiceDBStore.java
@@ -6081,8 +6081,6 @@ public class ServiceDBStore extends AbstractServiceStore {
/**
* Removes given service from security zones.
- * And if given service is the only service
- * associated with security zone, remove zone.
* @param service
* @throws Exception
*/
@@ -6099,9 +6097,6 @@ public class ServiceDBStore extends AbstractServiceStore {
securityZone.setServices(zoneServices);
securityZoneStore.updateSecurityZoneById(securityZone);
- if (zoneServices.isEmpty()) {
-
securityZoneStore.deleteSecurityZoneByName(zoneName);
- }
}
}
}