summaryrefslogtreecommitdiffstats
path: root/common/onap-common-configuration-management/onap-configuration-management-core/src/main
diff options
context:
space:
mode:
authorvasraz <vasyl.razinkov@est.tech>2021-03-07 12:49:44 +0000
committerVasyl Razinkov <vasyl.razinkov@est.tech>2021-03-07 12:50:49 +0000
commit77ae856a6ef8cf9beea4cd59fab690ece909671a (patch)
tree84feab4a7dd90e7d800b56e0b55ee9fd4567f3d6 /common/onap-common-configuration-management/onap-configuration-management-core/src/main
parent2c3856cc311bd1b0317b13b106abe90ed0ed0ead (diff)
Disable unstable CliFallbackAndLookupTest
Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Issue-ID: SDC-3490 Change-Id: I48f502125c3fb23f880f7c318f540b4396b5754e
Diffstat (limited to 'common/onap-common-configuration-management/onap-configuration-management-core/src/main')
-rw-r--r--common/onap-common-configuration-management/onap-configuration-management-core/src/main/java/org/onap/config/impl/CliConfigurationImpl.java19
1 files changed, 9 insertions, 10 deletions
diff --git a/common/onap-common-configuration-management/onap-configuration-management-core/src/main/java/org/onap/config/impl/CliConfigurationImpl.java b/common/onap-common-configuration-management/onap-configuration-management-core/src/main/java/org/onap/config/impl/CliConfigurationImpl.java
index 3fcbd4f1c4..f919e234f0 100644
--- a/common/onap-common-configuration-management/onap-configuration-management-core/src/main/java/org/onap/config/impl/CliConfigurationImpl.java
+++ b/common/onap-common-configuration-management/onap-configuration-management-core/src/main/java/org/onap/config/impl/CliConfigurationImpl.java
@@ -32,7 +32,7 @@ import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Set;
-
+import lombok.NoArgsConstructor;
import org.onap.config.ConfigurationUtils;
import org.onap.config.api.ConfigurationManager;
import org.onap.config.api.Hint;
@@ -40,15 +40,13 @@ import org.onap.config.type.ConfigurationQuery;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+@NoArgsConstructor
public final class CliConfigurationImpl extends ConfigurationImpl implements ConfigurationManager {
private static final Logger LOGGER = LoggerFactory.getLogger(CliConfigurationImpl.class);
private static final List<String> KEYS_TO_FILTER = Arrays.asList(NAMESPACE_KEY, MODE_KEY, LOAD_ORDER_KEY);
- public CliConfigurationImpl() {
- super();
- }
-
+ @Override
public String getConfigurationValue(Map<String, Object> input) {
return getConfigurationValue((ConfigurationQuery) getInput(input));
}
@@ -62,7 +60,7 @@ public final class CliConfigurationImpl extends ConfigurationImpl implements Con
value = get(queryData.getTenant(), queryData.getNamespace(), queryData.getKey(), String[].class, hints);
} else {
value = getInternal(queryData.getTenant(), queryData.getNamespace(), queryData.getKey(), String[].class,
- hints);
+ hints);
}
return ConfigurationUtils.getCommaSeparatedList(value);
} catch (Exception exception) {
@@ -88,7 +86,7 @@ public final class CliConfigurationImpl extends ConfigurationImpl implements Con
return toReturn;
}
try {
- toReturn = Class.forName(input.get("ImplClass").toString()).newInstance();
+ toReturn = Class.forName(input.get("ImplClass").toString()).getDeclaredConstructor().newInstance();
Method[] methods = toReturn.getClass().getMethods();
for (Method method : methods) {
if (input.containsKey(method.getName())) {
@@ -101,6 +99,7 @@ public final class CliConfigurationImpl extends ConfigurationImpl implements Con
return toReturn;
}
+ @Override
public Map<String, String> listConfiguration(Map<String, Object> input) {
return listConfiguration((ConfigurationQuery) getInput(input));
}
@@ -132,9 +131,9 @@ public final class CliConfigurationImpl extends ConfigurationImpl implements Con
}
} catch (Exception exception) {
LOGGER.warn("Error occurred while searching for in-memory keys for namespace: '{}' and tenant: '{}'",
- namespace,
- tenant,
- exception
+ namespace,
+ tenant,
+ exception
);
}
return keys;