From ee90372744da6e94c788e0579a32c60b244658f8 Mon Sep 17 00:00:00 2001 From: Sylvain Desbureaux Date: Thu, 9 Dec 2021 09:08:08 +0100 Subject: [SDC CLIENT] Allow HTTP By default, SDC client is using only https, which can be problematic when used on top of service mesh for example. Let's override isUseHttpsWithSDC in order to allow use of http thanks to a configuration variable. Issue-ID: OOM-2258 Signed-off-by: Sylvain Desbureaux Change-Id: Ifb8cb7cbf2881d3f2b2d131f1b0a44db6da3200e --- .../onap/ccsdk/sli/northbound/uebclient/SdncUebConfiguration.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/northbound/ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncUebConfiguration.java b/northbound/ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncUebConfiguration.java index 4efc29b77..82b86e217 100644 --- a/northbound/ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncUebConfiguration.java +++ b/northbound/ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncUebConfiguration.java @@ -56,6 +56,7 @@ public class SdncUebConfiguration implements IConfiguration{ private String sdncPasswd = null; private String asdcApiBaseUrl = null; private String asdcApiNamespace = null; + private String asdcUseHttps = null; private List msgBusAddress = null; private SdncArtifactMap artifactMap = SdncArtifactMap.getInstance(); @@ -129,6 +130,8 @@ public class SdncUebConfiguration implements IConfiguration{ environmentName = props.getProperty("org.onap.ccsdk.sli.northbound.uebclient.environment-name"); password = props.getProperty("org.onap.ccsdk.sli.northbound.uebclient.password"); user = props.getProperty("org.onap.ccsdk.sli.northbound.uebclient.user"); + asdcUseHttps = props.getProperty("org.onap.ccsdk.sli.northbound.uebclient.use-https", "true"); + sdncUser = props.getProperty("org.onap.ccsdk.sli.northbound.uebclient.sdnc-user"); sdncPasswd = props.getProperty("org.onap.ccsdk.sli.northbound.uebclient.sdnc-passwd"); @@ -309,6 +312,11 @@ public class SdncUebConfiguration implements IConfiguration{ return false; } + @Override + public Boolean isUseHttpsWithSDC() { + return Boolean.parseBoolean(asdcUseHttps); + } + @Override public List getMsgBusAddress() { return msgBusAddress; -- cgit 1.2.3-korg