summaryrefslogtreecommitdiffstats
path: root/nokiav2
diff options
context:
space:
mode:
Diffstat (limited to 'nokiav2')
-rw-r--r--nokiav2/driver/pom.xml10
-rw-r--r--nokiav2/driver/src/main/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/core/MsbApiProvider.java3
-rw-r--r--nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/vfc/TestVfcExternalSystemInfoProvider.java4
-rw-r--r--nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/vnfm/TestBase.java2
-rw-r--r--nokiav2/driver/src/test/resources/unittests/TestCbamCatalogManager.sample.csarbin1479 -> 2321 bytes
-rw-r--r--nokiav2/driverwar/pom.xml25
6 files changed, 28 insertions, 16 deletions
diff --git a/nokiav2/driver/pom.xml b/nokiav2/driver/pom.xml
index e770f3e4..46dfe936 100644
--- a/nokiav2/driver/pom.xml
+++ b/nokiav2/driver/pom.xml
@@ -52,10 +52,10 @@
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
- <version>20.0</version>
- <!-- parsing VNFDs -->
+ <version>24.0-jre</version>
</dependency>
<dependency>
+ <!-- parsing VNFDs -->
<groupId>org.yaml</groupId>
<artifactId>snakeyaml</artifactId>
<version>1.19</version>
@@ -96,9 +96,9 @@
<version>1.2.0</version>
</dependency>
<dependency>
- <groupId>org.onap.aai</groupId>
- <artifactId>rest-client</artifactId>
- <version>1.2.0</version>
+ <groupId>org.onap.aai</groupId>
+ <artifactId>rest-client</artifactId>
+ <version>1.2.0</version>
</dependency>
</dependencies>
<build>
diff --git a/nokiav2/driver/src/main/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/core/MsbApiProvider.java b/nokiav2/driver/src/main/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/core/MsbApiProvider.java
index b6f4644a..b652b59c 100644
--- a/nokiav2/driver/src/main/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/core/MsbApiProvider.java
+++ b/nokiav2/driver/src/main/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/core/MsbApiProvider.java
@@ -59,8 +59,9 @@ public class MsbApiProvider extends IpMappingProvider {
*/
public String getMicroServiceUrl(String name, String version) {
MicroServiceFullInfo microServiceFullInfo = getMicroServiceInfo(name, version);
- String protocol = "http://"; //FIXME the enable_ssl field should be used, but it is not available in SDK
String ipAnPort = getNodeIpAnPort(microServiceFullInfo);
+ //FIXME the enable_ssl field should be used, but it is not available in SDK depends on MSB-151 jira issue
+ String protocol = (ipAnPort.endsWith(":8443") || ipAnPort.endsWith(":443")) ? "https://" : "http://";
//the field name in A&AI is misleading the URL is relative path postfixed to http(s)://ip:port
String fullUrl = protocol + ipAnPort + microServiceFullInfo.getUrl();
return fullUrl;
diff --git a/nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/vfc/TestVfcExternalSystemInfoProvider.java b/nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/vfc/TestVfcExternalSystemInfoProvider.java
index 1081b93c..aec53e10 100644
--- a/nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/vfc/TestVfcExternalSystemInfoProvider.java
+++ b/nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/onap/vfc/TestVfcExternalSystemInfoProvider.java
@@ -63,8 +63,8 @@ public class TestVfcExternalSystemInfoProvider extends TestBase {
vfcExternalSystemInfoProvider.getVimInfo(VIM_ID);
fail();
} catch (Exception e) {
- assertEquals("Unable to query VIM from VF-C with myVimId identifier", e.getMessage());
- verify(logger).error("Unable to query VIM from VF-C with myVimId identifier", expectedException);
+ assertEquals("Unable to query VIM from VF-C with " + VIM_ID +" identifier", e.getMessage());
+ verify(logger).error("Unable to query VIM from VF-C with " + VIM_ID+" identifier", expectedException);
}
}
diff --git a/nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/vnfm/TestBase.java b/nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/vnfm/TestBase.java
index be3ea0eb..99e95b4c 100644
--- a/nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/vnfm/TestBase.java
+++ b/nokiav2/driver/src/test/java/org/onap/vfc/nfvo/driver/vnfm/svnfm/nokia/vnfm/TestBase.java
@@ -66,7 +66,7 @@ public class TestBase {
public static final String VNF_ID = "myVnfId";
public static final String VNFM_ID = "myVnfmId";
public static final String ONAP_CSAR_ID = "myOnapCsarId";
- public static final String VIM_ID = "myVimId";
+ public static final String VIM_ID = "myCloudOwnerId_myRegionName";
public static final String JOB_ID = "myJobId";
public static final String CBAM_VNFD_ID = "cbamVnfdId";
@Mock
diff --git a/nokiav2/driver/src/test/resources/unittests/TestCbamCatalogManager.sample.csar b/nokiav2/driver/src/test/resources/unittests/TestCbamCatalogManager.sample.csar
index 94f476f4..1a179166 100644
--- a/nokiav2/driver/src/test/resources/unittests/TestCbamCatalogManager.sample.csar
+++ b/nokiav2/driver/src/test/resources/unittests/TestCbamCatalogManager.sample.csar
Binary files differ
diff --git a/nokiav2/driverwar/pom.xml b/nokiav2/driverwar/pom.xml
index cb434678..a9a5c13c 100644
--- a/nokiav2/driverwar/pom.xml
+++ b/nokiav2/driverwar/pom.xml
@@ -23,11 +23,9 @@
<name>vfc/nfvo/driver/vnfm/svnfm/nokiav2/driverwar</name>
<description>svnfm vnfm driver</description>
<parent>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-starter-parent</artifactId>
- <version>1.5.9.RELEASE</version>
- <relativePath/>
- <!-- lookup parent from repository -->
+ <groupId>org.onap.vfc.nfvo.driver.vnfm.svnfm.nokiav2</groupId>
+ <artifactId>vfc-nfvo-driver-vnfm-svnfm-nokiav2</artifactId>
+ <version>1.1.0-SNAPSHOT</version>
</parent>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
@@ -43,15 +41,28 @@
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
- <version>1.5.9.RELEASE</version>
+ <version>1.5.10.RELEASE</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-war-plugin</artifactId>
+ <configuration>
+ <failOnMissingWebXml>false</failOnMissingWebXml>
+ <archive>
+ <manifest>
+ <mainClass>org.onap.vfc.nfvo.driver.vnfm.svnfm.nokia.NokiaSvnfmApplication</mainClass>
+ <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
+ </manifest>
+ </archive>
+ </configuration>
+ </plugin>
+ <plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
- <version>1.5.7.RELEASE</version>
+ <version>1.5.10.RELEASE</version>
<configuration>
<mainClass>org.onap.vfc.nfvo.driver.vnfm.svnfm.nokia.NokiaSvnfmApplication</mainClass>
<layout>ZIP</layout>