summaryrefslogtreecommitdiffstats
path: root/feature-healthcheck/src/main/java
diff options
context:
space:
mode:
authorJorge Hernandez <jorge.hernandez-herrero@att.com>2018-10-26 09:27:05 -0500
committerJorge Hernandez <jorge.hernandez-herrero@att.com>2018-10-26 09:46:46 -0500
commit7f983422c4970efdf778b99318e346e5de0cd60f (patch)
tree0d47d1f4f9eb769999c0911467b7d7ca7989ed94 /feature-healthcheck/src/main/java
parent5bf8486284313c32de3dc8c05233eeb621c845ab (diff)
Enable Authorization AAF Filter programmatically3.0.0-ONAP
The intent is to reduce configuration options and automatically set up the authorization filter (that will complement the authentication filter that the policy-endpoints common framework automatically provides). Previously to enable the AAF authorization filter, it will need the configuration had to kept track of AAF flag, and the "filterClasses" property configuration, make a bit more difficult to keep them sync, and easily turn on/off AAF. Change-Id: I3d59de6fa83986c5dcb6b3d38077278b8e75689a Issue-ID: POLICY-1216 Signed-off-by: Jorge Hernandez <jorge.hernandez-herrero@att.com>
Diffstat (limited to 'feature-healthcheck/src/main/java')
-rw-r--r--feature-healthcheck/src/main/java/org/onap/policy/drools/healthcheck/HealthCheck.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/feature-healthcheck/src/main/java/org/onap/policy/drools/healthcheck/HealthCheck.java b/feature-healthcheck/src/main/java/org/onap/policy/drools/healthcheck/HealthCheck.java
index 36444f8e..6b5dcfb8 100644
--- a/feature-healthcheck/src/main/java/org/onap/policy/drools/healthcheck/HealthCheck.java
+++ b/feature-healthcheck/src/main/java/org/onap/policy/drools/healthcheck/HealthCheck.java
@@ -256,6 +256,9 @@ class HealthCheckMonitor implements HealthCheck {
this.clients = getClientFactory().build(healthCheckProperties);
for (HttpServletServer server : servers) {
+ if (server.isAaf()) {
+ server.addFilterClass(null, AafHealthCheckFilter.class.getCanonicalName());
+ }
startServer(server);
}
} catch (Exception e) {