summaryrefslogtreecommitdiffstats
path: root/catalog-fe/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'catalog-fe/src/main/java')
-rw-r--r--catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java20
-rw-r--r--catalog-fe/src/main/java/org/openecomp/sdc/fe/client/BackendClient.java4
-rw-r--r--catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigMgrServlet.java8
-rw-r--r--catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigServlet.java4
-rw-r--r--catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeHealthCheckServlet.java4
-rw-r--r--catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java3
-rw-r--r--catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java2
7 files changed, 31 insertions, 14 deletions
diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java
index e157efcda9..a9f5c1294e 100644
--- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java
+++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java
@@ -1,3 +1,23 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * SDC
+ * ================================================================================
+ * Copyright (C) 2017 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.
+ * ============LICENSE_END=========================================================
+ */
+
package org.openecomp.sdc.fe;
public class Constants {
diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/client/BackendClient.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/client/BackendClient.java
index 93e17144c0..92e497d278 100644
--- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/client/BackendClient.java
+++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/client/BackendClient.java
@@ -151,7 +151,7 @@ public class BackendClient {
}
backendHttpClient.close();
} catch (IOException e) {
- log.error("failed to close httpClient: " + e.getMessage());
+ log.error("failed to close httpClient: {}", e.getMessage());
}
}
@@ -168,7 +168,7 @@ public class BackendClient {
if (headerValue != null) {
httpPost.setHeader(headerName, headerValue);
} else {
- log.error("missing required header " + headerName);
+ log.error("missing required header {}", headerName);
return allHeadersAreSet;
}
}
diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigMgrServlet.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigMgrServlet.java
index 7792225742..356f9261c6 100644
--- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigMgrServlet.java
+++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigMgrServlet.java
@@ -61,9 +61,9 @@ public class ConfigMgrServlet extends BasicServlet {
Configuration configuration = configurationManager.getConfiguration();
if (configuration == null) {
- log.warn("Configuration of type " + Configuration.class + " was not found");
+ log.warn("Configuration of type {} was not found", Configuration.class);
} else {
- log.info("The value returned from getConfig is " + configuration);
+ log.info("The value returned from getConfig is {}", configuration);
result = gson.toJson(configuration);
@@ -72,9 +72,9 @@ public class ConfigMgrServlet extends BasicServlet {
RestConfigurationInfo configuration = configurationManager.getRestClientConfiguration();
if (configuration == null) {
- log.warn("Configuration of type " + RestConfigurationInfo.class + " was not found");
+ log.warn("Configuration of type {} was not found", RestConfigurationInfo.class);
} else {
- log.info("The value returned from getConfig is " + configuration);
+ log.info("The value returned from getConfig is {}", configuration);
result = gson.toJson(configuration);
diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigServlet.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigServlet.java
index 92bb9e8743..b8d623b72e 100644
--- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigServlet.java
+++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/ConfigServlet.java
@@ -64,13 +64,13 @@ public class ConfigServlet extends BasicServlet {
Configuration configuration = configurationSource.getAndWatchConfiguration(Configuration.class, null);
if (configuration == null) {
- log.warn("Configuration of type " + Configuration.class + " was not found");
+ log.warn("Configuration of type {} was not found", Configuration.class);
}
log.debug("{}", configuration);
if (log.isInfoEnabled()) {
log.info("Info level ENABLED...");
}
- log.info("The value returned from getConfig is " + configuration);
+ log.info("The value returned from getConfig is {}", configuration);
result = gson.toJson(configuration);
diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeHealthCheckServlet.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeHealthCheckServlet.java
index da5b321339..1ed6ac5c07 100644
--- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeHealthCheckServlet.java
+++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeHealthCheckServlet.java
@@ -35,10 +35,6 @@ import com.jcabi.aspects.Loggable;
@Loggable(prepend = true, value = Loggable.TRACE, trim = false)
@Path("/healthCheck")
public class FeHealthCheckServlet extends BasicServlet {
-
- // private static Logger log =
- // LoggerFactory.getLogger(FeHealthCheckServlet.class.getName());
-
@GET
public Response getFEandBeHealthCheck(@Context final HttpServletRequest request) {
ServletContext context = request.getSession().getServletContext();
diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java
index 1cd28deb7a..11d4abf4af 100644
--- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java
+++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java
@@ -85,7 +85,7 @@ public class FeProxyServlet extends SSLProxyServlet {
String serviceInstanceID = httpRequest.getHeader(Constants.X_ECOMP_SERVICE_ID_HEADER);
if (uuid != null && uuid.length() > 0) {
- // User Id for logging
+ // UserId for logging
String userId = httpRequest.getHeader(Constants.USER_ID_HEADER);
String remoteAddr = httpRequest.getRemoteAddr();
@@ -201,6 +201,7 @@ public class FeProxyServlet extends SSLProxyServlet {
if (onboardingForwardContext == null || onboardingForwardContext.isEmpty()) {
onboardingForwardContext = "/onboarding-api";
}
+ redirectedUrl = redirectedUrl.replace("/sdc1/feProxy/dcae-api", "/dcae");
redirectedUrl = redirectedUrl.replace("/sdc1/feProxy/onboarding-api", onboardingForwardContext);
redirectedUrl = redirectedUrl.replace("/sdc1/feProxy", "/sdc2");
return redirectedUrl;
diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java
index 338e8d4c01..b7fce8d912 100644
--- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java
+++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java
@@ -40,9 +40,9 @@ import org.apache.http.impl.client.HttpClientBuilder;
import org.apache.http.util.EntityUtils;
import org.openecomp.sdc.common.api.Constants;
import org.openecomp.sdc.common.api.HealthCheckInfo;
+import org.openecomp.sdc.common.api.HealthCheckWrapper;
import org.openecomp.sdc.common.api.HealthCheckInfo.HealthCheckComponent;
import org.openecomp.sdc.common.api.HealthCheckInfo.HealthCheckStatus;
-import org.openecomp.sdc.common.api.HealthCheckWrapper;
import org.openecomp.sdc.common.config.EcompErrorName;
import org.openecomp.sdc.common.impl.ExternalConfiguration;
import org.openecomp.sdc.fe.config.Configuration;