aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--adapters/mso-catalog-db-adapter/src/main/resources/db/migration/R__MacroData.sql10
-rw-r--r--adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/BaseNssmfManager.java10
-rw-r--r--adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/ExternalNssmfManager.java1
-rw-r--r--adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/InternalNssmfManager.java2
-rw-r--r--adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/util/RestUtil.java9
-rw-r--r--adapters/mso-nssmf-adapter/src/main/resources/application.yaml2
-rw-r--r--adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/TaskServices.java10
-rw-r--r--adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/CreateInventoryTask.java7
-rw-r--r--adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/DeleteInventoryTask.java7
-rw-r--r--adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/PollService.java6
-rw-r--r--adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/RollbackService.java2
-rw-r--r--adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/StackService.java2
-rw-r--r--bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/NssmfAdapterUtils.groovy136
-rw-r--r--bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/OofUtils.groovy12
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/exception/ExceptionBuilder.java14
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/CreateVfModuleBB.bpmn149
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeleteVfModuleBB.bpmn69
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSliceService.groovy2
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSIandNSSI.groovy47
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSSI.groovy2
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateSliceServiceOption.groovy67
-rw-r--r--common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java2
-rw-r--r--common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java2
-rw-r--r--common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetType.java8
-rw-r--r--common/src/main/java/org/onap/so/utils/ExternalTaskServiceUtils.java10
-rw-r--r--docs/developer_info/Working_with_so_monitoring.rst118
-rw-r--r--docs/images/configmap.pngbin440254 -> 104117 bytes
-rw-r--r--docs/images/nodemap.pngbin48567 -> 30454 bytes
-rw-r--r--docs/images/nodeport.pngbin122080 -> 88806 bytes
-rw-r--r--docs/images/so-monitoring-config.pngbin0 -> 64690 bytes
-rw-r--r--docs/images/so-monitoring-password.pngbin0 -> 19960 bytes
-rw-r--r--docs/images/so-monitoring-secret.pngbin0 -> 27658 bytes
-rw-r--r--docs/images/so-monitorring-base64-password.pngbin0 -> 17378 bytes
-rw-r--r--docs/images/ui.pngbin47873 -> 22603 bytes
-rw-r--r--so-monitoring/so-monitoring-service/src/main/resources/application.yaml2
35 files changed, 410 insertions, 298 deletions
diff --git a/adapters/mso-catalog-db-adapter/src/main/resources/db/migration/R__MacroData.sql b/adapters/mso-catalog-db-adapter/src/main/resources/db/migration/R__MacroData.sql
index e4810840f1..542c004f64 100644
--- a/adapters/mso-catalog-db-adapter/src/main/resources/db/migration/R__MacroData.sql
+++ b/adapters/mso-catalog-db-adapter/src/main/resources/db/migration/R__MacroData.sql
@@ -949,13 +949,3 @@ VALUES
('VNFConfigModifyActivity','*','*','*','*','Manual','Abort','*', '*'),
('VNFUnsetInMaintFlagActivity','*','*','*','*','Manual','Abort','*', '*'),
('VNFUnsetClosedLoopDisabledActivity','*','*','*','*','Manual','Abort','*', '*');
-
-UPDATE orchestration_flow_reference set FLOW_NAME='ControllerExecutionBB', SCOPE='vnf', ACTION='config-assign' WHERE COMPOSITE_ACTION = 'Service-Macro-Create' and FLOW_NAME = 'ConfigAssignVnfBB';
-UPDATE orchestration_flow_reference set FLOW_NAME='ControllerExecutionBB', SCOPE='vnf', ACTION='config-deploy' WHERE COMPOSITE_ACTION = 'Service-Macro-Create' and FLOW_NAME = 'ConfigDeployVnfBB';
-UPDATE orchestration_flow_reference set FLOW_NAME='ControllerExecutionBB', SCOPE='vnf', ACTION='HealthCheck' WHERE COMPOSITE_ACTION = 'VFModule-ScaleOut' and FLOW_NAME = 'GenericVnfHealthCheckBB';
-UPDATE orchestration_flow_reference set FLOW_NAME='ControllerExecutionBB', SCOPE='vfmodule', ACTION='ScaleOutReconfiguration' WHERE COMPOSITE_ACTION = 'VFModule-ScaleOut' and FLOW_NAME = 'GenericVnfHealthCheckBB';
-
-INSERT INTO orchestration_flow_reference(COMPOSITE_ACTION, SEQ_NO, FLOW_NAME, FLOW_VERSION, NB_REQ_REF_LOOKUP_ID, SCOPE, ACTION) VALUES
-('VFModule-Delete', '1', 'ControllerExecutionBB', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VFModule-Delete' and CLOUD_OWNER = 'DEFAULT'), "vnf", "HealthCheck"),
-('VFModule-Delete', '2', 'ControllerExecutionBB', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VFModule-Delete' and CLOUD_OWNER = 'DEFAULT'), "vfmodule", "ScaleInReconfiguration"),
-('VFModule-Delete', '6', 'ControllerExecutionBB', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VFModule-Delete' and CLOUD_OWNER = 'DEFAULT'), "vnf", "HealthCheck"); \ No newline at end of file
diff --git a/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/BaseNssmfManager.java b/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/BaseNssmfManager.java
index c4f269c3a0..789f4f239d 100644
--- a/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/BaseNssmfManager.java
+++ b/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/BaseNssmfManager.java
@@ -210,10 +210,12 @@ public abstract class BaseNssmfManager implements NssmfManager {
private void urlHandler() {
NssmfUrlInfo nssmfUrlInfo =
NssmfAdapterConsts.getNssmfUrlInfo(this.executorType, this.esrInfo.getNetworkType(), actionType);
- this.nssmfUrl = nssmfUrlInfo.getUrl();
- this.httpMethod = nssmfUrlInfo.getHttpMethod();
- this.nssmfUrl = nssmfUrl.replaceAll("\\{apiVersion}", getApiVersion());
- this.params.forEach((k, v) -> this.nssmfUrl = this.nssmfUrl.replaceAll("\\{" + k + "}", v));
+ if (nssmfUrlInfo != null) {
+ this.nssmfUrl = nssmfUrlInfo.getUrl();
+ this.httpMethod = nssmfUrlInfo.getHttpMethod();
+ this.nssmfUrl = nssmfUrl.replaceAll("\\{apiVersion}", getApiVersion());
+ this.params.forEach((k, v) -> this.nssmfUrl = this.nssmfUrl.replaceAll("\\{" + k + "}", v));
+ }
}
/**
diff --git a/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/ExternalNssmfManager.java b/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/ExternalNssmfManager.java
index bb2b83fd59..72d1b53781 100644
--- a/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/ExternalNssmfManager.java
+++ b/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/ExternalNssmfManager.java
@@ -95,6 +95,7 @@ public abstract class ExternalNssmfManager extends BaseNssmfManager {
return marshal(actDeActNssi);
}
+ @Override
protected RestResponse doQueryJobStatus(ResourceOperationStatus status) throws ApplicationException {
return doResponseStatus(status);
}
diff --git a/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/InternalNssmfManager.java b/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/InternalNssmfManager.java
index 4705e871f3..88b5071371 100644
--- a/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/InternalNssmfManager.java
+++ b/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/manager/impl/InternalNssmfManager.java
@@ -98,7 +98,7 @@ public abstract class InternalNssmfManager extends BaseNssmfManager {
// internal
private RestResponse sendInternalRequest(String content) {
- Header header = new BasicHeader("X-Auth-Token", adapterConfig.getInfraAuth());
+ Header header = new BasicHeader("Authorization", adapterConfig.getInfraAuth());
this.nssmfUrl = adapterConfig.getInfraEndpoint() + this.nssmfUrl;
return restUtil.send(this.nssmfUrl, this.httpMethod, content, header);
}
diff --git a/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/util/RestUtil.java b/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/util/RestUtil.java
index a7adbe116a..7a86c5ba2b 100644
--- a/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/util/RestUtil.java
+++ b/adapters/mso-nssmf-adapter/src/main/java/org/onap/so/adapters/nssmf/util/RestUtil.java
@@ -270,6 +270,7 @@ public class RestUtil {
class HttpDeleteWithBody extends HttpEntityEnclosingRequestBase {
public static final String METHOD_NAME = "DELETE";
+ @Override
public String getMethod() {
return METHOD_NAME;
}
@@ -316,12 +317,15 @@ public class RestUtil {
public HttpClient getHttpsClient() {
TrustManager[] trustAllCerts = new TrustManager[] {new X509TrustManager() {
+ @Override
public java.security.cert.X509Certificate[] getAcceptedIssuers() {
return null;
}
+ @Override
public void checkClientTrusted(java.security.cert.X509Certificate[] certs, String authType) {}
+ @Override
public void checkServerTrusted(java.security.cert.X509Certificate[] certs, String authType) {}
}};
@@ -329,10 +333,9 @@ public class RestUtil {
try {
SSLContext sc = SSLContext.getInstance("SSL");
sc.init(null, trustAllCerts, new java.security.SecureRandom());
- // HttpsURLConnection.setDefaultSSLSocketFactory(sc.getSocketFactory());
- SSLConnectionSocketFactory sslsf =
- new SSLConnectionSocketFactory(sc, new String[] {"TLSv1"}, null, (s, sslSession) -> true);
+ SSLConnectionSocketFactory sslsf = new SSLConnectionSocketFactory(sc,
+ new String[] {"TLSv1", "TLSv1.1", "TLSv1.2", "TLSv1.3"}, null, (s, sslSession) -> true);
return HttpClients.custom().setSSLSocketFactory(sslsf).build();
} catch (Exception e) {
throw new IllegalArgumentException(e);
diff --git a/adapters/mso-nssmf-adapter/src/main/resources/application.yaml b/adapters/mso-nssmf-adapter/src/main/resources/application.yaml
index 8da911d4e0..5501fba88f 100644
--- a/adapters/mso-nssmf-adapter/src/main/resources/application.yaml
+++ b/adapters/mso-nssmf-adapter/src/main/resources/application.yaml
@@ -59,7 +59,7 @@ mso:
endpoint: https://so-request-db-adapter.{{ include "common.namespace" . }}:8083
auth: Basic YnBlbDpwYXNzd29yZDEk
infra:
- endpoint: https://so.{{ include "common.namespace" . }}:8080
+ endpoint: http://so.onap:8080
auth: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA==
#Actuator
diff --git a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/TaskServices.java b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/TaskServices.java
index b176892192..4e0c4ad8a6 100644
--- a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/TaskServices.java
+++ b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/TaskServices.java
@@ -62,13 +62,13 @@ public class TaskServices {
public void createtAAIInventory() throws Exception {
for (int i = 0; i < externalTaskServiceUtils.getMaxClients(); i++) {
ExternalTaskClient client = externalTaskServiceUtils.createExternalTaskClient();
- client.subscribe("InventoryCreate").lockDuration(externalTaskServiceUtils.getLongLockDuration())
+ client.subscribe("InventoryCreate").lockDuration(externalTaskServiceUtils.getLockDurationMedium())
.handler(createInventory::executeExternalTask).open();
}
}
@PostConstruct
- public void auditAAIInventory() throws Exception {
+ public void deleteAAIInventory() throws Exception {
for (int i = 0; i < externalTaskServiceUtils.getMaxClients(); i++) {
externalTaskServiceUtils.createExternalTaskClient().subscribe("InventoryDelete")
.lockDuration(externalTaskServiceUtils.getLockDurationMedium())
@@ -80,7 +80,7 @@ public class TaskServices {
public void openstackInvoker() throws Exception {
for (int i = 0; i < externalTaskServiceUtils.getMaxClients(); i++) {
ExternalTaskClient client = externalTaskServiceUtils.createExternalTaskClient();
- client.subscribe("OpenstackAdapterInvoke").lockDuration(externalTaskServiceUtils.getLockDuration())
+ client.subscribe("OpenstackAdapterInvoke").lockDuration(externalTaskServiceUtils.getLockDurationShort())
.handler(stackService::executeExternalTask).open();
}
}
@@ -89,7 +89,7 @@ public class TaskServices {
public void openstackPoller() throws Exception {
for (int i = 0; i < externalTaskServiceUtils.getMaxClients(); i++) {
ExternalTaskClient client = externalTaskServiceUtils.createExternalTaskClient();
- client.subscribe("OpenstackAdapterPolling").lockDuration(externalTaskServiceUtils.getLockDuration())
+ client.subscribe("OpenstackAdapterPolling").lockDuration(externalTaskServiceUtils.getLockDurationMedium())
.handler(pollService::executeExternalTask).open();
}
}
@@ -98,7 +98,7 @@ public class TaskServices {
public void openstackRollback() throws Exception {
for (int i = 0; i < externalTaskServiceUtils.getMaxClients(); i++) {
ExternalTaskClient client = externalTaskServiceUtils.createExternalTaskClient();
- client.subscribe("OpenstackAdapterRollback").lockDuration(externalTaskServiceUtils.getLockDuration())
+ client.subscribe("OpenstackAdapterRollback").lockDuration(externalTaskServiceUtils.getLockDurationShort())
.handler(rollbackService::executeExternalTask).open();
}
}
diff --git a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/CreateInventoryTask.java b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/CreateInventoryTask.java
index 3c9a4833ae..711394a95d 100644
--- a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/CreateInventoryTask.java
+++ b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/CreateInventoryTask.java
@@ -22,6 +22,8 @@
package org.onap.so.adapters.tasks.inventory;
+import java.util.HashMap;
+import java.util.Map;
import org.camunda.bpm.client.task.ExternalTask;
import org.camunda.bpm.client.task.ExternalTaskService;
import org.onap.logging.ref.slf4j.ONAPLogConstants;
@@ -57,6 +59,7 @@ public class CreateInventoryTask extends ExternalTaskUtils {
public void executeExternalTask(ExternalTask externalTask, ExternalTaskService externalTaskService) {
mdcSetup.setupMDC(externalTask);
+ Map<String, Object> variables = new HashMap<>();
String externalTaskId = externalTask.getId();
CloudInformation cloudInformation = externalTask.getVariable("cloudInformation");
boolean success = true;
@@ -69,6 +72,7 @@ public class CreateInventoryTask extends ExternalTaskUtils {
} catch (Exception e) {
logger.error("Error during inventory of stack", e);
success = false;
+ variables.put("inventoryErrorMessage", e.getMessage());
}
mdcSetup.setElapsedTime();
if (success) {
@@ -84,7 +88,8 @@ public class CreateInventoryTask extends ExternalTaskUtils {
externalTaskService.handleFailure(externalTask, UNABLE_TO_WRITE_ALL_INVENTORY_TO_A_AI,
UNABLE_TO_WRITE_ALL_INVENTORY_TO_A_AI, getRetrySequence().length, 10000);
} else if (retryCount != null && retryCount - 1 == 0) {
- externalTaskService.handleBpmnError(externalTask, AAI_INVENTORY_FAILURE);
+ externalTaskService.handleBpmnError(externalTask, AAI_INVENTORY_FAILURE, AAI_INVENTORY_FAILURE,
+ variables);
mdcSetup.setResponseCode(ONAPLogConstants.ResponseStatus.ERROR.toString());
logger.error("The External Task {} Failed, All Retries Exhausted", externalTaskId);
logger.info(ONAPLogConstants.Markers.EXIT, "Exiting");
diff --git a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/DeleteInventoryTask.java b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/DeleteInventoryTask.java
index 08361bdbbf..aad517129f 100644
--- a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/DeleteInventoryTask.java
+++ b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/inventory/DeleteInventoryTask.java
@@ -22,6 +22,8 @@
package org.onap.so.adapters.tasks.inventory;
+import java.util.HashMap;
+import java.util.Map;
import org.camunda.bpm.client.task.ExternalTask;
import org.camunda.bpm.client.task.ExternalTaskService;
import org.onap.logging.ref.slf4j.ONAPLogConstants;
@@ -56,6 +58,7 @@ public class DeleteInventoryTask extends ExternalTaskUtils {
public void executeExternalTask(ExternalTask externalTask, ExternalTaskService externalTaskService) {
mdcSetup.setupMDC(externalTask);
+ Map<String, Object> variables = new HashMap<>();
String externalTaskId = externalTask.getId();
CloudInformation cloudInformation = externalTask.getVariable("cloudInformation");
boolean success = true;
@@ -66,6 +69,7 @@ public class DeleteInventoryTask extends ExternalTaskUtils {
} catch (Exception e) {
logger.error("Error during inventory of stack", e);
success = false;
+ variables.put("inventoryErrorMessage", e.getMessage());
}
mdcSetup.setElapsedTime();
if (success) {
@@ -81,7 +85,8 @@ public class DeleteInventoryTask extends ExternalTaskUtils {
externalTaskService.handleFailure(externalTask, UNABLE_TO_WRITE_ALL_INVENTORY_TO_A_AI,
UNABLE_TO_WRITE_ALL_INVENTORY_TO_A_AI, getRetrySequence().length, 10000);
} else if (retryCount != null && retryCount - 1 == 0) {
- externalTaskService.handleBpmnError(externalTask, AAI_INVENTORY_FAILURE);
+ externalTaskService.handleBpmnError(externalTask, AAI_INVENTORY_FAILURE, AAI_INVENTORY_FAILURE,
+ variables);
mdcSetup.setResponseCode(ONAPLogConstants.ResponseStatus.ERROR.toString());
logger.error("The External Task Id: {} Failed, All Retries Exhausted", externalTaskId);
logger.info(ONAPLogConstants.Markers.EXIT, "Exiting");
diff --git a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/PollService.java b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/PollService.java
index 9ff50e8644..6a5381cf3e 100644
--- a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/PollService.java
+++ b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/PollService.java
@@ -68,7 +68,7 @@ public class PollService extends ExternalTaskUtils {
public void executeExternalTask(ExternalTask externalTask, ExternalTaskService externalTaskService) {
mdcSetup.setupMDC(externalTask);
- logger.trace("Executing External Task Poll Service");
+ logger.debug("Starting External Task Poll Service");
Map<String, Object> variables = new HashMap<>();
MutableBoolean success = new MutableBoolean();
String errorMessage = null;
@@ -103,11 +103,11 @@ public class PollService extends ExternalTaskUtils {
}
} catch (Exception e) {
logger.error("Error during External Task Poll Service", e);
- errorMessage = e.getMessage();
+ errorMessage = e.toString();
+ variables.put("openstackAdapterErrorMessage", errorMessage);
}
variables.put("OpenstackPollSuccess", success.booleanValue());
- variables.put("openstackAdapterErrorMessage", errorMessage);
if (success.isTrue()) {
externalTaskService.complete(externalTask, variables);
logger.debug("The External Task Id: {} Successful", externalTask.getId());
diff --git a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/RollbackService.java b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/RollbackService.java
index 15e6ff581d..c25d752cc4 100644
--- a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/RollbackService.java
+++ b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/RollbackService.java
@@ -39,7 +39,7 @@ public class RollbackService extends ExternalTaskUtils {
public void executeExternalTask(ExternalTask externalTask, ExternalTaskService externalTaskService) {
mdcSetup.setupMDC(externalTask);
- logger.trace("Executing External Task Rollback Service");
+ logger.debug("Starting External Task Rollback Service");
Map<String, Object> variables = new HashMap<>();
boolean success = false;
boolean pollRollbackStatus = false;
diff --git a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/StackService.java b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/StackService.java
index 5196ffffda..c9fa30d949 100644
--- a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/StackService.java
+++ b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/adapters/tasks/orchestration/StackService.java
@@ -91,7 +91,7 @@ public class StackService extends ExternalTaskUtils {
Map<String, Object> variables = new HashMap<>();
mdcSetup.setupMDC(externalTask);
String xmlRequest = externalTask.getVariable("openstackAdapterTaskRequest");
- logger.debug("Executing External Task Stack Service. {}", xmlRequest);
+ logger.debug("Starting External Task Stack Service. {}", xmlRequest);
MutableBoolean success = new MutableBoolean();
MutableBoolean backout = new MutableBoolean();
String response = "";
diff --git a/bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/NssmfAdapterUtils.groovy b/bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/NssmfAdapterUtils.groovy
index 775f088136..bbe5f0d0a4 100644
--- a/bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/NssmfAdapterUtils.groovy
+++ b/bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/NssmfAdapterUtils.groovy
@@ -22,22 +22,15 @@ package org.onap.so.bpmn.common.scripts
import org.apache.commons.lang3.StringUtils
import org.camunda.bpm.engine.delegate.DelegateExecution
-import org.json.JSONArray
-import org.json.JSONObject
-import org.onap.logging.filter.base.ErrorCode
import org.onap.logging.filter.base.ONAPComponents
-import org.onap.logging.ref.slf4j.ONAPLogConstants
+import org.onap.so.beans.nsmf.NssmfAdapterNBIRequest
import org.onap.so.bpmn.core.UrnPropertiesReader
import org.onap.so.bpmn.core.json.JsonUtils
import org.onap.so.client.HttpClient
import org.onap.so.client.HttpClientFactory
-import org.onap.so.logger.LoggingAnchor
-import org.onap.so.logger.MessageEnum
import org.slf4j.Logger
import org.slf4j.LoggerFactory
-import org.springframework.web.util.UriUtils
-import javax.ws.rs.core.MediaType
import javax.ws.rs.core.Response
/***
@@ -94,56 +87,91 @@ class NssmfAdapterUtils {
}
- public String sendPostRequestNSSMF (DelegateExecution execution, String endPoint, String nssmfRequest) {
- try {
-
- String nssmfEndpoint = UrnPropertiesReader.getVariable("mso.adapters.nssmf.endpoint",execution)
- String queryEndpoint = nssmfEndpoint + endPoint
- def responseData
- HttpClient client = httpClientFactory.newJsonClient(new URL(queryEndpoint), ONAPComponents.EXTERNAL)
- String basicAuthCred = execution.getVariable("BasicAuthHeaderValue")
- client.addAdditionalHeader("Authorization", StringUtils.defaultIfEmpty(basicAuthCred, getBasicDBAuthHeader(execution)))
-
- logger.debug('sending POST to NSSMF endpoint: ' + endPoint)
- Response response = client.post(nssmfRequest)
-
- responseData = response.readEntity(String.class)
- if (responseData != null) {
- logger.debug("Received data from NSSMF: " + responseData)
- }
-
- logger.debug('Response code:' + response.getStatus())
- logger.debug('Response:' + System.lineSeparator() + responseData)
- if (response.getStatus() >= 200 && response.getStatus() < 300) {
- // parse response as needed
- return responseData
- }
- else {
- return null
- }
- }
- catch (Exception e) {
- logger.debug("ERROR WHILE QUERYING CATALOG DB: " + e.message)
- throw e
- }
+ public String sendPostRequestNSSMF (DelegateExecution execution, String endPoint, String nssmfRequest) {
+ try {
- }
+ String nssmfEndpoint = UrnPropertiesReader.getVariable("mso.adapters.nssmf.endpoint",execution)
+ String queryEndpoint = nssmfEndpoint + endPoint
+ def responseData
+ HttpClient client = httpClientFactory.newJsonClient(new URL(queryEndpoint), ONAPComponents.EXTERNAL)
+ String basicAuthCred = execution.getVariable("BasicAuthHeaderValue")
+ client.addAdditionalHeader("Authorization", StringUtils.defaultIfEmpty(basicAuthCred, getBasicDBAuthHeader(execution)))
+ logger.debug('sending POST to NSSMF endpoint: ' + endPoint)
+ Response response = client.post(nssmfRequest)
+
+ responseData = response.readEntity(String.class)
+ if (responseData != null) {
+ logger.debug("Received data from NSSMF: " + responseData)
+ }
+
+ logger.debug('Response code:' + response.getStatus())
+ logger.debug('Response:' + System.lineSeparator() + responseData)
+ if (response.getStatus() >= 200 && response.getStatus() < 300) {
+ // parse response as needed
+ return responseData
+ }
+ else {
+ return null
+ }
+ }
+ catch (Exception e) {
+ logger.debug("ERROR WHILE QUERYING CATALOG DB: " + e.message)
+ throw e
+ }
- private String getBasicDBAuthHeader(DelegateExecution execution) {
+ }
- String encodedString = null
- try {
- String basicAuthValueDB = UrnPropertiesReader.getVariable("mso.adapters.db.auth", execution)
- logger.debug("DEBUG", " Obtained BasicAuth userid password for Catalog DB adapter: " + basicAuthValueDB)
+ public String sendPostRequestNSSMF (DelegateExecution execution, String endPoint, NssmfAdapterNBIRequest nssmfRequest) {
+ try {
+
+ String nssmfEndpoint = UrnPropertiesReader.getVariable("mso.adapters.nssmf.endpoint",execution)
+ String queryEndpoint = nssmfEndpoint + endPoint
+ def responseData
+ HttpClient client = httpClientFactory.newJsonClient(new URL(queryEndpoint), ONAPComponents.EXTERNAL)
+ String basicAuthCred = execution.getVariable("BasicAuthHeaderValue")
+ client.addAdditionalHeader("Authorization", StringUtils.defaultIfEmpty(basicAuthCred, getBasicDBAuthHeader(execution)))
+
+ logger.debug('sending POST to NSSMF endpoint: ' + endPoint)
+ Response response = client.post(nssmfRequest)
+
+ responseData = response.readEntity(String.class)
+ if (responseData != null) {
+ logger.debug("Received data from NSSMF: " + responseData)
+ }
+
+ logger.debug('Response code:' + response.getStatus())
+ logger.debug('Response:' + System.lineSeparator() + responseData)
+ if (response.getStatus() >= 200 && response.getStatus() < 300) {
+ // parse response as needed
+ return responseData
+ }
+ else {
+ return null
+ }
+ }
+ catch (Exception e) {
+ logger.debug("ERROR WHILE QUERYING CATALOG DB: " + e.message)
+ throw e
+ }
+
+ }
+
+ private String getBasicDBAuthHeader(DelegateExecution execution) {
+
+ String encodedString = null
+ try {
+ String basicAuthValueDB = UrnPropertiesReader.getVariable("mso.adapters.db.auth", execution)
+ logger.debug("DEBUG", " Obtained BasicAuth userid password for Catalog DB adapter: " + basicAuthValueDB)
+
+ encodedString = utils.getBasicAuth(basicAuthValueDB, UrnPropertiesReader.getVariable("mso.msoKey", execution))
+ execution.setVariable("BasicAuthHeaderValue", encodedString)
+ } catch (IOException ex) {
+ String dataErrorMessage = " Unable to encode Catalog DB user/password string - " + ex.getMessage()
+ logger.error(dataErrorMessage)
+ }
+ return encodedString
+ }
- encodedString = utils.getBasicAuth(basicAuthValueDB, UrnPropertiesReader.getVariable("mso.msoKey", execution))
- execution.setVariable("BasicAuthHeaderValue", encodedString)
- } catch (IOException ex) {
- String dataErrorMessage = " Unable to encode Catalog DB user/password string - " + ex.getMessage()
- logger.error(dataErrorMessage)
- }
- return encodedString
- }
}
diff --git a/bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/OofUtils.groovy b/bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/OofUtils.groovy
index ff31c46a3a..37b30567c7 100644
--- a/bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/OofUtils.groovy
+++ b/bpmn/MSOCommonBPMN/src/main/groovy/org/onap/so/bpmn/common/scripts/OofUtils.groovy
@@ -22,6 +22,7 @@
package org.onap.so.bpmn.common.scripts
+import com.google.gson.GsonBuilder
import org.onap.so.beans.nsmf.oof.NsiReqBody
import org.onap.so.beans.nsmf.oof.NssiReqBody
import org.onap.so.beans.nsmf.oof.RequestInfo
@@ -682,9 +683,7 @@ return json.toString()
nsiReqBody.setNSSTInfo(nsstInfo)
nsiReqBody.setPreferReuse(preferReuse)
- ObjectMapper objectMapper = new ObjectMapper()
-
- return objectMapper.writeValueAsString(nsiReqBody)
+ return bean2JsonStr(nsiReqBody)
}
public <T> String buildSelectNSSIRequest(String requestId, TemplateInfo nsstInfo, String messageType,
@@ -710,9 +709,10 @@ return json.toString()
nssiReqBody.setSliceProfile(sliceProfile)
nssiReqBody.setNSSTInfo(nsstInfo)
+ return bean2JsonStr(nssiReqBody)
+ }
- ObjectMapper objectMapper = new ObjectMapper()
-
- return objectMapper.writeValueAsString(nssiReqBody)
+ private static <T> String bean2JsonStr(T t) {
+ return new GsonBuilder().setPrettyPrinting().create().toJson(t)
}
}
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/exception/ExceptionBuilder.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/exception/ExceptionBuilder.java
index 43db27917e..f40948fc49 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/exception/ExceptionBuilder.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/client/exception/ExceptionBuilder.java
@@ -376,4 +376,18 @@ public class ExceptionBuilder {
}
+ public void processInventoryException(DelegateExecution execution) {
+ String errorMessage = "";
+ logger.debug("Processing Inventory Exception");
+ try {
+ errorMessage = (String) execution.getVariable("inventoryErrorMessage");
+ } catch (Exception e) {
+ logger.debug("Error while Processing Inventory Exception", e);
+ }
+ buildWorkflowException(execution, 500, errorMessage, Components.OPENSTACK);
+ throw new BpmnError("MSOWorkflowException");
+
+
+ }
+
}
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/CreateVfModuleBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/CreateVfModuleBB.bpmn
index 7638f34a59..9e2c0db6ea 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/CreateVfModuleBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/CreateVfModuleBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="3.7.0">
<bpmn:process id="CreateVfModuleBB" name="CreateVfModuleBB" isExecutable="true">
<bpmn:startEvent id="CreateVfModuleBB_Start">
<bpmn:outgoing>SequenceFlow_1xr6chl</bpmn:outgoing>
@@ -43,17 +43,6 @@
<bpmn:incoming>SequenceFlow_15do1tu</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0rds4rj</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:subProcess id="SubProcess_1getwnf" name="Error Handling&#10;&#10;" triggeredByEvent="true">
- <bpmn:startEvent id="StartEvent_1c8o652">
- <bpmn:outgoing>SequenceFlow_0gcots6</bpmn:outgoing>
- <bpmn:errorEventDefinition />
- </bpmn:startEvent>
- <bpmn:endEvent id="EndEvent_1emam1w">
- <bpmn:incoming>SequenceFlow_0gcots6</bpmn:incoming>
- <bpmn:terminateEventDefinition />
- </bpmn:endEvent>
- <bpmn:sequenceFlow id="SequenceFlow_0gcots6" sourceRef="StartEvent_1c8o652" targetRef="EndEvent_1emam1w" />
- </bpmn:subProcess>
<bpmn:sequenceFlow id="SequenceFlow_0rds4rj" sourceRef="UpdateVfModuleHeatStackId" targetRef="UpdateVfModuleStatus" />
<bpmn:sequenceFlow id="SequenceFlow_1vbwdaw" sourceRef="UpdateVfModuleStatus" targetRef="CreateVfModuleBB_End" />
<bpmn:serviceTask id="CreateNetworkPolicies" name="AAI Create (network policies)" camunda:expression="${AAICreateTasks.createNetworkPolicies(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
@@ -61,7 +50,7 @@
<bpmn:outgoing>SequenceFlow_0xqhep5</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_0xqhep5" sourceRef="CreateNetworkPolicies" targetRef="UpdateVnfIpv4OamAddress" />
- <bpmn:serviceTask id="UpdateVnfIpv4OamAddress" name="AAI Update (VNF) " camunda:expression="${AAIUpdateTasks.updateIpv4OamAddressVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
+ <bpmn:serviceTask id="UpdateVnfIpv4OamAddress" name="AAI Update (VNF) " camunda:expression="${AAIUpdateTasks.updateIpv4OamAddressVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0xqhep5</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_1yo6mvv</bpmn:outgoing>
</bpmn:serviceTask>
@@ -97,14 +86,30 @@
<bpmn:outgoing>SequenceFlow_1mg8eym</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="YesHelm" name="Yes Helm" sourceRef="CheckIfIsHelm" targetRef="CnfAdapter">
- <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[${execution.getVariable("isHelm")}]]></bpmn:conditionExpression>
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">${execution.getVariable("isHelm")}</bpmn:conditionExpression>
</bpmn:sequenceFlow>
<bpmn:sequenceFlow id="SequenceFlow_1mg8eym" sourceRef="CnfAdapter" targetRef="ServiceTask_01zrt6x" />
<bpmn:sequenceFlow id="SequenceFlow_1ig2ix4" sourceRef="QueryVfModule" targetRef="CheckIfIsHelm" />
<bpmn:sequenceFlow id="NoHelm" name="No Helm" sourceRef="CheckIfIsHelm" targetRef="CreateVfModule" />
<bpmn:sequenceFlow id="SequenceFlow_0dehck5" sourceRef="CreateVfModule" targetRef="VnfAdapter" />
<bpmn:sequenceFlow id="SequenceFlow_0uetprw" sourceRef="VnfAdapter" targetRef="ServiceTask_01zrt6x" />
+ <bpmn:subProcess id="Activity_10eqhmz" name="Inventory Error Handling" triggeredByEvent="true">
+ <bpmn:endEvent id="Event_108oetk">
+ <bpmn:incoming>Flow_03q6ty9</bpmn:incoming>
+ </bpmn:endEvent>
+ <bpmn:startEvent id="Event_1pengt4">
+ <bpmn:outgoing>Flow_1sqy91r</bpmn:outgoing>
+ <bpmn:errorEventDefinition id="ErrorEventDefinition_1idpz1m" errorRef="Error_0t7oivz" />
+ </bpmn:startEvent>
+ <bpmn:serviceTask id="Activity_1p8hxyt" name="Process Error" camunda:expression="${ExceptionBuilder.processInventoryException(execution)}">
+ <bpmn:incoming>Flow_1sqy91r</bpmn:incoming>
+ <bpmn:outgoing>Flow_03q6ty9</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:sequenceFlow id="Flow_1sqy91r" sourceRef="Event_1pengt4" targetRef="Activity_1p8hxyt" />
+ <bpmn:sequenceFlow id="Flow_03q6ty9" sourceRef="Activity_1p8hxyt" targetRef="Event_108oetk" />
+ </bpmn:subProcess>
</bpmn:process>
+ <bpmn:error id="Error_0t7oivz" name="AAIInventoryFailure" errorCode="AAIInventoryFailure" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="CreateVfModuleBB">
<bpmndi:BPMNShape id="StartEvent_0kxwniy_di" bpmnElement="CreateVfModuleBB_Start">
@@ -117,8 +122,8 @@
<dc:Bounds x="513" y="66" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1xr6chl_di" bpmnElement="SequenceFlow_1xr6chl">
- <di:waypoint xsi:type="dc:Point" x="192" y="106" />
- <di:waypoint xsi:type="dc:Point" x="313" y="106" />
+ <di:waypoint x="192" y="106" />
+ <di:waypoint x="313" y="106" />
<bpmndi:BPMNLabel>
<dc:Bounds x="156" y="91" width="0" height="0" />
</bpmndi:BPMNLabel>
@@ -133,8 +138,8 @@
<dc:Bounds x="794" y="66" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1s4rpyp_di" bpmnElement="SequenceFlow_1s4rpyp">
- <di:waypoint xsi:type="dc:Point" x="413" y="106" />
- <di:waypoint xsi:type="dc:Point" x="513" y="106" />
+ <di:waypoint x="413" y="106" />
+ <di:waypoint x="513" y="106" />
<bpmndi:BPMNLabel>
<dc:Bounds x="321" y="91" width="90" height="0" />
</bpmndi:BPMNLabel>
@@ -151,40 +156,18 @@
<bpmndi:BPMNShape id="ServiceTask_04k1b85_di" bpmnElement="UpdateVfModuleHeatStackId">
<dc:Bounds x="959" y="428" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="SubProcess_1getwnf_di" bpmnElement="SubProcess_1getwnf" isExpanded="true">
- <dc:Bounds x="202" y="556" width="231" height="135" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="StartEvent_1c8o652_di" bpmnElement="StartEvent_1c8o652">
- <dc:Bounds x="241" y="614" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="72" y="606" width="90" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="EndEvent_1emam1w_di" bpmnElement="EndEvent_1emam1w">
- <dc:Bounds x="378" y="614" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="209" y="606" width="90" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_0gcots6_di" bpmnElement="SequenceFlow_0gcots6">
- <di:waypoint xsi:type="dc:Point" x="277" y="632" />
- <di:waypoint xsi:type="dc:Point" x="378" y="632" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="186" y="567" width="90" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0rds4rj_di" bpmnElement="SequenceFlow_0rds4rj">
- <di:waypoint xsi:type="dc:Point" x="1059" y="468" />
- <di:waypoint xsi:type="dc:Point" x="1124" y="468" />
+ <di:waypoint x="1059" y="468" />
+ <di:waypoint x="1124" y="468" />
<bpmndi:BPMNLabel>
<dc:Bounds x="950" y="409" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1vbwdaw_di" bpmnElement="SequenceFlow_1vbwdaw">
- <di:waypoint xsi:type="dc:Point" x="1224" y="468" />
- <di:waypoint xsi:type="dc:Point" x="1265" y="468" />
- <di:waypoint xsi:type="dc:Point" x="1265" y="468" />
- <di:waypoint xsi:type="dc:Point" x="1300" y="468" />
+ <di:waypoint x="1224" y="468" />
+ <di:waypoint x="1265" y="468" />
+ <di:waypoint x="1265" y="468" />
+ <di:waypoint x="1300" y="468" />
<bpmndi:BPMNLabel>
<dc:Bounds x="1138" y="424" width="90" height="0" />
</bpmndi:BPMNLabel>
@@ -193,8 +176,8 @@
<dc:Bounds x="324" y="428" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0xqhep5_di" bpmnElement="SequenceFlow_0xqhep5">
- <di:waypoint xsi:type="dc:Point" x="424" y="468" />
- <di:waypoint xsi:type="dc:Point" x="477" y="468" />
+ <di:waypoint x="424" y="468" />
+ <di:waypoint x="477" y="468" />
<bpmndi:BPMNLabel>
<dc:Bounds x="309" y="409" width="90" height="0" />
</bpmndi:BPMNLabel>
@@ -203,8 +186,8 @@
<dc:Bounds x="477" y="428" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1yo6mvv_di" bpmnElement="SequenceFlow_1yo6mvv">
- <di:waypoint xsi:type="dc:Point" x="577" y="468" />
- <di:waypoint xsi:type="dc:Point" x="646" y="468" />
+ <di:waypoint x="577" y="468" />
+ <di:waypoint x="646" y="468" />
<bpmndi:BPMNLabel>
<dc:Bounds x="470" y="409" width="90" height="0" />
</bpmndi:BPMNLabel>
@@ -213,8 +196,8 @@
<dc:Bounds x="646" y="428" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1i03uy2_di" bpmnElement="SequenceFlow_1i03uy2">
- <di:waypoint xsi:type="dc:Point" x="746" y="468" />
- <di:waypoint xsi:type="dc:Point" x="794" y="468" />
+ <di:waypoint x="746" y="468" />
+ <di:waypoint x="794" y="468" />
<bpmndi:BPMNLabel>
<dc:Bounds x="628" y="409" width="90" height="0" />
</bpmndi:BPMNLabel>
@@ -223,8 +206,8 @@
<dc:Bounds x="794" y="428" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_15do1tu_di" bpmnElement="SequenceFlow_15do1tu">
- <di:waypoint xsi:type="dc:Point" x="894" y="468" />
- <di:waypoint xsi:type="dc:Point" x="959" y="468" />
+ <di:waypoint x="894" y="468" />
+ <di:waypoint x="959" y="468" />
<bpmndi:BPMNLabel>
<dc:Bounds x="785" y="399" width="90" height="0" />
</bpmndi:BPMNLabel>
@@ -233,8 +216,8 @@
<dc:Bounds x="665" y="326" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1io8r33_di" bpmnElement="SequenceFlow_1io8r33">
- <di:waypoint xsi:type="dc:Point" x="665" y="366" />
- <di:waypoint xsi:type="dc:Point" x="563" y="366" />
+ <di:waypoint x="665" y="366" />
+ <di:waypoint x="563" y="366" />
<bpmndi:BPMNLabel>
<dc:Bounds x="569" y="297" width="90" height="20" />
</bpmndi:BPMNLabel>
@@ -243,10 +226,10 @@
<dc:Bounds x="463" y="326" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1yn8o6d_di" bpmnElement="SequenceFlow_1yn8o6d">
- <di:waypoint xsi:type="dc:Point" x="463" y="366" />
- <di:waypoint xsi:type="dc:Point" x="255" y="366" />
- <di:waypoint xsi:type="dc:Point" x="255" y="463" />
- <di:waypoint xsi:type="dc:Point" x="324" y="463" />
+ <di:waypoint x="463" y="366" />
+ <di:waypoint x="255" y="366" />
+ <di:waypoint x="255" y="463" />
+ <di:waypoint x="324" y="463" />
<bpmndi:BPMNLabel>
<dc:Bounds x="225" y="361" width="90" height="20" />
</bpmndi:BPMNLabel>
@@ -261,48 +244,68 @@
<dc:Bounds x="665" y="166" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0q1janp_di" bpmnElement="YesHelm">
- <di:waypoint xsi:type="dc:Point" x="715" y="131" />
- <di:waypoint xsi:type="dc:Point" x="715" y="166" />
+ <di:waypoint x="715" y="131" />
+ <di:waypoint x="715" y="166" />
<bpmndi:BPMNLabel>
<dc:Bounds x="730" y="136" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1mg8eym_di" bpmnElement="SequenceFlow_1mg8eym">
- <di:waypoint xsi:type="dc:Point" x="715" y="246" />
- <di:waypoint xsi:type="dc:Point" x="715" y="326" />
+ <di:waypoint x="715" y="246" />
+ <di:waypoint x="715" y="326" />
<bpmndi:BPMNLabel>
<dc:Bounds x="846" y="291.5" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1ig2ix4_di" bpmnElement="SequenceFlow_1ig2ix4">
- <di:waypoint xsi:type="dc:Point" x="613" y="106" />
- <di:waypoint xsi:type="dc:Point" x="691" y="106" />
+ <di:waypoint x="613" y="106" />
+ <di:waypoint x="691" y="106" />
<bpmndi:BPMNLabel>
<dc:Bounds x="652" y="85" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1g7zahc_di" bpmnElement="NoHelm">
- <di:waypoint xsi:type="dc:Point" x="740" y="106" />
- <di:waypoint xsi:type="dc:Point" x="794" y="106" />
+ <di:waypoint x="740" y="106" />
+ <di:waypoint x="794" y="106" />
<bpmndi:BPMNLabel>
<dc:Bounds x="767" y="85" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0dehck5_di" bpmnElement="SequenceFlow_0dehck5">
- <di:waypoint xsi:type="dc:Point" x="894" y="106" />
- <di:waypoint xsi:type="dc:Point" x="959" y="106" />
+ <di:waypoint x="894" y="106" />
+ <di:waypoint x="959" y="106" />
<bpmndi:BPMNLabel>
<dc:Bounds x="926.5" y="85" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0uetprw_di" bpmnElement="SequenceFlow_0uetprw">
- <di:waypoint xsi:type="dc:Point" x="1009" y="146" />
- <di:waypoint xsi:type="dc:Point" x="1009" y="366" />
- <di:waypoint xsi:type="dc:Point" x="765" y="366" />
+ <di:waypoint x="1009" y="146" />
+ <di:waypoint x="1009" y="366" />
+ <di:waypoint x="765" y="366" />
<bpmndi:BPMNLabel>
<dc:Bounds x="1024" y="228" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="Activity_10eqhmz_di" bpmnElement="Activity_10eqhmz" isExpanded="true">
+ <dc:Bounds x="240" y="590" width="340" height="180" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_108oetk_di" bpmnElement="Event_108oetk">
+ <dc:Bounds x="512" y="662" width="36" height="36" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_1pengt4_di" bpmnElement="Event_1pengt4">
+ <dc:Bounds x="280" y="662" width="36" height="36" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_1p8hxyt_di" bpmnElement="Activity_1p8hxyt">
+ <dc:Bounds x="360" y="640" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="Flow_1sqy91r_di" bpmnElement="Flow_1sqy91r">
+ <di:waypoint x="316" y="680" />
+ <di:waypoint x="360" y="680" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_03q6ty9_di" bpmnElement="Flow_03q6ty9">
+ <di:waypoint x="460" y="680" />
+ <di:waypoint x="512" y="680" />
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeleteVfModuleBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeleteVfModuleBB.bpmn
index 9a33a3e4bf..fba1139117 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeleteVfModuleBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeleteVfModuleBB.bpmn
@@ -31,17 +31,6 @@
<bpmn:incoming>SequenceFlow_08tvhtf</bpmn:incoming>
<bpmn:outgoing>Flow_0hlvlw2</bpmn:outgoing>
</bpmn:callActivity>
- <bpmn:subProcess id="SubProcess_11p7mrh" name="Error Handling&#10;&#10;" triggeredByEvent="true">
- <bpmn:startEvent id="StartEvent_1xp6ewt">
- <bpmn:outgoing>SequenceFlow_0h607z0</bpmn:outgoing>
- <bpmn:errorEventDefinition />
- </bpmn:startEvent>
- <bpmn:endEvent id="EndEvent_0guhjau">
- <bpmn:incoming>SequenceFlow_0h607z0</bpmn:incoming>
- <bpmn:terminateEventDefinition />
- </bpmn:endEvent>
- <bpmn:sequenceFlow id="SequenceFlow_0h607z0" sourceRef="StartEvent_1xp6ewt" targetRef="EndEvent_0guhjau" />
- </bpmn:subProcess>
<bpmn:serviceTask id="UpdateVfModuleHeatStackId" name="&#10;AAI&#10;Update&#10; (vf module)&#10;" camunda:expression="${AAIUpdateTasks.updateHeatStackIdVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0yuz21z</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_01vfwtp</bpmn:outgoing>
@@ -89,9 +78,25 @@
<bpmn:sequenceFlow id="Flow_0plbl7p" sourceRef="ServiceTask_0itw3by" targetRef="aaiThrow" />
<bpmn:sequenceFlow id="Flow_0hlvlw2" sourceRef="VnfAdapter" targetRef="ServiceTask_08ulmzc" />
<bpmn:sequenceFlow id="Flow_02lmh6f" sourceRef="DeleteVfModuleBB_Start" targetRef="DeleteVfModuleVnfAdapter" />
+ <bpmn:subProcess id="Activity_1thbmzc" name="Inventory Error Handling" triggeredByEvent="true">
+ <bpmn:endEvent id="Event_00dlrto">
+ <bpmn:incoming>Flow_0yqo5xu</bpmn:incoming>
+ </bpmn:endEvent>
+ <bpmn:startEvent id="Event_0dfwcfl">
+ <bpmn:outgoing>Flow_0qyhv7c</bpmn:outgoing>
+ <bpmn:errorEventDefinition id="ErrorEventDefinition_1p6vsj6" errorRef="Error_1le3oui" />
+ </bpmn:startEvent>
+ <bpmn:serviceTask id="Activity_025387k" name="Process Error" camunda:expression="${ExceptionBuilder.processInventoryException(execution)}">
+ <bpmn:incoming>Flow_0qyhv7c</bpmn:incoming>
+ <bpmn:outgoing>Flow_0yqo5xu</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:sequenceFlow id="Flow_0qyhv7c" sourceRef="Event_0dfwcfl" targetRef="Activity_025387k" />
+ <bpmn:sequenceFlow id="Flow_0yqo5xu" sourceRef="Activity_025387k" targetRef="Event_00dlrto" />
+ </bpmn:subProcess>
</bpmn:process>
<bpmn:error id="Error_0jjnve8" name="Error_3k24na6" errorCode="AAIInventoryFailure" />
<bpmn:escalation id="Escalation_130je8j" name="audit" escalationCode="audit1" />
+ <bpmn:error id="Error_1le3oui" name="AAIInventoryFailure" errorCode="AAIInventoryFailure" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DeleteVfModuleBB">
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="DeleteVfModuleBB_Start">
@@ -122,28 +127,6 @@
<bpmndi:BPMNShape id="CallActivity_0whogn3_di" bpmnElement="VnfAdapter">
<dc:Bounds x="435" y="84" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="SubProcess_11p7mrh_di" bpmnElement="SubProcess_11p7mrh" isExpanded="true">
- <dc:Bounds x="304" y="500" width="231" height="135" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="StartEvent_1xp6ewt_di" bpmnElement="StartEvent_1xp6ewt">
- <dc:Bounds x="347" y="562" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="261" y="976" width="90" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="EndEvent_0guhjau_di" bpmnElement="EndEvent_0guhjau">
- <dc:Bounds x="476" y="562" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="390" y="976" width="90" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_0h607z0_di" bpmnElement="SequenceFlow_0h607z0">
- <di:waypoint x="383" y="580" />
- <di:waypoint x="476" y="580" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="371" y="937" width="90" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_0vlgqod_di" bpmnElement="UpdateVfModuleHeatStackId">
<dc:Bounds x="800" y="308" width="100" height="80" />
</bpmndi:BPMNShape>
@@ -239,6 +222,26 @@
<di:waypoint x="195" y="124" />
<di:waypoint x="290" y="124" />
</bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="Activity_1thbmzc_di" bpmnElement="Activity_1thbmzc" isExpanded="true">
+ <dc:Bounds x="280" y="490" width="340" height="180" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_00dlrto_di" bpmnElement="Event_00dlrto">
+ <dc:Bounds x="552" y="562" width="36" height="36" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_0dfwcfl_di" bpmnElement="Event_0dfwcfl">
+ <dc:Bounds x="320" y="562" width="36" height="36" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_025387k_di" bpmnElement="Activity_025387k">
+ <dc:Bounds x="400" y="540" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="Flow_0qyhv7c_di" bpmnElement="Flow_0qyhv7c">
+ <di:waypoint x="356" y="580" />
+ <di:waypoint x="400" y="580" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0yqo5xu_di" bpmnElement="Flow_0yqo5xu">
+ <di:waypoint x="500" y="580" />
+ <di:waypoint x="552" y="580" />
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSliceService.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSliceService.groovy
index 5f0d412de0..70acadf0d8 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSliceService.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSliceService.groovy
@@ -349,7 +349,7 @@ public class CreateSliceService extends AbstractServiceTaskProcessor {
TemplateInfo nstInfo = new TemplateInfo()
nstInfo.setUUID(nstSolution.get("UUID") as String)
nstInfo.setInvariantUUID(nstSolution.get("invariantUUID") as String)
- nstInfo.setName(nstSolution.get("name") as String)
+ nstInfo.setName(nstSolution.get("NSTName") as String)
sliceTaskParams.setNSTInfo(nstInfo)
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSIandNSSI.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSIandNSSI.groovy
index d0c189cb04..1c4bbdcd26 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSIandNSSI.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSIandNSSI.groovy
@@ -41,7 +41,6 @@ import org.onap.so.beans.nsmf.CnSliceProfile
import org.onap.so.beans.nsmf.EsrInfo
import org.onap.so.beans.nsmf.NssiResponse
import org.onap.so.beans.nsmf.NssmfAdapterNBIRequest
-import org.onap.so.beans.nsmf.ResponseDescriptor
import org.onap.so.beans.nsmf.ServiceInfo
import org.onap.so.beans.nsmf.SliceTaskInfo
import org.onap.so.beans.nsmf.SliceTaskParamsAdapter
@@ -157,6 +156,7 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
logger.info(msg)
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
}
+ execution.setVariable("sliceTaskParams", sliceParams)
logger.debug("Exit CreateNSIinAAI in DoAllocateNSIandNSSI()")
}
@@ -201,8 +201,7 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
try {
AAIResultWrapper wrapper = client.get(nsiServiceUri, NotFoundException.class)
Optional<ServiceInstance> si = wrapper.asBean(ServiceInstance.class)
- //todo: if exists
- if (!si.ifPresent()) {
+ if (!si.isPresent()) {
String msg = "NSI suggested in the option doesn't exist. " + nsiServiceInstanceID
logger.debug(msg)
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
@@ -251,15 +250,13 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
rspi.setOrchestrationStatus(oStatus)
rspi.setModelInvariantId(sliceTaskInfo.NSSTInfo.invariantUUID)
rspi.setModelVersionId(sliceTaskInfo.NSSTInfo.UUID)
- rspi.setInputParameters(uuiRequest)
- rspi.setWorkloadContext(useInterval)
- rspi.setEnvironmentContext(sNSSAI_id)
+ rspi.setInputParameters(execution.getVariable("uuiRequest"))
+ rspi.setWorkloadContext(execution.getVariable("useInterval"))
+ rspi.setEnvironmentContext(execution.getVariable("sNSSAI_id"))
//timestamp format YYYY-MM-DD hh:mm:ss
rspi.setCreatedAt(new Date(System.currentTimeMillis()).format("yyyy-MM-dd HH:mm:ss", TimeZone.getDefault()))
- execution.setVariable("communicationServiceInstance", rspi)
-
AAIResourceUri uri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(globalSubscriberId).serviceSubscription(subscriptionServiceType).serviceInstance(serviceInstanceId))
client.create(uri, rspi)
@@ -312,11 +309,7 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
NssmfAdapterNBIRequest nbiRequest = new NssmfAdapterNBIRequest()
AllocateAnNssi allocateAnNssi = new AllocateAnNssi()
- allocateAnNssi.nsstId = sliceTaskInfo.NSSTInfo.UUID
- allocateAnNssi.nssiId = sliceTaskInfo.NSSTInfo.UUID
- allocateAnNssi.nssiName = sliceTaskInfo.NSSTInfo.name
allocateAnNssi.sliceProfile = sliceTaskInfo.sliceProfile
- allocateAnNssi.nsiInfo.nsiId = sliceParams.suggestNsiId
EsrInfo esrInfo = new EsrInfo()
//todo: vendor and network
@@ -339,7 +332,7 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
nbiRequest.setAllocateAnNssi(allocateAnNssi)
execution.setVariable("AnAllocateNssiNbiRequest", nbiRequest)
- execution.setVariable("anBHSliceTaskInfo", sliceTaskInfo)
+ execution.setVariable("anSliceTaskInfo", sliceTaskInfo)
execution.setVariable("anSubnetType", SubnetType.AN_NF)
}
@@ -592,7 +585,7 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
SliceTaskParamsAdapter sliceParams =
execution.getVariable("sliceTaskParams") as SliceTaskParamsAdapter
- ResponseDescriptor result = execution.getVariable("anNssiAllocateResult") as ResponseDescriptor
+ NssiResponse result = execution.getVariable("anNssiAllocateResult") as NssiResponse
String nssiId = result.getNssiId()
String nsiId = sliceParams.getSuggestNsiId()
String sliceProfileInstanceId = sliceParams.anSliceTaskInfo.sliceInstanceId
@@ -660,23 +653,25 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
execution.getVariable("sliceTaskParams") as SliceTaskParamsAdapter
//sliceParams.setServiceId(nsiServiceInstanceID)
- AAIResourceUri nsiServiceUri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(globalSubscriberId).serviceSubscription(subscriptionServiceType).serviceInstance(nssiId))
+ AAIResourceUri nsiServiceUri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(execution.getVariable("globalSubscriberId")).serviceSubscription(execution.getVariable("subscriptionServiceType")).serviceInstance(nssiId))
String endpointId = null
try {
AAIResultWrapper wrapper = client.get(nsiServiceUri, NotFoundException.class)
Optional<ServiceInstance> si = wrapper.asBean(ServiceInstance.class)
- //todo: if exists
- if (!si.ifPresent()) {
+ if (!si.isPresent()) {
String msg = "NSSI in the option doesn't exist. " + nssiId
logger.debug(msg)
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
- }
-
- if (si.ifPresent()) {
+ } else {
ServiceInstance nssiInstance = si.get()
//todo: handle relationship and return endpointId
+ if (nssiInstance.relationshipList == null) {
+ String msg = "relationshipList of " + nssiId + " is null"
+ logger.debug(msg)
+ return null
+ }
for (Relationship relationship : nssiInstance.relationshipList.getRelationship()) {
if (relationship.relationshipLabel){
endpointId = relationship //todo
@@ -689,7 +684,7 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
}catch(BpmnError e) {
throw e
}catch (Exception ex){
- String msg = "NSSI suggested in the option doesn't exist. " + nssiId
+ String msg = "Exception: " + ex
logger.debug(msg)
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
}
@@ -735,14 +730,14 @@ class DoAllocateNSIandNSSI extends AbstractServiceTaskProcessor{
//relation ship
Relationship relationship = new Relationship()
- AAIResourceUri nsiServiceUri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(execution.getVariable("globalSubscriberId")).serviceSubscription(execution.getVariable("subscriptionServiceType")).serviceInstance(targetId))
+ AAIResourceUri targetInstanceUri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(execution.getVariable("globalSubscriberId")).serviceSubscription(execution.getVariable("subscriptionServiceType")).serviceInstance(targetId))
- logger.info("Creating Allotted resource relationship, nsiServiceUri: " + nsiServiceUri)
+ logger.info("Creating relationship, targetInstanceUri: " + targetInstanceUri)
- relationship.setRelatedLink(nsiServiceUri.build().toString())
+ relationship.setRelatedLink(targetInstanceUri.build().toString())
- AAIResourceUri uri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(execution.getVariable("globalSubscriberId")).serviceSubscription(execution.getVariable("subscriptionServiceType")).serviceInstance(sourceId).relationshipAPI())
- client.create(uri, relationship)
+ AAIResourceUri sourceInstanceUri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(execution.getVariable("globalSubscriberId")).serviceSubscription(execution.getVariable("subscriptionServiceType")).serviceInstance(sourceId)).relationshipAPI()
+ client.create(sourceInstanceUri, relationship)
}
}
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSSI.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSSI.groovy
index 3e834fa7bb..896d7ff4b1 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSSI.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoAllocateNSSI.groovy
@@ -139,7 +139,7 @@ class DoAllocateNSSI extends AbstractServiceTaskProcessor {
case SubnetType.CN:
sliceTaskParams.cnSliceTaskInfo = sliceTaskInfo
break
- case SubnetType.AN_NF:
+ case SubnetType.AN:
sliceTaskParams.anSliceTaskInfo = sliceTaskInfo
break
case SubnetType.TN_BH:
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateSliceServiceOption.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateSliceServiceOption.groovy
index cfdbe98c34..bc4060e10d 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateSliceServiceOption.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateSliceServiceOption.groovy
@@ -44,6 +44,7 @@ import org.onap.so.bpmn.core.json.JsonUtils
import org.slf4j.Logger
import org.slf4j.LoggerFactory
import org.springframework.http.ResponseEntity
+import org.springframework.util.StringUtils
class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
@@ -139,7 +140,6 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
* @param execution
*/
public void processDecompositionNSST(DelegateExecution execution) {
-
List<ServiceDecomposition> nsstServiceDecompositions =
execution.getVariable("nsstServiceDecompositions") as List<ServiceDecomposition>
@@ -153,6 +153,9 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
int num = execution.getVariable("maxNsstIndex") as Integer
int index = execution.getVariable("currentNsstIndex") as Integer
+ List<TemplateInfo> nsstInfos = execution.getVariable("nsstInfos") as List<TemplateInfo>
+ nsstInfos.get(index).name = nsstServiceDecomposition.modelInfo.modelName
+ execution.setVariable("nsstInfos", nsstInfos)
execution.setVariable("currentNsstIndex", index + 1)
if (index >= num) {
@@ -178,17 +181,16 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
List<SubnetCapability> subnetCapabilities = new ArrayList<>()
for (ServiceDecomposition serviceDecomposition : nsstServiceDecompositions) {
- SubnetCapability subnetCapability = new SubnetCapability()
- handleByType(execution, serviceDecomposition, sliceParams, subnetCapability)
- subnetCapabilities.add(subnetCapability)
+ handleByType(execution, serviceDecomposition, sliceParams, subnetCapabilities)
}
execution.setVariable("sliceTaskParams", sliceParams)
execution.setVariable("subnetCapabilities", subnetCapabilities)
+ logger.debug("sliceTaskParams= " + sliceParams.toString())
}
private void handleByType(DelegateExecution execution, ServiceDecomposition serviceDecomposition,
- SliceTaskParamsAdapter sliceParams, SubnetCapability subnetCapability) {
+ SliceTaskParamsAdapter sliceParams, List<SubnetCapability> subnetCapabilities) {
ModelInfo modelInfo = serviceDecomposition.getModelInfo()
String vendor = serviceDecomposition.getServiceRole()
SubnetType subnetType = convertServiceCategory(serviceDecomposition.getServiceCategory())
@@ -210,7 +212,7 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
sliceParams.tnMHSliceTaskInfo.NSSTInfo.invariantUUID = modelInfo.getModelInvariantUuid()
sliceParams.tnMHSliceTaskInfo.NSSTInfo.name = modelInfo.getModelName()
break
- case SubnetType.AN_NF:
+ case SubnetType.AN:
sliceParams.anSliceTaskInfo.vendor = vendor
sliceParams.anSliceTaskInfo.subnetType = subnetType
sliceParams.anSliceTaskInfo.networkType = subnetType.networkType
@@ -236,12 +238,14 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
}
String response = querySubnetCapability(execution, vendor, subnetType)
- ResponseEntity responseEntity = objectMapper.readValue(response, ResponseEntity.class)
-
- Map<String, Object> result = responseEntity.getBody() as Map
- for (Map.Entry<String, Object> entry : result.entrySet()) {
- subnetCapability.setDomainType(entry.getKey())
- subnetCapability.setCapabilityDetails(entry.getValue())
+ if (!StringUtils.isEmpty(response)) {
+ SubnetCapability subnetCapability = new SubnetCapability()
+ Map<String, Object> result = objectMapper.readValue(response, Map.class)
+ for (Map.Entry<String, Object> entry : result.entrySet()) {
+ subnetCapability.setDomainType(entry.getKey())
+ subnetCapability.setCapabilityDetails(entry.getValue())
+ }
+ subnetCapabilities.add(subnetCapability)
}
}
@@ -254,7 +258,7 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
return SubnetType.CN
}
if (serviceCategory ==~ /AN.*NF.*/){
- return SubnetType.AN_NF
+ return SubnetType.AN
}
if (serviceCategory ==~ /TN.*BH.*/){
return SubnetType.TN_BH
@@ -271,9 +275,8 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
*/
private String querySubnetCapability(DelegateExecution execution, String vendor, SubnetType subnetType) {
- String strRequest = objectMapper.writeValueAsString(buildQuerySubnetCapRequest(vendor, subnetType))
-
- String response = nssmfAdapterUtils.sendPostRequestNSSMF(execution, QUERY_SUB_NET_CAPABILITY, strRequest)
+ String response = nssmfAdapterUtils.sendPostRequestNSSMF(execution, QUERY_SUB_NET_CAPABILITY,
+ buildQuerySubnetCapRequest(vendor, subnetType))
return response
}
@@ -284,24 +287,24 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
* @param networkType
* @return
*/
- private static String buildQuerySubnetCapRequest(String vendor, SubnetType subnetType) {
+ private static NssmfAdapterNBIRequest buildQuerySubnetCapRequest(String vendor, SubnetType subnetType) {
NssmfAdapterNBIRequest request = new NssmfAdapterNBIRequest()
-// List<String> subnetTypes = new ArrayList<>()
-// subnetTypes.add(subnetType.subnetType)
- Map<String, Object> paramMap = new HashMap()
- paramMap.put("subnetType", subnetType.subnetType)
+ List<String> subnetTypes = new ArrayList<>()
+
+ subnetTypes.add(subnetType.subnetType)
+
+ Map<String, Object> paramMap = new HashMap<>()
+ paramMap.put("subnetTypes", subnetTypes)
- request.setSubnetCapabilityQuery(objectMapper.writeValueAsString(paramMap))
+ request.setSubnetCapabilityQuery(paramMap)
EsrInfo esrInfo = new EsrInfo()
esrInfo.setVendor(vendor)
esrInfo.setNetworkType(subnetType.networkType)
request.setEsrInfo(esrInfo)
- String strRequest = objectMapper.writeValueAsString(request)
-
- return strRequest
+ return request
}
/**
@@ -336,7 +339,7 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
execution.getVariable("subnetCapabilities") as List<SubnetCapability>
String oofRequest = oofUtils.buildSelectNSIRequest(requestId, nstInfo, nsstInfos,
- messageType, profileInfo, subnetCapabilities, timeout as Integer, preferReuse)
+ messageType, profileInfo, subnetCapabilities, 600, preferReuse)
execution.setVariable("nsiSelection_oofRequest", oofRequest)
logger.debug("Sending request to OOF: " + oofRequest)
@@ -358,7 +361,13 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
//This needs to be changed to derive a value when we add policy to decide the solution options.
Map<String, Object> resMap = objectMapper.readValue(oofResponse, Map.class)
+ String requestStatus = resMap.get("requestStatus")
+ if (StringUtils.isEmpty(requestStatus)) {
+ exceptionUtil.buildWorkflowException(execution, 7000, "get nsi from oof error: " + oofResponse)
+ }
+
List<Map<String, Object>> nsiSolutions = (List<Map<String, Object>>) resMap.get("solutions")
+
Map<String, Object> solution = nsiSolutions.get(0)
String resourceSharingLevel = execution.getVariable("resourceSharingLevel")
@@ -378,7 +387,6 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
}
}
execution.setVariable("sliceTaskParams", sliceTaskParams)
- //logger.debug("sliceTaskParams: " + sliceTaskParams.convertToJson())
logger.debug("*** Completed options Call to OOF ***")
}
@@ -402,6 +410,7 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
sliceParams.tnBHSliceTaskInfo.sliceProfile = sliceProfile as TnSliceProfile
break
case "an-nf":
+ case "an":
sliceParams.anSliceTaskInfo.sliceProfile = sliceProfile as AnSliceProfile
break
case "cn":
@@ -602,7 +611,7 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
execution.setVariable("nssiSelection_timeout", timeout)
String oofRequest = oofUtils.buildSelectNSSIRequest(requestId, nsstInfo, messageType,
- profileInfo, timeout as Integer)
+ profileInfo, 600)
execution.setVariable("nssiSelection_oofRequest", oofRequest)
logger.debug("Sending request to OOF: " + oofRequest)
@@ -665,7 +674,7 @@ class DoCreateSliceServiceOption extends AbstractServiceTaskProcessor{
sliceTaskParams.cnSliceTaskInfo.suggestNssiId = solution.get("NSSIId")
sliceTaskParams.cnSliceTaskInfo.suggestNssiName = solution.get("NSSIName")
break
- case SubnetType.AN_NF:
+ case SubnetType.AN:
sliceTaskParams.anSliceTaskInfo.suggestNssiId = solution.get("NSSIId")
sliceTaskParams.anSliceTaskInfo.suggestNssiName = solution.get("NSSIName")
break
diff --git a/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java b/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java
index 71c50c1684..9b6406d57f 100644
--- a/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java
+++ b/common/src/main/java/org/onap/so/beans/nsmf/SliceTaskInfo.java
@@ -40,7 +40,7 @@ public class SliceTaskInfo<T> implements Serializable {
private T sliceProfile;
- private TemplateInfo NSSTInfo;
+ private TemplateInfo NSSTInfo = new TemplateInfo();
private String sliceInstanceId;
diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java
index 292a0d5ae4..ee3d8aecf8 100644
--- a/common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java
+++ b/common/src/main/java/org/onap/so/beans/nsmf/oof/RequestInfo.java
@@ -40,7 +40,7 @@ public class RequestInfo implements Serializable {
private Integer numSolutions;
- private Integer timeout;
+ private Object timeout;
private Map<?, ?> addtnlArgs;
}
diff --git a/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetType.java b/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetType.java
index 4b0136a798..536bb04fce 100644
--- a/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetType.java
+++ b/common/src/main/java/org/onap/so/beans/nsmf/oof/SubnetType.java
@@ -26,15 +26,13 @@ import org.onap.so.beans.nsmf.NetworkType;
public enum SubnetType {
AN("AN", NetworkType.ACCESS),
- AN_NF("AN-NF", NetworkType.ACCESS),
-
CN("CN", NetworkType.CORE),
- TN_FH("TN-FH", NetworkType.TRANSPORT),
+ TN_FH("TN_FH", NetworkType.TRANSPORT),
- TN_MH("TN-MH", NetworkType.TRANSPORT),
+ TN_MH("TN_MH", NetworkType.TRANSPORT),
- TN_BH("TN-BH", NetworkType.TRANSPORT),;
+ TN_BH("TN_BH", NetworkType.TRANSPORT),;
private NetworkType networkType;
diff --git a/common/src/main/java/org/onap/so/utils/ExternalTaskServiceUtils.java b/common/src/main/java/org/onap/so/utils/ExternalTaskServiceUtils.java
index c601b88ae5..1a8307e8bc 100644
--- a/common/src/main/java/org/onap/so/utils/ExternalTaskServiceUtils.java
+++ b/common/src/main/java/org/onap/so/utils/ExternalTaskServiceUtils.java
@@ -64,16 +64,6 @@ public class ExternalTaskServiceUtils {
return Integer.parseInt(env.getProperty("workflow.topics.maxClients", "10"));
}
- public Long getLockDuration() {
- Long lockDuration = Long.parseLong(env.getProperty("mso.audit.lock-time", "60000"));
- return lockDuration;
- }
-
- public Long getLongLockDuration() {
- Long lockDuration = Long.parseLong(env.getProperty("mso.long.lock-time", "600000"));
- return lockDuration;
- }
-
@ScheduledLogging
@Scheduled(fixedDelay = 30000)
public void checkAllClientsActive() {
diff --git a/docs/developer_info/Working_with_so_monitoring.rst b/docs/developer_info/Working_with_so_monitoring.rst
index 18b6d948c0..697f2c0141 100644
--- a/docs/developer_info/Working_with_so_monitoring.rst
+++ b/docs/developer_info/Working_with_so_monitoring.rst
@@ -1,28 +1,24 @@
.. This work is licensed under a Creative Commons Attribution 4.0 International License.
.. http://creativecommons.org/licenses/by/4.0
.. Copyright 2017 Huawei Technologies Co., Ltd.
+.. Modifications Copyright (c) 2020 Nokia
Working with SO Monitoring
==========================
-After the SO code is fully deployed, certain changes needs to be made in order to access the so-monitoring ui.
+Starting from Guilin release SO Monitoring uses https and NodePort service during communication with operator.
+Certificates used for communication are generated automatically using AAF and certInitializer, when SO Monitoring
+is deployed using OOM. For that reason, no additional tasks are needed in order to access the SO Monitoring ui,
+when the SO is fully deployed.
-1. Change the service type to NodePort
----------------------------------------
-
-By default, the type of the so monitoring service is ClusterIP, which makes the Service only reachable from within the cluster.
-This is changed to NodePort, which is used to expose the service at a static port . Hence we will be able to contact the NodePort Service, from outside the cluster, by requesting <NodeIP>:<NodePort>.
-
-Command used to get the service configuration of so monitoring is:
-
-**sudo kubectl edit svc so-monitoring -n onap**
+SO Monitoring contains also pre-installed certs which can be used in local development environment. **They are
+for development purpose only!**
-.. image:: ../images/nodeport.png
-
-2. Add the credentials to login
---------------------------------
+1. Credentials to login and initial setup
+---------------------------------------------
-The override.yaml needs to be added with the login credentials, that is the username and the password in encrypted form.
+Defalut credentials and certs of SO Monitoring, if you want to develop SO Monitoring out of ONAP cluster,
+are stored in the app. Credentials are as follows:
.. code-block:: bash
@@ -32,39 +28,109 @@ The override.yaml needs to be added with the login credentials, that is the user
security:
usercredentials:
-
- username: gui
- password: '$2a$10$Fh9ffgPw2vnmsghsRD3ZauBL1aKXebigbq3BB1RPWtE62UDILsjke'
+ username: demo
+ password: '$2a$10$ndkDhATUid4a3g0JJVRv2esX4rtB.vzCn7iBhKyR1qZ/wDdvNzjTS'
role: GUI-Client
-This override.yaml can be directly edited in case of local setup using docker.
+Username - demo. Password (**demo123456!**) is bcrypted.
+
-When deploying in any environment using OOM, then after deployment the configmap needs to be edited. As configmap is the one reading the override.yaml.
+This setup is overridden by the override.yaml file which is stored in the OOM project.
+Override.yaml file can be edited directly in case of local ONAP setup. This file is loaded into
+container through configmap.
-**Note** : Before deployment , if we add these changes in override.yaml ,then it may give parsing error in configmap while deployment. And after deployment the permissions on override.yaml don't allow us to edit it. So the best option is to edit the configmap using the below command and restart the pod.
+**Note** : If you want to change config stored in override.yaml on working deployment, you have to edit k8s
+configmap. Due to insufficient permissions it is not possible directly in the container. After that pod have
+to be restarted.
**kubectl -n onap edit configmap dev-so-monitoring-app-configmap**
.. image:: ../images/configmap.png
-Special care needs to be given to the indentation. spring needs to be inline with the mso already present and others added accordingly.
+Special care needs to be given to the indentation. Spring needs to be inline with the mso already present and others
+added accordingly.
+
+**Attention! The default setup of the OOM makes SO Monitoring password is being automatically generated during ONAP
+deployment and injected through k8s secret**
+
+
+2. Setup, retrieve and edit default SO Monitoring password
+----------------------------------------------------------
+
+Automatic generation of password for SO Monitoring during ONAP deployment can be overriden. In result, password
+can be set up manually. Such case requires to edit ONAP config file, template of which is stored in
+**oom/kubernetes/onap/values.yaml** file.
+
+.. image:: ../images/so-monitoring-config.png
+
+Following lines presented in fig. has to be uncommented.
+
+If customized file is used, following code has to be paste under the SO config (be aware of indentation):
+
+.. code-block:: bash
+
+ so:
+ ...
+ so-monitoring:
+ server:
+ monitoring:
+ password: demo123456!
+ ...
+
+Alternative way (**not recommended**) is to add password entry in the **oom/kubernetes/so/components/so-monitoring/values.yaml**
+
+.. code-block:: bash
+
+ ...
+ server:
+ monitoring:
+ password: demo123456!
+ ...
+
+To retrieve actual password for SO Monitoring on existing ONAP install, run the following command:
+
+**kubectl get secret -n onap dev-so-monitoring-app-user-creds -o json | jq -r .data.password | base64 --decode**
+
+.. image:: ../images/so-monitoring-password.png
+
+To change actual password on existing ONAP install, **dev-so-monitoring-app-user-creds** secret has to be modified.
+
+**kubectl edit secret -n onap dev-so-monitoring-app-user-creds**
+
+.. image:: ../images/so-monitoring-secret.png
+
+Edit password entry, which has to be given in base64 form. Base64 form of password can be obtained by running:
+
+**echo 'YOUR_PASSWORD' | base64**
+
+.. image:: ../images/so-monitorring-base64-password.png
+
+Once, password was edited, pod has to be restarted.
+
3. Login to SO Monitoring
-------------------------
-We need to first identify the external port which its mapped to using the following command :
+Identify the external port which is mapped to SO Monitoring using the following command. The default port is 30224 :
**sudo kubectl -n onap get svc | grep so-monitoring**
.. image:: ../images/nodemap.png
-Then access the UI of so monitoring , for example by http://<IP>:30224/
+Then access the UI of SO Monitoring, for example by https://<IP>:30224/
-username : gui,
-password: password1$
+.. image:: ../images/ui.png
+4. Hiding the SO Monitoring service (ClusterIP)
+---------------------------------------
-.. image:: ../images/ui.png
+The SO Monitoring service is set to the NodePort type. It is used to expose the service at a static port.
+Hence there is possibility to contact the NodePort Service, from outside cluster, by requesting <NodeIP>:<NodePort>.
+In order to make the service only reachable from within the cluster, ClusterIP service has to be set.
+Command used to edit the service configuration of SO Monitoring is:
+**sudo kubectl edit svc so-monitoring -n onap**
+.. image:: ../images/nodeport.png
diff --git a/docs/images/configmap.png b/docs/images/configmap.png
index 3683de3d57..c662e1f18a 100644
--- a/docs/images/configmap.png
+++ b/docs/images/configmap.png
Binary files differ
diff --git a/docs/images/nodemap.png b/docs/images/nodemap.png
index 8dfda6ca12..afe1ebffdd 100644
--- a/docs/images/nodemap.png
+++ b/docs/images/nodemap.png
Binary files differ
diff --git a/docs/images/nodeport.png b/docs/images/nodeport.png
index 53bc02f7f9..d44ea76cdf 100644
--- a/docs/images/nodeport.png
+++ b/docs/images/nodeport.png
Binary files differ
diff --git a/docs/images/so-monitoring-config.png b/docs/images/so-monitoring-config.png
new file mode 100644
index 0000000000..74c2aebf2b
--- /dev/null
+++ b/docs/images/so-monitoring-config.png
Binary files differ
diff --git a/docs/images/so-monitoring-password.png b/docs/images/so-monitoring-password.png
new file mode 100644
index 0000000000..89647c7686
--- /dev/null
+++ b/docs/images/so-monitoring-password.png
Binary files differ
diff --git a/docs/images/so-monitoring-secret.png b/docs/images/so-monitoring-secret.png
new file mode 100644
index 0000000000..cacf707eed
--- /dev/null
+++ b/docs/images/so-monitoring-secret.png
Binary files differ
diff --git a/docs/images/so-monitorring-base64-password.png b/docs/images/so-monitorring-base64-password.png
new file mode 100644
index 0000000000..e57db59783
--- /dev/null
+++ b/docs/images/so-monitorring-base64-password.png
Binary files differ
diff --git a/docs/images/ui.png b/docs/images/ui.png
index 1c075bab22..66382b6300 100644
--- a/docs/images/ui.png
+++ b/docs/images/ui.png
Binary files differ
diff --git a/so-monitoring/so-monitoring-service/src/main/resources/application.yaml b/so-monitoring/so-monitoring-service/src/main/resources/application.yaml
index ef0b6aa786..c57d79c75b 100644
--- a/so-monitoring/so-monitoring-service/src/main/resources/application.yaml
+++ b/so-monitoring/so-monitoring-service/src/main/resources/application.yaml
@@ -26,6 +26,6 @@ spring:
security:
usercredentials:
-
- username: gui
+ username: demo
password: '$2a$10$ndkDhATUid4a3g0JJVRv2esX4rtB.vzCn7iBhKyR1qZ/wDdvNzjTS'
role: GUI-Client