aboutsummaryrefslogtreecommitdiffstats
path: root/main/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'main/src/main/java')
-rw-r--r--main/src/main/java/org/onap/policy/pdpx/main/XacmlState.java3
-rw-r--r--main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpAafFilter.java38
-rw-r--r--main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpStatisticsManager.java3
-rw-r--r--main/src/main/java/org/onap/policy/pdpx/main/startstop/XacmlPdpActivator.java5
4 files changed, 5 insertions, 44 deletions
diff --git a/main/src/main/java/org/onap/policy/pdpx/main/XacmlState.java b/main/src/main/java/org/onap/policy/pdpx/main/XacmlState.java
index d67a1fad..6728f6e8 100644
--- a/main/src/main/java/org/onap/policy/pdpx/main/XacmlState.java
+++ b/main/src/main/java/org/onap/policy/pdpx/main/XacmlState.java
@@ -93,8 +93,7 @@ public class XacmlState {
status.setHealthy(XacmlPdpActivator.getCurrent().isAlive() ? PdpHealthStatus.HEALTHY
: PdpHealthStatus.NOT_HEALTHY);
- PdpStatus heartbeat = new PdpStatus(status);
- return heartbeat;
+ return new PdpStatus(status);
}
/**
diff --git a/main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpAafFilter.java b/main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpAafFilter.java
deleted file mode 100644
index 5a4c3bc6..00000000
--- a/main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpAafFilter.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- * SPDX-License-Identifier: Apache-2.0
- * ============LICENSE_END=========================================================
- */
-
-package org.onap.policy.pdpx.main.rest;
-
-import org.onap.policy.common.endpoints.http.server.aaf.AafGranularAuthFilter;
-
-/**
- * Class to manage aaf filters for Xacml PDP component.
- *
- */
-public class XacmlPdpAafFilter extends AafGranularAuthFilter {
-
- public static final String AAF_NODETYPE = "policy-pdpx";
- public static final String AAF_ROOT_PERMISSION = DEFAULT_NAMESPACE + "." + AAF_NODETYPE;
-
- @Override
- public String getPermissionTypeRoot() {
- return AAF_ROOT_PERMISSION;
- }
-} \ No newline at end of file
diff --git a/main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpStatisticsManager.java b/main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpStatisticsManager.java
index 253a0095..ab0ebd6c 100644
--- a/main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpStatisticsManager.java
+++ b/main/src/main/java/org/onap/policy/pdpx/main/rest/XacmlPdpStatisticsManager.java
@@ -1,6 +1,7 @@
/*-
* ============LICENSE_START=======================================================
* Copyright (C) 2019, 2021-2022 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2023 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -70,7 +71,7 @@ public class XacmlPdpStatisticsManager {
private long undeployFailureCount;
private long indeterminantDecisionsCount;
private long notApplicableDecisionsCount;
- private Map<String, Map<String, Integer>> applicationMetrics = new HashMap<>();
+ private final Map<String, Map<String, Integer>> applicationMetrics = new HashMap<>();
/**
* Used to update our Map of ApplicationNames to statistics.
diff --git a/main/src/main/java/org/onap/policy/pdpx/main/startstop/XacmlPdpActivator.java b/main/src/main/java/org/onap/policy/pdpx/main/startstop/XacmlPdpActivator.java
index 531374d0..d421ba75 100644
--- a/main/src/main/java/org/onap/policy/pdpx/main/startstop/XacmlPdpActivator.java
+++ b/main/src/main/java/org/onap/policy/pdpx/main/startstop/XacmlPdpActivator.java
@@ -1,6 +1,7 @@
/*-
* ============LICENSE_START=======================================================
* Copyright (C) 2019, 2021 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2023 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -42,7 +43,6 @@ import org.onap.policy.pdpx.main.comm.XacmlPdpHearbeatPublisher;
import org.onap.policy.pdpx.main.comm.listeners.XacmlPdpStateChangeListener;
import org.onap.policy.pdpx.main.comm.listeners.XacmlPdpUpdateListener;
import org.onap.policy.pdpx.main.parameters.XacmlPdpParameterGroup;
-import org.onap.policy.pdpx.main.rest.XacmlPdpAafFilter;
import org.onap.policy.pdpx.main.rest.XacmlPdpApplicationManager;
import org.onap.policy.pdpx.main.rest.XacmlPdpRestController;
import org.onap.policy.pdpx.main.rest.XacmlPdpServiceFilter;
@@ -132,8 +132,7 @@ public class XacmlPdpActivator extends ServiceManagerContainer {
XacmlPdpServiceFilter.disableApi();
restServer = new XacmlPdpRestServer(xacmlPdpParameterGroup.getRestServerParameters(),
- List.of(XacmlPdpServiceFilter.class, XacmlPdpAafFilter.class),
- List.of(XacmlPdpRestController.class));
+ List.of(XacmlPdpServiceFilter.class), List.of(XacmlPdpRestController.class));
} catch (RuntimeException | HttpClientConfigException | BidirectionalTopicClientException e) {
throw new PolicyXacmlPdpRuntimeException(e.getMessage(), e);