diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 0792bdc47cf..ce3774675a5 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -26,7 +26,7 @@ on: - development - master - staging - - lineageondemand + - test-at jobs: build: diff --git a/auth-agents-common/src/main/java/org/apache/atlas/policytransformer/CachePolicyTransformerImpl.java b/auth-agents-common/src/main/java/org/apache/atlas/policytransformer/CachePolicyTransformerImpl.java index 52a046f7b24..e7022110a4b 100644 --- a/auth-agents-common/src/main/java/org/apache/atlas/policytransformer/CachePolicyTransformerImpl.java +++ b/auth-agents-common/src/main/java/org/apache/atlas/policytransformer/CachePolicyTransformerImpl.java @@ -170,27 +170,27 @@ public ServicePolicies getPolicies(String serviceName, String pluginId, Long las } } - //Process abac based policies - String abacServiceName = (String) service.getAttribute(ATTR_SERVICE_ABAC_SERVICE); - if (StringUtils.isNotEmpty(abacServiceName)) { - AtlasEntityHeader abacService = getServiceEntity(abacServiceName); - - if (abacService != null) { - allPolicies.addAll(getServicePolicies(abacService)); - - ServicePolicies.AbacPolicies abacPolicies = new ServicePolicies.AbacPolicies(); - - abacPolicies.setServiceName(abacServiceName); - abacPolicies.setPolicyUpdateTime(new Date()); - abacPolicies.setServiceId(abacService.getGuid()); - abacPolicies.setPolicyVersion(-1L); - - String abacServiceDefName = String.format(RESOURCE_SERVICE_DEF_PATTERN, abacService.getAttribute(NAME)); - abacPolicies.setServiceDef(getResourceAsObject(abacServiceDefName, RangerServiceDef.class)); - - servicePolicies.setAbacPolicies(abacPolicies); - } - } +// //Process abac based policies +// String abacServiceName = (String) service.getAttribute(ATTR_SERVICE_ABAC_SERVICE); +// if (StringUtils.isNotEmpty(abacServiceName)) { +// AtlasEntityHeader abacService = getServiceEntity(abacServiceName); +// +// if (abacService != null) { +// allPolicies.addAll(getServicePolicies(abacService)); +// +// ServicePolicies.AbacPolicies abacPolicies = new ServicePolicies.AbacPolicies(); +// +// abacPolicies.setServiceName(abacServiceName); +// abacPolicies.setPolicyUpdateTime(new Date()); +// abacPolicies.setServiceId(abacService.getGuid()); +// abacPolicies.setPolicyVersion(-1L); +// +// String abacServiceDefName = String.format(RESOURCE_SERVICE_DEF_PATTERN, abacService.getAttribute(NAME)); +// abacPolicies.setServiceDef(getResourceAsObject(abacServiceDefName, RangerServiceDef.class)); +// +// servicePolicies.setAbacPolicies(abacPolicies); +// } +// } AtlasPerfMetrics.MetricRecorder recorderFilterPolicies = RequestContext.get().startMetricRecord("filterPolicies"); //filter out policies based on serviceName @@ -202,7 +202,7 @@ public ServicePolicies getPolicies(String serviceName, String pluginId, Long las try { policiesA = allPolicies.stream().filter(x -> serviceName.equals(x.getService())).collect(Collectors.toList()); policiesB = allPolicies.stream().filter(x -> tagServiceName.equals(x.getService())).collect(Collectors.toList()); - policiesC = allPolicies.stream().filter(x -> abacServiceName.equals(x.getService())).collect(Collectors.toList()); +// policiesC = allPolicies.stream().filter(x -> abacServiceName.equals(x.getService())).collect(Collectors.toList()); } catch (NullPointerException exception) {}