summaryrefslogtreecommitdiffstats
path: root/openecomp-be/api
diff options
context:
space:
mode:
Diffstat (limited to 'openecomp-be/api')
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/healthcheck-rest/healthcheck-rest-services/src/main/java/org/openecomp/sdcrests/health/rest/services/HealthCheckImpl.java15
1 files changed, 5 insertions, 10 deletions
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/healthcheck-rest/healthcheck-rest-services/src/main/java/org/openecomp/sdcrests/health/rest/services/HealthCheckImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/healthcheck-rest/healthcheck-rest-services/src/main/java/org/openecomp/sdcrests/health/rest/services/HealthCheckImpl.java
index bb2d9ea565..04844b08b2 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/healthcheck-rest/healthcheck-rest-services/src/main/java/org/openecomp/sdcrests/health/rest/services/HealthCheckImpl.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/healthcheck-rest/healthcheck-rest-services/src/main/java/org/openecomp/sdcrests/health/rest/services/HealthCheckImpl.java
@@ -21,7 +21,6 @@
package org.openecomp.sdcrests.health.rest.services;
import org.apache.cxf.jaxrs.impl.ResponseBuilderImpl;
-import org.openecomp.sdc.common.session.SessionContext;
import org.openecomp.sdc.common.session.SessionContextProviderFactory;
import org.openecomp.sdc.health.HealthCheckManager;
import org.openecomp.sdc.health.HealthCheckManagerFactory;
@@ -58,21 +57,17 @@ public class HealthCheckImpl implements org.openecomp.sdcrests.health.rest.Healt
public Response checkHealth() {
HealthCheckResult healthCheckResult = new HealthCheckResult();
- SessionContext context =
- SessionContextProviderFactory.getInstance().createInterface().get();
-
- SessionContextProviderFactory.getInstance().createInterface().create("public",
- context.getTenant());
+ SessionContextProviderFactory.getInstance().createInterface().create("public", "dox");
try {
Collection<HealthInfo> healthInfos = healthCheckManager.checkHealth();
healthCheckResult.setComponentsInfo(healthInfos);
boolean someIsDown = healthInfos.stream()
.anyMatch(healthInfo -> healthInfo.getHealthCheckStatus().equals(HealthCheckStatus.DOWN));
- healthInfos.stream().
- filter(healthInfo -> healthInfo.getHealthCheckComponent()
- .equals(org.openecomp.sdc.health.data.MonitoredModules.BE)).
- findFirst()
+ healthInfos.stream()
+ .filter(healthInfo -> healthInfo.getHealthCheckComponent()
+ .equals(org.openecomp.sdc.health.data.MonitoredModules.BE))
+ .findFirst()
.ifPresent(healthInfo -> healthCheckResult.setSdcVersion(healthInfo.getVersion()));
if (someIsDown) {
Response.ResponseBuilder responseBuilder = new ResponseBuilderImpl();