summaryrefslogtreecommitdiffstats
path: root/bpmn/so-bpmn-tasks
diff options
context:
space:
mode:
authorLukasz Muszkieta <lukasz.muszkieta@nokia.com>2020-05-22 14:50:26 +0200
committerLukasz Muszkieta <lukasz.muszkieta@nokia.com>2020-05-22 14:54:55 +0200
commit594721c136abf0b1f203228bf946a286747ed34c (patch)
tree89d6603c3d1de20b67b8f78585c542cc1ea7ae28 /bpmn/so-bpmn-tasks
parent2109b159bb28fc8eff6613b227fe7e5d5d8ae915 (diff)
use existing pnf - logging improvement
Issue-ID: SO-2937 Signed-off-by: Lukasz Muszkieta <lukasz.muszkieta@nokia.com> Change-Id: Ic4832d7f6608b684d0b1c902a8a7b48f6639e6e1
Diffstat (limited to 'bpmn/so-bpmn-tasks')
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/AAIPnfResources.java3
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIPnfResourcesTest.java3
2 files changed, 4 insertions, 2 deletions
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/AAIPnfResources.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/AAIPnfResources.java
index 7184bba377..3b22cd9d81 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/AAIPnfResources.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/AAIPnfResources.java
@@ -98,7 +98,8 @@ public class AAIPnfResources {
pnfFromAai.getPnfName());
} else {
String errorMessage = String.format(
- "pnf with name %s already exists with orchestration status %s, only status Inventoried allows to use existing pnf",
+ "pnf with name %s already exists with orchestration status %s, existing pnf can be used only "
+ + "if status is not set or set as Inventoried",
pnfFromAai.getPnfName(), pnfFromAai.getOrchestrationStatus());
logger.error(errorMessage);
throw new Exception(errorMessage);
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIPnfResourcesTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIPnfResourcesTest.java
index 5e9b4c7592..59cd53edd5 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIPnfResourcesTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIPnfResourcesTest.java
@@ -149,7 +149,8 @@ public class AAIPnfResourcesTest extends TestDataSetup {
} catch (Exception e) {
// then
assertThat(e.getMessage()).isEqualTo(String.format(
- "pnf with name %s already exists with orchestration status Active, only status Inventoried allows to use existing pnf",
+ "pnf with name %s already exists with orchestration status Active, existing pnf can be used only "
+ + "if status is not set or set as Inventoried",
PNF_NAME));
}
}