Fixed health check issue
[portal.git] / portal-BE / src / main / java / org / onap / portal / controller / WidgetsCatalogMarkupController.java
index e63de2e..1c29355 100644 (file)
@@ -50,7 +50,6 @@ import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.onap.portalsdk.core.util.SystemProperties;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.context.annotation.Bean;
-import org.springframework.context.annotation.EnableAspectJAutoProxy;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.RestController;
@@ -60,11 +59,10 @@ import org.springframework.web.multipart.commons.CommonsMultipartResolver;
 
 @EPAuditLog
 @RestController
-@EnableAspectJAutoProxy
 public class WidgetsCatalogMarkupController {
 
        private EELFLoggerDelegate logger = EELFLoggerDelegate.getLogger(WidgetsCatalogMarkupController.class);
-       private RestTemplate template = new RestTemplate();
+       private final RestTemplate template = new RestTemplate();
        private final String whatService = "widgets-service";
 
        @Autowired
@@ -77,9 +75,7 @@ public class WidgetsCatalogMarkupController {
 
        static {
               // for localhost testing only
-              javax.net.ssl.HttpsURLConnection.setDefaultHostnameVerifier((hostname, sslSession) -> {
-                     return hostname.equals("localhost");
-              });
+              javax.net.ssl.HttpsURLConnection.setDefaultHostnameVerifier((hostname, sslSession) -> hostname.equals("localhost"));
        }
 
        @GetMapping(value = "/portalApi/microservices/markup/{widgetId}")