aboutsummaryrefslogtreecommitdiffstats
path: root/adapters/etsi-sol003-adapter/etsi-sol003-lcm
diff options
context:
space:
mode:
Diffstat (limited to 'adapters/etsi-sol003-adapter/etsi-sol003-lcm')
-rw-r--r--adapters/etsi-sol003-adapter/etsi-sol003-lcm/etsi-sol003-lcm-adapter/src/main/java/org/onap/so/adapters/etsisol003adapter/lcm/extclients/aai/AaiPropertiesImpl.java9
1 files changed, 8 insertions, 1 deletions
diff --git a/adapters/etsi-sol003-adapter/etsi-sol003-lcm/etsi-sol003-lcm-adapter/src/main/java/org/onap/so/adapters/etsisol003adapter/lcm/extclients/aai/AaiPropertiesImpl.java b/adapters/etsi-sol003-adapter/etsi-sol003-lcm/etsi-sol003-lcm-adapter/src/main/java/org/onap/so/adapters/etsisol003adapter/lcm/extclients/aai/AaiPropertiesImpl.java
index b3b22e239d..9e08cda354 100644
--- a/adapters/etsi-sol003-adapter/etsi-sol003-lcm/etsi-sol003-lcm-adapter/src/main/java/org/onap/so/adapters/etsisol003adapter/lcm/extclients/aai/AaiPropertiesImpl.java
+++ b/adapters/etsi-sol003-adapter/etsi-sol003-lcm/etsi-sol003-lcm-adapter/src/main/java/org/onap/so/adapters/etsisol003adapter/lcm/extclients/aai/AaiPropertiesImpl.java
@@ -32,13 +32,15 @@ public class AaiPropertiesImpl implements AAIProperties {
private final String endpoint;
private final String encryptedBasicAuth;
private final String encrytptionKey;
+ private final String aaiVersion;
public AaiPropertiesImpl() {
-
final ApplicationContext context = SpringContextHelper.getAppContext();
this.endpoint = context.getEnvironment().getProperty("aai.endpoint");
this.encryptedBasicAuth = context.getEnvironment().getProperty("aai.auth");
this.encrytptionKey = context.getEnvironment().getProperty("mso.key");
+ this.aaiVersion = context.getEnvironment().getProperty("aai.version");
+
}
@Override
@@ -53,6 +55,11 @@ public class AaiPropertiesImpl implements AAIProperties {
@Override
public AAIVersion getDefaultVersion() {
+ for (final AAIVersion version : AAIVersion.values()) {
+ if (version.toString().equalsIgnoreCase(this.aaiVersion)) {
+ return version;
+ }
+ }
return AAIVersion.LATEST;
}