import org.codehaus.jackson.map.JsonMappingException;
import org.codehaus.jackson.map.ObjectMapper;
import org.codehaus.jackson.map.annotate.JsonRootName;
-
+import org.openecomp.mso.logger.MessageEnum;
import org.openecomp.mso.logger.MsoLogger;
+import org.openecomp.mso.openstack.exceptions.MsoCloudIdentityNotFound;
/**
* JavaBean JSON class for a CloudConfig. This bean maps a JSON-format cloud
* configuration file to Java. The CloudConfig contains information about
- * Openstack cloud configurations (in particular for the NVP/AIC cloud).
- * It includes:
- * - CloudIdentity objects, representing DCP nodes (Openstack Identity Service)
+ * Openstack cloud configurations. It includes:
+ * - CloudIdentity objects,representing DCP nodes (Openstack Identity Service)
* - CloudSite objects, representing LCP nodes (Openstack Compute & other services)
*
- * Note that this is only used to access Cloud Configurations loaded from a
- * JSON config file, so there are no explicit property setters.
+ * Note that this is only used to access Cloud Configurations loaded from a JSON
+ * config file, so there are no explicit property setters.
*
* This class also contains methods to query cloud sites and/or identity
* services by ID.
@JsonRootName("cloud_config")
public class CloudConfig {
+ private boolean validCloudConfig = false;
@JsonProperty("identity_services")
- private Map <String, CloudIdentity> identityServices = new HashMap <String, CloudIdentity> ();
+ private Map<String, CloudIdentity> identityServices = new HashMap<String, CloudIdentity>();
@JsonProperty("cloud_sites")
- private Map <String, CloudSite> cloudSites = new HashMap <String, CloudSite> ();
+ private Map<String, CloudSite> cloudSites = new HashMap<String, CloudSite>();
- private static ObjectMapper mapper = new ObjectMapper ();
+ private static ObjectMapper mapper = new ObjectMapper();
- private static final MsoLogger LOGGER = MsoLogger.getMsoLogger (MsoLogger.Catalog.RA);
+ private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.RA);
- protected String configFilePath;
+ protected String configFilePath;
- protected int refreshTimerInMinutes;
+ protected int refreshTimerInMinutes;
- public CloudConfig () {
- mapper.enable (DeserializationConfig.Feature.UNWRAP_ROOT_VALUE);
- mapper.enable (DeserializationConfig.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY);
+ public CloudConfig() {
+ mapper.enable(DeserializationConfig.Feature.UNWRAP_ROOT_VALUE);
+ mapper.enable(DeserializationConfig.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY);
}
- /**
- * Get a Map of all IdentityServices that have been loaded.
- * @return the Map
- */
- public synchronized Map <String, CloudIdentity> getIdentityServices () {
+ /**
+ * Get a Map of all IdentityServices that have been loaded.
+ *
+ * @return the Map
+ */
+ public synchronized Map<String, CloudIdentity> getIdentityServices() {
return identityServices;
}
- /**
- * Get a Map of all CloudSites that have been loaded.
- * @return the Map
- */
- public synchronized Map <String, CloudSite> getCloudSites () {
- return cloudSites;
- }
-
- /**
- * Get a specific CloudSites, based on an ID. The ID is first checked against
- * the regions, and if no match is found there, then against individual entries
- * to try and find one with a CLLI that matches the ID and an AIC version of 2.5.
- * @param id the ID to match
- * @return a CloudSite, or null of no match found
- */
- public synchronized CloudSite getCloudSite (String id) {
- if (id != null) {
- if (cloudSites.containsKey (id)) {
- return cloudSites.get (id);
- }
- // check for id == CLLI now as well
- return getCloudSiteWithClli(id, "2.5");
- }
- return null;
- }
-
- /**
- * Get a specific CloudSites, based on a CLLI and (optional) version, which will be matched
- * against the aic_version field of the CloudSite.
- * @param clli the CLLI to match
- * @param version the version to match; may be null in which case any version matches
- * @return a CloudSite, or null of no match found
- */
- public synchronized CloudSite getCloudSiteWithClli(String clli, String version) {
- if (clli != null) {
- // New with 1610 - find cloud site called "DEFAULT" - return that object,
- // with the name modified to match what they asked for. We're looping thru
- // the cloud sites anyway - so save off the default one in case we need it.
- CloudSite defaultCloudSite = null;
- for (CloudSite cs : cloudSites.values()) {
- if (cs.getClli() != null && clli.equals(cs.getClli())) {
- if (version == null || version.equals(cs.getAic_version())) {
- return cs;
- }
- } else if (cs.getId().equalsIgnoreCase("default")) {
- // save it off in case we need it
- defaultCloudSite = cs.clone();
- }
- }
- // If we get here - we didn't find a match - so return the default cloud site
+ /**
+ * Get a Map of all CloudSites that have been loaded.
+ *
+ * @return the Map
+ */
+ public synchronized Map<String, CloudSite> getCloudSites() {
+ return cloudSites;
+ }
+
+ /**
+ * Get a specific CloudSites, based on an ID. The ID is first checked
+ * against the regions, and if no match is found there, then against
+ * individual entries to try and find one with a CLLI that matches the ID
+ * and an AIC version of 2.5.
+ *
+ * @param id
+ * the ID to match
+ * @return a CloudSite, or null of no match found
+ */
+ public synchronized CloudSite getCloudSite(String id) {
+ if (id != null) {
+ if (cloudSites.containsKey(id)) {
+ return cloudSites.get(id);
+ }
+ // check for id == CLLI now as well
+ return getCloudSiteWithClli(id, "2.5");
+ }
+ return null;
+ }
+
+ /**
+ * Get a specific CloudSites, based on a CLLI and (optional) version, which
+ * will be matched against the aic_version field of the CloudSite.
+ *
+ * @param clli
+ * the CLLI to match
+ * @param version
+ * the version to match; may be null in which case any version
+ * matches
+ * @return a CloudSite, or null of no match found
+ */
+ public synchronized CloudSite getCloudSiteWithClli(String clli, String version) {
+ if (clli != null) {
+ // New with 1610 - find cloud site called "DEFAULT" - return that
+ // object,with the name modified to match what they asked for. We're
+ // looping thru the cloud sites anyway - so save off the default one in case we
+ // need it.
+ CloudSite defaultCloudSite = null;
+ for (CloudSite cs : cloudSites.values()) {
+ if (cs.getClli() != null && clli.equals(cs.getClli())) {
+ if (version == null || version.equals(cs.getAic_version())) {
+ return cs;
+ }
+ } else if (cs.getId().equalsIgnoreCase("default")) {
+ // save it off in case we need it
+ defaultCloudSite = cs.clone();
+ }
+ }
+ // If we get here - we didn't find a match - so return the default
+ // cloud site
if (defaultCloudSite != null) {
defaultCloudSite.setRegionId(clli);
defaultCloudSite.setId(clli);
}
- return defaultCloudSite;
- }
+ return defaultCloudSite;
+ }
return null;
- }
-
- /**
- * Get a specific CloudIdentity, based on an ID.
- * @param id the ID to match
- * @return a CloudIdentity, or null of no match found
- */
- public synchronized CloudIdentity getIdentityService (String id) {
- if (identityServices.containsKey (id)) {
- return identityServices.get (id);
- }
- return null;
- }
-
- protected synchronized void reloadPropertiesFile() throws JsonParseException, JsonMappingException, IOException {
- this.loadCloudConfig(this.configFilePath, this.refreshTimerInMinutes);
- }
-
- protected synchronized void loadCloudConfig (String configFile, int refreshTimer) throws JsonParseException, JsonMappingException, IOException {
-
- FileReader reader=null;
- configFilePath=configFile;
- this.refreshTimerInMinutes = refreshTimer;
-
- CloudConfig cloudConfig = null;
-
- try {
- reader = new FileReader (configFile);
- // Parse the JSON input into a CloudConfig
-
- cloudConfig = mapper.readValue (reader, CloudConfig.class);
-
- this.cloudSites = cloudConfig.cloudSites;
- this.identityServices = cloudConfig.identityServices;
-
- // Copy Cloud Identity IDs to CloudIdentity objects
- for (Entry <String, CloudIdentity> entry : cloudConfig.getIdentityServices ().entrySet ()) {
- entry.getValue ().setId (entry.getKey ());
- }
-
- // Copy Cloud Site IDs to CloudSite objects, and set up internal
- // pointers to their corresponding identity service.
- for (Entry <String, CloudSite> entry : cloudConfig.getCloudSites ().entrySet ()) {
- CloudSite s = entry.getValue ();
- s.setId (entry.getKey ());
- s.setIdentityService (cloudConfig.getIdentityService (s.getIdentityServiceId ()));
- }
- } finally {
- try {
- if (reader != null) {
- reader.close();
- }
- } catch (IOException e) {
- LOGGER.debug("Exception while closing reader for file:" + configFilePath, e);
- }
- }
}
- public String getConfigFilePath() {
- return configFilePath;
- }
-
- @Override
- public synchronized CloudConfig clone() {
- CloudConfig ccCopy = new CloudConfig();
- for (Entry<String,CloudIdentity> e:identityServices.entrySet()) {
-
- ccCopy.identityServices.put(e.getKey(), e.getValue().clone());
- }
-
- for (Entry<String,CloudSite> e:cloudSites.entrySet()) {
-
- ccCopy.cloudSites.put(e.getKey(), e.getValue().clone());
- }
-
- ccCopy.configFilePath = this.configFilePath;
-
- ccCopy.refreshTimerInMinutes = this.refreshTimerInMinutes;
-
- return ccCopy;
- }
-
- @Override
- public int hashCode() {
- final int prime = 31;
- int result = 1;
- result = prime * result + ((cloudSites == null) ? 0 : cloudSites.hashCode());
- result = prime * result + ((configFilePath == null) ? 0 : configFilePath.hashCode());
- result = prime * result + ((identityServices == null) ? 0 : identityServices.hashCode());
- result = prime * result + refreshTimerInMinutes;
- return result;
- }
-
- @Override
- public boolean equals(Object obj) {
- if (this == obj)
- return true;
- if (obj == null)
- return false;
- if (getClass() != obj.getClass())
- return false;
- CloudConfig other = (CloudConfig) obj;
- if (cloudSites == null) {
- if (other.cloudSites != null)
- return false;
- } else if (!cloudSites.equals(other.cloudSites))
- return false;
- if (configFilePath == null) {
- if (other.configFilePath != null)
- return false;
- } else if (!configFilePath.equals(other.configFilePath))
- return false;
- if (identityServices == null) {
- if (other.identityServices != null)
- return false;
- } else if (!identityServices.equals(other.identityServices))
- return false;
- if (refreshTimerInMinutes != other.refreshTimerInMinutes)
- return false;
- return true;
- }
-}
+ /**
+ * Get a specific CloudIdentity, based on an ID.
+ *
+ * @param id
+ * the ID to match
+ * @return a CloudIdentity, or null of no match found
+ */
+ public synchronized CloudIdentity getIdentityService(String id) {
+ if (identityServices.containsKey(id)) {
+ return identityServices.get(id);
+ }
+ return null;
+ }
+
+ protected synchronized void reloadPropertiesFile() throws JsonParseException, JsonMappingException, IOException, MsoCloudIdentityNotFound {
+ this.loadCloudConfig(this.configFilePath, this.refreshTimerInMinutes);
+ }
+
+ protected synchronized void loadCloudConfig(String configFile, int refreshTimer)
+ throws JsonParseException, JsonMappingException, IOException, MsoCloudIdentityNotFound {
+
+ FileReader reader = null;
+ configFilePath = configFile;
+ this.refreshTimerInMinutes = refreshTimer;
+
+ CloudConfig cloudConfig = null;
+ this.validCloudConfig=false;
+
+ try {
+ reader = new FileReader(configFile);
+ // Parse the JSON input into a CloudConfig
+
+ cloudConfig = mapper.readValue(reader, CloudConfig.class);
+
+ this.cloudSites = cloudConfig.cloudSites;
+ this.identityServices = cloudConfig.identityServices;
+
+ // Copy Cloud Identity IDs to CloudIdentity objects
+ for (Entry<String, CloudIdentity> entry : cloudConfig.getIdentityServices().entrySet()) {
+ entry.getValue().setId(entry.getKey());
+ }
+
+ // Copy Cloud Site IDs to CloudSite objects, and set up internal
+ // pointers to their corresponding identity service.
+ for (Entry<String, CloudSite> entry : cloudConfig.getCloudSites().entrySet()) {
+ CloudSite s = entry.getValue();
+ s.setId(entry.getKey());
+ CloudIdentity cloudIdentity = cloudConfig.getIdentityService(s.getIdentityServiceId());
+ s.setIdentityService(cloudIdentity);
+ if (cloudIdentity == null) {
+ throw new MsoCloudIdentityNotFound(s.getId()+" Cloud site refers to a non-existing identity service: "+s.getIdentityServiceId());
+ }
+ }
+ this.validCloudConfig=true;
+
+ } finally {
+ try {
+ if (reader != null) {
+ reader.close();
+ }
+ } catch (IOException e) {
+ LOGGER.debug("Exception while closing reader for file:" + configFilePath, e);
+ }
+ }
+ }
+
+ public String getConfigFilePath() {
+ return configFilePath;
+ }
+
+ /**
+ * @return the validCouldConfig
+ */
+ public synchronized boolean isValidCloudConfig() {
+ return validCloudConfig;
+ }
+
+ @Override
+ public synchronized CloudConfig clone() {
+ CloudConfig ccCopy = new CloudConfig();
+ for (Entry<String, CloudIdentity> e : identityServices.entrySet()) {
+ ccCopy.identityServices.put(e.getKey(), e.getValue().clone());
+ }
+
+ for (Entry<String, CloudSite> e : cloudSites.entrySet()) {
+
+ ccCopy.cloudSites.put(e.getKey(), e.getValue().clone());
+ }
+ ccCopy.configFilePath = this.configFilePath;
+ ccCopy.refreshTimerInMinutes = this.refreshTimerInMinutes;
+ ccCopy.validCloudConfig = this.validCloudConfig;
+ return ccCopy;
+ }
+
+ /* (non-Javadoc)
+ * @see java.lang.Object#hashCode()
+ */
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((cloudSites == null) ? 0 : cloudSites.hashCode());
+ result = prime * result + ((configFilePath == null) ? 0 : configFilePath.hashCode());
+ result = prime * result + ((identityServices == null) ? 0 : identityServices.hashCode());
+ result = prime * result + refreshTimerInMinutes;
+ result = prime * result + (validCloudConfig ? 1231 : 1237);
+ return result;
+ }
+
+ /* (non-Javadoc)
+ * @see java.lang.Object#equals(java.lang.Object)
+ */
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj)
+ return true;
+ if (obj == null)
+ return false;
+ if (getClass() != obj.getClass())
+ return false;
+ CloudConfig other = (CloudConfig) obj;
+ if (cloudSites == null) {
+ if (other.cloudSites != null)
+ return false;
+ } else if (!cloudSites.equals(other.cloudSites))
+ return false;
+ if (configFilePath == null) {
+ if (other.configFilePath != null)
+ return false;
+ } else if (!configFilePath.equals(other.configFilePath))
+ return false;
+ if (identityServices == null) {
+ if (other.identityServices != null)
+ return false;
+ } else if (!identityServices.equals(other.identityServices))
+ return false;
+ if (refreshTimerInMinutes != other.refreshTimerInMinutes)
+ return false;
+ if (validCloudConfig != other.validCloudConfig)
+ return false;
+ return true;
+ }
+
+
+}
import org.codehaus.jackson.map.JsonMappingException;
import org.openecomp.mso.logger.MsoLogger;
+import org.openecomp.mso.openstack.exceptions.MsoCloudIdentityNotFound;
import org.openecomp.mso.openstack.utils.MsoHeatUtils;
import org.openecomp.mso.openstack.utils.MsoKeystoneUtils;
import org.openecomp.mso.openstack.utils.MsoNeutronUtils;
}
}
- public void initializeCloudConfig (String filePath, int refreshTimer) {
+ public void initializeCloudConfig (String filePath, int refreshTimer) throws MsoCloudIdentityNotFound {
rwl.writeLock ().lock ();
try {
}
}
- public void changeMsoPropertiesFilePath (String newMsoPropPath) throws MsoPropertiesException {
+ public void changeMsoPropertiesFilePath (String newMsoPropPath) {
rwl.writeLock ().lock ();
try {
CloudConfigFactory.cloudConfigCache.configFilePath = prefixMsoPropertiesPath + newMsoPropPath;
public CloudConfig getCloudConfig () {
rwl.readLock ().lock ();
try {
- return cloudConfigCache.clone ();
+ if (cloudConfigCache.isValidCloudConfig()) {
+ return cloudConfigCache.clone ();
+ } else {
+ return new CloudConfig();
+ }
} finally {
rwl.readLock ().unlock ();
}
try {
if (refreshTimer <= 1) {
- CloudConfig oldCloudConfig = cloudConfigCache.clone();
+ CloudConfig oldCloudConfig = null;
+ if (cloudConfigCache.isValidCloudConfig()) {
+ oldCloudConfig = cloudConfigCache.clone();
+ }
cloudConfigCache.reloadPropertiesFile ();
refreshTimer = cloudConfigCache.refreshTimerInMinutes;
if (!cloudConfigCache.equals(oldCloudConfig)) {
@Produces("text/plain")
public Response showCloudConfig () {
CloudConfig cloudConfig = this.getCloudConfig ();
-
- StringBuffer response = new StringBuffer ();
- response.append ("Cloud Sites:\n");
- for (CloudSite site : cloudConfig.getCloudSites ().values ()) {
- response.append (site.toString () + "\n");
- }
-
- response.append ("\n\nCloud Identity Services:\n");
- for (CloudIdentity identity : cloudConfig.getIdentityServices ().values ()) {
- response.append (identity.toString () + "\n");
+ if (cloudConfig != null) {
+ StringBuffer response = new StringBuffer ();
+ response.append ("Cloud Sites:\n");
+ for (CloudSite site : cloudConfig.getCloudSites ().values ()) {
+ response.append (site.toString () + "\n");
+ }
+
+ response.append ("\n\nCloud Identity Services:\n");
+ for (CloudIdentity identity : cloudConfig.getIdentityServices ().values ()) {
+ response.append (identity.toString () + "\n");
+ }
+
+ return Response.status (200).entity (response).build ();
+ } else {
+ return Response.status (500).entity ("Cloud Config has not been loaded properly, this could be due to a bad JSON structure (Check the logs for additional details)").build ();
}
-
- return Response.status (200).entity (response).build ();
}
@GET
--- /dev/null
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.openstack.exceptions;
+
+
+/**
+ * Cloud site not found exception.
+ */
+public class MsoCloudIdentityNotFound extends MsoException {
+
+ /**
+ * Serialization id.
+ */
+ private static final long serialVersionUID = 2583769056266415665L;
+
+ /**
+ * Default constructor (needed for BPEL/JAXB)
+ */
+ public MsoCloudIdentityNotFound () {
+ super("Cloud Identity not found");
+ super.category=MsoExceptionCategory.USERDATA;
+ }
+
+ /**
+ * Constructor to create a new MsoOpenstackException instance
+ * @param cloudSite the cloud site
+ */
+ public MsoCloudIdentityNotFound (String cloudIdentity) {
+ // Set the detailed error as the Exception 'message'
+ super("Cloud Identity [" + cloudIdentity + "] not found");
+ super.category=MsoExceptionCategory.USERDATA;
+ }
+
+ @Override
+ public String toString () {
+ return getMessage();
+ }
+}
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
-import org.junit.BeforeClass;
+
+import org.junit.Assert;
+import org.junit.Before;
import org.junit.Test;
import java.util.Map;
import org.openecomp.mso.cloud.CloudConfig;
import org.openecomp.mso.cloud.CloudConfigFactory;
import org.openecomp.mso.cloud.CloudIdentity;
import org.openecomp.mso.cloud.CloudSite;
+import org.openecomp.mso.openstack.exceptions.MsoCloudIdentityNotFound;
+
/**
/**
* This method is called before any test occurs.
* It creates a fake tree from scratch
+ * @throws MsoCloudIdentityNotFound
*/
- @BeforeClass
- public static final void prepare () {
+ @Before
+ public final void prepare () throws MsoCloudIdentityNotFound {
ClassLoader classLoader = CloudConfigTest.class.getClassLoader();
String config = classLoader.getResource("cloud_config.json").toString().substring(5);
CloudIdentity identity2 = con.getIdentityService("Test");
assertNull(identity2);
}
+
+ @Test (expected = MsoCloudIdentityNotFound.class)
+ public final void testLoadWithWrongFile () throws MsoCloudIdentityNotFound {
+ ClassLoader classLoader = CloudConfigTest.class.getClassLoader();
+ String config = classLoader.getResource("cloud_config_bad.json").toString().substring(5);
+
+ cloudConfigFactory.initializeCloudConfig(config,1);
+ }
+
+ @Test
+ public final void testReloadWithWrongFile () {
+ ClassLoader classLoader = CloudConfigTest.class.getClassLoader();
+ String config = classLoader.getResource("cloud_config_bad.json").toString().substring(5);
+
+ try {
+ cloudConfigFactory.initializeCloudConfig(config,1);
+ Assert.fail("MsoCloudIdentityNotFound was expected");
+ } catch (MsoCloudIdentityNotFound e) {
+
+ }
+ Assert.assertTrue("Should be an empty CloudConfig", cloudConfigFactory.getCloudConfig().getCloudSites().isEmpty());
+ Assert.assertTrue("Should be an empty CloudConfig", cloudConfigFactory.getCloudConfig().getIdentityServices().isEmpty());
+
+ // Now reload the right config
+ config = classLoader.getResource("cloud_config.json").toString().substring(5);
+ cloudConfigFactory.changeMsoPropertiesFilePath(config);
+ cloudConfigFactory.reloadCloudConfig();
+ Assert.assertTrue("Flag valid Config should be true now that the cloud_config is correct", cloudConfigFactory.getCloudConfig().isValidCloudConfig());
+
+ }
}
import org.openecomp.mso.cloud.CloudConfigFactory;
import org.openecomp.mso.openstack.exceptions.MsoAdapterException;
+import org.openecomp.mso.openstack.exceptions.MsoCloudIdentityNotFound;
import org.openecomp.mso.openstack.exceptions.MsoCloudSiteNotFound;
import org.openecomp.mso.openstack.exceptions.MsoException;
import org.openecomp.mso.openstack.exceptions.MsoIOException;
public static MsoHeatUtils msoHeatUtils;
@BeforeClass
- public static final void loadClasses() {
+ public static final void loadClasses() throws MsoCloudIdentityNotFound {
ClassLoader classLoader = CloudConfigTest.class.getClassLoader();
String config = classLoader.getResource("cloud_config.json").toString().substring(5);
cloudConfigFactory.initializeCloudConfig(config, 1);
--- /dev/null
+{ "cloud_config": {
+ "identity_services":
+ {
+ "MT_KEYSTONE":
+ {
+ "identity_url": "http://localhost:5000/v2.0",
+ "mso_id": "john",
+ "mso_pass": "FD205490A48D48475607C36B9AD902BF",
+ "admin_tenant": "admin",
+ "member_role": "_member_",
+ "tenant_metadata": false,
+ "identity_server_type": "KEYSTONE",
+ "identity_authentication_type": "RACKSPACE_APIKEY"
+ }
+ },
+ "cloud_sites":
+ {
+ "MT":
+ {
+ "region_id": "regionOne",
+ "clli": "MT",
+ "aic_version": "2.5",
+ "identity_service_id": "MT_KEYSTONE_NOT_EXISTING"
+ }
+ }
+}
+}
+
+
+
+
String operation = "";
try {
- reqId = headers.getRequestHeader("att-mso-request-id").get(0);
- action = headers.getRequestHeader("att-mso-request-action").get(0);
- operation = headers.getRequestHeader("att-mso-request-operation").get(0);
+ reqId = headers.getRequestHeader("mso-request-id").get(0);
+ action = headers.getRequestHeader("mso-request-action").get(0);
+ operation = headers.getRequestHeader("mso-request-operation").get(0);
MsoLogger.setLogContext(reqId, "");
@Produces({MediaType.APPLICATION_JSON})
public Response service(
SDNCServiceRequest request,
- @HeaderParam(value="att-mso-request-id") String msoRequestId,
- @HeaderParam(value="att-mso-service-instance-id") String msoServiceInstanceId) {
+ @HeaderParam(value="mso-request-id") String msoRequestId,
+ @HeaderParam(value="mso-service-instance-id") String msoServiceInstanceId) {
MsoLogger.setLogContext(msoRequestId, msoServiceInstanceId);
@Override
public boolean isResourceAlreadyDeployed(VfResourceStructure vfResourceStruct)
throws ArtifactInstallerException {
-
+
boolean status = false;
VfResourceStructure vfResourceStructure = (VfResourceStructure)vfResourceStruct;
- try(CatalogDatabase db = new CatalogDatabase()) {
+ try(CatalogDatabase db = new CatalogDatabase()) {
String resourceType = vfResourceStruct.getResourceInstance().getResourceType();
String category = vfResourceStruct.getResourceInstance().getCategory();
import org.openecomp.mso.rest.RESTConfig\r
\r
class AaiUtil {\r
- \r
+\r
public MsoUtils utils = new MsoUtils()\r
- public static final String AAI_NAMESPACE_STRING = 'http://org.openecomp.aai.inventory/'\r
+ public static final String AAI_NAMESPACE_STRING_KEY = 'URN_mso_workflow_global_default_aai_namespace'\r
public static final String DEFAULT_VERSION_KEY = 'URN_mso_workflow_global_default_aai_version'\r
- \r
+\r
+ private String aaiNamespace = null;\r
+ \r
private AbstractServiceTaskProcessor taskProcessor\r
\r
public AaiUtil(AbstractServiceTaskProcessor taskProcessor) {\r
this.taskProcessor = taskProcessor\r
}\r
- \r
+\r
public String getNetworkGenericVnfEndpoint(Execution execution) {\r
def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
String endpoint = execution.getVariable("URN_aai_endpoint")\r
taskProcessor.logDebug('AaiUtil.getNetworkGenericVnfUri() - AAI URI: ' + uri, isDebugLogEnabled)\r
return uri\r
}\r
- \r
+\r
public String getNetworkVpnBindingUri(Execution execution) {\r
def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
def uri = getUri(execution, 'vpn_binding')\r
taskProcessor.logDebug('AaiUtil.getNetworkTableReferencesUri() - AAI URI: ' + uri, isDebugLogEnabled)\r
return uri\r
}\r
- \r
+\r
public String getNetworkVceUri(Execution execution) {\r
def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
def uri = getUri(execution, 'vce')\r
taskProcessor.logDebug('AaiUtil.getCloudInfrastructureCloudRegionEndpoint() - AAI endpoint: ' + endpoint + uri, isDebugLogEnabled)\r
return endpoint + uri\r
}\r
- \r
+\r
public String getCloudInfrastructureCloudRegionUri(Execution execution) {\r
def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
def uri = getUri(execution, 'cloud_region')\r
taskProcessor.logDebug('AaiUtil.getSearchNodesQueryUri() - AAI URI: ' + uri, isDebugLogEnabled)\r
return uri\r
}\r
- \r
+\r
public String getSearchNodesQueryEndpoint(Execution execution) {\r
def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
String endpoint = execution.getVariable("URN_aai_endpoint")\r
taskProcessor.logDebug('AaiUtil.getSearchNodesQueryEndpoint() - AAI endpoint: ' + endpoint + uri, isDebugLogEnabled)\r
return endpoint + uri\r
}\r
- \r
+\r
public String getSearchGenericQueryUri(Execution execution) {\r
def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
def uri = getUri(execution, 'generic_query')\r
def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
\r
resourceName = resourceName.replaceAll('-', '_')\r
- \r
+\r
def versionWithResourceKey = "URN_mso_workflow_default_aai_${resourceName}_version"\r
def versionWithProcessKey = "URN_mso_workflow_custom_${processKey}_aai_version"\r
\r
def version = execution.getVariable(versionWithProcessKey)\r
if (version) {\r
taskProcessor.logDebug("AaiUtil.getVersion() - using flow specific ${versionWithProcessKey}=${version}", isDebugLogEnabled)\r
- return version \r
+ return version\r
}\r
- \r
+\r
version = execution.getVariable(versionWithResourceKey)\r
if (version) {\r
taskProcessor.logDebug("AaiUtil.getVersion() - using resource specific ${versionWithResourceKey}=${version}", isDebugLogEnabled)\r
return version\r
}\r
- \r
+\r
version = execution.getVariable(DEFAULT_VERSION_KEY)\r
if (version) {\r
taskProcessor.logDebug("AaiUtil.getVersion() - using default version ${DEFAULT_VERSION_KEY}=${version}", isDebugLogEnabled)\r
return version\r
}\r
- \r
+\r
(new ExceptionUtil()).buildAndThrowWorkflowException(execution, 9999, "Internal Error: One of the following should be defined in MSO URN properties file: ${versionWithResourceKey}, ${versionWithProcessKey}, ${DEFAULT_VERSION_KEY}")\r
}\r
- \r
+\r
public String getUri(Execution execution, resourceName) {\r
\r
def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
def processKey = taskProcessor.getMainProcessKey(execution)\r
- \r
resourceName = resourceName.replaceAll('-', '_')\r
+\r
+ //set namespace\r
+ setNamespace(execution)\r
\r
// Check for flow+resource specific first\r
def key = "URN_mso_workflow_${processKey}_aai_${resourceName}_uri"\r
taskProcessor.logDebug("AaiUtil.getUri() - using flow+resource specific key: ${key}=${uri}", isDebugLogEnabled)\r
return uri\r
}\r
- \r
+\r
// Check for versioned key\r
def version = getVersion(execution, resourceName, processKey)\r
key = "URN_mso_workflow_default_aai_v${version}_${resourceName}_uri"\r
(new ExceptionUtil()).buildAndThrowWorkflowException(execution, 9999, 'Internal Error: AAI URI entry for ' + key + ' not defined in the MSO URN properties file')\r
}\r
\r
+ public String setNamespace(Execution execution) {\r
+ def key = AAI_NAMESPACE_STRING_KEY\r
+ aaiNamespace = execution.getVariable(key)\r
+ if (aaiNamespace == null ) {\r
+ (new ExceptionUtil()).buildAndThrowWorkflowException(execution, 9999, 'Internal Error: AAI URI entry for ' + key + ' not defined in the MSO URN properties file')\r
+ }\r
+ }\r
+ \r
+ /**\r
+ * This method can be used for getting the building namespace out of uri.\r
+ * NOTE: A getUri() method needs to be invoked first.\r
+ * Alternative method is the getNamespaceFromUri(Execution execution, String uri)\r
+ * return namespace (plus version from uri)\r
+ *\r
+ * @param url\r
+ *\r
+ * @return namespace\r
+ */\r
+ \r
public String getNamespaceFromUri(String uri) {\r
- String namespace = AAI_NAMESPACE_STRING\r
+ if (aaiNamespace == null) {\r
+ throw new Exception('Internal Error: AAI Namespace has not been set yet. A getUri() method needs to be invoked first.')\r
+ }\r
+ String namespace = aaiNamespace\r
if(uri!=null){\r
- return namespace + uri.substring(uri.indexOf("v"), uri.indexOf("v")+2)\r
+ String version = getVersionFromUri(uri)\r
+ return namespace + "v"+version\r
}else{\r
return namespace\r
}\r
}\r
\r
-\r
+ /**\r
+ * This method can be used for building namespace with aai version out of uri.\r
+ * NOTE: 2 arguments: Execution execution & String uri\r
+ * @param execution\r
+ * @param url\r
+ *\r
+ * @return namespace\r
+ */\r
+ public String getNamespaceFromUri(Execution execution, String uri) {\r
+ String namespace = execution.getVariable(AAI_NAMESPACE_STRING_KEY)\r
+ if (namespace == null ) {\r
+ (new ExceptionUtil()).buildAndThrowWorkflowException(execution, 9999, 'Internal Error: AAI URI entry for ' + AAI_NAMESPACE_STRING_KEY + ' not defined in the MSO URN properties file')\r
+ }\r
+ if(uri!=null){\r
+ String version = getVersionFromUri(uri)\r
+ return namespace + "v"+version\r
+ }else{\r
+ return namespace\r
+ }\r
+ }\r
+ \r
+ /**\r
+ * This is used to extract the version from uri.\r
+ *\r
+ * @param uri\r
+ *\r
+ * @return version\r
+ */\r
+ private String getVersionFromUri(String uri) {\r
+ def version = ""\r
+ def savedVersion = ""\r
+ for (int x=2; x<6; x++) {\r
+ version = uri.substring(uri.indexOf("v")+1, uri.indexOf("v")+x)\r
+ if (!Character.isDigit(version.charAt(version.size()-1))) {\r
+ break\r
+ }\r
+ savedVersion = version\r
+ }\r
+ return savedVersion\r
+ }\r
\r
+\r
/**\r
* This reusable method can be used for making AAI Get Calls. The url should\r
* be passed as a parameter along with the execution. The method will\r
String uuid = UUID.randomUUID()\r
taskProcessor.logDebug( "Generated uuid is: " + uuid, isDebugEnabled)\r
taskProcessor.logDebug( "URL to be used is: " + url, isDebugEnabled)\r
- \r
+ \r
String basicAuthCred = utils.getBasicAuth(execution.getVariable("URN_aai_auth"),execution.getVariable("URN_mso_msoKey"))\r
\r
RESTConfig config = new RESTConfig(url);\r
RESTClient client = new RESTClient(config).addHeader("X-FromAppId", "MSO").addHeader("X-TransactionId", uuid).addHeader("Accept","application/xml");\r
-\r
+ \r
if (basicAuthCred != null && !"".equals(basicAuthCred)) {\r
client.addAuthorizationHeader(basicAuthCred)\r
}\r
-\r
+ \r
APIResponse apiResponse = client.get()\r
return apiResponse\r
\r
taskProcessor.logDebug( "======== COMPLETED Execute AAI Get Process ======== ", isDebugEnabled)\r
}\r
\r
+\r
/**\r
* This reusable method can be used for making AAI httpPut Calls. The url should\r
* be passed as a parameter along with the execution and payload. The method will\r
}\r
taskProcessor.logDebug( "======== Completed Execute AAI Put Process ======== ", isDebugEnabled)\r
}\r
- \r
+\r
/**\r
* This reusable method can be used for making AAI httpPatch Calls. The url should\r
* be passed as a parameter along with the execution and payload. The method will\r
taskProcessor.logDebug( "URL to be used is: " + url, isDebugEnabled)\r
\r
String basicAuthCred = utils.getBasicAuth(execution.getVariable("URN_aai_auth"),execution.getVariable("URN_mso_msoKey"))\r
- \r
+\r
RESTConfig config = new RESTConfig(url);\r
RESTClient client = new RESTClient(config).addHeader("X-FromAppId", "MSO").addHeader("X-TransactionId", uuid).addHeader("Accept","application/xml");\r
if (basicAuthCred != null && !"".equals(basicAuthCred)) {\r
try{\r
String uuid = UUID.randomUUID()\r
taskProcessor.logDebug( "Generated uuid is: " + uuid, isDebugEnabled)\r
+\r
taskProcessor.logDebug( "URL to be used is: " + url, isDebugEnabled)\r
- \r
+\r
String basicAuthCred = utils.getBasicAuth(execution.getVariable("URN_aai_auth"),execution.getVariable("URN_mso_msoKey"))\r
RESTConfig config = new RESTConfig(url);\r
RESTClient client = new RESTClient(config).addHeader("X-FromAppId", "MSO").addHeader("X-TransactionId", uuid).addHeader("Accept","application/xml").addAuthorizationHeader(authHeader);\r
}\r
taskProcessor.logDebug( "======== Completed Execute AAI Delete Process ======== ", isDebugEnabled)\r
}\r
- \r
+\r
/**\r
- * This reusable method can be used for making AAI Post Calls. The url should\r
- * be passed as a parameter along with the execution. The method will\r
- * return an APIResponse.\r
+ * This reusable method can be used for making AAI Post Calls. The url\r
+ * and payload should be passed as a parameters along with the execution.\r
+ * The method will return an APIResponse.\r
*\r
* @param execution\r
* @param url\r
String basicAuthCred = utils.getBasicAuth(execution.getVariable("URN_aai_auth"),execution.getVariable("URN_mso_msoKey"))\r
RESTConfig config = new RESTConfig(url);\r
RESTClient client = new RESTClient(config).addHeader("X-FromAppId", "MSO").addHeader("X-TransactionId", uuid).addHeader("Accept","application/xml");\r
+ \r
if (basicAuthCred != null && !"".equals(basicAuthCred)) {\r
client.addAuthorizationHeader(basicAuthCred)\r
}\r
taskProcessor.logDebug( "======== Completed Execute AAI Post Process ======== ", isDebugEnabled)\r
}\r
\r
- /** Utilitty to get the Cloud Region from AAI\r
+ /**\r
+ * This reusable method can be used for making AAI Post Calls. The url\r
+ * and payload should be passed as a parameters along with the execution.\r
+ * The method will return an APIResponse.\r
+ *\r
+ * @param execution\r
+ * @param url\r
+ * @param payload\r
+ * @param authenticationHeader - addAuthenticationHeader value\r
+ * @param headerName - name of header you want to add, i.e. addHeader(headerName, headerValue)\r
+ * @param headerValue - the header's value, i.e. addHeader(headerName, headerValue)\r
+ *\r
+ * @return APIResponse\r
+ */\r
+ public APIResponse executeAAIPostCall(Execution execution, String url, String payload, String authenticationHeaderValue, String headerName, String headerValue){\r
+ def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
+ taskProcessor.logDebug( " ======== Started Execute AAI Post Process ======== ", isDebugEnabled)\r
+ try{\r
+ taskProcessor.logDebug( "URL to be used is: " + url, isDebugEnabled)\r
+\r
+ String basicAuthCred = utils.getBasicAuth(execution.getVariable("URN_aai_auth"),execution.getVariable("URN_mso_msoKey"))\r
+ \r
+ RESTConfig config = new RESTConfig(url);\r
+ RESTClient client = new RESTClient(config).addAuthorizationHeader(authenticationHeaderValue).addHeader(headerName, headerValue)\r
+ if (basicAuthCred != null && !"".equals(basicAuthCred)) {\r
+ client.addAuthorizationHeader(basicAuthCred)\r
+ }\r
+ APIResponse apiResponse = client.httpPost(payload)\r
+\r
+ return apiResponse\r
+\r
+ }catch(Exception e){\r
+ taskProcessor.utils.log("ERROR", "Exception occured while executing AAI Post Call. Exception is: \n" + e, isDebugEnabled)\r
+ return e\r
+ }\r
+ taskProcessor.logDebug( "======== Completed Execute AAI Post Process ======== ", isDebugEnabled)\r
+ }\r
+\r
+\r
+ \r
+\r
+\r
+ /* Utility to get the Cloud Region from AAI\r
* Returns String cloud region id, (ie, cloud-region-id)\r
* @param execution\r
* @param url - url for AAI get cloud region\r
return "ERROR"\r
}\r
} else { // not 200\r
- if (returnCode == "404") {\r
+ if (returnCode == "404") {\r
if (backend == "PO") {\r
regionId = inputCloudRegion\r
} else { // backend not "PO"\r
}\r
taskProcessor.utils.log("DEBUG", "Cloud Region value for code='404' of " + backend + " is: " + regionId, isDebugEnabled)\r
return regionId\r
- } else {\r
- taskProcessor.utils.log("ERROR", "Call AAI Cloud Region is NOT Successful.", isDebugEnabled)\r
- return "ERROR"\r
- }\r
+ } else {\r
+ taskProcessor.utils.log("ERROR", "Call AAI Cloud Region is NOT Successful.", isDebugEnabled)\r
+ return "ERROR"\r
+ }\r
}\r
}catch(Exception e) {\r
taskProcessor.utils.log("ERROR", "Exception occured while getting the Cloud Reqion. Exception is: \n" + e, isDebugEnabled)\r
return ret\r
}\r
\r
- \r
/**\r
- * Get the lowest unused VF Module index from AAI response for a given module type. The criteria for \r
+ * Get the lowest unused VF Module index from AAI response for a given module type. The criteria for\r
* determining module type is specified by "key" parameter (for example, "persona-model-id"),\r
* the value for filtering is specified in "value" parameter\r
- * \r
+ *\r
* @param execution\r
* @param aaiVnfResponse\r
* @param key\r
* @param value\r
*\r
* @return moduleIndex\r
- * \r
+ *\r
*/\r
public int getLowestUnusedVfModuleIndexFromAAIVnfResponse(Execution execution, String aaiVnfResponse, String key, String value) {\r
def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
String vfModulesText = taskProcessor.utils.getNodeXml(aaiVnfResponse, "vf-modules")\r
if (vfModulesText == null || vfModulesText.isEmpty()) {\r
taskProcessor.utils.log("DEBUG", "There are no VF modules in this VNF yet", isDebugEnabled)\r
- return 0 \r
+ return 0\r
}\r
else {\r
def xmlVfModules= new XmlSlurper().parseText(vfModulesText)\r
matchingVfModules = matchingVfModules + taskProcessor.utils.removeXmlPreamble(vfModuleXml)\r
}\r
}\r
- matchingVfModules = matchingVfModules + "</vfModules>" \r
+ matchingVfModules = matchingVfModules + "</vfModules>"\r
taskProcessor.utils.log("DEBUG", "Matching VF Modules: " + matchingVfModules, isDebugEnabled)\r
String lowestUnusedIndex = taskProcessor.utils.getLowestUnusedIndex(matchingVfModules)\r
return Integer.parseInt(lowestUnusedIndex)\r
- } \r
+ }\r
}\r
else {\r
return 0\r
}\r
}\r
-\r
}
\ No newline at end of file
\r
/**\r
* Constructs a workflow message callback URL for the specified message type and correlator.\r
+ * This type of callback URL is used when a workflow wants an MSO adapter (like the SDNC\r
+ * adapter) to call it back. In other words, this is for callbacks internal to the MSO\r
+ * complex. Use <code>createWorkflowMessageAdapterCallbackURL</code> if the callback\r
+ * will come from outside the MSO complex.\r
* @param messageType the message type (e.g. SDNCAResponse or VNFAResponse)\r
* @param correlator the correlator value (e.g. a request ID)\r
*/\r
'/' + UriUtils.encodePathSegment(messageType, 'UTF-8') +\r
'/' + UriUtils.encodePathSegment(correlator, 'UTF-8')\r
}\r
+ \r
+ /**\r
+ *\r
+ * Constructs a workflow message callback URL for the specified message type and correlator.\r
+ * This type of callback URL is used when a workflow wants a system outside the MSO complex\r
+ * to call it back through the Workflow Message Adapter.\r
+ * @param messageType the message type (e.g. SNIROResponse)\r
+ * @param correlator the correlator value (e.g. a request ID)\r
+ */\r
+ public String createWorkflowMessageAdapterCallbackURL(Execution execution, String messageType, String correlator) {\r
+ String endpoint = (String) execution.getVariable('URN_mso_adapters_workflow_message_endpoint')\r
+\r
+ if (endpoint == null || endpoint.isEmpty()) {\r
+ ExceptionUtil exceptionUtil = new ExceptionUtil()\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2000,\r
+ 'mso:adapters:workflow:message:endpoint URN mapping is not set')\r
+ }\r
+\r
+ while (endpoint.endsWith('/')) {\r
+ endpoint = endpoint.substring(0, endpoint.length()-1)\r
+ }\r
+\r
+ return endpoint +\r
+ '/' + UriUtils.encodePathSegment(messageType, 'UTF-8') +\r
+ '/' + UriUtils.encodePathSegment(correlator, 'UTF-8')\r
+ }\r
}
\ No newline at end of file
--- /dev/null
+package org.openecomp.mso.bpmn.common.scripts\r
+\r
+import org.apache.commons.lang3.StringEscapeUtils;\r
+import org.camunda.bpm.engine.delegate.BpmnError\r
+import org.camunda.bpm.engine.runtime.Execution;\r
+import org.openecomp.mso.bpmn.core.WorkflowException\r
+import org.openecomp.mso.rest.APIResponse;\r
+\r
+class AllottedResourceUtils {\r
+ \r
+ private AbstractServiceTaskProcessor taskProcessor\r
+ ExceptionUtil exceptionUtil = new ExceptionUtil()\r
+ MsoUtils utils;\r
+\r
+ public AllottedResourceUtils(AbstractServiceTaskProcessor taskProcessor) {\r
+ this.taskProcessor = taskProcessor\r
+ this.utils = taskProcessor.utils\r
+ }\r
+\r
+ /*Used on Create - called from DoCreate\r
+ * Using Consuming ServiceInstanceId get related Allotted Resources Orchestration status from AAI\r
+ * 1) get related AR links for CSI 2) get AR from AR links\r
+ * return: null -> AR Not found\r
+ * return: " " -> AR found with empty orchStatus\r
+ * return: orchStatus - > AR found with this orchStatus\r
+ * setsVariable aaiARGetResponse\r
+ */\r
+ public String getAROrchStatus (Execution execution) {\r
+\r
+ def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
+ utils.log("DEBUG"," ***** getAROrchStatus *****", isDebugEnabled)\r
+ String msg = ""\r
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
+ String arType = execution.getVariable("allottedResourceType")\r
+ String arRole = execution.getVariable("allottedResourceRole")\r
+ String siXml = execution.getVariable("CSI_service")\r
+ String ar = null\r
+ String orchStatus = null\r
+ XmlParser xmlParser = new XmlParser()\r
+ utils.log("DEBUG","getAROrchStatus siXml:" + siXml, isDebugEnabled)\r
+ try {\r
+ if (!isBlank(siXml)) {\r
+ def groovy.util.Node siNode = xmlParser.parseText(siXml)\r
+ def groovy.util.Node relationshipList = utils.getChildNode(siNode, 'relationship-list')\r
+ if (relationshipList != null) {\r
+ def groovy.util.NodeList relationships = utils.getIdenticalChildren(relationshipList, 'relationship')\r
+ for (groovy.util.Node relationship in relationships) {\r
+ def groovy.util.Node relatedTo = utils.getChildNode(relationship, 'related-to')\r
+ if ((relatedTo != null) && (relatedTo.text().equals('allotted-resource'))) {\r
+ utils.log("DEBUG","getARORchStatus AR found", isDebugEnabled)\r
+ def groovy.util.Node relatedLink = utils.getChildNode(relationship, 'related-link')\r
+ if (relatedLink != null){\r
+ ar = getARbyLink(execution, relatedLink.text(), arRole)\r
+ if (!isBlank(ar))\r
+ {\r
+ orchStatus = execution.getVariable("aaiAROrchStatus")\r
+ break\r
+ }\r
+ }\r
+ }\r
+ }\r
+ }\r
+ }\r
+ }catch(Exception e){\r
+ utils.log("DEBUG", " Error encountered in getAROrchStatus" + e.getMessage(), isDebugEnabled)\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error in getAROrchStatus" + e.getMessage())\r
+ }\r
+ utils.log("DEBUG"," *****Exit getAROrchStatus **** OrchStatus:" + orchStatus, isDebugEnabled)\r
+ return orchStatus\r
+ }\r
+\r
+ // get Allotted Resource by AllottedResourceId\r
+ // used on Delete - called from doDeleteAR\r
+ // setsVariable aaiARGetResponse\r
+ public String getARbyId (Execution execution, String allottedResourceId) {\r
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
+ utils.log("DEBUG", " ***** getARbyId ***** ", isDebugEnabled)\r
+ String arLink = getARLinkbyId(execution, allottedResourceId)\r
+ String ar = null\r
+ if (!isBlank(arLink))\r
+ {\r
+ ar = getARbyLink(execution, arLink, "")\r
+ }\r
+ utils.log("DEBUG", " ***** Exit GetARbyId ***** AR:" + ar, isDebugEnabled)\r
+ return ar;\r
+ }\r
+\r
+ // get Allotted Resource Link by AllottedResourceId using Nodes Query\r
+ // used on Delete - called from getARbyId\r
+ public String getARLinkbyId (Execution execution, String allottedResourceId) {\r
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
+ utils.log("DEBUG", " ***** getARLinkbyId ***** ", isDebugEnabled)\r
+ String arLink = null\r
+ try {\r
+ AaiUtil aaiUriUtil = new AaiUtil(taskProcessor)\r
+ String aaiNQUri = aaiUriUtil.getSearchNodesQueryEndpoint(execution)\r
+ String aaiEndpoint = execution.getVariable("URN_aai_endpoint")\r
+ String aaiUrl = "${aaiNQUri}?search-node-type=allotted-resource&filter=id:EQUALS:${allottedResourceId}"\r
+\r
+ utils.log("DEBUG", "getARLinkbyId url: \n" + aaiUrl, isDebugEnabled)\r
+\r
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, aaiUrl)\r
+ int responseCode = response.getStatusCode()\r
+ utils.log("DEBUG", " GET AR response code is: " + responseCode, isDebugEnabled)\r
+\r
+ String aaiResponse = response.getResponseBodyAsString()\r
+ aaiResponse = StringEscapeUtils.unescapeXml(aaiResponse)\r
+ utils.log("DEBUG", "GET AR:" + aaiResponse, isDebugEnabled)\r
+ if(responseCode == 200 || responseCode == 202){\r
+ utils.log("DEBUG", "GET AR Received a Good Response Code", isDebugEnabled)\r
+ if(utils.nodeExists(aaiResponse, "result-data")){\r
+ utils.log("DEBUG", "Query for AllottedResource Url Response Does Contain Data" , isDebugEnabled)\r
+ arLink = utils.getNodeText1(aaiResponse, "resource-link")\r
+ }else{\r
+ utils.log("DEBUG", "GET AR Response Does NOT Contain Data" , isDebugEnabled)\r
+ }\r
+ }else if(responseCode == 404){\r
+ utils.log("DEBUG", "GET AR received a Not Found (404) Response", isDebugEnabled)\r
+ }\r
+ else{\r
+ utils.log("DEBUG", " GET AR received a Bad Response: \n" + aaiResponse, isDebugEnabled)\r
+ buildAAIErrorResponse(execution, aaiResponse, "Error retrieving AR from AAI")\r
+ }\r
+ }catch(Exception e){\r
+ utils.log("DEBUG", " Error encountered within GetAaiAR" + e.getMessage(), isDebugEnabled)\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error in GetARbyId" + e.getMessage())\r
+ }\r
+ utils.log("DEBUG", " ***** Exit GetARLinkbyId ***** Link:" + arLink, isDebugEnabled)\r
+ return arLink\r
+ }\r
+\r
+ // get Allotted resource using Link\r
+ // used on Create called from getARORchStatus\r
+ // used on Delete called from getARbyId\r
+ // setsVariable aaiARPath - used for Patch in create\r
+ public String getARbyLink (Execution execution, String link, String role) {\r
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
+ utils.log("DEBUG", " ***** getARbyLink ***** ", isDebugEnabled)\r
+ String ar = null\r
+ String arUrl = null\r
+ try {\r
+ AaiUtil aaiUriUtil = new AaiUtil(taskProcessor)\r
+ String aai_endpoint = execution.getVariable("URN_aai_endpoint")\r
+ String arEndpoint = ""\r
+\r
+ if(!isBlank(link)) {\r
+ utils.log("DEBUG", "Incoming AR Resource Link is: " + link, isDebugEnabled)\r
+ String[] split = link.split("/aai/")\r
+ arEndpoint = "/aai/" + split[1]\r
+ }\r
+\r
+ arUrl = "${aai_endpoint}" + arEndpoint\r
+ \r
+ utils.log("DEBUG", "GET AR Aai Path is: \n" + arUrl, isDebugEnabled)\r
+\r
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, arUrl)\r
+ int responseCode = response.getStatusCode()\r
+ utils.log("DEBUG", " GET AR response code is: " + responseCode, isDebugEnabled)\r
+\r
+ String aaiResponse = response.getResponseBodyAsString()\r
+ aaiResponse = StringEscapeUtils.unescapeXml(aaiResponse)\r
+ utils.log("DEBUG", "GET AR:" + aaiResponse, isDebugEnabled)\r
+ if(responseCode == 200 || responseCode == 202){\r
+ utils.log("DEBUG", "GET AR Received a Good Response Code", isDebugEnabled)\r
+ if(utils.nodeExists(aaiResponse, "allotted-resource")){\r
+ if (!isBlank(role))\r
+ {\r
+ if (utils.nodeExists(aaiResponse, "role") && role.equals(utils.getNodeText1(aaiResponse, "role"))) {\r
+ ar = aaiResponse\r
+ }else{\r
+ utils.log("DEBUG", "AAI AR does not match input role:" + role, isDebugEnabled)\r
+ }\r
+ }\r
+ else\r
+ {\r
+ ar = aaiResponse\r
+ }\r
+ }\r
+ else\r
+ {\r
+ utils.log("DEBUG", "GET AR Does NOT Contain Data" , isDebugEnabled)\r
+ }\r
+ }else if(responseCode == 404){\r
+ utils.log("DEBUG", "GET AR received a Not Found (404) Response", isDebugEnabled)\r
+ }\r
+ else{\r
+ utils.log("DEBUG", " GET AR received a Bad Response: \n" + aaiResponse, isDebugEnabled)\r
+ buildAAIErrorResponse(execution, aaiResponse, "Error retrieving AR from AAI")\r
+ }\r
+ }catch(Exception e){\r
+ utils.log("DEBUG", " Error encountered within GetAaiAR" + e.getMessage(), isDebugEnabled)\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error in GetAaiAR" + e.getMessage())\r
+ }\r
+ if (!isBlank(ar))\r
+ {\r
+ execution.setVariable("aaiARGetResponse", ar)\r
+ execution.setVariable("aaiARPath", arUrl)\r
+ \r
+ String resourceVersion = null\r
+ if (utils.nodeExists(ar, "resource-version")) {\r
+ resourceVersion = utils.getNodeText1(ar, "resource-version")\r
+ execution.setVariable("aaiARResourceVersion", resourceVersion)\r
+ }\r
+ \r
+ String orchStatus = null\r
+ if (utils.nodeExists(ar, "orchestration-status")) {\r
+ orchStatus= utils.getNodeText1(ar, "orchestration-status")\r
+ }\r
+ else\r
+ {\r
+ orchStatus = " "\r
+ }\r
+ execution.setVariable("aaiAROrchStatus", orchStatus)\r
+ }\r
+ utils.log("DEBUG", " ***** Exit GetARbyLink ***** AR:" + ar, isDebugEnabled)\r
+ return ar\r
+ }\r
+\r
+ public void updateAROrchStatus(Execution execution, String status, String aaiARPath){\r
+ def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
+ utils.log("DEBUG", " *** updaAROrchStatus *** ", isDebugEnabled)\r
+ try{\r
+\r
+ String updateReq = """\r
+ {\r
+ "orchestration-status": "Created""\r
+ }\r
+ """\r
+\r
+ utils.log("DEBUG", 'AAI AR URI: ' + aaiARPath, isDebugEnabled)\r
+\r
+ AaiUtil aaiUriUtil = new AaiUtil(taskProcessor)\r
+ APIResponse apiResponse = aaiUriUtil.executeAAIPatchCall(execution, aaiARPath, updateReq)\r
+ def aaiResponse = StringEscapeUtils.unescapeXml(apiResponse.getResponseBodyAsString())\r
+ def responseCode = apiResponse.getStatusCode()\r
+\r
+ utils.logAudit("AAI Response Code: " + responseCode)\r
+ utils.logAudit("AAI Response: " + aaiResponse)\r
+ if(responseCode == 200){\r
+ utils.log("DEBUG", "UpdateAR Good REST Response is: " + "\n" + aaiResponse, isDebugEnabled)\r
+ }else{\r
+ utils.log("DEBUG", "UpdateAROrchStatus Bad REST Response!", isDebugEnabled)\r
+ buildAAIErrorResponse(execution, aaiResponse, "Error updating AR OrchStatus in AAI")\r
+ }\r
+\r
+ }catch(BpmnError b){\r
+ utils.log("DEBUG", "Rethrowing MSOWorkflowException ", isDebugEnabled)\r
+ throw b\r
+ }catch(Exception e){\r
+ utils.log("ERROR", "Exception in updateAR. Exception is:\n" + e.getMessage(), isDebugEnabled)\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, 'Internal Error in updateAROrchStatus.' + e.getMessage())\r
+ }\r
+ utils.log("DEBUG", " *** Exit updateAROrchStatus *** ", isDebugEnabled)\r
+ }\r
+ \r
+ //Sets Variable "wasDeleted"\r
+ public void deleteAR(Execution execution, String aaiARPath){\r
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
+ utils.log("DEBUG", " *** deleteAR *** aaiARPath:" + aaiARPath, isDebugEnabled)\r
+ try {\r
+ AaiUtil aaiUriUtil = new AaiUtil(taskProcessor)\r
+ APIResponse response = aaiUriUtil.executeAAIDeleteCall(execution, aaiARPath)\r
+ int responseCode = response.getStatusCode()\r
+ execution.setVariable("deleteARResponseCode", responseCode)\r
+ \r
+ utils.log("DEBUG", " Delete AR response code:" + responseCode, isDebugEnabled)\r
+\r
+ String aaiResponse = response.getResponseBodyAsString()\r
+ aaiResponse = StringEscapeUtils.unescapeXml(aaiResponse)\r
+ execution.setVariable("aaiARDeleteResponse", aaiResponse)\r
+\r
+ utils.log("DEBUG", "Delete AR Response:" + aaiResponse)\r
+ //Process Response\r
+ if(responseCode == 204){\r
+ utils.log("DEBUG", " Delete AR Received a Good Response", isDebugEnabled)\r
+ execution.setVariable("wasDeleted", "true")\r
+ }else if(responseCode == 404){\r
+ utils.log("DEBUG", " Delete AR Received a Not Found (404) Response", isDebugEnabled)\r
+ }else if(responseCode == 412){\r
+ utils.log("DEBUG", "Delete AR Received a Resource Version Mismatch Error: \n" + aaiResponse, isDebugEnabled)\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 412, "DeleteAR Received a resource-version Mismatch Error Response from AAI")\r
+ }else{\r
+ utils.log("DEBUG", "Delete AR Received a BAD REST Response: \n" + aaiResponse, isDebugEnabled)\r
+ buildAAIErrorResponse(execution, aaiResponse, "Error deleting AR in AAI")\r
+ exceptionUtil.MapAAIExceptionToWorkflowExceptionGeneric(execution, aaiResponse, responseCode)\r
+ }\r
+ }catch(BpmnError b){\r
+ utils.log("DEBUG", "Rethrowing MSOWorkflowException", isDebugEnabled)\r
+ throw b\r
+ }catch(Exception e){\r
+ utils.log("DEBUG", " Error encountered in deleteAR!" + e, isDebugEnabled)\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured During Delete AR")\r
+ }\r
+ utils.log("DEBUG", " *** Exit deleteAR *** ", isDebugEnabled)\r
+ }\r
+\r
+ public void buildAAIErrorResponse(Execution execution, String response, String errorMessage){\r
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
+ utils.log("DEBUG", " *** BuildAAIErrorResponse*** ", isDebugEnabled)\r
+\r
+ if((response != null) && (response.contains("Fault") || response.contains("RESTFault"))){\r
+ WorkflowException workflowException = exceptionUtil.MapAAIExceptionToWorkflowException(response, execution)\r
+ execution.setVariable("WorkflowException", workflowException)\r
+ }else{\r
+ exceptionUtil.buildWorkflowException(execution, 500, errorMessage)\r
+ }\r
+\r
+ utils.log("DEBUG", " *** Exit BuildAAIErrorResponse Process*** ", isDebugEnabled)\r
+ throw new BpmnError("MSOWorkflowException")\r
+ }\r
+\r
+}
\ No newline at end of file
AaiUtil aaiUriUtil = new AaiUtil(this)\r
def aai_uri = aaiUriUtil.getNetworkGenericVnfUri(execution)\r
logDebug('AAI URI is: ' + aai_uri, isDebugEnabled)\r
- String aaiNamespace = aaiUriUtil.getNamespaceFromUri(aai_uri)\r
+ String aaiNamespace = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)\r
logDebug('AAI namespace is: ' + aaiNamespace, isDebugEnabled)\r
\r
execution.setVariable("CAAIVfMod_aaiNamespace","${aaiNamespace}") \r
<vnf-type>${execution.getVariable("CAAIVfMod_vnfType")}</vnf-type>\r
<service-id>${execution.getVariable("CAAIVfMod_serviceId")}</service-id>\r
<orchestration-status>active</orchestration-status>\r
- <persona-model-id>${execution.getVariable("CAAIVfMod_vnfPersonaId")}</persona-model-id>\r
- <persona-model-version>${execution.getVariable("CAAIVfMod_vnfPersonaVer")}</persona-model-version>\r
+ <model-invariant-id>${execution.getVariable("CAAIVfMod_vnfPersonaId")}</model-invariant-id>\r
+ <model-version-id>${execution.getVariable("CAAIVfMod_vnfPersonaVer")}</model-version-id>\r
</generic-vnf>""" as String\r
execution.setVariable("CAAIVfMod_createGenericVnfPayload", payload)\r
\r
def aaiVnfResponse = execution.getVariable("CAAIVfMod_queryGenericVnfResponse")\r
AaiUtil aaiUtil = new AaiUtil(this)\r
def personaModelId = execution.getVariable("CAAIVfMod_personaId")\r
+ \r
+ // Check if the response includes model-invariant-id or persona-model-id\r
+ // note: getRequiredNodeText() throws an exception if the field is missing\r
+ // need to retun a null for the subsequent "either/or" logic to work properly\r
+// def modelInvariantId = getRequiredNodeText(execution, aaiVnfResponse,'model-invariant-id')\r
+ def modelInvariantId = getNodeText(aaiVnfResponse,'model-invariant-id', null)\r
+ def fieldToCheck = 'model-invariant-id'\r
+ if (!modelInvariantId) {\r
+ fieldToCheck = 'persona-model-id'\r
+ }\r
+ \r
moduleIndex = aaiUtil.getLowestUnusedVfModuleIndexFromAAIVnfResponse(execution, aaiVnfResponse, \r
- "persona-model-id", personaModelId)\r
+ fieldToCheck, personaModelId)\r
}\r
def moduleIndexString = String.valueOf(moduleIndex)\r
\r
String payload = """<vf-module xmlns="${execution.getVariable("CAAIVfMod_aaiNamespace")}">\r
<vf-module-id>${newModuleId}</vf-module-id>\r
<vf-module-name>${execution.getVariable("CAAIVfMod_moduleName")}</vf-module-name>\r
- <persona-model-id>${execution.getVariable("CAAIVfMod_personaId")}</persona-model-id>\r
- <persona-model-version>${execution.getVariable("CAAIVfMod_personaVer")}</persona-model-version>\r
- <persona-model-customization-id>${execution.getVariable("CAAIVfMod_modelCustomizationId")}</persona-model-customization-id>\r
+ <model-invariant-id>${execution.getVariable("CAAIVfMod_personaId")}</model-invariant-id>\r
+ <model-version-id>${execution.getVariable("CAAIVfMod_personaVer")}</model-version-id>\r
+ <model-customization-id>${execution.getVariable("CAAIVfMod_modelCustomizationId")}</model-customization-id>\r
<is-base-vf-module>${isBaseModule}</is-base-vf-module>\r
- <orchestration-status>pending-create</orchestration-status>\r
+ <orchestration-status>PendingCreate</orchestration-status>\r
<module-index>${moduleIndex}</module-index>\r
</vf-module>""" as String\r
execution.setVariable("CAAIVfMod_createVfModulePayload", payload)\r
+++ /dev/null
-/*-
- * ============LICENSE_START=======================================================
- * OPENECOMP - MSO
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-package org.openecomp.mso.bpmn.common.scripts
-
-import org.openecomp.mso.bpmn.core.WorkflowException
-import org.openecomp.mso.rest.APIResponse;
-
-import org.camunda.bpm.engine.runtime.Execution;
-import org.camunda.bpm.engine.delegate.BpmnError
-
-/**
- * Please describe the CreateGenericVNFUtils.groovy class
- *
- */
-class CreateGenericVNFUtils{
-
- String Prefix="CRTGVNF_"
-
- def utils=new MsoUtils()
-
- private AbstractServiceTaskProcessor taskProcessor
-
- public CreateGenericVNFUtils(AbstractServiceTaskProcessor taskProcessor) {
- this.taskProcessor = taskProcessor
- }
-
- /**
- * This method is executed during the Initialization task of the process.
- *
- * @param execution
- *
- */
-
- public APIResponse queryAAI(Execution execution, String path){
-
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
- utils.log("DEBUG", " ======== STARTED queryAAI Process ======== ", isDebugEnabled)
-
- def uuid = execution.getVariable("CRTGVNF_uuid")
- utils.log("DEBUG", "UUID is: " + uuid, isDebugEnabled)
-
- //Setting request path
- String queryAAIRequestPath = execution.getVariable("URN_aai_endpoint")+path
-// execution.setVariable("CRTGVNF_queryAAIRequestPath", queryAAIRequestPath)
- utils.log("DEBUG", "QueryAAIRequest Path is: " + "\n" + queryAAIRequestPath, isDebugEnabled)
-
- try {
- AaiUtil aaiUtil = new AaiUtil(taskProcessor)
- return aaiUtil.executeAAIGetCall(execution, queryAAIRequestPath)
- }catch(Exception e){
- utils.log("ERROR", "Exception Occured Processing queryAAI. Exception is:\n" + e, isDebugEnabled)
- execution.setVariable("CRTGVNF_dataValidationFlag", false)
- execution.setVariable("CRTGVNF_ErrorResponse", "Error Occured during queryAAI Method:\n" + e.getMessage())
- }
- utils.log("DEBUG", "======== COMPLETED queryAAI Process ======== ", isDebugEnabled)
-}
-
- public String buildSDNCRequest(Execution execution, String svcInstId, String action){
-
- String uuid = execution.getVariable('testReqId') // for junits
- if(uuid==null){
- uuid = execution.getVariable("mso-request-id") + "-" + System.currentTimeMillis()
- }
- def callbackURL = execution.getVariable("CRTGVNF_sdncCallbackUrl")
- def requestId = execution.getVariable("CRTGVNF_requestId")
- def serviceType = execution.getVariable("CRTGVNF_serviceType")
- def vnfType = execution.getVariable("CRTGVNF_vnfType")
- def vnfName = execution.getVariable("CRTGVNF_vnfName")
- def tenantId = execution.getVariable("CRTGVNF_tenantId")
- def source = execution.getVariable("CRTGVNF_source")
- String vnfId = svcInstId
- String sdncVNFParamsXml = ""
-
- if(execution.getVariable("CRTGVNF_vnfParamsExistFlag") == true){
- sdncVNFParamsXml = buildSDNCParamsXml(execution)
- }else{
- sdncVNFParamsXml = ""
- }
-
- String sdncRequest =
- """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
- <sdncadapter:RequestHeader>
- <sdncadapter:RequestId>${uuid}</sdncadapter:RequestId>
- <sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>
- <sdncadapter:SvcAction>${action}</sdncadapter:SvcAction>
- <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>
- <sdncadapter:CallbackUrl>${callbackURL}</sdncadapter:CallbackUrl>
- </sdncadapter:RequestHeader>
- <sdncadapterworkflow:SDNCRequestData>
- <request-information>
- <request-id>${requestId}</request-id>
- <request-action>VNFActivateRequest</request-action>
- <source>${source}</source>
- </request-information>
- <service-information>
- <service-type>${serviceType}</service-type>
- <service-instance-id>${vnfId}</service-instance-id>
- <subscriber-name>notsurewecare</subscriber-name>
- </service-information>
- <vnf-request-information>
- <vnf-id>${vnfId}</vnf-id>
- <vnf-type>${vnfType}</vnf-type>
- <vnf-name>${vnfName}</vnf-name>
- <tenant>${tenantId}</tenant>
-${sdncVNFParamsXml}
- </vnf-request-information>
- </sdncadapterworkflow:SDNCRequestData>
- </sdncadapterworkflow:SDNCAdapterWorkflowRequest>"""
-
- return sdncRequest
-
- }
-
- public String buildSDNCParamsXml(Execution execution){
-
- String params = ""
- StringBuilder sb = new StringBuilder()
- Map<String, String> paramsMap = execution.getVariable("CRTGVNF_vnfParamsMap")
-
- for (Map.Entry<String, String> entry : paramsMap.entrySet()) {
- String paramsXml
- String key = entry.getKey();
- if(key.endsWith("_network")){
- String requestKey = key.substring(0, key.indexOf("_network"))
- String requestValue = entry.getValue()
- paramsXml =
-"""<vnf-networks>
- <network-role>{ functx:substring-before-match(data($param/@name), '_network') }</network-role>
- <network-name>{ $param/text() }</network-name>
-</vnf-networks>"""
- }else{
- paramsXml = ""
- }
- params = sb.append(paramsXml)
- }
- return params
- }
-
-}
-
-
-
-
-
String matchingVfModules = "<vfModules>"\r
for (i in 0..vfModulesSize-1) {\r
def vfModuleXml = groovy.xml.XmlUtil.serialize(vfModules[i])\r
- def personaModelIdFromAAI = utils.getNodeText(vfModuleXml, "persona-model-id")\r
+ def personaModelIdFromAAI = utils.getNodeText(vfModuleXml, "model-invariant-id")\r
+ if (!personaModelIdFromAAI) {\r
+ // check old attribute name\r
+ personaModelIdFromAAI = utils.getNodeText(vfModuleXml, "persona-model-id") \r
+ }\r
if (personaModelIdFromAAI != null && personaModelIdFromAAI.equals(personaModelId)) {\r
matchingVfModules = matchingVfModules + utils.removeXmlPreamble(vfModuleXml)\r
} \r
*\r
*\r
* Out Mapping Variables:\r
- * @param - GENDV_vnf\r
* @param - GENDV_SuccessIndicator\r
* @param - GENDV_FoundIndicator\r
* @param - WorkflowException\r
* Variable Mapping Below:\r
*\r
* In Mapping Variables:\r
+ * For Allotted-Resource:\r
+ * @param - GENGS_allottedResourceId\r
+ * @param - GENGS_type\r
+ * @param (Optional) - GENGS_serviceInstanceId\r
+ * @param (Optional) - GENGS_serviceType\r
+ * @param (Optional) - GENGS_globalCustomerId\r
+ *\r
* For Service-Instance:\r
* @param - GENGS_serviceInstanceId or @param - GENGS_serviceInstanceName\r
* @param - GENGS_type\r
* @param - WorkflowException\r
*\r
*\r
+ * @author cb645j\r
*/\r
class GenericGetService extends AbstractServiceTaskProcessor{\r
\r
* variables the calling flow provided.\r
*\r
* @param - execution\r
+ *\r
+ * @author cb645j\r
*/\r
public void preProcessRequest(Execution execution) {\r
def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
execution.setVariable("prefix",Prefix)\r
utils.log("DEBUG", " *** STARTED GenericGetService PreProcessRequest Process*** ", isDebugEnabled)\r
\r
- execution.setVariable("GENGS_obtainServiceInstanceUrl", false)\r
+ execution.setVariable("GENGS_obtainObjectsUrl", false)\r
execution.setVariable("GENGS_obtainServiceInstanceUrlByName", false)\r
execution.setVariable("GENGS_SuccessIndicator", false)\r
execution.setVariable("GENGS_FoundIndicator", false)\r
+ execution.setVariable("GENGS_resourceLink", null)\r
execution.setVariable("GENGS_siResourceLink", null)\r
\r
try{\r
// Get Variables\r
+ String allottedResourceId = execution.getVariable("GENGS_allottedResourceId")\r
String serviceInstanceId = execution.getVariable("GENGS_serviceInstanceId")\r
String serviceInstanceName = execution.getVariable("GENGS_serviceInstanceName")\r
String serviceType = execution.getVariable("GENGS_serviceType")\r
\r
if(type != null){\r
utils.log("DEBUG", "Incoming GENGS_type is: " + type, isDebugEnabled)\r
- if(type.equalsIgnoreCase("service-instance")){\r
+ if(type.equalsIgnoreCase("allotted-resource")){\r
+ if(isBlank(allottedResourceId)){\r
+ utils.log("DEBUG", "Incoming allottedResourceId is null. Allotted Resource Id is required to Get an allotted-resource.", isDebugEnabled)\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Incoming allottedResourceId is null. Allotted Resource Id is required to Get an allotted-resource.")\r
+ }else{\r
+ utils.log("DEBUG", "Incoming Allotted Resource Id is: " + allottedResourceId, isDebugEnabled)\r
+ if(isBlank(globalCustomerId) || isBlank(serviceType) || isBlank(serviceInstanceId)){\r
+ execution.setVariable("GENGS_obtainObjectsUrl", true)\r
+ }else{\r
+ utils.log("DEBUG", "Incoming Service Instance Id is: " + serviceInstanceId, isDebugEnabled)\r
+ utils.log("DEBUG", "Incoming Service Type is: " + serviceType, isDebugEnabled)\r
+ utils.log("DEBUG", "Incoming Global Customer Id is: " + globalCustomerId, isDebugEnabled)\r
+ }\r
+ }\r
+ }else if(type.equalsIgnoreCase("service-instance")){\r
if(isBlank(serviceInstanceId) && isBlank(serviceInstanceName)){\r
utils.log("DEBUG", "Incoming serviceInstanceId and serviceInstanceName are null. ServiceInstanceId or ServiceInstanceName is required to Get a service-instance.", isDebugEnabled)\r
exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Incoming serviceInstanceId and serviceInstanceName are null. ServiceInstanceId or ServiceInstanceName is required to Get a service-instance.")\r
utils.log("DEBUG", "Incoming Service Instance Id is: " + serviceInstanceId, isDebugEnabled)\r
utils.log("DEBUG", "Incoming Service Instance Name is: " + serviceInstanceName, isDebugEnabled)\r
if(isBlank(globalCustomerId) || isBlank(serviceType)){\r
- execution.setVariable("GENGS_obtainServiceInstanceUrl", true)\r
+ execution.setVariable("GENGS_obtainObjectsUrl", true)\r
if(isBlank(serviceInstanceId)){\r
execution.setVariable("GENGS_obtainServiceInstanceUrlByName", true)\r
}\r
execution.setVariable("prefix",Prefix)\r
utils.log("DEBUG", " *** STARTED GenericGetService ObtainServiceInstanceUrlById Process*** ", isDebugEnabled)\r
try {\r
- String serviceInstanceId = execution.getVariable("GENGS_serviceInstanceId")\r
- utils.log("DEBUG", " Querying Node for Service-Instance URL by using Service-Instance Id: " + serviceInstanceId, isDebugEnabled)\r
-\r
AaiUtil aaiUriUtil = new AaiUtil(this)\r
String aai_uri = aaiUriUtil.getSearchNodesQueryEndpoint(execution)\r
String aai_endpoint = execution.getVariable("URN_aai_endpoint")\r
- \r
- utils.logAudit("GenericGetService AAI Endpoint: " + aai_endpoint)\r
- String path = "${aai_uri}?search-node-type=service-instance&filter=service-instance-id:EQUALS:${serviceInstanceId}"\r
+\r
+ String type = execution.getVariable("GENGS_type")\r
+ String path = ""\r
+ if(type.equalsIgnoreCase("service-instance")){\r
+ String serviceInstanceId = execution.getVariable("GENGS_serviceInstanceId")\r
+ utils.log("DEBUG", " Querying Node for Service-Instance URL by using Service-Instance Id: " + serviceInstanceId, isDebugEnabled)\r
+ path = "${aai_uri}?search-node-type=service-instance&filter=service-instance-id:EQUALS:${serviceInstanceId}"\r
+ utils.logAudit("Service Instance Node Query Url is: " + path)\r
+ utils.log("DEBUG", "Service Instance Node Query Url is: " + path, isDebugEnabled)\r
+ }else if(type.equalsIgnoreCase("allotted-resource")){\r
+ String allottedResourceId = execution.getVariable("GENGS_allottedResourceId")\r
+ utils.log("DEBUG", " Querying Node for Service-Instance URL by using Allotted Resource Id: " + allottedResourceId, isDebugEnabled)\r
+ path = "${aai_uri}?search-node-type=allotted-resource&filter=id:EQUALS:${allottedResourceId}"\r
+ utils.logAudit("Allotted Resource Node Query Url is: " + path)\r
+ utils.log("DEBUG", "Allotted Resource Node Query Url is: " + path, isDebugEnabled)\r
+ }\r
\r
//String url = "${aai_endpoint}${path}" host name needs to be removed from property\r
String url = "${path}"\r
- execution.setVariable("GENGS_obtainSIUrlPath", url)\r
+ execution.setVariable("GENGS_genericQueryPath", url)\r
\r
APIResponse response = aaiUriUtil.executeAAIGetCall(execution, url)\r
int responseCode = response.getStatusCode()\r
- execution.setVariable("GENGS_obtainSIUrlResponseCode", responseCode)\r
+ execution.setVariable("GENGS_genericQueryResponseCode", responseCode)\r
utils.log("DEBUG", " GET Service Instance response code is: " + responseCode, isDebugEnabled)\r
utils.logAudit("GenericGetService AAI GET Response Code: " + responseCode)\r
\r
String aaiResponse = response.getResponseBodyAsString()\r
+ execution.setVariable("GENGS_obtainSIUrlResponseBeforeUnescaping", aaiResponse)\r
+ utils.log("DEBUG", "GenericGetService AAI Response before unescaping: " + aaiResponse, isDebugEnabled)\r
aaiResponse = StringEscapeUtils.unescapeXml(aaiResponse)\r
- execution.setVariable("GENGS_obtainSIUrlResponse", aaiResponse)\r
+ execution.setVariable("GENGS_genericQueryResponse", aaiResponse)\r
utils.logAudit("GenericGetService AAI Response: " + aaiResponse)\r
+ utils.log("DEBUG", "GenericGetService AAI Response: " + aaiResponse, isDebugEnabled)\r
+\r
//Process Response\r
if(responseCode == 200){\r
- utils.log("DEBUG", " Query for Service Instance Url Received a Good Response Code", isDebugEnabled)\r
+ utils.log("DEBUG", "Generic Query Received a Good Response Code", isDebugEnabled)\r
execution.setVariable("GENGS_SuccessIndicator", true)\r
if(utils.nodeExists(aaiResponse, "result-data")){\r
- utils.log("DEBUG", "Query for Service Instance Url Response Does Contain Data" , isDebugEnabled)\r
+ utils.log("DEBUG", "Generic Query Response Does Contain Data" , isDebugEnabled)\r
execution.setVariable("GENGS_FoundIndicator", true)\r
String resourceLink = utils.getNodeText1(aaiResponse, "resource-link")\r
+ execution.setVariable("GENGS_resourceLink", resourceLink)\r
execution.setVariable("GENGS_siResourceLink", resourceLink)\r
}else{\r
- utils.log("DEBUG", "Query for Service Instance Url Response Does NOT Contains Data" , isDebugEnabled)\r
+ utils.log("DEBUG", "Generic Query Response Does NOT Contains Data" , isDebugEnabled)\r
execution.setVariable("WorkflowResponse", " ") //for junits\r
}\r
}else if(responseCode == 404){\r
- utils.log("DEBUG", " Query for Service Instance Received a Not Found (404) Response", isDebugEnabled)\r
+ utils.log("DEBUG", "Generic Query Received a Not Found (404) Response", isDebugEnabled)\r
execution.setVariable("GENGS_SuccessIndicator", true)\r
execution.setVariable("WorkflowResponse", " ") //for junits\r
}else{\r
- utils.log("DEBUG", "Query for Service Instance Received a BAD REST Response: \n" + aaiResponse, isDebugEnabled)\r
+ utils.log("DEBUG", "Generic Query Received a BAD REST Response: \n" + aaiResponse, isDebugEnabled)\r
exceptionUtil.MapAAIExceptionToWorkflowExceptionGeneric(execution, aaiResponse, responseCode)\r
throw new BpmnError("MSOWorkflowException")\r
}\r
execution.setVariable("GENGS_obtainSIUrlResponseCode", responseCode)\r
utils.log("DEBUG", " GET Service Instance response code is: " + responseCode, isDebugEnabled)\r
utils.logAudit("GenericGetService AAI Response Code: " + responseCode)\r
- \r
+\r
String aaiResponse = response.getResponseBodyAsString()\r
aaiResponse = StringEscapeUtils.unescapeXml(aaiResponse)\r
execution.setVariable("GENGS_obtainSIUrlResponse", aaiResponse)\r
- utils.logAudit("GenericGetService AAI Response: " + aaiResponse) \r
+ utils.logAudit("GenericGetService AAI Response: " + aaiResponse)\r
//Process Response\r
if(responseCode == 200){\r
utils.log("DEBUG", " Query for Service Instance Url Received a Good Response Code", isDebugEnabled)\r
utils.log("DEBUG", "Query for Service Instance Url Response Does Contain Data" , isDebugEnabled)\r
execution.setVariable("GENGS_FoundIndicator", true)\r
String resourceLink = utils.getNodeText1(aaiResponse, "resource-link")\r
+ execution.setVariable("GENGS_resourceLink", resourceLink)\r
execution.setVariable("GENGS_siResourceLink", resourceLink)\r
}else{\r
utils.log("DEBUG", "Query for Service Instance Url Response Does NOT Contains Data" , isDebugEnabled)\r
AaiUtil aaiUriUtil = new AaiUtil(this)\r
String aai_endpoint = execution.getVariable("URN_aai_endpoint")\r
String serviceEndpoint = ""\r
- \r
+\r
utils.logAudit("GenericGetService getServiceObject AAI Endpoint: " + aai_endpoint)\r
if(type.equalsIgnoreCase("service-instance")){\r
- String siResourceLink = execution.getVariable("GENGS_siResourceLink")\r
+ String siResourceLink = execution.getVariable("GENGS_resourceLink")\r
if(isBlank(siResourceLink)){\r
String serviceInstanceId = execution.getVariable("GENGS_serviceInstanceId")\r
utils.log("DEBUG", " Incoming GENGS_serviceInstanceId is: " + serviceInstanceId, isDebugEnabled)\r
logDebug('AAI URI is: ' + aai_uri, isDebugEnabled)\r
serviceEndpoint = "${aai_uri}/" + UriUtils.encode(globalCustomerId,"UTF-8") + "/service-subscriptions/service-subscription/" + UriUtils.encode(serviceType,"UTF-8") + "/service-instances/service-instance/" + UriUtils.encode(serviceInstanceId,"UTF-8")\r
}else{\r
- utils.log("DEBUG", "Incoming Service Instance Resource Link is: " + siResourceLink, isDebugEnabled)\r
+ utils.log("DEBUG", "Incoming Service Instance Url is: " + siResourceLink, isDebugEnabled)\r
+ String[] split = siResourceLink.split("/aai/")\r
+ serviceEndpoint = "/aai/" + split[1]\r
+ }\r
+ }else if(type.equalsIgnoreCase("allotted-resource")){\r
+ String siResourceLink = execution.getVariable("GENGS_resourceLink")\r
+ if(isBlank(siResourceLink)){\r
+ String allottedResourceId = execution.getVariable("GENGS_allottedResourceId")\r
+ utils.log("DEBUG", " Incoming GENGS_allottedResourceId is: " + allottedResourceId, isDebugEnabled)\r
+ String serviceInstanceId = execution.getVariable("GENGS_serviceInstanceId")\r
+ utils.log("DEBUG", " Incoming GENGS_serviceInstanceId is: " + serviceInstanceId, isDebugEnabled)\r
+ String serviceType = execution.getVariable("GENGS_serviceType")\r
+ utils.log("DEBUG", " Incoming GENGS_serviceType is: " + serviceType, isDebugEnabled)\r
+ String globalCustomerId = execution.getVariable("GENGS_globalCustomerId")\r
+ utils.log("DEBUG", "Incoming Global Customer Id is: " + globalCustomerId, isDebugEnabled)\r
+\r
+ String aai_uri = aaiUriUtil.getBusinessCustomerUri(execution)\r
+ logDebug('AAI URI is: ' + aai_uri, isDebugEnabled)\r
+ serviceEndpoint = "${aai_uri}/" + UriUtils.encode(globalCustomerId,"UTF-8") + "/service-subscriptions/service-subscription/" + UriUtils.encode(serviceType,"UTF-8") + "/service-instances/service-instance/" + UriUtils.encode(serviceInstanceId,"UTF-8") + "/allotted-resources/allotted-resource/" + UriUtils.encode(allottedResourceId,"UTF-8")\r
+ }else{\r
+ utils.log("DEBUG", "Incoming Allotted-Resource Url is: " + siResourceLink, isDebugEnabled)\r
String[] split = siResourceLink.split("/aai/")\r
serviceEndpoint = "/aai/" + split[1]\r
}\r
execution.setVariable("GENGS_getServiceResponseCode", responseCode)\r
utils.log("DEBUG", " GET Service response code is: " + responseCode, isDebugEnabled)\r
utils.logAudit("GenericGetService AAI Response Code: " + responseCode)\r
- \r
+\r
String aaiResponse = response.getResponseBodyAsString()\r
aaiResponse = StringEscapeUtils.unescapeXml(aaiResponse)\r
execution.setVariable("GENGS_getServiceResponse", aaiResponse)\r
utils.logAudit("GenericGetService AAI Response: " + aaiResponse)\r
- \r
//Process Response\r
if(responseCode == 200 || responseCode == 202){\r
utils.log("DEBUG", "GET Service Received a Good Response Code", isDebugEnabled)\r
utils.log("DEBUG", " *** COMPLETED GenericGetService GetServiceObject Process*** ", isDebugEnabled)\r
}\r
\r
-}\r
+}
\ No newline at end of file
\r
package org.openecomp.mso.bpmn.common.scripts\r
\r
-import static org.apache.commons.lang3.StringUtils.*\r
+import static org.openecomp.mso.bpmn.common.scripts.GenericUtils.*;\r
\r
import org.apache.commons.lang3.*\r
import org.camunda.bpm.engine.delegate.BpmnError\r
*
*
* Incoming Required Variables:
+ * @param - GENPS_requestId
* @param - GENPS_type - Required field. This will be required field populated as service-instance or service-subscription
* @param - GENPS_globalSubscriberId - Required field
* @param - GENPS_serviceType - Required Field
* @param - GENPS_allottedResourceId - Conditional Field. Required for allotted-resource.
* @param - GENPS_tunnelXconnectId - Conditional Field. Required for tunnel-xconnect.
*
- * @param - GENPS_requestId to trace the request id
- * @param - GENPS_serviceResourceVersion optional needs to be provided only in case of update for both service-instance and service subscription. The calling flows
+ * @param - GENPS_serviceResourceVersion - Conditional Field. Needs to be provided only in case of update for both service-instance and service subscription. The calling flows
* should check if a service-instance or servic-subscription exists by calling the subflow GenericGetService. if it exists then resourceversion should be
* obtained from aai and sent as an input parameter.
*
AaiUtil aaiUriUtil = new AaiUtil(this)
String aai_uri = aaiUriUtil.getBusinessCustomerUri(execution)
logDebug('AAI URI is: ' + aai_uri, isDebugEnabled)
- String namespace = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String namespace = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
logDebug('AAI namespace is: ' + namespace, isDebugEnabled)
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
--- /dev/null
+package org.openecomp.mso.bpmn.common.scripts\r
+\r
+import org.apache.commons.lang3.StringUtils;\r
+\r
+class GenericUtils extends StringUtils{\r
+\r
+ @Override\r
+ public static boolean isBlank(final CharSequence cs) {\r
+ int strLen;\r
+ if (cs == null || (strLen = cs.length()) == 0 || cs.equals("null")) {\r
+ return true;\r
+ }\r
+ for (int i = 0; i < strLen; i++) {\r
+ if (Character.isWhitespace(cs.charAt(i)) == false) {\r
+ return false;\r
+ }\r
+ }\r
+ return true;\r
+ }\r
+}\r
if (modelVersionId == null) {\r
modelVersionId = ""\r
}\r
- String modelCustomizationUuid = jsonUtil.getJsonValue(jsonModelInfo, "modelCustomizationId")\r
+ String modelCustomizationUuid = jsonUtil.getJsonValue(jsonModelInfo, "modelCustomizationUuid")\r
String modelCustomizationString = ""\r
if (modelCustomizationUuid != null) {\r
modelCustomizationString = "<model-customization-uuid>${modelCustomizationUuid}</model-customization-uuid>"\r
\r
\r
public class UpdateAAIGenericVnf extends AbstractServiceTaskProcessor {\r
- \r
+\r
private XmlParser xmlParser = new XmlParser()\r
ExceptionUtil exceptionUtil = new ExceptionUtil()\r
\r
execution.setVariable('UAAIGenVnf_personaModelVersion', null)\r
execution.setVariable("UAAIGenVnf_ipv4OamAddress", null)\r
execution.setVariable('UAAIGenVnf_managementV6Address', null)\r
+ execution.setVariable('UAAIGenVnf_orchestrationStatus', null)\r
execution.setVariable('UAAIGenVnf_getGenericVnfResponseCode' ,null)\r
execution.setVariable('UAAIGenVnf_getGenericVnfResponse', '')\r
execution.setVariable('UAAIGenVnf_updateGenericVnfResponseCode', null)\r
execution.setVariable('UAAIGenVnf_updateGenericVnfResponse', '')\r
}\r
- \r
+\r
/**\r
* Check for missing elements in the received request.\r
*\r
if (managementV6Address != null && !managementV6Address.isEmpty()) {\r
execution.setVariable('UAAIGenVnf_managementV6Address', managementV6Address)\r
}\r
+ \r
+ def orchestrationStatus = getNodeTextForce(xml, 'orchestration-status')\r
+ if (orchestrationStatus != null && !orchestrationStatus.isEmpty()) {\r
+ execution.setVariable('UAAIGenVnf_orchestrationStatus', orchestrationStatus)\r
+ }\r
\r
logDebug('Exited ' + method, isDebugLogEnabled)\r
} catch (BpmnError e) {\r
exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in preProcessRequest(): ' + e.getMessage())\r
}\r
}\r
- \r
+\r
/**\r
* Using the received vnfId, query AAI to get the corresponding Generic VNF.\r
* A 200 response is expected with the VF Module in the response body.\r
if (newPersonaModelId != null || newPersonaModelVersion != null) {\r
\r
// Confirm "new" persona-model-id is same as "current" persona-model-id\r
- def Node currPersonaModelIdNode = utils.getChildNode(genericVnfNode, 'persona-model-id')\r
+ def Node currPersonaModelIdNode = utils.getChildNode(genericVnfNode, 'model-invariant-id')\r
+ if (currPersonaModelIdNode == null) {\r
+ // check the old attribute name\r
+ currPersonaModelIdNode = utils.getChildNode(genericVnfNode, 'persona-model-id')\r
+ }\r
def String currPersonaModelId = ''\r
if (currPersonaModelIdNode != null) {\r
currPersonaModelId = currPersonaModelIdNode.text()\r
}\r
\r
// Construct payload\r
- personaModelVersionEntry = updateGenericVnfNode(origRequest, genericVnfNode, 'persona-model-version')\r
+ personaModelVersionEntry = updateGenericVnfNode(origRequest, genericVnfNode, 'model-version-id')\r
}\r
\r
// Handle ipv4-oam-address\r
// Construct payload\r
managementV6AddressEntry = updateGenericVnfNode(origRequest, genericVnfNode, 'management-v6-address')\r
}\r
+ \r
+ // Handle orchestration-status\r
+ def String orchestrationStatus = execution.getVariable('UAAIGenVnf_orchestrationStatus')\r
+ def String orchestrationStatusEntry = ""\r
+ if (orchestrationStatus != null) {\r
+ // Construct payload\r
+ orchestrationStatusEntry = updateGenericVnfNode(origRequest, genericVnfNode, 'orchestration-status')\r
+ }\r
\r
def payload = """\r
{ ${personaModelVersionEntry}\r
${ipv4OamAddressEntry}\r
- ${managementV6AddressEntry} \r
+ ${managementV6AddressEntry}\r
+ ${orchestrationStatusEntry}\r
"vnf-id": "${vnfId}" \r
}\r
"""\r
}\r
\r
/**\r
- * Construct and send a PUT request to AAI to update the VF Module.\r
+ * Construct and send a PATCH request to AAI to update the VF Module.\r
*\r
* @param execution The flow's execution instance.\r
*/\r
doPersonaModelVersion = false\r
} else {\r
// Confirm "new" persona-model-id is same as "current" persona-model-id\r
- def String currPersonaModelId = utils.getChildNodeText(vfModuleNode, 'persona-model-id')\r
+ def String currPersonaModelId = utils.getChildNodeText(vfModuleNode, 'model-invariant-id')\r
+ if (currPersonaModelId == null) {\r
+ // check the old attribute name\r
+ currPersonaModelId = utils.getChildNodeText(vfModuleNode, 'model-version-id')\r
+ }\r
if (currPersonaModelId == null) {\r
currPersonaModelId = ''\r
}\r
\r
/**\r
* Get the XmlParser.\r
- *\r
+ * \r
* @return the XmlParser.\r
*/\r
protected XmlParser getXmlParser() {\r
/**\r
* Find the VF Module with specified ID in the specified Generic VF. If no such\r
* VF Module is found, null is returned.\r
- *\r
+ * \r
* @param genericVnf The Generic VNF in which to search for the specified VF Moduel.\r
* @param vfModuleId The ID of the VF Module for which to search.\r
* @return a VFModule object for the found VF Module or null if no VF Module is found.\r
* element to a corresponding list of 'vnf-networks' specifications (typically used when\r
* invoking the VNF Rest Adpater). Each element in '*-params' whose name attribute ends\r
* with '_network' is used to create an 'vnf-networks' element.\r
- *\r
+ * \r
* @param paramsNode A Node representing a '*-params' element.\r
* @return a String of 'vnf-networks' elements, one for each 'param' element whose name\r
* attribute ends with '_network'.\r
\r
/**\r
* Extract the Tenant Id from the Volume Group information returned by AAI.\r
- *\r
+ * \r
* @param volumeGroupXml Volume Group XML returned by AAI.\r
* @return the Tenant Id extracted from the Volume Group information. 'null' is returned if\r
* the Tenant Id is missing or could not otherwise be extracted.\r
*/\r
\r
\r
- protected String buildVfModuleParams(String vnfParams, String sdncGetResponse, String vnfId, String vnfName,\r
+ protected String buildVfModuleParams(Map<String, String> vnfParamsMap, String sdncGetResponse, String vnfId, String vnfName,\r
String vfModuleId, String vfModuleName, String vfModuleIndex) {\r
\r
//Get SDNC Response Data\r
oldVnfId = utils.removeXmlNamespaces(oldVnfId)\r
serviceData = serviceData.replace(oldVnfId, "")\r
def vnfId1 = utils.getNodeText1(serviceData, "vnf-id")\r
- String vfModuleIndexParam = ""\r
+ \r
+ Map<String, String> paramsMap = new HashMap<String, String>()\r
\r
if (vfModuleIndex != null) {\r
- vfModuleIndexParam = """<entry>\r
- <key>vf_module_index</key>\r
- <value>${vfModuleIndex}</value>\r
- </entry>"""\r
+ paramsMap.put("vf_module_index", "${vfModuleIndex}")\r
}\r
\r
// Add-on data\r
- String vnfInfo =\r
- """<entry>\r
- <key>vnf_id</key>\r
- <value>${vnfId}</value>\r
- </entry>\r
- <entry>\r
- <key>vnf_name</key>\r
- <value>${vnfName}</value>\r
- </entry>\r
- <entry>\r
- <key>vf_module_id</key>\r
- <value>${vfModuleId}</value>\r
- </entry>\r
- <entry>\r
- <key>vf_module_name</key>\r
- <value>${vfModuleName}</value>\r
- </entry>\r
- ${vfModuleIndexParam}"""\r
-\r
- utils.logAudit("vnfInfo: " + vnfInfo)\r
+ paramsMap.put("vnf_id", "${vnfId}")\r
+ paramsMap.put("vnf_name", "${vnfName}")\r
+ paramsMap.put("vf_module_id", "${vfModuleId}")\r
+ paramsMap.put("vf_module_name", "${vfModuleName}")\r
+ \r
InputSource source = new InputSource(new StringReader(data));\r
DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();\r
docFactory.setNamespaceAware(true)\r
\r
\r
// Availability Zones Data\r
- String aZones = ""\r
- StringBuilder sbAZone = new StringBuilder()\r
\r
NodeList aZonesList = responseXml.getElementsByTagNameNS("*", "availability-zones")\r
String aZonePosition = "0"\r
Element eElement = (Element) node\r
String aZoneValue = utils.getElementText(eElement, "availability-zone")\r
aZonePosition = z.toString()\r
- String aZoneXml =\r
- """<entry>\r
- <key>availability_zone_${aZonePosition}</key>\r
- <value>${aZoneValue}</value>\r
- </entry>"""\r
- aZones = sbAZone.append(aZoneXml)\r
+ paramsMap.put("availability_zone_${aZonePosition}", "${aZoneValue}")\r
}\r
}\r
\r
// VNF Networks Data\r
- String vnfNetworkNetId = ""\r
- String vnfNetworkNetName = ""\r
- String vnfNetworkSubNetId = ""\r
- String vnfNetworkV6SubNetId = ""\r
- String vnfNetworkNetFqdn = ""\r
- String vnfNetworksSriovVlanFilters = ""\r
+ \r
StringBuilder sbNet = new StringBuilder()\r
- StringBuilder sbNet2 = new StringBuilder()\r
- StringBuilder sbNet3 = new StringBuilder()\r
- StringBuilder sbNet4 = new StringBuilder()\r
- StringBuilder sbNet5 = new StringBuilder()\r
- StringBuilder sbNet6 = new StringBuilder()\r
+ \r
NodeList vnfNetworkList = responseXml.getElementsByTagNameNS("*", "vnf-networks")\r
for (int x = 0; x < vnfNetworkList.getLength(); x++) {\r
Node node = vnfNetworkList.item(x)\r
String vnfNetworkSubNetIdValue = utils.getElementText(eElement, "subnet-id")\r
String vnfNetworkV6SubNetIdValue = utils.getElementText(eElement, "ipv6-subnet-id")\r
String vnfNetworkNetFqdnValue = utils.getElementText(eElement, "contrail-network-fqdn")\r
- String vnfNetworkNetIdXml =\r
- """<entry>\r
- <key>${vnfNetworkKey}_net_id</key>\r
- <value>${vnfNetworkNeutronIdValue}</value>\r
- </entry>"""\r
- vnfNetworkNetId = sbNet.append(vnfNetworkNetIdXml)\r
- String vnfNetworkNetNameXml =\r
- """<entry>\r
- <key>${vnfNetworkKey}_net_name</key>\r
- <value>${vnfNetworkNetNameValue}</value>\r
- </entry>"""\r
- vnfNetworkNetName = sbNet2.append(vnfNetworkNetNameXml)\r
- String vnfNetworkSubNetIdXml =\r
- """<entry>\r
- <key>${vnfNetworkKey}_subnet_id</key>\r
- <value>${vnfNetworkSubNetIdValue}</value>\r
- </entry>"""\r
- vnfNetworkSubNetId = sbNet3.append(vnfNetworkSubNetIdXml)\r
- String vnfNetworkV6SubNetIdXml =\r
- """<entry>\r
- <key>${vnfNetworkKey}_v6_subnet_id</key>\r
- <value>${vnfNetworkV6SubNetIdValue}</value>\r
- </entry>"""\r
- vnfNetworkV6SubNetId = sbNet5.append(vnfNetworkV6SubNetIdXml)\r
- String vnfNetworkNetFqdnXml =\r
- """<entry>\r
- <key>${vnfNetworkKey}_net_fqdn</key>\r
- <value>${vnfNetworkNetFqdnValue}</value>\r
- </entry>"""\r
- vnfNetworkNetFqdn = sbNet4.append(vnfNetworkNetFqdnXml)\r
+ paramsMap.put("${vnfNetworkKey}_net_id", "${vnfNetworkNeutronIdValue}")\r
+ paramsMap.put("${vnfNetworkKey}_net_name", "${vnfNetworkNetNameValue}")\r
+ paramsMap.put("${vnfNetworkKey}_subnet_id", "${vnfNetworkSubNetIdValue}")\r
+ paramsMap.put("${vnfNetworkKey}_v6_subnet_id", "${vnfNetworkV6SubNetIdValue}")\r
+ paramsMap.put("${vnfNetworkKey}_net_fqdn", "${vnfNetworkNetFqdnValue}")\r
\r
NodeList sriovVlanFilterList = eElement.getElementsByTagNameNS("*","sriov-vlan-filter-list")\r
StringBuffer sriovFilterBuf = new StringBuffer()\r
}\r
}\r
if (!values.isEmpty()) {\r
- String vnfNetworkSriovVlanFilterXml =\r
- """<entry>\r
- <key>${vnfNetworkKey}_ATT_VF_VLAN_FILTER</key>\r
- <value>${values}</value>\r
- </entry>"""\r
- vnfNetworksSriovVlanFilters = sbNet6.append(vnfNetworkSriovVlanFilterXml)\r
+ paramsMap.put("${vnfNetworkKey}_ATT_VF_VLAN_FILTER", "${values}")\r
}\r
}\r
}\r
\r
// VNF-VMS Data\r
- String vnfVMS = ""\r
- String vnfVMSPositions = ""\r
- String vmNetworks = ""\r
- String vmNetworksPositions = ""\r
- String vmNetworksPositionsV6 = ""\r
- String interfaceRoutePrefixes = ""\r
+ \r
def key\r
def value\r
def networkKey\r
def floatingIPV6Key\r
def floatingIPV6KeyValue\r
StringBuilder sb = new StringBuilder()\r
- StringBuilder sbPositions = new StringBuilder()\r
- StringBuilder sbVmNetworks = new StringBuilder()\r
- StringBuilder sbNetworksPositions = new StringBuilder()\r
- StringBuilder sbInterfaceRoutePrefixes = new StringBuilder()\r
- StringBuilder sbNetworksPositionsV6 = new StringBuilder()\r
\r
NodeList vmsList = responseXml.getElementsByTagNameNS("*","vnf-vms")\r
for (int x = 0; x < vmsList.getLength(); x++) {\r
values = sb1.append(value);\r
}\r
position = i.toString()\r
- String vnfPositionXml =\r
- """<entry>\r
- <key>${key}_name_${position}</key>\r
- <value>${value}</value>\r
- </entry>"""\r
- vnfVMSPositions = sbPositions.append(vnfPositionXml)\r
+ paramsMap.put("${key}_name_${position}", "${value}")\r
}\r
}\r
for(int n = 0; n < vmNetworksList.getLength(); n++){\r
networkKey = utils.getElementText(eElementNetworkKey, "network-role")\r
floatingIPKey = key + '_' + networkKey + '_floating_ip'\r
floatingIPKeyValue = utils.getElementText(eElementNetworkKey, "floating-ip")\r
- if(!floatingIPKeyValue.isEmpty()){ \r
- floatingIpKeyValueStr = """<entry>\r
- <key>$floatingIPKey</key>\r
- <value>$floatingIPKeyValue</value>\r
- </entry>"""\r
+ if(!floatingIPKeyValue.isEmpty()){\r
+ paramsMap.put("$floatingIPKey", "$floatingIPKeyValue")\r
}\r
floatingIPV6Key = key + '_' + networkKey + '_floating_v6_ip'\r
floatingIPV6KeyValue = utils.getElementText(eElementNetworkKey, "floating-ip-v6")\r
- if(!floatingIPV6KeyValue.isEmpty()){ \r
- floatingIpV6KeyValueStr = """<entry>\r
- <key>$floatingIPV6Key</key>\r
- <value>$floatingIPV6KeyValue</value>\r
- </entry>"""\r
+ if(!floatingIPV6KeyValue.isEmpty()){\r
+ paramsMap.put("$floatingIPV6Key", "$floatingIPV6KeyValue")\r
}\r
NodeList networkIpsList = eElementNetworkKey.getElementsByTagNameNS("*","network-ips")\r
for(int a = 0; a < networkIpsList.getLength(); a++){\r
ipAddressValues = sb2.append(ipAddressValue);\r
}\r
networkPosition = a.toString()\r
- String vmNetworksPositionsXml =\r
- """<entry>\r
- <key>${key}_${networkKey}_ip_${networkPosition}</key>\r
- <value>${ipAddressValue}</value>\r
- </entry>"""\r
- vmNetworksPositions = sbNetworksPositions.append(vmNetworksPositionsXml)\r
+ paramsMap.put("${key}_${networkKey}_ip_${networkPosition}", "${ipAddressValue}")\r
}\r
}\r
- vmNetworksPositions = sbNetworksPositions.append(floatingIpKeyValueStr).append(floatingIpV6KeyValueStr)\r
- \r
- String vmNetworksXml =\r
- """<entry>\r
- <key>${key}_${networkKey}_ips</key>\r
- <value>${ipAddressValues}</value>\r
- </entry>"""\r
- vmNetworks = sbVmNetworks.append(vmNetworksXml)\r
+ \r
+ paramsMap.put("${key}_${networkKey}_ips", "${ipAddressValues}")\r
\r
NodeList interfaceRoutePrefixesList = eElementNetworkKey.getElementsByTagNameNS("*","interface-route-prefixes")\r
String interfaceRoutePrefixValues = sb3.append("[")\r
\r
- for(int a = 0; a < interfaceRoutePrefixesList.getLength(); a++){ \r
- Node interfaceRoutePrefix = interfaceRoutePrefixesList.item(a) \r
+ for(int a = 0; a < interfaceRoutePrefixesList.getLength(); a++){\r
+ Node interfaceRoutePrefix = interfaceRoutePrefixesList.item(a)\r
if (interfaceRoutePrefix.getNodeType() == Node.ELEMENT_NODE) {\r
Element eElementInterfaceRoutePrefix = (Element) interfaceRoutePrefix\r
String interfaceRoutePrefixValue = utils.getElementText(eElementInterfaceRoutePrefix, "interface-route-prefix-cidr")\r
if (interfaceRoutePrefixValue == null || interfaceRoutePrefixValue.isEmpty()) {\r
interfaceRoutePrefixValue = utils.getElementText(eElementInterfaceRoutePrefix, "interface-route-prefix")\r
}\r
- if (a != interfaceRoutePrefixesList.getLength() - 1) { \r
+ if (a != interfaceRoutePrefixesList.getLength() - 1) {\r
interfaceRoutePrefixValues = sb3.append("{\"interface_route_table_routes_route_prefix\": \"" + interfaceRoutePrefixValue + "\"}" + ",")\r
}\r
else {\r
interfaceRoutePrefixValues = sb3.append("{\"interface_route_table_routes_route_prefix\": \"" + interfaceRoutePrefixValue + "\"}")\r
- } \r
+ }\r
}\r
}\r
interfaceRoutePrefixValues = sb3.append("]")\r
if (interfaceRoutePrefixesList.getLength() > 0) {\r
- String interfaceRoutePrefixesXml = \r
- """<entry>\r
- <key>${key}_${networkKey}_route_prefixes</key>\r
- <value>${interfaceRoutePrefixValues}</value>\r
- </entry>""" \r
- interfaceRoutePrefixes = sbInterfaceRoutePrefixes.append(interfaceRoutePrefixesXml)\r
+ paramsMap.put("${key}_${networkKey}_route_prefixes", "${interfaceRoutePrefixValues}")\r
}\r
\r
NodeList networkIpsV6List = eElementNetworkKey.getElementsByTagNameNS("*","network-ips-v6")\r
ipV6AddressValues = sb4.append(ipV6AddressValue);\r
}\r
networkPosition = a.toString()\r
- String vmNetworksPositionsV6Xml =\r
- """<entry>\r
- <key>${key}_${networkKey}_v6_ip_${networkPosition}</key>\r
- <value>${ipV6AddressValue}</value>\r
- </entry>"""\r
- vmNetworksPositionsV6 = sbNetworksPositionsV6.append(vmNetworksPositionsV6Xml)\r
+ paramsMap.put("${key}_${networkKey}_v6_ip_${networkPosition}", "${ipV6AddressValue}")\r
}\r
}\r
- String vmNetworksV6Xml =\r
- """<entry>\r
- <key>${key}_${networkKey}_v6_ips</key>\r
- <value>${ipV6AddressValues}</value>\r
- </entry>"""\r
- vmNetworks = sbVmNetworks.append(vmNetworksV6Xml)\r
+ paramsMap.put("${key}_${networkKey}_v6_ips", "${ipV6AddressValues}")\r
}\r
}\r
- String vnfXml =\r
- """<entry>\r
- <key>${key}_names</key>\r
- <value>${values}</value>\r
- </entry>"""\r
- vnfVMS = sb.append(vnfXml)\r
+ paramsMap.put("${key}_names", "${values}")\r
}\r
}\r
//SDNC Response Params\r
String vnfParamsChildNodes = utils.getChildNodes(data, "vnf-parameters")\r
if(vnfParamsChildNodes == null || vnfParamsChildNodes.length() < 1){\r
// No SDNC params\r
- }else{ \r
+ }else{\r
NodeList paramsList = responseXml.getElementsByTagNameNS("*", "vnf-parameters")\r
for (int z = 0; z < paramsList.getLength(); z++) {\r
Node node = paramsList.item(z)\r
String vnfParameterName = utils.getElementText(eElement, "vnf-parameter-name")\r
if (!sdncResponseParamsToSkip.contains(vnfParameterName)) {\r
String vnfParameterValue = utils.getElementText(eElement, "vnf-parameter-value")\r
- String paraEntry =\r
- """<entry>\r
- <key>${vnfParameterName}</key>\r
- <value>${vnfParameterValue}</value>\r
- </entry>"""\r
- sdncResponseParams = sb.append(paraEntry)\r
+ paramsMap.put("${vnfParameterName}", "${vnfParameterValue}")\r
}\r
}\r
}\r
+ \r
+ // Parameters received from the request should overwrite any parameters received from SDNC\r
+ if (vnfParamsMap != null) {\r
+ for (Map.Entry<String, String> entry : vnfParamsMap.entrySet()) {\r
+ String vnfKey = entry.getKey()\r
+ String vnfValue = entry.getValue()\r
+ paramsMap.put("$vnfKey", "$vnfValue")\r
+ }\r
+ }\r
+ \r
+ StringBuilder sbParams = new StringBuilder()\r
+ def vfModuleParams = ""\r
+ for (Map.Entry<String, String> entry : paramsMap.entrySet()) {\r
+ String paramsXml\r
+ String paramName = entry.getKey()\r
+ String paramValue = entry.getValue()\r
+ paramsXml =\r
+ """<entry>\r
+ <key>${paramName}</key>\r
+ <value>${paramValue}</value>\r
+ </entry>\r
+ """\r
\r
-\r
- def vfModuleParams = """\r
- ${vnfInfo}\r
- ${aZones}\r
- ${vnfNetworkNetId}\r
- ${vnfNetworkNetName}\r
- ${vnfNetworkSubNetId}\r
- ${vnfNetworkV6SubNetId}\r
- ${vnfNetworkNetFqdn}\r
- ${vnfNetworksSriovVlanFilters}\r
- ${vnfVMS}\r
- ${vnfVMSPositions}\r
- ${vmNetworks}\r
- ${vmNetworksPositions}\r
- ${vmNetworksPositionsV6}\r
- ${interfaceRoutePrefixes}\r
- ${vnfParams}\r
- ${sdncResponseParams}"""\r
+ vfModuleParams = sbParams.append(paramsXml)\r
+ }\r
\r
return vfModuleParams\r
\r
\r
\r
/*\r
- * VBNG specific method that parses VNF parameters passed in on the\r
+ * VBNG specific method that parses VNF parameters passed in on the \r
* incoming requests and SDNC parameters returned from SDNC get response\r
* and puts them into the format expected by VNF adapter.\r
* @param vnfParamsMap - map of VNF parameters passed in the request body\r
--- /dev/null
+package org.openecomp.mso.bpmn.common.workflow.service;\r
+\r
+import java.util.ArrayList;\r
+import java.util.HashMap;\r
+import java.util.List;\r
+import java.util.Map;\r
+\r
+import org.camunda.bpm.BpmPlatform;\r
+import org.camunda.bpm.engine.MismatchingMessageCorrelationException;\r
+import org.camunda.bpm.engine.ProcessEngineServices;\r
+import org.camunda.bpm.engine.RuntimeService;\r
+import org.camunda.bpm.engine.runtime.Execution;\r
+import org.camunda.bpm.engine.runtime.MessageCorrelationResult;\r
+import org.openecomp.mso.bpmn.core.PropertyConfiguration;\r
+import org.openecomp.mso.logger.MessageEnum;\r
+import org.openecomp.mso.logger.MsoLogger;\r
+\r
+/**\r
+ * Abstract base class for callback services.\r
+ */\r
+public abstract class AbstractCallbackService {\r
+ public static final long DEFAULT_TIMEOUT_SECONDS = 60;\r
+ public static final long FAST_POLL_DUR_SECONDS = 5;\r
+ public static final long FAST_POLL_INT_MS = 100;\r
+ public static final long SLOW_POLL_INT_MS = 1000;\r
+ \r
+ private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);\r
+\r
+ protected volatile ProcessEngineServices pes4junit = null;\r
+ \r
+ /**\r
+ * Parameterized callback handler.\r
+ */\r
+ protected CallbackResult handleCallback(String method, Object message,\r
+ String messageEventName, String messageVariable,\r
+ String correlationVariable, String correlationValue,\r
+ String logMarker) {\r
+\r
+ return handleCallback(method, message, messageEventName, messageVariable,\r
+ correlationVariable, correlationValue, logMarker, null);\r
+ }\r
+\r
+ /**\r
+ * Parameterized callback handler.\r
+ */\r
+ protected CallbackResult handleCallback(String method, Object message,\r
+ String messageEventName, String messageVariable,\r
+ String correlationVariable, String correlationValue,\r
+ String logMarker, Map<String, Object> injectedVariables) {\r
+\r
+ long startTime = System.currentTimeMillis();\r
+\r
+ LOGGER.debug(logMarker + " " + method + " received message: "\r
+ + (message == null ? "" : System.lineSeparator()) + message);\r
+\r
+ try {\r
+ Map<String, Object> variables = new HashMap<String, Object>();\r
+\r
+ if (injectedVariables != null) {\r
+ variables.putAll(injectedVariables);\r
+ }\r
+\r
+ variables.put(correlationVariable, correlationValue);\r
+ variables.put(messageVariable, message == null ? null : message.toString());\r
+\r
+ boolean ok = correlate(messageEventName, correlationVariable,\r
+ correlationValue, variables, logMarker);\r
+\r
+ if (!ok) {\r
+ String msg = "No process is waiting for " + messageEventName\r
+ + " with " + correlationVariable + " = '" + correlationValue + "'";\r
+ logCallbackError(method, startTime, msg);\r
+ return new CallbackError(msg);\r
+ }\r
+\r
+ logCallbackSuccess(method, startTime);\r
+ return new CallbackSuccess();\r
+ } catch (Exception e) {\r
+ String msg = "Caught " + e.getClass().getSimpleName()\r
+ + " processing " + messageEventName + " with " + correlationVariable\r
+ + " = '" + correlationValue + "'";\r
+ logCallbackError(method, startTime, msg);\r
+ return new CallbackError(msg);\r
+ }\r
+ }\r
+ \r
+ /**\r
+ * Performs message correlation. Waits a limited amount of time for\r
+ * a process to become ready for correlation. The return value indicates\r
+ * whether or not a process was found to receive the message. Due to the\r
+ * synchronous nature of message injection in Camunda, by the time this\r
+ * method returns, one of 3 things will have happened: (1) the process\r
+ * received the message and ended, (2) the process received the message\r
+ * and reached an activity that suspended, or (3) an exception occurred\r
+ * during correlation or while the process was executing. Correlation\r
+ * exceptions are handled differently from process execution exceptions.\r
+ * Correlation exceptions are thrown so the client knows something went\r
+ * wrong with the delivery of the message. Process execution exceptions\r
+ * are logged but not thrown.\r
+ * @param messageEventName the message event name\r
+ * @param correlationVariable the process variable used as the correlator\r
+ * @param correlationValue the correlation value\r
+ * @param variables variables to inject into the process\r
+ * @param logMarker a marker for debug logging\r
+ * @return true if a process could be found, false if not\r
+ * @throws Exception for correlation errors\r
+ */\r
+ protected boolean correlate(String messageEventName, String correlationVariable,\r
+ String correlationValue, Map<String, Object> variables, String logMarker)\r
+ throws Exception {\r
+\r
+ LOGGER.debug(logMarker + " Attempting to find process waiting"\r
+ + " for " + messageEventName + " with " + correlationVariable\r
+ + " = '" + correlationValue + "'");\r
+\r
+ RuntimeService runtimeService =\r
+ getProcessEngineServices().getRuntimeService();\r
+\r
+ Map<String, String> properties =\r
+ PropertyConfiguration.getInstance().getProperties("mso.bpmn.urn.properties");\r
+\r
+ long timeout = DEFAULT_TIMEOUT_SECONDS;\r
+\r
+ // The code is here in case we ever need to change the default.\r
+ String s = properties.get("mso.correlation.timeout");\r
+ if (s != null) {\r
+ try {\r
+ timeout = Long.parseLong(s);\r
+ } catch (NumberFormatException e) {\r
+ // Ignore\r
+ }\r
+ }\r
+\r
+ long now = System.currentTimeMillis();\r
+ long fastPollEndTime = now + (FAST_POLL_DUR_SECONDS * 1000);\r
+ long endTime = now + (timeout * 1000);\r
+ long sleep = FAST_POLL_INT_MS;\r
+\r
+ List<Execution> waitingProcesses = null;\r
+ Exception queryException = null;\r
+ int queryCount = 0;\r
+ int queryFailCount = 0;\r
+\r
+ while (true) {\r
+ try {\r
+ ++queryCount;\r
+ waitingProcesses = runtimeService.createExecutionQuery()\r
+ .messageEventSubscriptionName(messageEventName)\r
+ .processVariableValueEquals(correlationVariable, correlationValue)\r
+ .list();\r
+ } catch (Exception e) {\r
+ ++queryFailCount;\r
+ queryException = e;\r
+ }\r
+\r
+ if (waitingProcesses != null && waitingProcesses.size() > 0) {\r
+ break;\r
+ }\r
+\r
+ if (now > endTime - sleep) {\r
+ break;\r
+ }\r
+\r
+ Thread.sleep(sleep);\r
+ now = System.currentTimeMillis();\r
+\r
+ if (now > fastPollEndTime) {\r
+ sleep = SLOW_POLL_INT_MS;\r
+ }\r
+ }\r
+\r
+ if (waitingProcesses == null) {\r
+ waitingProcesses = new ArrayList<Execution>(0);\r
+ }\r
+\r
+ int count = waitingProcesses.size();\r
+\r
+ List<ExecInfo> execInfoList = new ArrayList<ExecInfo>(count);\r
+ for (Execution execution : waitingProcesses) {\r
+ execInfoList.add(new ExecInfo(execution));\r
+ }\r
+\r
+ LOGGER.debug(logMarker + " Found " + count + " process(es) waiting"\r
+ + " for " + messageEventName + " with " + correlationVariable\r
+ + " = '" + correlationValue + "': " + execInfoList);\r
+\r
+ if (count == 0) {\r
+ if (queryFailCount > 0) {\r
+ String msg = queryFailCount + "/" + queryCount\r
+ + " execution queries failed attempting to correlate "\r
+ + messageEventName + " with " + correlationVariable\r
+ + " = '" + correlationValue + "'; last exception was:"\r
+ + queryException;\r
+ LOGGER.debug(msg);\r
+ LOGGER.error(MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(),\r
+ MsoLogger.ErrorCode.UnknownError, msg, queryException);\r
+ }\r
+\r
+ return false;\r
+ }\r
+\r
+ if (count > 1) {\r
+ // Only one process should be waiting. Throw an exception back to the client.\r
+ throw new MismatchingMessageCorrelationException(messageEventName,\r
+ "more than 1 process is waiting with " + correlationVariable\r
+ + " = '" + correlationValue + "'");\r
+ }\r
+ \r
+ // We prototyped an asynchronous solution, i.e. resuming the process\r
+ // flow in a separate thread, but this affected too many existing tests,\r
+ // and we went back to the synchronous solution. The synchronous solution\r
+ // has some troublesome characteristics though. For example, the\r
+ // resumed flow may send request #2 to a remote system before MSO has\r
+ // acknowledged the notification associated with request #1. \r
+\r
+ try {\r
+ LOGGER.debug(logMarker + " Running " + execInfoList.get(0) + " to receive "\r
+ + messageEventName + " with " + correlationVariable + " = '"\r
+ + correlationValue + "'");\r
+\r
+ @SuppressWarnings("unused")\r
+ MessageCorrelationResult result = runtimeService\r
+ .createMessageCorrelation(messageEventName)\r
+ .setVariables(variables)\r
+ .processInstanceVariableEquals(correlationVariable, correlationValue)\r
+ .correlateWithResult();\r
+\r
+ } catch (MismatchingMessageCorrelationException e) {\r
+ // A correlation exception occurred even after we identified\r
+ // one waiting process. Throw it back to the client.\r
+ throw e;\r
+ } catch (Exception e) {\r
+ // This must be an exception from the flow itself. Log it, but don't\r
+ // report it back to the client.\r
+ String msg = "Caught " + e.getClass().getSimpleName() + " running "\r
+ + execInfoList.get(0) + " after receiving " + messageEventName\r
+ + " with " + correlationVariable + " = '" + correlationValue\r
+ + "': " + e;\r
+ LOGGER.debug(msg);\r
+ LOGGER.error(MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(),\r
+ MsoLogger.ErrorCode.UnknownError, msg, e);\r
+ }\r
+\r
+ return true;\r
+ }\r
+ \r
+ /**\r
+ * Records audit and metric events in the log for a callback success.\r
+ * @param method the method name\r
+ * @param startTime the request start time\r
+ */\r
+ protected void logCallbackSuccess(String method, long startTime) {\r
+ LOGGER.recordAuditEvent(startTime, MsoLogger.StatusCode.COMPLETE,\r
+ MsoLogger.ResponseCode.Suc, "Completed " + method);\r
+\r
+ LOGGER.recordMetricEvent(startTime, MsoLogger.StatusCode.COMPLETE,\r
+ MsoLogger.ResponseCode.Suc, "Completed " + method,\r
+ "BPMN", MsoLogger.getServiceName(), null);\r
+ }\r
+\r
+ /**\r
+ * Records error, audit and metric events in the log for a callback\r
+ * internal error.\r
+ * @param method the method name\r
+ * @param startTime the request start time\r
+ * @param msg the error message\r
+ */\r
+ protected void logCallbackError(String method, long startTime, String msg) {\r
+ logCallbackError(method, startTime, msg, null);\r
+ }\r
+\r
+ /**\r
+ * Records error, audit and metric events in the log for a callback\r
+ * internal error.\r
+ * @param method the method name\r
+ * @param startTime the request start time\r
+ * @param msg the error message\r
+ * @param e the exception\r
+ */\r
+ protected void logCallbackError(String method, long startTime, String msg, Exception e) {\r
+ if (e == null) {\r
+ LOGGER.error(MessageEnum.BPMN_CALLBACK_EXCEPTION, "BPMN", MsoLogger.getServiceName(), \r
+ MsoLogger.ErrorCode.UnknownError, msg);\r
+ } else {\r
+ LOGGER.error(MessageEnum.BPMN_CALLBACK_EXCEPTION, "BPMN", MsoLogger.getServiceName(), \r
+ MsoLogger.ErrorCode.UnknownError, msg, e);\r
+ }\r
+\r
+ LOGGER.recordAuditEvent(startTime, MsoLogger.StatusCode.COMPLETE,\r
+ MsoLogger.ResponseCode.InternalError, "Completed " + method);\r
+\r
+ LOGGER.recordMetricEvent(startTime, MsoLogger.StatusCode.COMPLETE,\r
+ MsoLogger.ResponseCode.InternalError, "Completed " + method,\r
+ "BPMN", MsoLogger.getServiceName(), null);\r
+ }\r
+ \r
+ /**\r
+ * Abstract callback result object.\r
+ */\r
+ protected abstract class CallbackResult {\r
+ }\r
+\r
+ /**\r
+ * Indicates that callback handling was successful.\r
+ */\r
+ protected class CallbackSuccess extends CallbackResult {\r
+ }\r
+\r
+ /**\r
+ * Indicates that callback handling failed.\r
+ */\r
+ protected class CallbackError extends CallbackResult {\r
+ private final String errorMessage;\r
+\r
+ public CallbackError(String errorMessage) {\r
+ this.errorMessage = errorMessage;\r
+ }\r
+\r
+ /**\r
+ * Gets the error message.\r
+ */\r
+ public String getErrorMessage() {\r
+ return errorMessage;\r
+ }\r
+ }\r
+\r
+ private static class ExecInfo {\r
+ private final Execution execution;\r
+\r
+ public ExecInfo(Execution execution) {\r
+ this.execution = execution;\r
+ }\r
+ \r
+ @Override\r
+ public String toString() {\r
+ return "Process[" + execution.getProcessInstanceId()\r
+ + ":" + execution.getId() + "]";\r
+ }\r
+ }\r
+ \r
+ protected ProcessEngineServices getProcessEngineServices() {\r
+ if (pes4junit == null) {\r
+ return BpmPlatform.getDefaultProcessEngine();\r
+ } else {\r
+ return pes4junit;\r
+ }\r
+ }\r
+\r
+ public void setProcessEngineServices4junit(ProcessEngineServices pes) {\r
+ pes4junit = pes;\r
+ }\r
+}
\ No newline at end of file
import org.openecomp.mso.bpmn.core.PropertyConfiguration;\r
import org.openecomp.mso.logger.MessageEnum;\r
import org.openecomp.mso.logger.MsoLogger;\r
+\r
/**\r
- * @version 1.0\r
- * \r
+ * Implementation of SDNCAdapterCallbackService.\r
*/\r
@WebService(serviceName="SDNCAdapterCallbackService", targetNamespace="http://org.openecomp/workflow/sdnc/adapter/schema/v1")\r
-public class SDNCAdapterCallbackServiceImpl implements SDNCCallbackAdapterPortType {\r
-\r
- private static MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);\r
- private final int DEFAULT_RETRY_ATTEMPTS = 60;\r
- private final int DEFAULT_SLEEP_TIME = 500;\r
+public class SDNCAdapterCallbackServiceImpl extends AbstractCallbackService implements SDNCCallbackAdapterPortType {\r
\r
private final String logMarker = "[SDNC-CALLBACK]";\r
\r
@Context WebServiceContext wsContext;\r
\r
- private volatile ProcessEngineServices pes4junit = null;\r
-\r
@WebMethod(operationName = "SDNCAdapterCallback")\r
@WebResult(name = "SDNCAdapterResponse", targetNamespace = "http://org.openecomp/workflow/sdnc/adapter/schema/v1", partName = "SDNCAdapterCallbackResponse")\r
public SDNCAdapterResponse sdncAdapterCallback(\r
@WebParam(name = "SDNCAdapterCallbackRequest", targetNamespace = "http://org.openecomp/workflow/sdnc/adapter/schema/v1", partName = "SDNCAdapterCallbackRequest")\r
SDNCAdapterCallbackRequest sdncAdapterCallbackRequest) {\r
\r
- //Callback URL to use http://localhost:28080/mso/SDNCAdapterCallbackService\r
- ProcessEngineServices pes = getProcessEngineServices();\r
- RuntimeService runtimeService = pes.getRuntimeService();\r
- String receivedRequestId = sdncAdapterCallbackRequest.getCallbackHeader().getRequestId();\r
- MsoLogger.setServiceName("MSO." + "sdncAdapter");\r
- MsoLogger.setLogContext(receivedRequestId, "N/A");\r
- msoLogger.debug(logMarker + "Received callback response:" + sdncAdapterCallbackRequest.toString());\r
- SDNCAdapterResponse sdncAdapterResponse;\r
- long startTime = System.currentTimeMillis();\r
-\r
- /*Correlating the response with the running instance*/\r
-\r
- // NOTE: the following loop is a workaround for problems we've had\r
- // with reliability of the runtime service. It seems that queries\r
- // sometimes return results, and sometimes they don't. This might\r
- // be a problem in mysql only. We aren't sure if it affects camunda\r
- // on oracle or mariadb. The workaround is to repeat the request\r
- // a number of times until it succeeds. If it doesn't succeed after\r
- // 60 tries, then we give up.\r
-\r
- int maxAttempts = DEFAULT_RETRY_ATTEMPTS;\r
- int attempt = 1;\r
- int sleepTime = DEFAULT_SLEEP_TIME;\r
+ String method = "sdncAdapterCallback";\r
+ Object message = sdncAdapterCallbackRequest;\r
+ String messageEventName = "sdncAdapterCallbackRequest";\r
+ String messageVariable = "sdncAdapterCallbackRequest";\r
+ String correlationVariable = "SDNCA_requestId";\r
+ String correlationValue = sdncAdapterCallbackRequest.getCallbackHeader().getRequestId();\r
\r
- Map<String,String> bpmnProperties = getMSOBPMNURNProperties();\r
- if (bpmnProperties != null) {\r
- try {\r
- maxAttempts = Integer.parseInt(bpmnProperties.get("mso.callbackRetryAttempts"));\r
- msoLogger.debug(logMarker + "mso.callbackRetryAttempts=" + maxAttempts);\r
- sleepTime = Integer.parseInt(bpmnProperties.get("mso.callbackRetrySleepTime"));\r
- msoLogger.debug(logMarker + "mso.callbackRetrySleepTime:" + sleepTime);\r
- } catch (Exception ex) {\r
- \r
- msoLogger.debug (logMarker \r
- + "Error parsing mso.callbackRetrySleepTime/mso.callbackRetryAttempts:" \r
- + sleepTime + ":" \r
- + maxAttempts);\r
- \r
- }\r
- }\r
-\r
- /* Check to make sure the process instance is reay for correlation*/\r
- try{\r
- isReadyforCorrelation(runtimeService, receivedRequestId, maxAttempts, sleepTime );\r
- }catch(Exception e){\r
- String msg =\r
- "SDNC Adapter Callback Service received a SDNC Adapter Callback Request with RequestId '"\r
- + receivedRequestId\r
- + "' but that RequestId doesn't exist or has timed out waiting for the callback";\r
- sdncAdapterResponse = new SDNCAdapterExceptionResponse(e);\r
- \r
- msoLogger.error (MessageEnum.BPMN_SDNC_CALLBACK_EXCEPTION, "BPMN", MsoLogger.getServiceName(), \r
- MsoLogger.ErrorCode.UnknownError, logMarker + ":" + msg, e);\r
- \r
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, logMarker \r
- + "Completed the execution of MSO SDNCAdapterCallbackService." );\r
- \r
- msoLogger.recordMetricEvent ( startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, \r
- logMarker + "Completed the execution of MSO SDNCAdapterCallbackService.", "BPMN", \r
- MsoLogger.getServiceName(), "sdncAdapterCallback");\r
- \r
- return sdncAdapterResponse;\r
- }\r
+ MsoLogger.setServiceName("MSO." + method);\r
+ MsoLogger.setLogContext(correlationValue, "N/A");\r
\r
- msoLogger.debug(logMarker + "*** Received MSO sdncAdapterCallbackService ******");\r
- \r
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, "Call to MSO sdncAdapterCallbackService"); \r
- \r
- msoLogger.debug(logMarker + "Callback response string:\n" + sdncAdapterCallbackRequest.toString());\r
+ CallbackResult result = handleCallback(method, message, messageEventName,\r
+ messageVariable, correlationVariable, correlationValue, logMarker);\r
\r
- String reqId = receivedRequestId;\r
- Map<String,Object> variables = new HashMap<String,Object>();\r
- variables.put("SDNCA_requestId", reqId );\r
- variables.put("sdncAdapterCallbackRequest", sdncAdapterCallbackRequest.toString());\r
- while (true) {\r
- try {\r
- // sdncAdapterCallbackRequest is the message event name (defined in the bpmn process)\r
- runtimeService.createMessageCorrelation("sdncAdapterCallbackRequest")\r
- .setVariables(variables)\r
- .processInstanceVariableEquals("SDNCA_requestId", reqId).correlate();\r
- sdncAdapterResponse = new SDNCAdapterResponse();\r
- msoLogger.debug(logMarker + "***** Completed processing of MSO sdncAdapterCallbackService ******");\r
- \r
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, logMarker \r
- + "Completed the execution of MSO SDNCAdapterCallbackService.");\r
- \r
- msoLogger.recordMetricEvent ( startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, \r
- logMarker + "Completed the execution of MSO SDNCAdapterCallbackService.", "BPMN", \r
- MsoLogger.getServiceName(), "sdncAdapterCallback");\r
- \r
- return sdncAdapterResponse;\r
- } catch(MismatchingMessageCorrelationException e) {\r
- msoLogger.debug(logMarker + "[CORM]correlation id mismatch (attempt " + attempt + "/" + maxAttempts + ")");\r
- if (attempt == maxAttempts) {\r
- // Couldn't correlate requestId to any active flow\r
- //MsoLogger logger = MsoLogger.getMsoLogger("SDNCAdapterCallbackService");\r
- String msg =\r
- "SDNC Adapter Callback Service received a SDNC Adapter Callback Request with RequestId '"\r
- + receivedRequestId\r
- + "' but that RequestId could not be correlated to any active process - ignoring the Request";\r
- sdncAdapterResponse = new SDNCAdapterExceptionResponse(e);\r
- \r
- msoLogger.error (MessageEnum.BPMN_SDNC_CALLBACK_EXCEPTION, "BPMN", MsoLogger.getServiceName(), \r
- MsoLogger.ErrorCode.UnknownError, logMarker + ":" + msg, e);\r
- \r
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, logMarker \r
- + "Completed the execution of MSO SDNCAdapterCallbackService." );\r
- \r
- msoLogger.recordMetricEvent ( startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, \r
- logMarker + "Completed the execution of MSO SDNCAdapterCallbackService.", "BPMN", \r
- MsoLogger.getServiceName(), "sdncAdapterCallback");\r
- \r
- return sdncAdapterResponse;\r
- }\r
-\r
- try {\r
- Thread.sleep(sleepTime);\r
- } catch (InterruptedException e2) {\r
- String msg =\r
- "SDNC Adapter Callback Service received a SDNC Adapter Callback Request with RequestId '"\r
- + receivedRequestId\r
- + "' but correlation was interrupted";\r
- sdncAdapterResponse = new SDNCAdapterExceptionResponse(e);\r
- \r
- msoLogger.error (MessageEnum.BPMN_SDNC_CALLBACK_EXCEPTION, "BPMN", MsoLogger.getServiceName(), \r
- MsoLogger.ErrorCode.UnknownError, logMarker + ":" + msg, e);\r
- \r
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, logMarker \r
- + "Completed the execution of MSO SDNCAdapterCallbackService.");\r
- \r
- msoLogger.recordMetricEvent ( startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, \r
- logMarker + "Completed the execution of MSO SDNCAdapterCallbackService.", "BPMN", \r
- MsoLogger.getServiceName(), "sdncAdapterCallback");\r
- \r
- return sdncAdapterResponse;\r
- }\r
- }\r
-\r
- attempt++;\r
- }\r
- }\r
-\r
-\r
- private Map<String,String> getMSOBPMNURNProperties() {\r
- PropertyConfiguration propertyConfiguration = PropertyConfiguration.getInstance();\r
- Map<String,String> props = propertyConfiguration.getProperties("mso.bpmn.urn.properties");\r
- return props;\r
- }\r
-\r
- private void isReadyforCorrelation(RuntimeService runtimeService,\r
- String receivedRequestId, int retries, int sleepTime){\r
- ExecutionQuery waitingInstances = null;\r
- long waitingInstancesCount = 0;\r
-\r
- //Workaround for performance testing, explicit wait for a second for the transactions to be committed\r
- //Also check to make sure the process didn't timeout before trying to correlate\r
- \r
- do{\r
- waitingInstances = runtimeService.createExecutionQuery() //\r
- .messageEventSubscriptionName("sdncAdapterCallbackRequest")\r
- .processVariableValueEquals("SDNCA_requestId", receivedRequestId);\r
- waitingInstancesCount = waitingInstances.count();\r
- retries--;\r
- msoLogger.debug(logMarker + "waitingInstancesCount: " + waitingInstancesCount);\r
- try {\r
- Thread.sleep(sleepTime);\r
- } catch (InterruptedException e) {\r
- \r
- msoLogger.error (MessageEnum.BPMN_SDNC_CALLBACK_EXCEPTION, "BPMN", MsoLogger.getServiceName(), \r
- MsoLogger.ErrorCode.UnknownError, logMarker, e);\r
- \r
- }\r
- }while (waitingInstancesCount==0 && retries > 0); \r
- if(waitingInstancesCount > 0){\r
- msoLogger.debug(logMarker + "waitingInstancesCount before timeout check: " + waitingInstancesCount);\r
- waitingInstancesCount = waitingInstances.processVariableValueEquals("asynchronousResponseTimeout", false).count();\r
- msoLogger.debug(logMarker + "waitingInstancesCount after timeout check: " + waitingInstancesCount);\r
- if(waitingInstancesCount<=0){\r
- msoLogger.debug(logMarker + "detected timeout on flow to correlate");\r
- throw new IllegalStateException("process timed out");\r
- }\r
- }else{\r
- //flow may have already ended, so can't check timeout variable. Throw exception?\r
- msoLogger.debug(logMarker + "no flow to correlate to");\r
- throw new IllegalStateException("no flow to correlate to");\r
- }\r
- }\r
-\r
- private ProcessEngineServices getProcessEngineServices() {\r
- if (pes4junit == null) {\r
- return BpmPlatform.getDefaultProcessEngine();\r
+ if (result instanceof CallbackError) {\r
+ return new SDNCAdapterErrorResponse(((CallbackError)result).getErrorMessage());\r
} else {\r
- return pes4junit;\r
+ return new SDNCAdapterResponse();\r
}\r
}\r
\r
- @WebMethod(exclude=true)\r
- public void setProcessEngineServices4junit(ProcessEngineServices pes) {\r
- pes4junit = pes;\r
- }\r
-\r
- public class SDNCAdapterExceptionResponse extends SDNCAdapterResponse {\r
- private Exception ex;\r
+ // This subclass allows unit tests to extract the error\r
+ public class SDNCAdapterErrorResponse extends SDNCAdapterResponse {\r
+ private String error;\r
\r
- public SDNCAdapterExceptionResponse(Exception ex) {\r
- super();\r
- this.ex = ex;\r
+ public SDNCAdapterErrorResponse(String error) {\r
+ this.error = error;\r
}\r
\r
- public Exception getException() {\r
- return ex;\r
+ public String getError() {\r
+ return error;\r
}\r
}\r
-}\r
+}
\ No newline at end of file
-/*-
- * ============LICENSE_START=======================================================
- * OPENECOMP - MSO
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-
-package org.openecomp.mso.bpmn.common.workflow.service;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.jws.Oneway;
-import javax.jws.WebMethod;
-import javax.jws.WebParam;
-import javax.jws.WebService;
-import javax.ws.rs.core.Context;
-import javax.xml.ws.Action;
-import javax.xml.ws.RequestWrapper;
-import javax.xml.ws.WebServiceContext;
-
-import org.camunda.bpm.BpmPlatform;
-import org.camunda.bpm.engine.MismatchingMessageCorrelationException;
-import org.camunda.bpm.engine.ProcessEngineServices;
-import org.camunda.bpm.engine.RuntimeService;
-import org.openecomp.mso.bpmn.common.adapter.vnf.CreateVnfNotification;
-import org.openecomp.mso.bpmn.common.adapter.vnf.DeleteVnfNotification;
-import org.openecomp.mso.bpmn.common.adapter.vnf.MsoExceptionCategory;
-import org.openecomp.mso.bpmn.common.adapter.vnf.QueryVnfNotification;
-import org.openecomp.mso.bpmn.common.adapter.vnf.RollbackVnfNotification;
-import org.openecomp.mso.bpmn.common.adapter.vnf.UpdateVnfNotification;
-import org.openecomp.mso.bpmn.common.adapter.vnf.VnfAdapterNotify;
-import org.openecomp.mso.bpmn.common.adapter.vnf.VnfRollback;
-import org.openecomp.mso.bpmn.common.adapter.vnf.VnfStatus;
-import org.openecomp.mso.logger.MessageEnum;
-import org.openecomp.mso.logger.MsoLogger;
-
-/**
- * This is the service class for VnfAdapterNotify
- * TODO: Add addition VnfAdapterNotify Methods for remaining VnfAdapterNotify operations.
- */
-
-@WebService(serviceName = "vnfAdapterNotify", targetNamespace = "http://org.openecomp.mso/vnfNotify")
-public class VnfAdapterNotifyServiceImpl implements VnfAdapterNotify{
-
+/*-\r
+ * ============LICENSE_START=======================================================\r
+ * OPENECOMP - MSO\r
+ * ================================================================================\r
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
+ * ================================================================================\r
+ * Licensed under the Apache License, Version 2.0 (the "License");\r
+ * you may not use this file except in compliance with the License.\r
+ * You may obtain a copy of the License at\r
+ * \r
+ * http://www.apache.org/licenses/LICENSE-2.0\r
+ * \r
+ * Unless required by applicable law or agreed to in writing, software\r
+ * distributed under the License is distributed on an "AS IS" BASIS,\r
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+ * See the License for the specific language governing permissions and\r
+ * limitations under the License.\r
+ * ============LICENSE_END=========================================================\r
+ */\r
+\r
+package org.openecomp.mso.bpmn.common.workflow.service;\r
+\r
+import javax.jws.Oneway;\r
+import javax.jws.WebMethod;\r
+import javax.jws.WebParam;\r
+import javax.jws.WebService;\r
+import javax.ws.rs.core.Context;\r
+import javax.xml.ws.Action;\r
+import javax.xml.ws.RequestWrapper;\r
+import javax.xml.ws.WebServiceContext;\r
+\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.CreateVnfNotification;\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.DeleteVnfNotification;\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.MsoExceptionCategory;\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.QueryVnfNotification;\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.RollbackVnfNotification;\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.UpdateVnfNotification;\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.VnfAdapterNotify;\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.VnfRollback;\r
+import org.openecomp.mso.bpmn.common.adapter.vnf.VnfStatus;\r
+import org.openecomp.mso.logger.MsoLogger;\r
+\r
+/**\r
+ * Implementation of the VnfAdapterNotify service.\r
+ */\r
+@WebService(serviceName = "vnfAdapterNotify", targetNamespace = "http://org.openecomp.mso/vnfNotify")\r
+public class VnfAdapterNotifyServiceImpl extends AbstractCallbackService implements VnfAdapterNotify{\r
+\r
private static MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
- private final String logMarker = "[VNF-NOTIFY]";
-
- @Context WebServiceContext wsContext;
-
- private volatile ProcessEngineServices pes4junit = null;
-
- /**
- *
- * @param errorMessage
- * @param exception
- * @param messageId
- * @param completed
- */
- @WebMethod(operationName = "rollbackVnfNotification")
- @Oneway
- @RequestWrapper(localName = "rollbackVnfNotification", targetNamespace = "http://org.openecomp.mso/vnfNotify", className = "org.openecomp.mso.adapters.vnf.async.client.RollbackVnfNotification")
+ private final String logMarker = "[VNF-NOTIFY]";\r
+\r
+ @Context WebServiceContext wsContext;\r
+\r
+ @WebMethod(operationName = "rollbackVnfNotification")\r
+ @Oneway\r
+ @RequestWrapper(localName = "rollbackVnfNotification", targetNamespace = "http://org.openecomp.mso/vnfNotify", className = "org.openecomp.mso.adapters.vnf.async.client.RollbackVnfNotification")\r
@Action(input = "http://org.openecomp.mso/notify/adapterNotify/rollbackVnfNotificationRequest")
- public void rollbackVnfNotification(
- @WebParam(name = "messageId", targetNamespace = "")
- String messageId,
- @WebParam(name = "completed", targetNamespace = "")
- boolean completed,
- @WebParam(name = "exception", targetNamespace = "")
- MsoExceptionCategory exception,
- @WebParam(name = "errorMessage", targetNamespace = "")
- String errorMessage) {
-
-
-
- RollbackVnfNotification rollbackVnfNotification = new RollbackVnfNotification();
-
- rollbackVnfNotification.setMessageId(messageId);
- rollbackVnfNotification.setCompleted(completed);
- rollbackVnfNotification.setException(exception);
- rollbackVnfNotification.setErrorMessage(errorMessage);
-
- ProcessEngineServices pes = getProcessEngineServices();
- RuntimeService runtimeService = pes.getRuntimeService();
-
- MsoLogger.setServiceName("MSO." + "vnfAdapterRollback");
- MsoLogger.setLogContext(messageId, "N/A");
- msoLogger.debug(logMarker + "Received RollbackVnfNotification" + rollbackVnfNotification.toString());
-
- long startTime = System.currentTimeMillis();
- try {
-
- /* Check to make sure the process instance is ready for correlation*/
- isReadyforCorrelation(runtimeService, messageId, "rollbackVnfNotificationCallback", "VNFRB_messageId");
-
- msoLogger.debug(logMarker + "*** Received MSO rollbackVnfNotification Callback ******");
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, "Call to MSO VnfAdapterNotifyService ");
- msoLogger.debug(logMarker + "Rollback VNF Notification string:\n" + rollbackVnfNotification.toString());
-
- System.out.println("testing ROllbackVnfNotification : " + rollbackVnfNotification.toString());
-
- Map<String,Object> variables = new HashMap<String,Object>();
- variables.put("VNFRB_messageId", messageId );
- variables.put("rollbackVnfNotificationCallback", rollbackVnfNotification.toString());
-
- /*Correlating the response with the running instance*/
-
- runtimeService.createMessageCorrelation("rollbackVnfNotificationCallback").setVariables(variables)
- .processInstanceVariableEquals("VNFRB_messageId", messageId).correlate();
-
- msoLogger.debug(logMarker + "***** Completed processing of MSO VnfAdapterNotifyService ******");
- } catch(MismatchingMessageCorrelationException e) {
- msoLogger.debug(logMarker + "[CORM]correlation id mismatch");
- String msg =
- "VNF Adapter Notify Service received a Create VNF Notification request with RequestId '"
- + messageId
- + "' but that RequestId could not be correlated to any active process - ignoring the request";
-
- msoLogger.error (MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(),
- MsoLogger.ErrorCode.UnknownError, logMarker + ":" + msg);
-
- }
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO Vnf Adapter Notify for Rollback VNF Notification.");
-
- msoLogger.recordMetricEvent ( startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO Vnf Adapter Notify for Rollback VNF Notification.", "BPMN",
- MsoLogger.getServiceName(), "rollbackVnfNotification");
-
- return;
- }
-
-
-
- /**
- *
- * @param errorMessage
- * @param vnfExists
- * @param status
- * @param exception
- * @param outputs
- * @param messageId
- * @param vnfId
- * @param completed
- */
- @WebMethod(operationName = "queryVnfNotification")
- @Oneway
+ public void rollbackVnfNotification(\r
+ @WebParam(name = "messageId", targetNamespace = "")\r
+ String messageId,\r
+ @WebParam(name = "completed", targetNamespace = "")\r
+ boolean completed,\r
+ @WebParam(name = "exception", targetNamespace = "")\r
+ MsoExceptionCategory exception,\r
+ @WebParam(name = "errorMessage", targetNamespace = "")\r
+ String errorMessage) {\r
+\r
+ RollbackVnfNotification rollbackVnfNotification = new RollbackVnfNotification();\r
+\r
+ rollbackVnfNotification.setMessageId(messageId);\r
+ rollbackVnfNotification.setCompleted(completed);\r
+ rollbackVnfNotification.setException(exception);\r
+ rollbackVnfNotification.setErrorMessage(errorMessage);\r
+\r
+ String method = "rollbackVnfNotification";\r
+ Object message = rollbackVnfNotification;\r
+ String messageEventName = "rollbackVnfNotificationCallback";\r
+ String messageVariable = "rollbackVnfNotificationCallback";\r
+ String correlationVariable = "VNFRB_messageId";\r
+ String correlationValue = messageId;\r
+\r
+ handleCallback(method, message, messageEventName, messageVariable,\r
+ correlationVariable, correlationValue, logMarker);\r
+ }\r
+\r
+ @WebMethod(operationName = "queryVnfNotification")\r
+ @Oneway\r
@RequestWrapper(localName = "queryVnfNotification", targetNamespace = "http://org.openecomp.mso/vnfNotify", className = "org.openecomp.mso.adapters.vnf.async.client.QueryVnfNotification")
@Action(input = "http://org.openecomp.mso/notify/adapterNotify/queryVnfNotificationRequest")
- public void queryVnfNotification(
- @WebParam(name = "messageId", targetNamespace = "")
- String messageId,
- @WebParam(name = "completed", targetNamespace = "")
- boolean completed,
- @WebParam(name = "exception", targetNamespace = "")
- MsoExceptionCategory exception,
- @WebParam(name = "errorMessage", targetNamespace = "")
- String errorMessage,
- @WebParam(name = "vnfExists", targetNamespace = "")
- Boolean vnfExists,
- @WebParam(name = "vnfId", targetNamespace = "")
- String vnfId,
- @WebParam(name = "status", targetNamespace = "")
- VnfStatus status,
- @WebParam(name = "outputs", targetNamespace = "")
- org.openecomp.mso.bpmn.common.adapter.vnf.QueryVnfNotification.Outputs outputs){
-
- QueryVnfNotification queryVnfNotification = new QueryVnfNotification();
-
- queryVnfNotification.setMessageId(messageId);
- queryVnfNotification.setCompleted(completed);
- queryVnfNotification.setException(exception);
- queryVnfNotification.setErrorMessage(errorMessage);
- queryVnfNotification.setVnfExists(vnfExists);
- queryVnfNotification.setVnfId(vnfId);
- queryVnfNotification.setStatus(status);
- queryVnfNotification.setOutputs(outputs);
-
-
- ProcessEngineServices pes = getProcessEngineServices();
- RuntimeService runtimeService = pes.getRuntimeService();
-
- MsoLogger.setServiceName("MSO." + "vnf Adapter Query");
- MsoLogger.setLogContext(messageId, "N/A");
- msoLogger.debug(logMarker + "Received QueryVnfNotification" + queryVnfNotification.toString());
-
- System.out.println("Received QueryVnfNotification : " + queryVnfNotification.toString());
-
- long startTime = System.currentTimeMillis();
- try {
-
- /* Check to make sure the process instance is ready for correlation*/
- isReadyforCorrelation(runtimeService, messageId, "queryVnfNotificationCallback", "VNFQ_messageId");
-
- msoLogger.debug(logMarker + "*** Received MSO queryVnfNotification Callback ******");
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, "Call to MSO VnfAdapterNotifyService ");
- msoLogger.debug(logMarker + "Query VNF Notification string:\n" + queryVnfNotification.toString());
-
- Map<String,Object> variables = new HashMap<String,Object>();
- variables.put("VNFQ_messageId", messageId );
- variables.put("queryVnfNotificationCallback", queryVnfNotification.toString());
-
- /*Correlating the response with the running instance*/
-
- runtimeService.createMessageCorrelation("queryVnfNotificationCallback").setVariables(variables)
- .processInstanceVariableEquals("VNFQ_messageId", messageId).correlate();
-
- msoLogger.debug(logMarker + "***** Completed processing of MSO VnfAdapterNotifyService ******");
- } catch(MismatchingMessageCorrelationException e) {
- msoLogger.debug(logMarker + "[CORM]correlation id mismatch");
- String msg =
- "VNF Adapter Notify Service received a Query VNF Notification request with RequestId '"
- + messageId
- + "' but that RequestId could not be correlated to any active process - ignoring the request";
-
- msoLogger.error(MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(),
- MsoLogger.ErrorCode.UnknownError, logMarker + ":" + msg, e);
- }
-
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO Vnf Adapter Notify for Query VNF Notification.");
-
- return;
- }
-
-
-
-
- /**
- *
- * @param errorMessage
- * @param exception
- * @param rollback
- * @param outputs
- * @param messageId
- * @param vnfId
- * @param completed
- */
- @WebMethod(operationName = "createVnfNotification")
- @Oneway
+ public void queryVnfNotification(\r
+ @WebParam(name = "messageId", targetNamespace = "")\r
+ String messageId,\r
+ @WebParam(name = "completed", targetNamespace = "")\r
+ boolean completed,\r
+ @WebParam(name = "exception", targetNamespace = "")\r
+ MsoExceptionCategory exception,\r
+ @WebParam(name = "errorMessage", targetNamespace = "")\r
+ String errorMessage,\r
+ @WebParam(name = "vnfExists", targetNamespace = "")\r
+ Boolean vnfExists,\r
+ @WebParam(name = "vnfId", targetNamespace = "")\r
+ String vnfId,\r
+ @WebParam(name = "status", targetNamespace = "")\r
+ VnfStatus status,\r
+ @WebParam(name = "outputs", targetNamespace = "")\r
+ QueryVnfNotification.Outputs outputs){\r
+\r
+ String method = "queryVnfNotification";\r
+ String messageEventName = "queryVnfNotificationCallback";\r
+ String messageVariable = "queryVnfNotificationCallback";\r
+ String correlationVariable = "VNFQ_messageId";\r
+ String correlationValue = messageId;\r
+\r
+ MsoLogger.setServiceName("MSO." + method);\r
+ MsoLogger.setLogContext(correlationValue, "N/A");\r
+\r
+ QueryVnfNotification message = new QueryVnfNotification();\r
+\r
+ message.setMessageId(messageId);\r
+ message.setCompleted(completed);\r
+ message.setException(exception);\r
+ message.setErrorMessage(errorMessage);\r
+ message.setVnfExists(vnfExists);\r
+ message.setVnfId(vnfId);\r
+ message.setStatus(status);\r
+ message.setOutputs(outputs);\r
+\r
+ handleCallback(method, message, messageEventName, messageVariable,\r
+ correlationVariable, correlationValue, logMarker);\r
+ }\r
+\r
+ @WebMethod(operationName = "createVnfNotification")\r
+ @Oneway\r
@RequestWrapper(localName = "createVnfNotification", targetNamespace = "http://org.openecomp.mso/vnfNotify", className = "org.openecomp.mso.adapters.vnf.async.client.CreateVnfNotification")
@Action(input = "http://org.openecomp.mso/notify/adapterNotify/createVnfNotificationRequest")
- public void createVnfNotification(
- @WebParam(name = "messageId", targetNamespace = "")
- String messageId,
- @WebParam(name = "completed", targetNamespace = "")
- boolean completed,
- @WebParam(name = "exception", targetNamespace = "")
- MsoExceptionCategory exception,
- @WebParam(name = "errorMessage", targetNamespace = "")
- String errorMessage,
- @WebParam(name = "vnfId", targetNamespace = "")
- String vnfId,
- @WebParam(name = "outputs", targetNamespace = "")
- org.openecomp.mso.bpmn.common.adapter.vnf.CreateVnfNotification.Outputs outputs,
- @WebParam(name = "rollback", targetNamespace = "")
- VnfRollback rollback){
-
- CreateVnfNotification createVnfNotification = new CreateVnfNotification();
-
- createVnfNotification.setMessageId(messageId);
- createVnfNotification.setCompleted(completed);
- createVnfNotification.setException(exception);
- createVnfNotification.setErrorMessage(errorMessage);
- createVnfNotification.setVnfId(vnfId);
- createVnfNotification.setOutputs(outputs);
- createVnfNotification.setRollback(rollback);
-
- ProcessEngineServices pes = getProcessEngineServices();
- RuntimeService runtimeService = pes.getRuntimeService();
-
- MsoLogger.setServiceName("MSO." + "vnf Adapter Create");
- MsoLogger.setLogContext(messageId, "N/A");
- msoLogger.debug(logMarker + "Received CreateVnfNotification - " + createVnfNotification.toString());
-
- long startTime = System.currentTimeMillis();
- try {
-
- /* Check to make sure the process instance is ready for correlation*/
- isReadyforCorrelation(runtimeService, messageId, "createVnfNotificationCallback", "VNFC_messageId");
-
- msoLogger.debug(logMarker + "*** Received MSO createVnfNotification Callback ******");
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, "Call to MSO VnfAdapterNotifyService ");
-
- msoLogger.debug(logMarker + "Create VNF Notification string:\n" + createVnfNotification.toString());
-
- Map<String,Object> variables = new HashMap<String,Object>();
- variables.put("VNFC_messageId", messageId );
- variables.put("createVnfNotificationCallback", createVnfNotification.toString());
-
- /*Correlating the response with the running instance*/
-
- runtimeService.createMessageCorrelation("createVnfNotificationCallback").setVariables(variables)
- .processInstanceVariableEquals("VNFC_messageId", messageId).correlate();
-
- msoLogger.debug(logMarker + "***** Completed processing of MSO VnfAdapterNotifyService ******");
- } catch(MismatchingMessageCorrelationException e) {
- msoLogger.debug(logMarker + "[CORM]correlation id mismatch");
- String msg =
- "VNF Adapter Notify Service received a Create VNF Notification request with RequestId '"
- + messageId
- + "' but that RequestId could not be correlated to any active process - ignoring the request";
-
- msoLogger.error(MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(),
- MsoLogger.ErrorCode.UnknownError, logMarker + ":" + msg, e);
-
- }
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO Vnf Adapter Notify for Query VNF Notification.");
-
- msoLogger.recordMetricEvent ( startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO Vnf Adapter Notify for Query VNF Notification.", "BPMN",
- MsoLogger.getServiceName(), "createVnfNotification");
-
- return;
- }
-
- /**
- *
- * @param errorMessage
- * @param exception
- * @param rollback
- * @param outputs
- * @param messageId
- * @param completed
- */
- @WebMethod(operationName = "updateVnfNotification")
- @Oneway
+ public void createVnfNotification(\r
+ @WebParam(name = "messageId", targetNamespace = "")\r
+ String messageId,\r
+ @WebParam(name = "completed", targetNamespace = "")\r
+ boolean completed,\r
+ @WebParam(name = "exception", targetNamespace = "")\r
+ MsoExceptionCategory exception,\r
+ @WebParam(name = "errorMessage", targetNamespace = "")\r
+ String errorMessage,\r
+ @WebParam(name = "vnfId", targetNamespace = "")\r
+ String vnfId,\r
+ @WebParam(name = "outputs", targetNamespace = "")\r
+ CreateVnfNotification.Outputs outputs,\r
+ @WebParam(name = "rollback", targetNamespace = "")\r
+ VnfRollback rollback){\r
+\r
+ String method = "createVnfNotification";\r
+ String messageEventName = "createVnfNotificationCallback";\r
+ String messageVariable = "createVnfNotificationCallback";\r
+ String correlationVariable = "VNFC_messageId";\r
+ String correlationValue = messageId;\r
+\r
+ MsoLogger.setServiceName("MSO." + method);\r
+ MsoLogger.setLogContext(correlationValue, "N/A");\r
+\r
+ CreateVnfNotification message = new CreateVnfNotification();\r
+\r
+ message.setMessageId(messageId);\r
+ message.setCompleted(completed);\r
+ message.setException(exception);\r
+ message.setErrorMessage(errorMessage);\r
+ message.setVnfId(vnfId);\r
+ message.setOutputs(outputs);\r
+ message.setRollback(rollback);\r
+\r
+ handleCallback(method, message, messageEventName, messageVariable,\r
+ correlationVariable, correlationValue, logMarker);\r
+ }\r
+\r
+ @WebMethod(operationName = "updateVnfNotification")\r
+ @Oneway\r
@RequestWrapper(localName = "updateVnfNotification", targetNamespace = "http://org.openecomp.mso/vnfNotify", className = "org.openecomp.mso.adapters.vnf.async.client.UpdateVnfNotification")
@Action(input = "http://org.openecomp.mso/notify/adapterNotify/updateVnfNotificationRequest")
- public void updateVnfNotification(
- @WebParam(name = "messageId", targetNamespace = "")
- String messageId,
- @WebParam(name = "completed", targetNamespace = "")
- boolean completed,
- @WebParam(name = "exception", targetNamespace = "")
- MsoExceptionCategory exception,
- @WebParam(name = "errorMessage", targetNamespace = "")
- String errorMessage,
- @WebParam(name = "outputs", targetNamespace = "")
- org.openecomp.mso.bpmn.common.adapter.vnf.UpdateVnfNotification.Outputs outputs,
- @WebParam(name = "rollback", targetNamespace = "")
- VnfRollback rollback){
-
- UpdateVnfNotification updateVnfNotification = new UpdateVnfNotification();
-
- updateVnfNotification.setMessageId(messageId);
- updateVnfNotification.setCompleted(completed);
- updateVnfNotification.setException(exception);
- updateVnfNotification.setErrorMessage(errorMessage);
- updateVnfNotification.setOutputs(outputs);
- updateVnfNotification.setRollback(rollback);
-
- ProcessEngineServices pes = getProcessEngineServices();
- RuntimeService runtimeService = pes.getRuntimeService();
-
- MsoLogger.setServiceName("MSO." + "vnf Adapter Update");
- MsoLogger.setLogContext(messageId, "N/A");
- msoLogger.debug(logMarker + "Received UpdateVnfNotification - " + updateVnfNotification.toString());
-
- long startTime = System.currentTimeMillis();
- try {
-
- // Check to make sure the process instance is ready for correlation
- isReadyforCorrelation(runtimeService, messageId, "updateVnfNotificationCallback", "VNFU_messageId");
-
- msoLogger.debug(logMarker + "*** Received MSO updateVnfNotification Callback ******");
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, "Call to MSO VnfAdapterNotifyService ");
-
- msoLogger.debug(logMarker + "Update VNF Notification string:\n" + updateVnfNotification.toString());
-
- Map<String,Object> variables = new HashMap<String,Object>();
- variables.put("VNFU_messageId", messageId );
- variables.put("updateVnfNotificationCallback", updateVnfNotification.toString());
-
- //Correlating the response with the running instance
- runtimeService.createMessageCorrelation("updateVnfNotificationCallback").setVariables(variables)
- .processInstanceVariableEquals("VNFU_messageId", messageId).correlate();
-
- msoLogger.debug(logMarker + "***** Completed processing of MSO VnfAdapterNotifyService ******");
-
- } catch(MismatchingMessageCorrelationException e) {
- msoLogger.debug(logMarker + "[CORM]correlation id mismatch");
- String msg =
- "VNF Adapter Notify Service received a Update VNF Notification request with RequestId '"
- + messageId
- + "' but that RequestId could not be correlated to any active process - ignoring the request";
-
- msoLogger.error(MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(),
- MsoLogger.ErrorCode.UnknownError, logMarker + ":" + msg, e);
-
- }
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO Vnf Adapter Notify for Update VNF Notification.");
-
- msoLogger.recordMetricEvent ( startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO Vnf Adapter Notify for Update VNF Notification.", "BPMN",
- MsoLogger.getServiceName(), "updateVnfNotification");
-
- return;
- }
-
- /**
- *
- * @param errorMessage
- * @param exception
- * @param messageId
- * @param completed
- */
-
- //@WebService(serviceName="VNFAdapterDeleteCallbackV1", targetNamespace="http://org.openecomp.mso/vnfNotify")
- @WebMethod(operationName = "deleteVnfNotification")
- @Oneway
+ public void updateVnfNotification(\r
+ @WebParam(name = "messageId", targetNamespace = "")\r
+ String messageId,\r
+ @WebParam(name = "completed", targetNamespace = "")\r
+ boolean completed,\r
+ @WebParam(name = "exception", targetNamespace = "")\r
+ MsoExceptionCategory exception,\r
+ @WebParam(name = "errorMessage", targetNamespace = "")\r
+ String errorMessage,\r
+ @WebParam(name = "outputs", targetNamespace = "")\r
+ UpdateVnfNotification.Outputs outputs,\r
+ @WebParam(name = "rollback", targetNamespace = "")\r
+ VnfRollback rollback){\r
+\r
+ String method = "updateVnfNotification";\r
+ String messageEventName = "updateVnfNotificationCallback";\r
+ String messageVariable = "updateVnfNotificationCallback";\r
+ String correlationVariable = "VNFU_messageId";\r
+ String correlationValue = messageId;\r
+\r
+ MsoLogger.setServiceName("MSO." + method);\r
+ MsoLogger.setLogContext(correlationValue, "N/A");\r
+\r
+ UpdateVnfNotification message = new UpdateVnfNotification();\r
+\r
+ message.setMessageId(messageId);\r
+ message.setCompleted(completed);\r
+ message.setException(exception);\r
+ message.setErrorMessage(errorMessage);\r
+ message.setOutputs(outputs);\r
+ message.setRollback(rollback);\r
+\r
+ handleCallback(method, message, messageEventName, messageVariable,\r
+ correlationVariable, correlationValue, logMarker);\r
+ }\r
+\r
+ @WebMethod(operationName = "deleteVnfNotification")\r
+ @Oneway\r
@RequestWrapper(localName = "deleteVnfNotification", targetNamespace = "http://org.openecomp.mso/vnfNotify", className = "org.openecomp.mso.adapters.vnf.async.client.DeleteVnfNotification")
@Action(input = "http://org.openecomp.mso/notify/adapterNotify/deleteVnfNotificationRequest")
- public void deleteVnfNotification(
- @WebParam(name = "messageId", targetNamespace = "")
- String messageId,
- @WebParam(name = "completed", targetNamespace = "")
- boolean completed,
- @WebParam(name = "exception", targetNamespace = "")
- MsoExceptionCategory exception,
- @WebParam(name = "errorMessage", targetNamespace = "")
- String errorMessage) {
-
- //Callback URL to use http://localhost:28080/mso/services/VNFAdapterDeleteCallbackV1
-
- //DeleteVnfNotification Class
- DeleteVnfNotification deleteVnfNotification = new DeleteVnfNotification();
- deleteVnfNotification.setMessageId(messageId);
- deleteVnfNotification.setCompleted(completed);
- deleteVnfNotification.setException(exception);
- deleteVnfNotification.setErrorMessage(errorMessage);
-
- ProcessEngineServices pes = getProcessEngineServices();
- RuntimeService runtimeService = pes.getRuntimeService();
-
- MsoLogger.setServiceName("MSO." + "vnfAdapterDelete");
- MsoLogger.setLogContext(messageId, "N/A");
- msoLogger.debug(logMarker + "Received DeleteVnfNotification callback: " + deleteVnfNotification.toString());
-
- long startTime = System.currentTimeMillis();
- try {
-
- /* Check to make sure the process instance is ready for correlation*/
- //isReadyforCorrelation(runtimeService, messageId, "deleteVnfACallback", "VNFDEL_uuid");
-
- msoLogger.debug(logMarker + " *** Received MSO deleteVnfACallback ******");
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, "Call to MSO deleteVnfACallback ");
- msoLogger.debug(logMarker + " Callback response string:\n" + deleteVnfNotification.toString());
-
- Map<String,Object> variables = new HashMap<String,Object>();
- variables.put("VNFDEL_uuid", messageId);
- variables.put("deleteVnfACallback", deleteVnfNotification.toString());
-
- /*Correlating the response with the running instance*/
-
- runtimeService.createMessageCorrelation("deleteVnfACallback")
- .setVariables(variables)
- .processInstanceVariableEquals("VNFDEL_uuid", messageId).correlate();
-
- msoLogger.debug(logMarker + "***** Completed processing of MSO deleteVnfACallback ******");
-
- } catch(MismatchingMessageCorrelationException e) {
-
- msoLogger.debug(logMarker + " [CORM]correlation id mismatch");
- // Couldn't correlate requestId to any active flow
- //MsoLogger logger = MsoLogger.getMsoLogger("SDNCAdapterCallbackService");
-
- String msg =
- "Vnf Adapter Callback Service received a Vnf Adapter Callback with messageId '"
- + messageId
- + "' but that messageId could not be correlated to any active process - ignoring the Request";
-
- msoLogger.error(MessageEnum.BPMN_SDNC_CALLBACK_EXCEPTION, "BPMN", MsoLogger.getServiceName(),
- MsoLogger.ErrorCode.UnknownError, logMarker + ":" + msg, e);
-
- }
- msoLogger.recordAuditEvent (startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO VNFAdapterDeleteCallbackV1.");
-
- msoLogger.recordMetricEvent ( startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc,
- logMarker + "Completed the execution of MSO VNFAdapterDeleteCallbackV1.", "BPMN",
- MsoLogger.getServiceName(), "deleteVnfNotification");
-
- return;
- }
-
- private void isReadyforCorrelation(RuntimeService runtimeService, String requestId, String responseName, String correlationValue) {
-
- long waitingInstances = runtimeService.createExecutionQuery().messageEventSubscriptionName(responseName).processVariableValueEquals(correlationValue, requestId).count();
- int retries = 50;
- while (waitingInstances==0 && retries > 0) {
- try {
- Thread.sleep(100);
- } catch (InterruptedException e) {
- // TODO Auto-generated catch block
- // should I add new exception Message to MessageEnum???
- msoLogger.error(MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(), MsoLogger.ErrorCode.UnknownError, logMarker, e);
-
- } // you can still play with the numbers
- waitingInstances = runtimeService.createExecutionQuery() //
- .messageEventSubscriptionName(responseName)
- .processVariableValueEquals(correlationValue, requestId).count();
- retries--;
- }
- }
-
-
- private ProcessEngineServices getProcessEngineServices() {
- if (pes4junit == null) {
- return BpmPlatform.getDefaultProcessEngine();
- } else {
- return pes4junit;
- }
- }
-
- @WebMethod(exclude=true)
- public void setProcessEngineServices4junit(ProcessEngineServices pes) {
- pes4junit = pes;
- }
-}
+ public void deleteVnfNotification(\r
+ @WebParam(name = "messageId", targetNamespace = "")\r
+ String messageId,\r
+ @WebParam(name = "completed", targetNamespace = "")\r
+ boolean completed,\r
+ @WebParam(name = "exception", targetNamespace = "")\r
+ MsoExceptionCategory exception,\r
+ @WebParam(name = "errorMessage", targetNamespace = "")\r
+ String errorMessage) {\r
+\r
+ String method = "deleteVnfNotification";\r
+ String messageEventName = "deleteVnfACallback";\r
+ String messageVariable = "deleteVnfACallback";\r
+ String correlationVariable = "VNFDEL_uuid";\r
+ String correlationValue = messageId;\r
+\r
+ MsoLogger.setServiceName("MSO." + method);\r
+ MsoLogger.setLogContext(correlationValue, "N/A");\r
+\r
+ DeleteVnfNotification message = new DeleteVnfNotification();\r
+\r
+ message.setMessageId(messageId);\r
+ message.setCompleted(completed);\r
+ message.setException(exception);\r
+ message.setErrorMessage(errorMessage);\r
+\r
+ handleCallback(method, message, messageEventName, messageVariable,\r
+ correlationVariable, correlationValue, logMarker);\r
+ }\r
+}
\ No newline at end of file
import java.util.Map;\r
\r
import javax.ws.rs.Consumes;\r
+import javax.ws.rs.HeaderParam;\r
import javax.ws.rs.POST;\r
import javax.ws.rs.Path;\r
import javax.ws.rs.PathParam;\r
import javax.ws.rs.core.MediaType;\r
import javax.ws.rs.core.Response;\r
\r
-import org.camunda.bpm.BpmPlatform;\r
-import org.camunda.bpm.engine.ProcessEngineServices;\r
-import org.camunda.bpm.engine.RuntimeService;\r
-\r
import org.openecomp.mso.logger.MessageEnum;\r
import org.openecomp.mso.logger.MsoLogger;\r
\r
* </pre>\r
*/\r
@Path("/")\r
-public class WorkflowMessageResource {\r
+public class WorkflowMessageResource extends AbstractCallbackService {\r
private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);\r
private static final String LOGMARKER = "[WORKFLOW-MESSAGE]";\r
-\r
- private ProcessEngineServices pes4junit = null;\r
\r
@POST\r
@Path("/WorkflowMessage/{messageType}/{correlator}")\r
@Consumes("*/*")\r
@Produces(MediaType.TEXT_PLAIN)\r
- public Response deliver(@PathParam("messageType") String messageType,\r
- @PathParam("correlator") String correlator, String message) {\r
+ public Response deliver(\r
+ @HeaderParam("Content-Type") String contentType,\r
+ @PathParam("messageType") String messageType,\r
+ @PathParam("correlator") String correlator,\r
+ String message) {\r
+\r
+ String method = "receiveWorkflowMessage";\r
+ MsoLogger.setServiceName("MSO." + method);\r
+ MsoLogger.setLogContext(correlator, "N/A");\r
\r
LOGGER.debug(LOGMARKER + " Received workflow message"\r
+ " type='" + messageType + "'"\r
+ " correlator='" + correlator + "'"\r
- + System.lineSeparator() + message);\r
-\r
- MsoLogger.setServiceName("MSO." + "WorkflowMessage");\r
+ + (contentType == null ? "" : " contentType='" + contentType + "'")\r
+ + " message=" + System.lineSeparator() + message);\r
\r
if (messageType == null || messageType.isEmpty()) {\r
String msg = "Missing message type";\r
return Response.status(400).entity(msg).build();\r
}\r
\r
- String correlatorVariable = messageType + "_CORRELATOR";\r
+ String messageEventName = "WorkflowMessage";\r
String messageVariable = messageType + "_MESSAGE";\r
+ String correlationVariable = messageType + "_CORRELATOR";\r
+ String correlationValue = correlator;\r
+ String contentTypeVariable = messageType + "_CONTENT_TYPE";\r
\r
- long startTime = System.currentTimeMillis();\r
-\r
- try {\r
- RuntimeService runtimeService = getProcessEngineServices().getRuntimeService();\r
-\r
- if (!isReadyforCorrelation(runtimeService, correlatorVariable, correlator)) {\r
- String msg = "No process is waiting to receive '" + messageType + "' WorkflowMessage with correlator '" + correlator + "'";\r
- LOGGER.debug(LOGMARKER + " " + msg);\r
- LOGGER.error(MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(), MsoLogger.ErrorCode.UnknownError, LOGMARKER + ":" + msg);\r
- LOGGER.recordMetricEvent(startTime, MsoLogger.StatusCode.ERROR, MsoLogger.ResponseCode.BusinessProcesssError, msg, "BPMN", MsoLogger.getServiceName(), messageType);\r
- LOGGER.recordAuditEvent(startTime, MsoLogger.StatusCode.ERROR, MsoLogger.ResponseCode.BusinessProcesssError, msg);\r
- return Response.status(500).entity(msg).build();\r
- }\r
+ Map<String, Object> variables = new HashMap<String, Object>();\r
\r
- Map<String, Object> variables = new HashMap<String, Object>();\r
- variables.put(correlatorVariable, correlator);\r
- variables.put(messageVariable, message);\r
-\r
- runtimeService.createMessageCorrelation("WorkflowMessage").setVariables(variables)\r
- .processInstanceVariableEquals(correlatorVariable, correlator).correlate();\r
-\r
- String msg = "Completed delivery of '" + messageType + "' WorkflowMessage with correlator '" + correlator + "'";\r
- LOGGER.debug(LOGMARKER + msg);\r
- LOGGER.recordMetricEvent(startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, msg, "BPMN", MsoLogger.getServiceName(), messageType);\r
- LOGGER.recordAuditEvent(startTime, MsoLogger.StatusCode.COMPLETE, MsoLogger.ResponseCode.Suc, msg);\r
- return Response.status(204).build();\r
- } catch (Exception e) {\r
- // For example: MismatchingMessageCorrelationException\r
- String msg = "Caught " + e.getClass().getSimpleName() + " processing '" + messageType + "' WorkflowMessage with " + correlatorVariable + "='" + correlator + "'";\r
- LOGGER.debug(LOGMARKER + " " + msg);\r
- LOGGER.error(MessageEnum.BPMN_GENERAL_EXCEPTION, "BPMN", MsoLogger.getServiceName(), MsoLogger.ErrorCode.UnknownError, LOGMARKER + ":" + msg, e);\r
- LOGGER.recordMetricEvent(startTime, MsoLogger.StatusCode.ERROR, MsoLogger.ResponseCode.UnknownError, msg, "BPMN", MsoLogger.getServiceName(), messageType);\r
- LOGGER.recordAuditEvent(startTime, MsoLogger.StatusCode.ERROR, MsoLogger.ResponseCode.UnknownError, msg);\r
- return Response.status(500).entity(msg).build();\r
+ if (contentType != null) {\r
+ variables.put(contentTypeVariable, contentType);\r
}\r
- }\r
- \r
- private boolean isReadyforCorrelation(RuntimeService runtimeService,\r
- String correlationVariable, String correlationValue)\r
- throws InterruptedException {\r
-\r
- long waitingInstances = runtimeService.createExecutionQuery()\r
- .messageEventSubscriptionName("WorkflowMessage")\r
- .processVariableValueEquals(correlationVariable, correlationValue)\r
- .count();\r
-\r
- int retries = 50;\r
- while (waitingInstances == 0 && retries > 0) {\r
- Thread.sleep(100);\r
\r
- waitingInstances = runtimeService.createExecutionQuery()\r
- .messageEventSubscriptionName("WorkflowMessage")\r
- .processVariableValueEquals(correlationVariable, correlationValue)\r
- .count();\r
-\r
- retries--;\r
- }\r
+ CallbackResult result = handleCallback(method, message, messageEventName,\r
+ messageVariable, correlationVariable, correlationValue, LOGMARKER, variables);\r
\r
- return waitingInstances != 0;\r
- }\r
- \r
- private ProcessEngineServices getProcessEngineServices() {\r
- if (pes4junit == null) {\r
- return BpmPlatform.getDefaultProcessEngine();\r
+ if (result instanceof CallbackError) {\r
+ return Response.status(500).entity(((CallbackError)result).getErrorMessage()).build();\r
} else {\r
- return pes4junit;\r
+ return Response.status(204).build();\r
}\r
}\r
-\r
- public void setProcessEngineServices4junit(ProcessEngineServices pes) {\r
- pes4junit = pes;\r
- }\r
}
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd" id="_D5VzAHElEeaJwpcpVN5gXw" exporter="camunda modeler" exporterVersion="2.7.0" targetNamespace="http://camunda.org/schema/1.0/bpmn">
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_D5VzAHElEeaJwpcpVN5gXw" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:process id="GenericGetService" name="GenericGetService" isExecutable="true">
<bpmn2:scriptTask id="intialization" name="Initialization" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
getService.preProcessRequest(execution)
]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="intialization" targetRef="getUrl"/>
- <bpmn2:exclusiveGateway id="getUrl" name="Get Url?" default="getUrlNo">
+ <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="intialization" targetRef="getUrl" />
+ <bpmn2:exclusiveGateway id="getUrl" name="Need Object's Url?" default="getUrlNo">
<bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
<bpmn2:outgoing>getUrlYes</bpmn2:outgoing>
<bpmn2:outgoing>getUrlNo</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
<bpmn2:sequenceFlow id="getUrlYes" name="Yes" sourceRef="getUrl" targetRef="obtain">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("GENGS_obtainServiceInstanceUrl" ) == true}]]></bpmn2:conditionExpression>
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("GENGS_obtainObjectsUrl" ) == true}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="getUrlNo" name="No" sourceRef="getUrl" targetRef="ExclusiveGateway_2"/>
+ <bpmn2:sequenceFlow id="getUrlNo" name="No" sourceRef="getUrl" targetRef="ExclusiveGateway_2" />
<bpmn2:subProcess id="bpmnExceptionHandlingSubProcess" name="Error Handling Sub Process" triggeredByEvent="true">
<bpmn2:scriptTask id="processBPMNException" name="Process Error" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
ExceptionUtil ex = new ExceptionUtil()
ex.processSubflowsBPMNException(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="processBPMNException" targetRef="EndEvent_2"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="processBPMNException" targetRef="EndEvent_2" />
<bpmn2:startEvent id="StartEvent_2">
<bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
- <bpmn2:errorEventDefinition id="ErrorEventDefinition_1"/>
+ <bpmn2:errorEventDefinition id="ErrorEventDefinition_1" />
</bpmn2:startEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="StartEvent_2" targetRef="processBPMNException"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="StartEvent_2" targetRef="processBPMNException" />
<bpmn2:endEvent id="EndEvent_2">
<bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>
</bpmn2:endEvent>
getService.setSuccessIndicator(execution, true)
]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="toggleSuccess" targetRef="EndEvent_1"/>
- <bpmn2:scriptTask id="getServiceInstance" name="GET
Service Instance" scriptFormat="groovy">
+ <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="toggleSuccess" targetRef="EndEvent_1" />
+ <bpmn2:scriptTask id="getServiceInstance" name="GET Object" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_5</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.common.scripts.*
GenericGetService getService = new GenericGetService()
getService.getServiceObject(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="getServiceInstance" targetRef="toggleSuccess"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="getServiceInstance" targetRef="toggleSuccess" />
<bpmn2:exclusiveGateway id="ExclusiveGateway_2">
<bpmn2:incoming>getUrlNo</bpmn2:incoming>
<bpmn2:incoming>foundYes</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_5</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="ExclusiveGateway_2" targetRef="getServiceInstance"/>
- <bpmn2:scriptTask id="obtainServiceUrlById" name="Obtain Service URL Using
Id" scriptFormat="groovy">
+ <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="ExclusiveGateway_2" targetRef="getServiceInstance" />
+ <bpmn2:scriptTask id="obtainServiceUrlById" name="Node Query Using Id " scriptFormat="groovy">
<bpmn2:incoming>obtainById</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.common.scripts.*
GenericGetService getService = new GenericGetService()
getService.obtainServiceInstanceUrlById(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="obtainServiceUrlById" targetRef="ExclusiveGateway_3"/>
- <bpmn2:scriptTask id="obtainServiceUrlByName" name="Obtain Service Url Using
Name" scriptFormat="groovy">
+ <bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="obtainServiceUrlById" targetRef="ExclusiveGateway_3" />
+ <bpmn2:scriptTask id="obtainServiceUrlByName" name="Node Query Using Name" scriptFormat="groovy">
<bpmn2:incoming>obtainByName</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_13</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.common.scripts.*
GenericGetService getService = new GenericGetService()
getService.obtainServiceInstanceUrlByName(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_13" name="" sourceRef="obtainServiceUrlByName" targetRef="ExclusiveGateway_3"/>
- <bpmn2:exclusiveGateway id="obtain" name="Obtain By?" default="obtainById">
+ <bpmn2:sequenceFlow id="SequenceFlow_13" name="" sourceRef="obtainServiceUrlByName" targetRef="ExclusiveGateway_3" />
+ <bpmn2:exclusiveGateway id="obtain" name="Query By?" default="obtainById">
<bpmn2:incoming>getUrlYes</bpmn2:incoming>
<bpmn2:outgoing>obtainById</bpmn2:outgoing>
<bpmn2:outgoing>obtainByName</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="obtainById" name="Id" sourceRef="obtain" targetRef="obtainServiceUrlById"/>
+ <bpmn2:sequenceFlow id="obtainById" name="Id" sourceRef="obtain" targetRef="obtainServiceUrlById" />
<bpmn2:sequenceFlow id="obtainByName" name="Name" sourceRef="obtain" targetRef="obtainServiceUrlByName">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("GENGS_obtainServiceInstanceUrlByName" ) == true}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
<bpmn2:sequenceFlow id="foundYes" name="Yes" sourceRef="serviceFoundCheck" targetRef="ExclusiveGateway_2">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("GENGS_FoundIndicator" ) == true}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="notFound" name="No" sourceRef="serviceFoundCheck" targetRef="EndEvent_3"/>
+ <bpmn2:sequenceFlow id="notFound" name="No" sourceRef="serviceFoundCheck" targetRef="EndEvent_3" />
<bpmn2:endEvent id="EndEvent_3">
<bpmn2:incoming>notFound</bpmn2:incoming>
- <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_29"/>
+ <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_29" />
</bpmn2:endEvent>
<bpmn2:exclusiveGateway id="ExclusiveGateway_3">
<bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>
<bpmn2:incoming>SequenceFlow_13</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_14</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="SequenceFlow_14" name="" sourceRef="ExclusiveGateway_3" targetRef="serviceFoundCheck"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_14" name="" sourceRef="ExclusiveGateway_3" targetRef="serviceFoundCheck" />
<bpmn2:endEvent id="EndEvent_1">
<bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
- <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_26"/>
+ <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_26" />
</bpmn2:endEvent>
<bpmn2:startEvent id="StartEvent_1">
<bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
</bpmn2:startEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="StartEvent_1" targetRef="intialization"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="StartEvent_1" targetRef="intialization" />
</bpmn2:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="GenericGetService">
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_69" bpmnElement="StartEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="108.0" y="264.0"/>
+ <dc:Bounds x="108" y="264" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="126.0" y="305.0"/>
+ <dc:Bounds x="126" y="305" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_288" bpmnElement="intialization">
- <dc:Bounds height="80.0" width="100.0" x="228.0" y="242.0"/>
+ <dc:Bounds x="228" y="242" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_69" targetElement="_BPMNShape_ScriptTask_288">
- <di:waypoint xsi:type="dc:Point" x="144.0" y="282.0"/>
- <di:waypoint xsi:type="dc:Point" x="228.0" y="282.0"/>
+ <di:waypoint xsi:type="dc:Point" x="144" y="282" />
+ <di:waypoint xsi:type="dc:Point" x="228" y="282" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="177.0" y="282.0"/>
+ <dc:Bounds x="177" y="282" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_227" bpmnElement="getUrl" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="372.0" y="256.0"/>
+ <dc:Bounds x="372" y="256" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="70.0" x="408.0" y="286.0"/>
+ <dc:Bounds x="420" y="282" width="72" height="24" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_ScriptTask_288" targetElement="_BPMNShape_ExclusiveGateway_227">
- <di:waypoint xsi:type="dc:Point" x="328.0" y="282.0"/>
- <di:waypoint xsi:type="dc:Point" x="372.0" y="281.0"/>
+ <di:waypoint xsi:type="dc:Point" x="328" y="282" />
+ <di:waypoint xsi:type="dc:Point" x="372" y="281" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="350.0" y="281.0"/>
+ <dc:Bounds x="350" y="281" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_289" bpmnElement="obtainServiceUrlById">
- <dc:Bounds height="80.0" width="100.0" x="528.0" y="197.0"/>
+ <dc:Bounds x="528" y="197" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_228" bpmnElement="ExclusiveGateway_2" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="738.0" y="256.0"/>
+ <dc:Bounds x="738" y="256" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="763.0" y="311.0"/>
+ <dc:Bounds x="763" y="311" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_290" bpmnElement="getServiceInstance">
- <dc:Bounds height="80.0" width="100.0" x="820.0" y="242.0"/>
+ <dc:Bounds x="820" y="242" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="getUrlYes" sourceElement="_BPMNShape_ExclusiveGateway_227" targetElement="_BPMNShape_ExclusiveGateway_233">
- <di:waypoint xsi:type="dc:Point" x="397.0" y="256.0"/>
- <di:waypoint xsi:type="dc:Point" x="397.0" y="170.0"/>
- <di:waypoint xsi:type="dc:Point" x="446.0" y="170.0"/>
+ <di:waypoint xsi:type="dc:Point" x="397" y="256" />
+ <di:waypoint xsi:type="dc:Point" x="397" y="170" />
+ <di:waypoint xsi:type="dc:Point" x="446" y="170" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="29.0" x="397.0" y="213.0"/>
+ <dc:Bounds x="397" y="213" width="29" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_4" sourceElement="_BPMNShape_ScriptTask_289" targetElement="_BPMNShape_ExclusiveGateway_234">
- <di:waypoint xsi:type="dc:Point" x="628.0" y="237.0"/>
- <di:waypoint xsi:type="dc:Point" x="671.0" y="237.0"/>
- <di:waypoint xsi:type="dc:Point" x="671.0" y="195.0"/>
+ <di:waypoint xsi:type="dc:Point" x="628" y="237" />
+ <di:waypoint xsi:type="dc:Point" x="671" y="237" />
+ <di:waypoint xsi:type="dc:Point" x="671" y="195" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="668.0" y="221.0"/>
+ <dc:Bounds x="668" y="221" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_5" sourceElement="_BPMNShape_ExclusiveGateway_228" targetElement="_BPMNShape_ScriptTask_290">
- <di:waypoint xsi:type="dc:Point" x="788.0" y="281.0"/>
- <di:waypoint xsi:type="dc:Point" x="820.0" y="282.0"/>
+ <di:waypoint xsi:type="dc:Point" x="788" y="281" />
+ <di:waypoint xsi:type="dc:Point" x="820" y="282" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="798.0" y="281.0"/>
+ <dc:Bounds x="798" y="281" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_6" bpmnElement="getUrlNo" sourceElement="_BPMNShape_ExclusiveGateway_227" targetElement="_BPMNShape_ExclusiveGateway_228">
- <di:waypoint xsi:type="dc:Point" x="397.0" y="306.0"/>
- <di:waypoint xsi:type="dc:Point" x="397.0" y="370.0"/>
- <di:waypoint xsi:type="dc:Point" x="763.0" y="370.0"/>
- <di:waypoint xsi:type="dc:Point" x="763.0" y="306.0"/>
+ <di:waypoint xsi:type="dc:Point" x="397" y="306" />
+ <di:waypoint xsi:type="dc:Point" x="397" y="370" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="370" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="306" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="22.0" x="400.0" y="324.0"/>
+ <dc:Bounds x="400" y="324" width="22" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_291" bpmnElement="toggleSuccess">
- <dc:Bounds height="80.0" width="100.0" x="960.0" y="242.0"/>
+ <dc:Bounds x="960" y="242" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_7" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_290" targetElement="_BPMNShape_ScriptTask_291">
- <di:waypoint xsi:type="dc:Point" x="920.0" y="282.0"/>
- <di:waypoint xsi:type="dc:Point" x="960.0" y="282.0"/>
+ <di:waypoint xsi:type="dc:Point" x="920" y="282" />
+ <di:waypoint xsi:type="dc:Point" x="960" y="282" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="937.0" y="282.0"/>
+ <dc:Bounds x="937" y="282" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_223" bpmnElement="EndEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="1133.0" y="264.0"/>
+ <dc:Bounds x="1133" y="264" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="1151.0" y="305.0"/>
+ <dc:Bounds x="1151" y="305" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_ScriptTask_291" targetElement="_BPMNShape_EndEvent_223">
- <di:waypoint xsi:type="dc:Point" x="1060.0" y="282.0"/>
- <di:waypoint xsi:type="dc:Point" x="1133.0" y="282.0"/>
+ <di:waypoint xsi:type="dc:Point" x="1060" y="282" />
+ <di:waypoint xsi:type="dc:Point" x="1133" y="282" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1100.0" y="282.0"/>
+ <dc:Bounds x="1100" y="282" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_SubProcess_25" bpmnElement="bpmnExceptionHandlingSubProcess" isExpanded="true">
- <dc:Bounds height="169.0" width="325.0" x="152.0" y="468.0"/>
+ <dc:Bounds x="152" y="468" width="325" height="169" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_70" bpmnElement="StartEvent_2">
- <dc:Bounds height="36.0" width="36.0" x="176.0" y="535.0"/>
+ <dc:Bounds x="176" y="535" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="194.0" y="576.0"/>
+ <dc:Bounds x="194" y="576" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_224" bpmnElement="EndEvent_2">
- <dc:Bounds height="36.0" width="36.0" x="416.0" y="535.0"/>
+ <dc:Bounds x="416" y="535" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="434.0" y="576.0"/>
+ <dc:Bounds x="434" y="576" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_292" bpmnElement="processBPMNException">
- <dc:Bounds height="80.0" width="100.0" x="265.0" y="513.0"/>
+ <dc:Bounds x="265" y="513" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_9" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_StartEvent_70" targetElement="_BPMNShape_ScriptTask_292">
- <di:waypoint xsi:type="dc:Point" x="212.0" y="553.0"/>
- <di:waypoint xsi:type="dc:Point" x="265.0" y="553.0"/>
+ <di:waypoint xsi:type="dc:Point" x="212" y="553" />
+ <di:waypoint xsi:type="dc:Point" x="265" y="553" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="233.0" y="553.0"/>
+ <dc:Bounds x="233" y="553" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_10" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_ScriptTask_292" targetElement="_BPMNShape_EndEvent_224">
- <di:waypoint xsi:type="dc:Point" x="365.0" y="553.0"/>
- <di:waypoint xsi:type="dc:Point" x="416.0" y="553.0"/>
+ <di:waypoint xsi:type="dc:Point" x="365" y="553" />
+ <di:waypoint xsi:type="dc:Point" x="416" y="553" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="385.0" y="553.0"/>
+ <dc:Bounds x="385" y="553" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_301" bpmnElement="obtainServiceUrlByName">
- <dc:Bounds height="80.0" width="100.0" x="528.0" y="59.0"/>
+ <dc:Bounds x="528" y="59" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_233" bpmnElement="obtain" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="446.0" y="145.0"/>
+ <dc:Bounds x="446" y="145" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="71.0" x="496.0" y="162.0"/>
+ <dc:Bounds x="501" y="164" width="53" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_234" bpmnElement="ExclusiveGateway_3" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="646.0" y="145.0"/>
+ <dc:Bounds x="646" y="145" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="671.0" y="200.0"/>
+ <dc:Bounds x="671" y="200" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_13" bpmnElement="obtainById" sourceElement="_BPMNShape_ExclusiveGateway_233" targetElement="_BPMNShape_ScriptTask_289">
- <di:waypoint xsi:type="dc:Point" x="471.0" y="195.0"/>
- <di:waypoint xsi:type="dc:Point" x="471.0" y="236.0"/>
- <di:waypoint xsi:type="dc:Point" x="528.0" y="237.0"/>
+ <di:waypoint xsi:type="dc:Point" x="471" y="195" />
+ <di:waypoint xsi:type="dc:Point" x="471" y="236" />
+ <di:waypoint xsi:type="dc:Point" x="528" y="237" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="16.0" x="476.0" y="207.0"/>
+ <dc:Bounds x="476" y="207" width="16" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_14" bpmnElement="obtainByName" sourceElement="_BPMNShape_ExclusiveGateway_233" targetElement="_BPMNShape_ScriptTask_301">
- <di:waypoint xsi:type="dc:Point" x="471.0" y="145.0"/>
- <di:waypoint xsi:type="dc:Point" x="471.0" y="99.0"/>
- <di:waypoint xsi:type="dc:Point" x="528.0" y="99.0"/>
+ <di:waypoint xsi:type="dc:Point" x="471" y="145" />
+ <di:waypoint xsi:type="dc:Point" x="471" y="99" />
+ <di:waypoint xsi:type="dc:Point" x="528" y="99" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="40.0" x="471.0" y="115.0"/>
+ <dc:Bounds x="471" y="115" width="40" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_15" bpmnElement="SequenceFlow_13" sourceElement="_BPMNShape_ScriptTask_301" targetElement="_BPMNShape_ExclusiveGateway_234">
- <di:waypoint xsi:type="dc:Point" x="628.0" y="99.0"/>
- <di:waypoint xsi:type="dc:Point" x="671.0" y="99.0"/>
- <di:waypoint xsi:type="dc:Point" x="671.0" y="145.0"/>
+ <di:waypoint xsi:type="dc:Point" x="628" y="99" />
+ <di:waypoint xsi:type="dc:Point" x="671" y="99" />
+ <di:waypoint xsi:type="dc:Point" x="671" y="145" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="665.0" y="99.0"/>
+ <dc:Bounds x="665" y="99" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_235" bpmnElement="serviceFoundCheck" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="738.0" y="145.0"/>
+ <dc:Bounds x="738" y="145" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="59.0" x="735.0" y="125.0"/>
+ <dc:Bounds x="735" y="125" width="59" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_16" bpmnElement="SequenceFlow_14" sourceElement="_BPMNShape_ExclusiveGateway_234" targetElement="_BPMNShape_ExclusiveGateway_235">
- <di:waypoint xsi:type="dc:Point" x="696.0" y="170.0"/>
- <di:waypoint xsi:type="dc:Point" x="738.0" y="170.0"/>
+ <di:waypoint xsi:type="dc:Point" x="696" y="170" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="170" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="704.0" y="170.0"/>
+ <dc:Bounds x="704" y="170" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_17" bpmnElement="foundYes" sourceElement="_BPMNShape_ExclusiveGateway_235" targetElement="_BPMNShape_ExclusiveGateway_228">
- <di:waypoint xsi:type="dc:Point" x="763.0" y="195.0"/>
- <di:waypoint xsi:type="dc:Point" x="763.0" y="256.0"/>
+ <di:waypoint xsi:type="dc:Point" x="763" y="195" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="256" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="29.0" x="762.0" y="205.0"/>
+ <dc:Bounds x="762" y="205" width="29" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_18" bpmnElement="notFound" sourceElement="_BPMNShape_ExclusiveGateway_235" targetElement="_BPMNShape_EndEvent_229">
- <di:waypoint xsi:type="dc:Point" x="788.0" y="170.0"/>
- <di:waypoint xsi:type="dc:Point" x="877.0" y="171.0"/>
+ <di:waypoint xsi:type="dc:Point" x="788" y="170" />
+ <di:waypoint xsi:type="dc:Point" x="877" y="171" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="22.0" x="798.0" y="170.0"/>
+ <dc:Bounds x="798" y="170" width="22" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_229" bpmnElement="EndEvent_3">
- <dc:Bounds height="36.0" width="36.0" x="877.0" y="153.0"/>
+ <dc:Bounds x="877" y="153" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="895.0" y="194.0"/>
+ <dc:Bounds x="895" y="194" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
</bpmndi:BPMNPlane>
-/*-
- * ============LICENSE_START=======================================================
- * OPENECOMP - MSO
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-
-package org.openecomp.mso.bpmn.common.scripts;
-
-import static org.junit.Assert.*;
-import static org.mockito.Mockito.*
-
-import org.mockito.MockitoAnnotations
-import org.mockito.runners.MockitoJUnitRunner
-import org.mockito.internal.debugging.MockitoDebuggerImpl
-import org.junit.Before
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil;
-import org.junit.Rule;
-import org.junit.Test
-import org.junit.Ignore
-import org.junit.runner.RunWith
-import org.junit.Before;
-import org.junit.Test;
-import org.camunda.bpm.engine.ProcessEngineServices
-import org.camunda.bpm.engine.RepositoryService
-import org.camunda.bpm.engine.impl.persistence.entity.ExecutionEntity
-import org.camunda.bpm.engine.impl.pvm.process.ProcessDefinitionImpl
-import org.camunda.bpm.engine.repository.ProcessDefinition
-
-@RunWith(MockitoJUnitRunner.class)
-class AaiUtilTest extends MsoGroovyTest {
-
- @Test
- public void testGetVersionDefault() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def version = aaiUtil.getVersion(mockExecution, 'l3-network', 'CreateAAIVfModule')
- assertEquals('8', version)
- }
-
- @Test
- public void testGetVersionResourceSpecific() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_l3_network_version")).thenReturn('7')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def version = aaiUtil.getVersion(mockExecution, 'l3-network', 'CreateAAIVfModule')
- assertEquals('7', version)
- }
-
- @Test
- public void testGetVersionFlowSpecific() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_custom_CreateAAIVfModule_aai_version")).thenReturn('6')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_l3_network_version")).thenReturn('7')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def version = aaiUtil.getVersion(mockExecution, 'l3-network', 'CreateAAIVfModule')
- assertEquals('6', version)
- }
-
- @Test(expected=java.lang.Exception.class)
- public void testGetVersionNotDefined() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def version = aaiUtil.getVersion(mockExecution, 'l3-network', 'CreateAAIVfModule')
- }
-
- @Test
- public void testGetUriDefaultVersion() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn('/aai/v8/network/l3-networks/l3-network')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
-
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getUri(mockExecution, 'l3-network')
- assertEquals('/aai/v8/network/l3-networks/l3-network', uri)
- }
-
- @Test
- public void testGetUriFlowAndResourceSpecific() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_CreateAAIVfModule_aai_l3_network_uri")).thenReturn('/aai/v6/network/l3-networks/l3-network')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn('/aai/v8/network/l3-networks/l3-network')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
-
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getUri(mockExecution, 'l3-network')
- assertEquals('/aai/v6/network/l3-networks/l3-network', uri)
- }
-
- @Test
- public void testGetNetworkGenericVnfEndpoint() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_generic_vnf_uri")).thenReturn('/aai/v8/network/generic-vnfs/generic-vnf')
- when(mockExecution.getVariable('URN_aai_endpoint')).thenReturn('http://localhost:28090')
-
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def endpoint = aaiUtil.getNetworkGenericVnfEndpoint(mockExecution)
- assertEquals('http://localhost:28090/aai/v8/network/generic-vnfs/generic-vnf', endpoint)
- }
-
- @Test
- public void testGetNetworkGenericVnfUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_generic_vnf_uri")).thenReturn('/aai/v8/network/generic-vnfs/generic-vnf')
-
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getNetworkGenericVnfUri(mockExecution)
- assertEquals('/aai/v8/network/generic-vnfs/generic-vnf', uri)
- }
-
- @Test
- public void testGetNetworkVpnBindingUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_vpn_binding_uri")).thenReturn('/aai/v8/network/vpn-bindings/vpn-binding')
-
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getNetworkVpnBindingUri(mockExecution)
- assertEquals('/aai/v8/network/vpn-bindings/vpn-binding', uri)
- }
-
- @Test
- public void testGetNetworkPolicyUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_network_policy_uri")).thenReturn('/aai/v8/network/network-policies/network-policy')
-
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getNetworkPolicyUri(mockExecution)
- assertEquals('/aai/v8/network/network-policies/network-policy', uri)
- }
-
- @Test
- public void testGetNetworkTableReferencesUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_route_table_reference_uri")).thenReturn('/aai/v8/network/route-table-references/route-table-reference')
-
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getNetworkTableReferencesUri(mockExecution)
- assertEquals('/aai/v8/network/route-table-references/route-table-reference', uri)
- }
-
- @Test
- public void testGetNetworkVceUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_vce_uri")).thenReturn('/aai/v8/network/vces/vce')
-
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getNetworkVceUri(mockExecution)
- assertEquals('/aai/v8/network/vces/vce', uri)
- }
-
- @Test
- public void testGetNetworkL3NetworkUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn('/aai/v8/network/l3-networks/l3-network')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getNetworkL3NetworkUri(mockExecution)
- assertEquals('/aai/v8/network/l3-networks/l3-network', uri)
- }
-
- @Test
- public void testGetBusinessCustomerUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_customer_uri")).thenReturn('/aai/v8/business/customers/customer')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getBusinessCustomerUri(mockExecution)
- assertEquals('/aai/v8/business/customers/customer', uri)
- }
-
- @Test
- public void testGetCloudInfrastructureCloudRegionEndpoint() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_cloud_region_uri")).thenReturn('/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic')
- when(mockExecution.getVariable('URN_aai_endpoint')).thenReturn('http://localhost:28090')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getCloudInfrastructureCloudRegionEndpoint(mockExecution)
- assertEquals('http://localhost:28090/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic', uri)
- }
-
- @Test
- public void testGetCloudInfrastructureCloudRegionUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_cloud_region_uri")).thenReturn('/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getCloudInfrastructureCloudRegionUri(mockExecution)
- assertEquals('/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic', uri)
- }
-
- @Test
- public void testGetCloudInfrastructureTenantUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_tenant_uri")).thenReturn('/aai/v8/cloud-infrastructure/tenants/tenant')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getCloudInfrastructureTenantUri(mockExecution)
- assertEquals('/aai/v8/cloud-infrastructure/tenants/tenant', uri)
- }
-
- @Test
- public void testGetSearchNodesQueryUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_nodes_query_uri")).thenReturn('/aai/v8/search/nodes-query')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getSearchNodesQueryUri(mockExecution)
- assertEquals('/aai/v8/search/nodes-query', uri)
- }
-
- @Test
- public void testGetSearchNodesQueryEndpoint() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_nodes_query_uri")).thenReturn('/aai/v8/search/nodes-query')
- when(mockExecution.getVariable('URN_aai_endpoint')).thenReturn('http://localhost:28090')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getSearchNodesQueryEndpoint(mockExecution)
- assertEquals('http://localhost:28090/aai/v8/search/nodes-query', uri)
- }
-
- @Test
- public void testGetSearchGenericQueryUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_generic_query_uri")).thenReturn('/aai/v8/search/generic-query')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def uri = aaiUtil.getSearchGenericQueryUri(mockExecution)
- assertEquals('/aai/v8/search/generic-query', uri)
- }
-
- @Test
- public void testGetNamespaceFromUri() {
- ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')
- CreateAAIVfModule myproc = new CreateAAIVfModule()
- AaiUtil aaiUtil = new AaiUtil(myproc)
- def ns = aaiUtil.getNamespaceFromUri('/aai/v6/search/generic-query')
- assertEquals('http://org.openecomp.aai.inventory/v6', ns)
- }
-
-}
+/*- \r
+ * ============LICENSE_START======================================================= \r
+ * OPENECOMP - MSO \r
+ * ================================================================================ \r
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. \r
+ * ================================================================================ \r
+ * Licensed under the Apache License, Version 2.0 (the "License"); \r
+ * you may not use this file except in compliance with the License. \r
+ * You may obtain a copy of the License at \r
+ * \r
+ * http://www.apache.org/licenses/LICENSE-2.0 \r
+ * \r
+ * Unless required by applicable law or agreed to in writing, software \r
+ * distributed under the License is distributed on an "AS IS" BASIS, \r
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. \r
+ * See the License for the specific language governing permissions and \r
+ * limitations under the License. \r
+ * ============LICENSE_END========================================================= \r
+ */ \r
+\r
+package org.openecomp.mso.bpmn.common.scripts;\r
+\r
+import static org.junit.Assert.*;\r
+import static org.mockito.Mockito.*\r
+\r
+import org.openecomp.mso.rest.HttpHeader\r
+import org.mockito.MockitoAnnotations\r
+import org.mockito.runners.MockitoJUnitRunner\r
+import org.mockito.internal.debugging.MockitoDebuggerImpl\r
+import org.junit.Before\r
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil;\r
+import org.junit.Rule;\r
+import org.junit.Test\r
+import org.junit.Ignore\r
+import org.junit.runner.RunWith\r
+import org.junit.Before;\r
+import org.junit.Test;\r
+import org.camunda.bpm.engine.ProcessEngineServices\r
+import org.camunda.bpm.engine.RepositoryService\r
+import org.camunda.bpm.engine.impl.persistence.entity.ExecutionEntity\r
+import org.camunda.bpm.engine.impl.pvm.process.ProcessDefinitionImpl\r
+import org.camunda.bpm.engine.repository.ProcessDefinition\r
+\r
+@RunWith(MockitoJUnitRunner.class)\r
+class AaiUtilTest extends MsoGroovyTest {\r
+ \r
+ @Test\r
+ public void testGetVersionDefault() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def version = aaiUtil.getVersion(mockExecution, 'l3-network', 'CreateAAIVfModule')\r
+ assertEquals('8', version)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetVersionResourceSpecific() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_l3_network_version")).thenReturn('7')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def version = aaiUtil.getVersion(mockExecution, 'l3-network', 'CreateAAIVfModule')\r
+ assertEquals('7', version)\r
+ }\r
+\r
+ @Test\r
+ public void testGetVersionFlowSpecific() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_custom_CreateAAIVfModule_aai_version")).thenReturn('6')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_l3_network_version")).thenReturn('7')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def version = aaiUtil.getVersion(mockExecution, 'l3-network', 'CreateAAIVfModule')\r
+ assertEquals('6', version)\r
+ }\r
+\r
+ @Test(expected=java.lang.Exception.class)\r
+ public void testGetVersionNotDefined() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def version = aaiUtil.getVersion(mockExecution, 'l3-network', 'CreateAAIVfModule')\r
+ }\r
+ \r
+ @Test\r
+ public void testGetUriDefaultVersion() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn('/aai/v8/network/l3-networks/l3-network')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getUri(mockExecution, 'l3-network')\r
+ assertEquals('/aai/v8/network/l3-networks/l3-network', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetUriFlowAndResourceSpecific() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_CreateAAIVfModule_aai_l3_network_uri")).thenReturn('/aai/v6/network/l3-networks/l3-network')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn('/aai/v8/network/l3-networks/l3-network')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getUri(mockExecution, 'l3-network')\r
+ assertEquals('/aai/v6/network/l3-networks/l3-network', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNetworkGenericVnfEndpoint() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_generic_vnf_uri")).thenReturn('/aai/v8/network/generic-vnfs/generic-vnf')\r
+ when(mockExecution.getVariable('URN_aai_endpoint')).thenReturn('http://localhost:28090')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def endpoint = aaiUtil.getNetworkGenericVnfEndpoint(mockExecution)\r
+ assertEquals('http://localhost:28090/aai/v8/network/generic-vnfs/generic-vnf', endpoint)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNetworkGenericVnfUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_generic_vnf_uri")).thenReturn('/aai/v8/network/generic-vnfs/generic-vnf')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkGenericVnfUri(mockExecution)\r
+ assertEquals('/aai/v8/network/generic-vnfs/generic-vnf', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNetworkVpnBindingUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_vpn_binding_uri")).thenReturn('/aai/v8/network/vpn-bindings/vpn-binding')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkVpnBindingUri(mockExecution)\r
+ assertEquals('/aai/v8/network/vpn-bindings/vpn-binding', uri)\r
+ }\r
+\r
+ @Test\r
+ public void testGetNetworkPolicyUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_network_policy_uri")).thenReturn('/aai/v8/network/network-policies/network-policy')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkPolicyUri(mockExecution)\r
+ assertEquals('/aai/v8/network/network-policies/network-policy', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNetworkTableReferencesUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_route_table_reference_uri")).thenReturn('/aai/v8/network/route-table-references/route-table-reference')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkTableReferencesUri(mockExecution)\r
+ assertEquals('/aai/v8/network/route-table-references/route-table-reference', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNetworkVceUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_vce_uri")).thenReturn('/aai/v8/network/vces/vce')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkVceUri(mockExecution)\r
+ assertEquals('/aai/v8/network/vces/vce', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNetworkL3NetworkUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn('/aai/v8/network/l3-networks/l3-network')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkL3NetworkUri(mockExecution)\r
+ assertEquals('/aai/v8/network/l3-networks/l3-network', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetBusinessCustomerUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_customer_uri")).thenReturn('/aai/v8/business/customers/customer')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getBusinessCustomerUri(mockExecution)\r
+ assertEquals('/aai/v8/business/customers/customer', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetCloudInfrastructureCloudRegionEndpoint() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_cloud_region_uri")).thenReturn('/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic')\r
+ when(mockExecution.getVariable('URN_aai_endpoint')).thenReturn('http://localhost:28090')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getCloudInfrastructureCloudRegionEndpoint(mockExecution)\r
+ assertEquals('http://localhost:28090/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetCloudInfrastructureCloudRegionUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_cloud_region_uri")).thenReturn('/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getCloudInfrastructureCloudRegionUri(mockExecution)\r
+ assertEquals('/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetCloudInfrastructureTenantUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_tenant_uri")).thenReturn('/aai/v8/cloud-infrastructure/tenants/tenant')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getCloudInfrastructureTenantUri(mockExecution)\r
+ assertEquals('/aai/v8/cloud-infrastructure/tenants/tenant', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetSearchNodesQueryUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_nodes_query_uri")).thenReturn('/aai/v8/search/nodes-query')\r
+ when(mockExecution.getVariable('URN_aai_endpoint')).thenReturn('http://localhost:28090')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getSearchNodesQueryUri(mockExecution)\r
+ assertEquals('/aai/v8/search/nodes-query', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetSearchNodesQueryEndpoint() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_nodes_query_uri")).thenReturn('/aai/v8/search/nodes-query')\r
+ when(mockExecution.getVariable('URN_aai_endpoint')).thenReturn('http://localhost:28090')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getSearchNodesQueryEndpoint(mockExecution)\r
+ assertEquals('http://localhost:28090/aai/v8/search/nodes-query', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetSearchGenericQueryUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('8')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_generic_query_uri")).thenReturn('/aai/v8/search/generic-query')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ \r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getSearchGenericQueryUri(mockExecution)\r
+ assertEquals('/aai/v8/search/generic-query', uri)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNamespaceFromUri() {\r
+ ExecutionEntity mockExecution = setupMock('CreateAAIVfModule')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('6')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v6_l3_network_uri")).thenReturn('/aai/v6/network/l3-networks/l3-network')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkL3NetworkUri(mockExecution) // Required to populate the namespace in the class\r
+ def ns = aaiUtil.getNamespaceFromUri('/aai/v6/search/generic-query')\r
+ assertEquals('http://org.openecomp.aai.inventory/v6', ns)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNamespaceFromUri2() {\r
+ ExecutionEntity mockExecution = setupMock('DeleteVfModuleVolumeInfraV1')\r
+ //\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('10')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v10_l3_network_uri")).thenReturn('/aai/v10/network/l3-networks/l3-network')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ //\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkL3NetworkUri(mockExecution) // Required to populate the namespace in the class\r
+ def ns = aaiUtil.getNamespaceFromUri('/aai/v10/search/generic-query')\r
+ assertEquals('http://org.openecomp.aai.inventory/v10', ns)\r
+ }\r
+ \r
+ @Test\r
+ public void testGetNamespaceFromUri3() {\r
+ ExecutionEntity mockExecution = setupMock('DeleteVfModuleVolumeInfraV1')\r
+ //\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('100')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v100_l3_network_uri")).thenReturn('/aai/v100/network/l3-networks/l3-network')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ //\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def uri = aaiUtil.getNetworkL3NetworkUri(mockExecution) // Required to populate the namespace in the class\r
+ def ns = aaiUtil.getNamespaceFromUri('/aai/v100/search/generic-query')\r
+ assertEquals('http://org.openecomp.aai.inventory/v100', ns)\r
+ }\r
+\r
+ @Test\r
+ public void testGetNamespaceFromUri_twoArguments() { // (execution, uri)\r
+ ExecutionEntity mockExecution = setupMock('DeleteVfModuleVolumeInfraV1')\r
+ //\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn('10')\r
+ when(mockExecution.getVariable("URN_mso_workflow_default_aai_v10_l3_network_uri")).thenReturn('/aai/v10/network/l3-networks/l3-network')\r
+ when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_namespace")).thenReturn('http://org.openecomp.aai.inventory/')\r
+ //\r
+ when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn('true')\r
+ CreateAAIVfModule myproc = new CreateAAIVfModule()\r
+ AaiUtil aaiUtil = new AaiUtil(myproc)\r
+ def ns = aaiUtil.getNamespaceFromUri(mockExecution,'/aai/v10/search/generic-query')\r
+ assertEquals('http://org.openecomp.aai.inventory/v10', ns)\r
+ }\r
+}\r
-/*-
- * ============LICENSE_START=======================================================
- * OPENECOMP - MSO
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-
-package org.openecomp.mso.bpmn.common;
-
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfByIdWithPriority;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetVfModuleId;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutVfModuleIdNoResponse;
-
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.UUID;
-
-import org.camunda.bpm.engine.test.Deployment;
-import org.junit.Assert;
-import org.junit.Test;
-import org.openecomp.mso.bpmn.mock.FileUtil;
-
-/**
- * Unit tests for CreateAAIVfModuleVolumeGroup.bpmn.
- */
-public class CreateAAIVfModuleVolumeGroupTest extends WorkflowTest {
-
- /**
- * Test the happy path through the flow.
- */
- @Test
- @Deployment(resources = {
- "subprocess/CreateAAIVfModuleVolumeGroup.bpmn"
- })
- public void happyPath() throws IOException {
-
- logStart();
-
- String updateAAIVfModuleRequest = FileUtil.readResourceFile("__files/VfModularity/CreateAAIVfModuleVolumeGroupRequest.xml");
- MockGetGenericVnfByIdWithPriority("skask", "lukewarm", 200, "VfModularity/VfModule-lukewarm.xml", 2);
- MockPutVfModuleIdNoResponse("skask", "PCRF", "lukewarm");
-
- String businessKey = UUID.randomUUID().toString();
- Map<String, Object> variables = new HashMap<String, Object>();
- variables.put("mso-request-id", "999-99-9999");
- variables.put("isDebugLogEnabled","true");
- variables.put("CreateAAIVfModuleVolumeGroupRequest", updateAAIVfModuleRequest);
- invokeSubProcess("CreateAAIVfModuleVolumeGroup", businessKey, variables);
-
- Assert.assertTrue(isProcessEnded(businessKey));
- String response = (String) getVariableFromHistory(businessKey, "CAAIVfModVG_updateVfModuleResponse");
- Integer responseCode = (Integer) getVariableFromHistory(businessKey, "CAAIVfModVG_updateVfModuleResponseCode");
- System.out.println("Subflow response code: " + responseCode);
- System.out.println("Subflow response: " + response);
- Assert.assertEquals(200, responseCode.intValue());
-
- logEnd();
- }
-
- /**
- * Test the case where the GET to AAI returns a 404.
- */
- @Test
- @Deployment(resources = {
- "subprocess/CreateAAIVfModuleVolumeGroup.bpmn"
- })
- public void badGet() throws IOException {
-
- logStart();
-
- String updateAAIVfModuleRequest = FileUtil.readResourceFile("__files/VfModularity/CreateAAIVfModuleVolumeGroupRequest.xml");
- MockGetVfModuleId("skask", ".*", "VfModularity/VfModule-supercool.xml", 404);
-
- String businessKey = UUID.randomUUID().toString();
- Map<String, Object> variables = new HashMap<String, Object>();
- variables.put("mso-request-id", "999-99-9999");
- variables.put("isDebugLogEnabled","true");
- variables.put("CreateAAIVfModuleVolumeGroupRequest", updateAAIVfModuleRequest);
- invokeSubProcess("CreateAAIVfModuleVolumeGroup", businessKey, variables);
-
- Assert.assertTrue(isProcessEnded(businessKey));
- String response = (String) getVariableFromHistory(businessKey, "CAAIVfModVG_getVfModuleResponse");
- Integer responseCode = (Integer) getVariableFromHistory(businessKey, "CAAIVfModVG_getVfModuleResponseCode");
- System.out.println("Subflow response code: " + responseCode);
- System.out.println("Subflow response: " + response);
- Assert.assertEquals(404, responseCode.intValue());
-
- logEnd();
- }
-
- /**
- * Test the case where the GET to AAI is successful, but he subsequent PUT returns 404.
- */
- @Test
- @Deployment(resources = {
- "subprocess/CreateAAIVfModuleVolumeGroup.bpmn"
- })
- public void badPut() throws IOException {
-
- logStart();
-
- String updateAAIVfModuleRequest = FileUtil.readResourceFile("__files/VfModularity/CreateAAIVfModuleVolumeGroupRequest.xml");
- MockGetVfModuleId("skask", "lukewarm", "VfModularity/VfModule-lukewarm.xml", 200);
-
- String businessKey = UUID.randomUUID().toString();
- Map<String, Object> variables = new HashMap<String, Object>();
- variables.put("mso-request-id", "999-99-9999");
- variables.put("isDebugLogEnabled","true");
- variables.put("CreateAAIVfModuleVolumeGroupRequest", updateAAIVfModuleRequest);
- invokeSubProcess("CreateAAIVfModuleVolumeGroup", businessKey, variables);
-
- Assert.assertTrue(isProcessEnded(businessKey));
- String response = (String) getVariableFromHistory(businessKey, "CAAIVfModVG_updateVfModuleResponse");
- Integer responseCode = (Integer) getVariableFromHistory(businessKey, "CAAIVfModVG_updateVfModuleResponseCode");
- System.out.println("Subflow response code: " + responseCode);
- System.out.println("Subflow response: " + response);
- Assert.assertEquals(404, responseCode.intValue());
-
- logEnd();
- }
-}
-
+/*- \r
+ * ============LICENSE_START======================================================= \r
+ * OPENECOMP - MSO \r
+ * ================================================================================ \r
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. \r
+ * ================================================================================ \r
+ * Licensed under the Apache License, Version 2.0 (the "License"); \r
+ * you may not use this file except in compliance with the License. \r
+ * You may obtain a copy of the License at \r
+ * \r
+ * http://www.apache.org/licenses/LICENSE-2.0 \r
+ * \r
+ * Unless required by applicable law or agreed to in writing, software \r
+ * distributed under the License is distributed on an "AS IS" BASIS, \r
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. \r
+ * See the License for the specific language governing permissions and \r
+ * limitations under the License. \r
+ * ============LICENSE_END========================================================= \r
+ */ \r
+\r
+package org.openecomp.mso.bpmn.common;\r
+\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfByIdWithPriority;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetVfModuleId;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutVfModuleIdNoResponse;\r
+\r
+import java.io.IOException;\r
+import java.util.HashMap;\r
+import java.util.Map;\r
+import java.util.UUID;\r
+\r
+import org.camunda.bpm.engine.test.Deployment;\r
+import org.junit.Assert;\r
+import org.junit.Test;\r
+import org.openecomp.mso.bpmn.mock.FileUtil;\r
+\r
+/**\r
+ * Unit tests for CreateAAIVfModuleVolumeGroup.bpmn.\r
+ */\r
+public class CreateAAIVfModuleVolumeGroupTest extends WorkflowTest {\r
+ \r
+ /**\r
+ * Test the happy path through the flow.\r
+ */\r
+ @Test \r
+ @Deployment(resources = {\r
+ "subprocess/CreateAAIVfModuleVolumeGroup.bpmn"\r
+ })\r
+ public void happyPath() throws IOException {\r
+ \r
+ logStart();\r
+ \r
+ String updateAAIVfModuleRequest = FileUtil.readResourceFile("__files/VfModularity/CreateAAIVfModuleVolumeGroupRequest.xml"); \r
+ MockGetGenericVnfByIdWithPriority("skask", "lukewarm", 200, "VfModularity/VfModule-lukewarm.xml", 2);\r
+ MockPutVfModuleIdNoResponse("skask", "PCRF", "lukewarm");\r
+ \r
+ String businessKey = UUID.randomUUID().toString();\r
+ Map<String, Object> variables = new HashMap<String, Object>();\r
+ variables.put("mso-request-id", "999-99-9999");\r
+ variables.put("isDebugLogEnabled","true");\r
+ variables.put("CreateAAIVfModuleVolumeGroupRequest", updateAAIVfModuleRequest);\r
+ invokeSubProcess("CreateAAIVfModuleVolumeGroup", businessKey, variables);\r
+ \r
+ Assert.assertTrue(isProcessEnded(businessKey));\r
+ String response = (String) getVariableFromHistory(businessKey, "CAAIVfModVG_updateVfModuleResponse");\r
+ Integer responseCode = (Integer) getVariableFromHistory(businessKey, "CAAIVfModVG_updateVfModuleResponseCode");\r
+ System.out.println("Subflow response code: " + responseCode);\r
+ System.out.println("Subflow response: " + response);\r
+ Assert.assertEquals(200, responseCode.intValue());\r
+ \r
+ logEnd();\r
+ }\r
+\r
+ /**\r
+ * Test the case where the GET to AAI returns a 404.\r
+ */\r
+ @Test \r
+ @Deployment(resources = {\r
+ "subprocess/CreateAAIVfModuleVolumeGroup.bpmn"\r
+ })\r
+ public void badGet() throws IOException {\r
+ \r
+ logStart();\r
+ \r
+ String updateAAIVfModuleRequest = FileUtil.readResourceFile("__files/VfModularity/CreateAAIVfModuleVolumeGroupRequest.xml"); \r
+ MockGetVfModuleId("skask", ".*", "VfModularity/VfModule-supercool.xml", 404);\r
+ \r
+ String businessKey = UUID.randomUUID().toString();\r
+ Map<String, Object> variables = new HashMap<String, Object>();\r
+ variables.put("mso-request-id", "999-99-9999");\r
+ variables.put("isDebugLogEnabled","true");\r
+ variables.put("CreateAAIVfModuleVolumeGroupRequest", updateAAIVfModuleRequest);\r
+ invokeSubProcess("CreateAAIVfModuleVolumeGroup", businessKey, variables);\r
+ \r
+ Assert.assertTrue(isProcessEnded(businessKey));\r
+ String response = (String) getVariableFromHistory(businessKey, "CAAIVfModVG_getVfModuleResponse");\r
+ Integer responseCode = (Integer) getVariableFromHistory(businessKey, "CAAIVfModVG_getVfModuleResponseCode");\r
+ System.out.println("Subflow response code: " + responseCode);\r
+ System.out.println("Subflow response: " + response);\r
+ Assert.assertEquals(404, responseCode.intValue());\r
+ \r
+ logEnd();\r
+ }\r
+\r
+ /**\r
+ * Test the case where the GET to AAI is successful, but he subsequent PUT returns 404.\r
+ */\r
+ @Test \r
+ @Deployment(resources = {\r
+ "subprocess/CreateAAIVfModuleVolumeGroup.bpmn"\r
+ })\r
+ public void badPatch() throws IOException {\r
+ \r
+ logStart();\r
+ \r
+ String updateAAIVfModuleRequest = FileUtil.readResourceFile("__files/VfModularity/CreateAAIVfModuleVolumeGroupRequest.xml"); \r
+ MockGetVfModuleId("skask", "lukewarm", "VfModularity/VfModule-lukewarm.xml", 200);\r
+\r
+ String businessKey = UUID.randomUUID().toString();\r
+ Map<String, Object> variables = new HashMap<String, Object>();\r
+ variables.put("mso-request-id", "999-99-9999");\r
+ variables.put("isDebugLogEnabled","true");\r
+ variables.put("CreateAAIVfModuleVolumeGroupRequest", updateAAIVfModuleRequest);\r
+ invokeSubProcess("CreateAAIVfModuleVolumeGroup", businessKey, variables);\r
+ \r
+ Assert.assertTrue(isProcessEnded(businessKey));\r
+ String response = (String) getVariableFromHistory(businessKey, "CAAIVfModVG_updateVfModuleResponse");\r
+ Integer responseCode = (Integer) getVariableFromHistory(businessKey, "CAAIVfModVG_updateVfModuleResponseCode");\r
+ System.out.println("Subflow response code: " + responseCode);\r
+ System.out.println("Subflow response: " + response);\r
+ Assert.assertEquals(404, responseCode.intValue());\r
+ \r
+ logEnd();\r
+ }\r
+}\r
+\r
-/*
- * © 2014 AT&T Intellectual Property. All rights reserved. Used under license from AT&T Intellectual Property.
- */
-/*-
- * ============LICENSE_START=======================================================
- * OPENECOMP - MSO
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-
-package org.openecomp.mso.bpmn.common;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.openecomp.mso.bpmn.common.BPMNUtil.executeWorkFlow;
-import static org.openecomp.mso.bpmn.common.BPMNUtil.waitForWorkflowToFinish;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetServiceInstance;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetServiceInstance_404;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetServiceInstance_500;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetServiceSubscription;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceById;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceById_404;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceById_500;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceByName;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceByName_404;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceByName_500;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.camunda.bpm.engine.test.Deployment;
-import org.junit.Test;
-import org.openecomp.mso.bpmn.common.workflow.service.WorkflowResponse;
-
-
-/**
- * Unit Test for the GenericGetService Sub Flow
- */
-public class GenericGetServiceTest extends WorkflowTest {
-
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstance() throws Exception{
- MockGetServiceInstance("SDN-ETHERNET-INTERNET", "123456789", "MIS%252F1604%252F0026%252FSW_INTERNET", "GenericFlows/getServiceInstance.xml");
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, "SDN-ETHERNET-INTERNET", "123456789");
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- assertEquals("true", successIndicator);
- assertEquals("true", found);
- assertEquals("false", obtainUrl);
- assertEquals("false", byName);
- assertNotNull(response);
- assertEquals(null, workflowException);
- }
-
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceSubscription() throws Exception{
-
- MockGetServiceSubscription("1604-MVM-26", "SDN-ETHERNET-INTERNET", "GenericFlows/getServiceSubscription.xml");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesSubscription(variables, "", null , "1604-MVM-26", "SDN-ETHERNET-INTERNET");
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
-
- assertEquals("true", successIndicator);
- assertEquals("true", found);
- assertEquals("false", obtainUrl);
- assertEquals("false", byName);
- assertNotNull(response);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstance_byName() throws Exception{
-
- MockNodeQueryServiceInstanceByName("1604-MVM-26", "GenericFlows/getSIUrlByName.xml");
- MockGetServiceInstance("SDN-ETHERNET-INTERNET", "123456789", "MIS%252F1604%252F0026%252FSW_INTERNET", "GenericFlows/getServiceInstance.xml");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, null, "1604-MVM-26", null, null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");
-
- assertEquals("true", successIndicator);
- assertEquals("true", found);
- assertEquals("true", obtainUrl);
- assertEquals("true", byName);
- assertNotNull(response);
- assertEquals("200", siUrlResponseCode);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstance_byId() throws Exception{
-
- MockNodeQueryServiceInstanceById("MIS%2F1604%2F0026%2FSW_INTERNET", "GenericFlows/getSIUrlById.xml");
- MockGetServiceInstance("SDN-ETHERNET-INTERNET", "123456789", "MIS%252F1604%252F0026%252FSW_INTERNET", "GenericFlows/getServiceInstance.xml");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, null, null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");
-
- assertEquals("true", successIndicator);
- assertEquals("true", found);
- assertEquals("true", obtainUrl);
- assertEquals("false", byName);
- assertNotNull(response);
- assertEquals("200", siUrlResponseCode);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstance_404Response() throws Exception{
-
- MockGetServiceInstance_404("SDN-ETHERNET-INTERNET", "123456789", "MIS%2F1604%2F0026%2FSW_INTERNET");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, "SDN-ETHERNET-INTERNET", "123456789");
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
-
- assertEquals("true", successIndicator);
- assertEquals("false", found);
- assertEquals("false", obtainUrl);
- assertEquals("false", byName);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceSubscription404() throws Exception{
- MockGetServiceSubscription("1604-MVM-26", "SDN-ETHERNET-INTERNET", 404);
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesSubscription(variables, "", "", "SDN-ETHERNET-INTERNET", "1604-MVM-26");
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
-
- assertEquals("true", successIndicator);
- assertEquals("false", found);
- assertEquals("false", obtainUrl);
- assertEquals("false", byName);
- assertNotNull(response);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstanceByName404() throws Exception{
-
- MockNodeQueryServiceInstanceByName_404("1604-MVM-26");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "", "1604-MVM-26", null, null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");
-
- assertEquals("true", successIndicator);
- assertEquals("false", found);
- assertEquals("true", obtainUrl);
- assertEquals("true", byName);
- assertEquals("404", siUrlResponseCode);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstanceById404() throws Exception{
-
- MockNodeQueryServiceInstanceById_404("MIS%2F1604%2F0026%2FSW_INTERNET");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, null, null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");
-
- assertEquals("true", successIndicator);
- assertEquals("false", found);
- assertEquals("true", obtainUrl);
- assertEquals("false", byName);
- assertEquals("404", siUrlResponseCode);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstanceEmptyResponse() throws Exception{
-
- MockGetServiceInstance("1604-MVM-26", "SDN-ETHERNET-INTERNET", "MIS%252F1604%252F0026%252FSW_INTERNET", " ");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, "SDN-ETHERNET-INTERNET", "123456789");
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
-
- assertEquals("true", successIndicator);
- assertEquals("false", found);
- assertEquals("false", obtainUrl);
- assertEquals("false", byName);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstanceByNameEmpty() throws Exception{
- MockNodeQueryServiceInstanceByName("1604-MVM-26", "");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "", "1604-MVM-26", null, null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");
-
- assertEquals("true", successIndicator);
- assertEquals("false", found);
- assertEquals("true", obtainUrl);
- assertEquals("true", byName);
- assertEquals("200", siUrlResponseCode);
- assertEquals(null, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceInstanceByIdEmpty() throws Exception{
-
- MockNodeQueryServiceInstanceById("MIS[%]2F1604[%]2F0026[%]2FSW_INTERNET", "");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, null, null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");
-
- assertEquals("true", successIndicator);
- assertEquals("false", found);
- assertEquals("true", obtainUrl);
- assertEquals("false", byName);
- assertEquals("200", siUrlResponseCode);
- assertEquals(null, workflowException);
- }
-
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_error_serviceInstanceInvalidVariables() throws Exception{
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, null, null, "SDN-ETHERNET-INTERNET", null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
-
- String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Incoming serviceInstanceId and serviceInstanceName are null. ServiceInstanceId or ServiceInstanceName is required to Get a service-instance.]";
-
- assertEquals("false", successIndicator);
- assertEquals("false", found);
- assertEquals("false", obtainUrl);
- assertEquals("false", byName);
- assertEquals(expectedWorkflowException, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_success_serviceSubscriptionInvalidVariables() throws Exception{
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesSubscription(variables, "", "", "SDN-ETHERNET-INTERNET", null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
-
- String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Incoming ServiceType or GlobalCustomerId is null. These variables are required to Get a service-subscription.]";
-
-
- assertEquals("false", successIndicator);
- assertEquals("false", found);
- assertEquals("false", obtainUrl);
- assertEquals("false", byName);
- assertEquals(expectedWorkflowException, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_error_serviceInstance_getSIBadResponse() throws Exception{
-
- MockGetServiceInstance_500("SDN-ETHERNET-INTERNET", "123456789", "MIS%252F1604%252F0026%252FSW_INTERNET");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", "1604-MVM-26", "SDN-ETHERNET-INTERNET", "123456789");
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
-
- String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Received a bad response from AAI]";
-
- assertEquals("false", successIndicator);
- assertEquals("false", found);
- assertEquals("false", obtainUrl);
- assertEquals("false", byName);
- assertEquals(expectedWorkflowException, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_error_serviceInstance_getUrlByIdBadResponse() throws Exception{
-
- MockNodeQueryServiceInstanceById_500("MIS%2F1604%2F0026%2FSW_INTERNET");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, null, null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");
-
- String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Received a bad response from AAI]";
-
- assertEquals("false", successIndicator);
- assertEquals("false", found);
- assertEquals("true", obtainUrl);
- assertEquals("false", byName);
- assertEquals("500", siUrlResponseCode);
- assertEquals(expectedWorkflowException, workflowException);
- }
-
- @Test
- @Deployment(resources = {"subprocess/GenericGetService.bpmn"})
- public void testGenericGetService_error_serviceInstance_getUrlByNameBadResponse() throws Exception{
-
- MockNodeQueryServiceInstanceByName_500("1604-MVM-26");
-
- Map<String, String> variables = new HashMap<String, String>();
- setVariablesInstance(variables, null, "1604-MVM-26", null, null);
-
- WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");
- String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");
- String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");
- String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrl");
- String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");
- String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");
-
- String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Received a bad response from AAI]";
-
- assertEquals("false", successIndicator);
- assertEquals("false", found);
- assertEquals("true", obtainUrl);
- assertEquals("true", byName);
- assertEquals("500", siUrlResponseCode);
- assertEquals(expectedWorkflowException, workflowException);
- }
-
-
- private void setVariablesInstance(Map<String, String> variables, String siId, String siName, String globalCustId, String serviceType) {
- variables.put("isDebugLogEnabled", "true");
- variables.put("GENGS_serviceInstanceId", siId);
- variables.put("GENGS_serviceInstanceName", siName);
- variables.put("GENGS_globalCustomerId",globalCustId);
- variables.put("GENGS_serviceType", serviceType);
- variables.put("GENGS_type", "service-instance");
- }
-
- private void setVariablesSubscription(Map<String, String> variables, String siId, String siName, String globalCustId, String serviceType) {
- variables.put("isDebugLogEnabled", "true");
- variables.put("GENGS_serviceInstanceId", siId);
- variables.put("GENGS_serviceInstanceName", siName);
- variables.put("GENGS_globalCustomerId",globalCustId);
- variables.put("GENGS_serviceType", serviceType);
- variables.put("GENGS_type", "service-subscription");
- }
-
-
-}
+/*\r
+ * © 2014 AT&T Intellectual Property. All rights reserved. Used under license from AT&T Intellectual Property.\r
+ */\r
+/*- \r
+ * ============LICENSE_START======================================================= \r
+ * OPENECOMP - MSO \r
+ * ================================================================================ \r
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. \r
+ * ================================================================================ \r
+ * Licensed under the Apache License, Version 2.0 (the "License"); \r
+ * you may not use this file except in compliance with the License. \r
+ * You may obtain a copy of the License at \r
+ * \r
+ * http://www.apache.org/licenses/LICENSE-2.0 \r
+ * \r
+ * Unless required by applicable law or agreed to in writing, software \r
+ * distributed under the License is distributed on an "AS IS" BASIS, \r
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. \r
+ * See the License for the specific language governing permissions and \r
+ * limitations under the License. \r
+ * ============LICENSE_END========================================================= \r
+ */ \r
+\r
+package org.openecomp.mso.bpmn.common;\r
+\r
+import static org.junit.Assert.assertEquals;\r
+import static org.junit.Assert.assertNotNull;\r
+import static org.openecomp.mso.bpmn.common.BPMNUtil.executeWorkFlow;\r
+import static org.openecomp.mso.bpmn.common.BPMNUtil.waitForWorkflowToFinish;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetServiceInstance;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetServiceInstance_404;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetServiceInstance_500;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetServiceSubscription;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceById;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceById_404;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceById_500;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceByName;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceByName_404;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceByName_500;\r
+\r
+import java.util.HashMap;\r
+import java.util.Map;\r
+\r
+import org.camunda.bpm.engine.test.Deployment;\r
+import org.junit.Test;\r
+import org.openecomp.mso.bpmn.common.workflow.service.WorkflowResponse;\r
+\r
+\r
+/**\r
+ * Unit Test for the GenericGetService Sub Flow\r
+ */\r
+public class GenericGetServiceTest extends WorkflowTest {\r
+\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstance() throws Exception{\r
+ MockGetServiceInstance("SDN-ETHERNET-INTERNET", "123456789", "MIS%252F1604%252F0026%252FSW_INTERNET", "GenericFlows/getServiceInstance.xml");\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, "SDN-ETHERNET-INTERNET", "123456789");\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("true", found);\r
+ assertEquals("false", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertNotNull(response);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceSubscription() throws Exception{\r
+\r
+ MockGetServiceSubscription("1604-MVM-26", "SDN-ETHERNET-INTERNET", "GenericFlows/getServiceSubscription.xml");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesSubscription(variables, "", null , "1604-MVM-26", "SDN-ETHERNET-INTERNET");\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("true", found);\r
+ assertEquals("false", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertNotNull(response);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstance_byName() throws Exception{\r
+\r
+ MockNodeQueryServiceInstanceByName("1604-MVM-26", "GenericFlows/getSIUrlByName.xml");\r
+ MockGetServiceInstance("SDN-ETHERNET-INTERNET", "123456789", "MIS%252F1604%252F0026%252FSW_INTERNET", "GenericFlows/getServiceInstance.xml");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, null, "1604-MVM-26", null, null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("true", found);\r
+ assertEquals("true", obtainUrl);\r
+ assertEquals("true", byName);\r
+ assertNotNull(response);\r
+ assertEquals("200", siUrlResponseCode);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstance_byId() throws Exception{\r
+\r
+ MockNodeQueryServiceInstanceById("MIS%2F1604%2F0026%2FSW_INTERNET", "GenericFlows/getSIUrlById.xml");\r
+ MockGetServiceInstance("SDN-ETHERNET-INTERNET", "123456789", "MIS%252F1604%252F0026%252FSW_INTERNET", "GenericFlows/getServiceInstance.xml");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, null, null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_genericQueryResponseCode");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("true", found);\r
+ assertEquals("true", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertNotNull(response);\r
+ assertEquals("200", siUrlResponseCode);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstance_404Response() throws Exception{\r
+\r
+ MockGetServiceInstance_404("SDN-ETHERNET-INTERNET", "123456789", "MIS%2F1604%2F0026%2FSW_INTERNET");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, "SDN-ETHERNET-INTERNET", "123456789");\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("false", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceSubscription404() throws Exception{\r
+ MockGetServiceSubscription("1604-MVM-26", "SDN-ETHERNET-INTERNET", 404);\r
+ \r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesSubscription(variables, "", "", "SDN-ETHERNET-INTERNET", "1604-MVM-26");\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String response = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowResponse");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("false", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertNotNull(response);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstanceByName404() throws Exception{\r
+\r
+ MockNodeQueryServiceInstanceByName_404("1604-MVM-26");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "", "1604-MVM-26", null, null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("true", obtainUrl);\r
+ assertEquals("true", byName);\r
+ assertEquals("404", siUrlResponseCode);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstanceById404() throws Exception{\r
+\r
+ MockNodeQueryServiceInstanceById_404("MIS%2F1604%2F0026%2FSW_INTERNET");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, null, null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_genericQueryResponseCode");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("true", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertEquals("404", siUrlResponseCode);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstanceEmptyResponse() throws Exception{\r
+\r
+ MockGetServiceInstance("1604-MVM-26", "SDN-ETHERNET-INTERNET", "MIS%252F1604%252F0026%252FSW_INTERNET", " ");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, "SDN-ETHERNET-INTERNET", "123456789");\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("false", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstanceByNameEmpty() throws Exception{\r
+ MockNodeQueryServiceInstanceByName("1604-MVM-26", "");\r
+ \r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "", "1604-MVM-26", null, null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("true", obtainUrl);\r
+ assertEquals("true", byName);\r
+ assertEquals("200", siUrlResponseCode);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceInstanceByIdEmpty() throws Exception{\r
+\r
+ MockNodeQueryServiceInstanceById("MIS[%]2F1604[%]2F0026[%]2FSW_INTERNET", "");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, null, null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_genericQueryResponseCode");\r
+\r
+ assertEquals("true", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("true", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertEquals("200", siUrlResponseCode);\r
+ assertEquals(null, workflowException);\r
+ }\r
+\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_error_serviceInstanceInvalidVariables() throws Exception{\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, null, null, "SDN-ETHERNET-INTERNET", null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+\r
+ String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Incoming serviceInstanceId and serviceInstanceName are null. ServiceInstanceId or ServiceInstanceName is required to Get a service-instance.]";\r
+\r
+ assertEquals("false", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("false", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertEquals(expectedWorkflowException, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_success_serviceSubscriptionInvalidVariables() throws Exception{\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesSubscription(variables, "", "", "SDN-ETHERNET-INTERNET", null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+\r
+ String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Incoming ServiceType or GlobalCustomerId is null. These variables are required to Get a service-subscription.]";\r
+\r
+\r
+ assertEquals("false", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("false", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertEquals(expectedWorkflowException, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_error_serviceInstance_getSIBadResponse() throws Exception{\r
+\r
+ MockGetServiceInstance_500("SDN-ETHERNET-INTERNET", "123456789", "MIS%252F1604%252F0026%252FSW_INTERNET");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", "1604-MVM-26", "SDN-ETHERNET-INTERNET", "123456789");\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+\r
+ String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Received a bad response from AAI]";\r
+\r
+ assertEquals("false", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("false", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertEquals(expectedWorkflowException, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_error_serviceInstance_getUrlByIdBadResponse() throws Exception{\r
+\r
+ MockNodeQueryServiceInstanceById_500("MIS%2F1604%2F0026%2FSW_INTERNET");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, "MIS%2F1604%2F0026%2FSW_INTERNET", null, null, null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_genericQueryResponseCode");\r
+\r
+ String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Received a bad response from AAI]";\r
+\r
+ assertEquals("false", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("true", obtainUrl);\r
+ assertEquals("false", byName);\r
+ assertEquals("500", siUrlResponseCode);\r
+ assertEquals(expectedWorkflowException, workflowException);\r
+ }\r
+\r
+ @Test\r
+ @Deployment(resources = {"subprocess/GenericGetService.bpmn"})\r
+ public void testGenericGetService_error_serviceInstance_getUrlByNameBadResponse() throws Exception{\r
+\r
+ MockNodeQueryServiceInstanceByName_500("1604-MVM-26");\r
+\r
+ Map<String, String> variables = new HashMap<String, String>();\r
+ setVariablesInstance(variables, null, "1604-MVM-26", null, null);\r
+\r
+ WorkflowResponse workflowResponse = executeWorkFlow(processEngineRule, "GenericGetService", variables);\r
+ waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());\r
+\r
+ String successIndicator = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_SuccessIndicator");\r
+ String found = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_FoundIndicator");\r
+ String workflowException = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "WorkflowException");\r
+ String obtainUrl = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainObjectsUrl");\r
+ String byName = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainServiceInstanceUrlByName");\r
+ String siUrlResponseCode = BPMNUtil.getVariable(processEngineRule, "GenericGetService", "GENGS_obtainSIUrlResponseCode");\r
+\r
+ String expectedWorkflowException = "WorkflowException[processKey=GenericGetService,errorCode=500,errorMessage=Received a bad response from AAI]";\r
+\r
+ assertEquals("false", successIndicator);\r
+ assertEquals("false", found);\r
+ assertEquals("true", obtainUrl);\r
+ assertEquals("true", byName);\r
+ assertEquals("500", siUrlResponseCode);\r
+ assertEquals(expectedWorkflowException, workflowException);\r
+ }\r
+\r
+\r
+ private void setVariablesInstance(Map<String, String> variables, String siId, String siName, String globalCustId, String serviceType) {\r
+ variables.put("isDebugLogEnabled", "true");\r
+ variables.put("GENGS_serviceInstanceId", siId);\r
+ variables.put("GENGS_serviceInstanceName", siName);\r
+ variables.put("GENGS_globalCustomerId",globalCustId);\r
+ variables.put("GENGS_serviceType", serviceType);\r
+ variables.put("GENGS_type", "service-instance");\r
+ }\r
+\r
+ private void setVariablesSubscription(Map<String, String> variables, String siId, String siName, String globalCustId, String serviceType) {\r
+ variables.put("isDebugLogEnabled", "true");\r
+ variables.put("GENGS_serviceInstanceId", siId);\r
+ variables.put("GENGS_serviceInstanceName", siName);\r
+ variables.put("GENGS_globalCustomerId",globalCustId);\r
+ variables.put("GENGS_serviceType", serviceType);\r
+ variables.put("GENGS_type", "service-subscription");\r
+ }\r
+\r
+\r
+}\r
\r
package org.openecomp.mso.bpmn.common;\r
\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockAAIVfModuleBadPatch;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfByIdWithDepth;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfById_404;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutGenericVnf;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPatchVfModuleId;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutGenericVnf;\r
\r
import java.io.IOException;\r
import java.util.HashMap;\r
@Deployment(resources = {\r
"subprocess/PrepareUpdateAAIVfModule.bpmn"\r
})\r
- public void badPut() throws IOException {\r
+ public void badPatch() throws IOException {\r
\r
logStart();\r
\r
String prepareUpdateAAIVfModuleRequest = FileUtil.readResourceFile("__files/VfModularity/PrepareUpdateAAIVfModuleRequest.xml"); \r
\r
MockGetGenericVnfByIdWithDepth("skask", 1, "VfModularity/GenericVnf.xml");\r
- \r
+ MockAAIVfModuleBadPatch("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/supercool", 404);\r
+ \r
String businessKey = UUID.randomUUID().toString();\r
Map<String, Object> variables = new HashMap<String, Object>(); \r
variables.put("mso-request-id", "999-99-9999");\r
\r
import javax.ws.rs.core.Response;\r
\r
-import org.camunda.bpm.engine.MismatchingMessageCorrelationException;\r
import org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl;\r
import org.camunda.bpm.engine.runtime.Job;\r
import org.camunda.bpm.engine.test.Deployment;\r
import org.openecomp.mso.bpmn.common.adapter.sdnc.SDNCAdapterCallbackRequest;\r
import org.openecomp.mso.bpmn.common.adapter.sdnc.SDNCAdapterResponse;\r
import org.openecomp.mso.bpmn.common.workflow.service.SDNCAdapterCallbackServiceImpl;\r
-import org.openecomp.mso.bpmn.common.workflow.service.SDNCAdapterCallbackServiceImpl.SDNCAdapterExceptionResponse;\r
+import org.openecomp.mso.bpmn.common.workflow.service.SDNCAdapterCallbackServiceImpl.SDNCAdapterErrorResponse;\r
import org.openecomp.mso.bpmn.common.workflow.service.WorkflowResource;\r
import org.openecomp.mso.bpmn.common.workflow.service.WorkflowResponse;\r
+import org.openecomp.mso.bpmn.core.PropertyConfigurationSetup;\r
import org.openecomp.mso.bpmn.mock.FileUtil;\r
\r
/**\r
SDNCAdapterResponse sdncAdapterResponse = callbackService.sdncAdapterCallback(sdncAdapterCallbackRequest);\r
//System.out.println("Back from executing process again");\r
\r
- assertFalse(sdncAdapterResponse instanceof SDNCAdapterExceptionResponse);\r
+ assertFalse(sdncAdapterResponse instanceof SDNCAdapterErrorResponse);\r
assertProcessInstanceFinished(pid);\r
\r
//System.out.println("SDNCAdapter sunny day flow Completed!");\r
SDNCAdapterResponse sdncAdapterResponse = callbackService.sdncAdapterCallback(sdncAdapterCallbackRequest);\r
//System.out.println("Back from executing process again");\r
\r
- assertFalse(sdncAdapterResponse instanceof SDNCAdapterExceptionResponse);\r
+ assertFalse(sdncAdapterResponse instanceof SDNCAdapterErrorResponse);\r
assertProcessInstanceNotFinished(pid);\r
\r
checkForTimeout(pid);\r
SDNCAdapterResponse sdncAdapterResponse = callbackService.sdncAdapterCallback(sdncAdapterCallbackRequest);\r
//System.out.println("Back from executing process again");\r
\r
- assertFalse(sdncAdapterResponse instanceof SDNCAdapterExceptionResponse);\r
+ assertFalse(sdncAdapterResponse instanceof SDNCAdapterErrorResponse);\r
assertProcessInstanceNotFinished(pid);\r
assertEquals(true, (Boolean) (getVariable(pid, "continueListening")));\r
\r
sdncAdapterResponse = callbackService.sdncAdapterCallback(sdncAdapterCallbackRequest);\r
//System.out.println("Back from executing process again");\r
\r
- assertFalse(sdncAdapterResponse instanceof SDNCAdapterExceptionResponse);\r
+ assertFalse(sdncAdapterResponse instanceof SDNCAdapterErrorResponse);\r
assertProcessInstanceFinished(pid);\r
assertEquals(false, (Boolean) (getVariable(pid, "continueListening")));\r
\r
@Deployment(resources = {"subprocess/SDNCAdapterV1.bpmn",\r
"subprocess/GenericNotificationService.bpmn"\r
})\r
- public void badCorrelationIdTest() throws InterruptedException {\r
+ public void badCorrelationIdTest() throws InterruptedException, IOException {\r
\r
mockSDNCAdapter(200);\r
\r
+ Map<String, String> urnProperties = PropertyConfigurationSetup.createBpmnUrnProperties();\r
+ urnProperties.put("mso.correlation.timeout", "5");\r
+ PropertyConfigurationSetup.addProperties(urnProperties, 10000);\r
+\r
//System.out.println("SDNCAdapter bad RequestId test Started!");\r
\r
ProcessExecutionThread thread = new ProcessExecutionThread(sdncAdapterWorkflowRequest);\r
SDNCAdapterResponse sdncAdapterResponse = callbackService.sdncAdapterCallback(sdncAdapterCallbackRequest);\r
//System.out.println("Back from executing process again");\r
\r
- assertTrue(sdncAdapterResponse instanceof SDNCAdapterExceptionResponse);\r
- assertTrue(((SDNCAdapterExceptionResponse) sdncAdapterResponse).getException() instanceof IllegalStateException);\r
+ assertTrue(sdncAdapterResponse instanceof SDNCAdapterErrorResponse);\r
+ assertTrue(((SDNCAdapterErrorResponse) sdncAdapterResponse).getError().contains("No process is waiting for sdncAdapterCallbackRequest"));\r
assertProcessInstanceNotFinished(pid);\r
\r
//System.out.println("SDNCAdapter bad RequestId test Completed!");\r
\r
package org.openecomp.mso.bpmn.common;\r
\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockAAIVfModuleBadPatch;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfByIdWithDepth;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfById_404;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPatchGenericVnf;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutGenericVnf;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutGenericVnf_Bad;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPatchGenericVnf;\r
\r
import java.io.IOException;\r
import java.util.HashMap;\r
@Deployment(resources = {\r
"subprocess/UpdateAAIGenericVnf.bpmn"\r
})\r
- public void badPut() throws IOException {\r
+ public void badPatch() throws IOException {\r
\r
logStart();\r
\r
\r
MockGetGenericVnfByIdWithDepth("skask", 1, "VfModularity/GenericVnf.xml");\r
MockPutGenericVnf_Bad("skask", 404);\r
+ MockAAIVfModuleBadPatch("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask", 404);\r
\r
String businessKey = UUID.randomUUID().toString();\r
Map<String, Object> variables = new HashMap<String, Object>();\r
\r
package org.openecomp.mso.bpmn.common;\r
\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockAAIVfModuleBadPatch;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfById;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfByIdWithPriority;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfById_404;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutGenericVnf;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPatchVfModuleId;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutGenericVnf;\r
\r
import java.io.IOException;\r
import java.util.HashMap;\r
@Deployment(resources = {\r
"subprocess/UpdateAAIVfModule.bpmn"\r
})\r
- public void badPut() throws IOException {\r
+ public void badPatch() throws IOException {\r
\r
logStart();\r
\r
String updateAAIVfModuleRequest = FileUtil.readResourceFile("__files/VfModularity/UpdateAAIVfModuleRequest.xml"); \r
MockGetGenericVnfById_404("/skask/vf-modules/vf-module/supercool");\r
MockGetGenericVnfById("/skask/vf-modules/vf-module/supercool", "VfModularity/VfModule-supercool.xml", 200);\r
+ MockAAIVfModuleBadPatch("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/supercool", 404);\r
\r
String businessKey = UUID.randomUUID().toString();\r
Map<String, Object> variables = new HashMap<String, Object>();\r
@Rule\r
public final WireMockRule wireMockRule;\r
\r
+ /**\r
+ * Content-Type for XML.\r
+ */\r
+ protected static final String XML = "application/xml";\r
+\r
+ /**\r
+ * Content-Type for JSON.\r
+ */\r
+ protected static final String JSON = "application/json; charset=UTF-8";\r
+\r
/**\r
* Constructor.\r
*/\r
* @param businessKey a unique key that will identify the process instance\r
* @param injectedVariables variables to inject into the process\r
*/\r
- protected void invokeSubProcess(String processKey, String businessKey,\r
- Map<String, Object> injectedVariables) {\r
+ protected void invokeSubProcess(String processKey, String businessKey, Map<String, Object> injectedVariables) {\r
RuntimeMXBean runtimeMxBean = ManagementFactory.getRuntimeMXBean();\r
List<String> arguments = runtimeMxBean.getInputArguments();\r
System.out.println("JVM args = " + arguments);\r
\r
msoRequestId = (String) injectedVariables.get("mso-request-id");\r
+ String requestId = (String) injectedVariables.get("msoRequestId");\r
\r
- if (msoRequestId == null) {\r
+ if (msoRequestId == null && requestId == null) {\r
String msg = "mso-request-id variable was not provided";\r
System.out.println(msg);\r
fail(msg);\r
* @param injectedVariables optional variables to inject into the process\r
* @return a TestAsyncResponse object associated with the test\r
*/\r
- public TestAsyncResponse invokeAsyncProcess(String processKey,\r
+ protected TestAsyncResponse invokeAsyncProcess(String processKey,\r
String schemaVersion, String businessKey, String request,\r
Map<String, Object> injectedVariables) {\r
\r
* @param timeout the timeout in milliseconds\r
* @return the WorkflowResponse\r
*/\r
- public WorkflowResponse receiveResponse(String businessKey,\r
+ protected WorkflowResponse receiveResponse(String businessKey,\r
TestAsyncResponse asyncResponse, long timeout) {\r
System.out.println("Waiting " + timeout + "ms for process with business key " + businessKey\r
+ " to send a response");\r
}\r
\r
String content = null;\r
+ String contentType = null;\r
\r
if ("STD".equals(modifier)) {\r
- content = callbacks.get(action);\r
+ CallbackData callbackData = callbacks.get(action);\r
\r
- if (content == null) {\r
+ if (callbackData == null) {\r
String msg = "No callback defined for '" + action + "' SDNC request";\r
System.out.println(msg);\r
fail(msg);\r
}\r
+\r
+ content = callbackData.getContent();\r
+ contentType = callbackData.getContentType();\r
} else if ("ERR".equals(modifier)) {\r
content = "{\"SDNCServiceError\":{\"sdncRequestId\":\"((REQUEST-ID))\",\"responseCode\":\"500\",\"responseMessage\":\"SIMULATED ERROR FROM SDNC ADAPTER\",\"ackFinalIndicator\":\"Y\"}}";\r
+ contentType = JSON;\r
} else {\r
String msg = "Invalid SDNC program modifier: '" + modifier + "'";\r
System.out.println(msg);\r
fail(msg);\r
}\r
\r
- if (!injectSDNCRestCallback(content, 10000)) {\r
+ if (contentType == null) {\r
+ // Default for backward compatibility with existing tests.\r
+ contentType = JSON;\r
+ }\r
+\r
+ if (!injectSDNCRestCallback(contentType, content, 10000)) {\r
fail("Failed to inject SDNC '" + action + "' callback");\r
}\r
\r
* <pre>\r
* event1, event2\r
* </pre>\r
+ * NOTE: Each callback must have a message type associated with it, e.g.\r
+ * "SDNCAEvent".\r
* Errors are handled with junit assertions and will cause the test to fail.\r
- * Defaults the Event Type to "SDNCAEvent" for backward compatibility.\r
* @param callbacks an object containing event data for the program\r
* @param program the program to execute\r
*/\r
protected void injectSDNCEvents(CallbackSet callbacks, String program) {\r
- injectSDNCEvents(callbacks, program, "SDNCAEvent");\r
- }\r
-\r
- /**\r
- * Runs a program to inject SDNC events into the test environment.\r
- * A program is essentially just a list of keys that identify event data\r
- * to be injected, in sequence. An example program:\r
- * <pre>\r
- * event1, event2\r
- * </pre>\r
- * Errors are handled with junit assertions and will cause the test to fail.\r
- * @param callbacks an object containing event data for the program\r
- * @param program the program to execute\r
- * @param eventType (i.e. "SDNCAEvent", "SNIROResponse", etc.)\r
- */\r
- protected void injectSDNCEvents(CallbackSet callbacks, String program, String eventType) {\r
-\r
- String[] cmds = program.replaceAll("\\s+", "").split(",");\r
-\r
- for (String cmd : cmds) {\r
- String action = cmd;\r
- String modifier = "STD";\r
-\r
- if (cmd.contains(":")) {\r
- String[] parts = cmd.split(":");\r
- action = parts[0];\r
- modifier = parts[1];\r
- }\r
-\r
- String content = null;\r
-\r
- if ("STD".equals(modifier)) {\r
- content = callbacks.get(action);\r
-\r
- if (content == null) {\r
- String msg = "No SDNC event callback defined for '" + action + "'";\r
- System.out.println(msg);\r
- fail(msg);\r
- }\r
- } else {\r
- String msg = "Invalid SDNC program modifier: '" + modifier + "'";\r
- System.out.println(msg);\r
- fail(msg);\r
- }\r
-\r
- if (!injectWorkflowMessage(eventType, content, 10000)) {\r
- fail("Failed to inject SDNC '" + action + "' event");\r
- }\r
-\r
- try {\r
- Thread.sleep(1000);\r
- } catch (InterruptedException e) {\r
- fail("Interrupted after injection of SDNC '" + action + "' event");\r
- }\r
- }\r
+ injectWorkflowMessages(callbacks, program);\r
}\r
\r
/**\r
* @param callbacks an object containing callback data for the program\r
* @param program the program to execute\r
*/\r
- public void injectSDNCCallbacks(CallbackSet callbacks, String program) {\r
+ protected void injectSDNCCallbacks(CallbackSet callbacks, String program) {\r
\r
String[] cmds = program.replaceAll("\\s+", "").split(",");\r
\r
String respMsg = "OK";\r
\r
if ("STD".equals(modifier)) {\r
- content = callbacks.get(action);\r
+ CallbackData callbackData = callbacks.get(action);\r
\r
- if (content == null) {\r
+ if (callbackData == null) {\r
String msg = "No callback defined for '" + action + "' SDNC request";\r
System.out.println(msg);\r
fail(msg);\r
}\r
\r
+ content = callbackData.getContent();\r
respCode = 200;\r
respMsg = "OK";\r
} else if ("ERR".equals(modifier)) {\r
* @param callbacks an object containing callback data for the program\r
* @param program the program to execute\r
*/\r
- public void injectVNFRestCallbacks(CallbackSet callbacks, String program) {\r
+ protected void injectVNFRestCallbacks(CallbackSet callbacks, String program) {\r
\r
String[] cmds = program.replaceAll("\\s+", "").split(",");\r
\r
}\r
\r
String content = null;\r
+ String contentType = null;\r
\r
if ("STD".equals(modifier)) {\r
- content = callbacks.get(action);\r
+ CallbackData callbackData = callbacks.get(action);\r
\r
- if (content == null) {\r
+ if (callbackData == null) {\r
String msg = "No callback defined for '" + action + "' VNF REST request";\r
System.out.println(msg);\r
fail(msg);\r
}\r
+\r
+ content = callbackData.getContent();\r
+ contentType = callbackData.getContentType();\r
} else if ("ERR".equals(modifier)) {\r
content = "SIMULATED ERROR FROM VNF ADAPTER";\r
+ contentType = "text/plain";\r
} else {\r
String msg = "Invalid VNF REST program modifier: '" + modifier + "'";\r
System.out.println(msg);\r
fail(msg);\r
}\r
\r
- if (!injectVnfAdapterRestCallback(content, 10000)) {\r
+ if (contentType == null) {\r
+ // Default for backward compatibility with existing tests.\r
+ contentType = XML;\r
+ }\r
+\r
+ if (!injectVnfAdapterRestCallback(contentType, content, 10000)) {\r
fail("Failed to inject VNF REST '" + action + "' callback");\r
}\r
\r
String content = null;\r
\r
if ("STD".equals(modifier)) {\r
- content = callbacks.get(action);\r
+ CallbackData callbackData = callbacks.get(action);\r
\r
- if (content == null) {\r
+ if (callbackData == null) {\r
String msg = "No callback defined for '" + action + "' VNF request";\r
System.out.println(msg);\r
fail(msg);\r
}\r
\r
+ content = callbackData.getContent();\r
} else if ("ERR".equals(modifier)) {\r
String msg = "Currently unsupported VNF program modifier: '" + modifier + "'";\r
System.out.println(msg);\r
* @param count the desired count\r
* @param timeout the timeout in milliseconds\r
*/\r
- public void waitForRunningProcessCount(String processKey, int count, long timeout) {\r
+ protected void waitForRunningProcessCount(String processKey, int count, long timeout) {\r
System.out.println("Waiting " + timeout + "ms for there to be " + count + " "\r
+ processKey + " instances");\r
\r
* may contain the placeholder string ((REQUEST-ID)) which is replaced with\r
* the actual SDNC request ID. Note: this is not the requestId in the original\r
* MSO request.\r
+ * @param contentType the HTTP content type for the callback\r
* @param content the content of the callback\r
* @param timeout the timeout in milliseconds\r
* @return true if the callback could be injected, false otherwise\r
*/\r
- protected boolean injectSDNCRestCallback(String content, long timeout) {\r
+ protected boolean injectSDNCRestCallback(String contentType, String content, long timeout) {\r
String sdncRequestId = (String) getProcessVariable("SDNCAdapterRestV1",\r
"SDNCAResponse_CORRELATOR", timeout);\r
\r
System.out.println("Injecting SDNC adapter callback");\r
WorkflowMessageResource workflowMessageResource = new WorkflowMessageResource();\r
workflowMessageResource.setProcessEngineServices4junit(processEngineRule);\r
- Response response = workflowMessageResource.deliver("SDNCAResponse", sdncRequestId, content);\r
+ Response response = workflowMessageResource.deliver(contentType, "SDNCAResponse", sdncRequestId, content);\r
System.out.println("Workflow response to SDNC adapter callback: " + response);\r
return true;\r
}\r
* may contain the placeholder string ((MESSAGE-ID)) which is replaced with\r
* the actual message ID. Note: this is not the requestId in the original\r
* MSO request.\r
+ * @param contentType the HTTP content type for the callback\r
* @param content the content of the callback\r
* @param timeout the timeout in milliseconds\r
* @return true if the callback could be injected, false otherwise\r
*/\r
- protected boolean injectVnfAdapterRestCallback(String content, long timeout) {\r
+ protected boolean injectVnfAdapterRestCallback(String contentType, String content, long timeout) {\r
String messageId = (String) getProcessVariable("vnfAdapterRestV1",\r
"VNFAResponse_CORRELATOR", timeout);\r
\r
System.out.println("Injecting VNF adapter callback");\r
WorkflowMessageResource workflowMessageResource = new WorkflowMessageResource();\r
workflowMessageResource.setProcessEngineServices4junit(processEngineRule);\r
- Response response = workflowMessageResource.deliver("VNFAResponse", messageId, content);\r
+ Response response = workflowMessageResource.deliver(contentType, "VNFAResponse", messageId, content);\r
System.out.println("Workflow response to VNF adapter callback: " + response);\r
return true;\r
}\r
return true;\r
}\r
\r
+ /**\r
+ * Runs a program to inject workflow messages into the test environment.\r
+ * A program is essentially just a list of keys that identify event data\r
+ * to be injected, in sequence. An example program:\r
+ * <pre>\r
+ * event1, event2\r
+ * </pre>\r
+ * Errors are handled with junit assertions and will cause the test to fail.\r
+ * NOTE: Each callback must have a workflow message type associated with it.\r
+ * @param callbacks an object containing event data for the program\r
+ * @param program the program to execute\r
+ */\r
+ protected void injectWorkflowMessages(CallbackSet callbacks, String program) {\r
+\r
+ String[] cmds = program.replaceAll("\\s+", "").split(",");\r
+\r
+ for (String cmd : cmds) {\r
+ String action = cmd;\r
+ String modifier = "STD";\r
+\r
+ if (cmd.contains(":")) {\r
+ String[] parts = cmd.split(":");\r
+ action = parts[0];\r
+ modifier = parts[1];\r
+ }\r
+\r
+ String messageType = null;\r
+ String content = null;\r
+ String contentType = null;\r
+\r
+ if ("STD".equals(modifier)) {\r
+ CallbackData callbackData = callbacks.get(action);\r
+\r
+ if (callbackData == null) {\r
+ String msg = "No '" + action + "' workflow message callback is defined";\r
+ System.out.println(msg);\r
+ fail(msg);\r
+ }\r
+\r
+ messageType = callbackData.getMessageType();\r
+\r
+ if (messageType == null || messageType.trim().equals("")) {\r
+ String msg = "No workflow message type is defined in the '" + action + "' callback";\r
+ System.out.println(msg);\r
+ fail(msg);\r
+ }\r
+\r
+ content = callbackData.getContent();\r
+ contentType = callbackData.getContentType();\r
+ } else {\r
+ String msg = "Invalid workflow message program modifier: '" + modifier + "'";\r
+ System.out.println(msg);\r
+ fail(msg);\r
+ }\r
+\r
+ if (!injectWorkflowMessage(contentType, messageType, content, 10000)) {\r
+ fail("Failed to inject '" + action + "' workflow message");\r
+ }\r
+\r
+ try {\r
+ Thread.sleep(1000);\r
+ } catch (InterruptedException e) {\r
+ fail("Interrupted after injection of '" + action + "' workflow message");\r
+ }\r
+ }\r
+ }\r
+\r
/**\r
* Injects a workflow message. The specified callback data may contain the\r
* placeholder string ((CORRELATOR)) which is replaced with the actual\r
* correlator value.\r
- * @param content the message type\r
- * @param content the message content\r
+ * @param contentType the HTTP contentType for the message (possibly null)\r
+ * @param messageType the message type\r
+ * @param content the message content (possibly null)\r
* @param timeout the timeout in milliseconds\r
- * @return true if the event could be injected, false otherwise\r
+ * @return true if the message could be injected, false otherwise\r
*/\r
- protected boolean injectWorkflowMessage(String messageType, String content, long timeout) {\r
+ protected boolean injectWorkflowMessage(String contentType, String messageType, String content, long timeout) {\r
String correlator = (String) getProcessVariable("ReceiveWorkflowMessage",\r
messageType + "_CORRELATOR", timeout);\r
\r
return false;\r
}\r
\r
- content = content.replace("((CORRELATOR))", correlator);\r
+ if (content != null) {\r
+ content = content.replace("((CORRELATOR))", correlator);\r
+ }\r
\r
System.out.println("Injecting " + messageType + " message");\r
WorkflowMessageResource workflowMessageResource = new WorkflowMessageResource();\r
workflowMessageResource.setProcessEngineServices4junit(processEngineRule);\r
- Response response = workflowMessageResource.deliver(messageType, correlator, content);\r
+ Response response = workflowMessageResource.deliver(contentType, messageType, correlator, content);\r
System.out.println("Workflow response to " + messageType + " message: " + response);\r
return true;\r
}\r
* @param businessKey the process business key\r
* @param timeout the amount of time to wait, in milliseconds\r
*/\r
- public void waitForProcessEnd(String businessKey, long timeout) {\r
+ protected void waitForProcessEnd(String businessKey, long timeout) {\r
System.out.println("Waiting " + timeout + "ms for process with business key " +\r
businessKey + " to end");\r
\r
* @param variable the variable name\r
* @param value the expected variable value\r
*/\r
- public void checkVariable(String businessKey, String variable, Object value) {\r
+ protected void checkVariable(String businessKey, String variable, Object value) {\r
if (!isProcessEnded(businessKey)) {\r
fail("Cannot get historic variable " + variable + " because process with business key " +\r
businessKey + " has not ended");\r
* @return the variable value, or null if the variable could not be\r
* obtained\r
*/\r
- public Object getVariableFromHistory(String businessKey, String variableName) {\r
+ protected Object getVariableFromHistory(String businessKey, String variableName) {\r
try {\r
HistoricProcessInstance processInstance = processEngineRule.getHistoryService()\r
.createHistoricProcessInstanceQuery().processInstanceBusinessKey(businessKey).singleResult();\r
}\r
\r
/**\r
+ * @author cb645j\r
+ *\r
* Gets the value of a subflow variable from the specified subflow's\r
* historical process instance.\r
*\r
List<HistoricProcessInstance> processInstanceList = processEngineRule.getHistoryService()\r
.createHistoricProcessInstanceQuery().processDefinitionName(subflowName).list();\r
\r
+ if (processInstanceList == null) {\r
+ return null;\r
+ }\r
+\r
Collections.sort(processInstanceList, new Comparator<HistoricProcessInstance>() {\r
public int compare(HistoricProcessInstance m1, HistoricProcessInstance m2) {\r
return m1.getStartTime().compareTo(m2.getStartTime());\r
\r
HistoricProcessInstance processInstance = processInstanceList.get(0);\r
\r
- if (processInstanceList == null) {\r
- return null;\r
- }\r
-\r
HistoricVariableInstance v = processEngineRule.getHistoryService()\r
.createHistoricVariableInstanceQuery().processInstanceId(processInstance.getId())\r
.variableName(variableName).singleResult();\r
}\r
\r
/**\r
+ * @author cb645j\r
+ *\r
* Gets the value of a subflow variable from the subflow's\r
* historical process x instance.\r
*\r
List<HistoricProcessInstance> processInstanceList = processEngineRule.getHistoryService()\r
.createHistoricProcessInstanceQuery().processDefinitionName(subflowName).list();\r
\r
+ if (processInstanceList == null) {\r
+ return null;\r
+ }\r
+\r
Collections.sort(processInstanceList, new Comparator<HistoricProcessInstance>() {\r
public int compare(HistoricProcessInstance m1, HistoricProcessInstance m2) {\r
return m1.getStartTime().compareTo(m2.getStartTime());\r
\r
HistoricProcessInstance processInstance = processInstanceList.get(subflowInstanceIndex);\r
\r
- if (processInstanceList == null) {\r
- return null;\r
- }\r
-\r
HistoricVariableInstance v = processEngineRule.getHistoryService()\r
.createHistoricVariableInstanceQuery().processInstanceId(processInstance.getId())\r
.variableName(variableName).singleResult();\r
* An object that contains callback data for a "program".\r
*/\r
public class CallbackSet {\r
- private final Map<String, String> map = new HashMap<String, String>();\r
+ private final Map<String, CallbackData> map = new HashMap<String, CallbackData>();\r
\r
/**\r
- * Add callback data to the set.\r
+ * Add untyped callback data to the set.\r
* @param action the action with which the data is associated\r
* @param content the callback data\r
*/\r
public void put(String action, String content) {\r
- map.put(action, content);\r
+ map.put(action, new CallbackData(null, null, content));\r
+ }\r
+\r
+ /**\r
+ * Add callback data to the set.\r
+ * @param action the action with which the data is associated\r
+ * @param messageType the callback message type\r
+ * @param content the callback data\r
+ */\r
+ public void put(String action, String messageType, String content) {\r
+ map.put(action, new CallbackData(null, messageType, content));\r
+ }\r
+\r
+ /**\r
+ * Add callback data to the set.\r
+ * @param action the action with which the data is associated\r
+ * @param contentType the callback HTTP content type\r
+ * @param messageType the callback message type\r
+ * @param content the callback data\r
+ */\r
+ public void put(String action, String contentType, String messageType, String content) {\r
+ map.put(action, new CallbackData(contentType, messageType, content));\r
}\r
\r
/**\r
* @param action the action with which the data is associated\r
* @return the callback data, or null if there is none for the specified operation\r
*/\r
- public String get(String action) {\r
+ public CallbackData get(String action) {\r
return map.get(action);\r
}\r
}\r
\r
+ /**\r
+ * Represents a callback data item.\r
+ */\r
+ public class CallbackData {\r
+ private final String contentType;\r
+ private final String messageType;\r
+ private final String content;\r
+\r
+ /**\r
+ * Constructor\r
+ * @param contentType the HTTP content type (optional)\r
+ * @param type the callback message type (optional)\r
+ * @param content the content\r
+ */\r
+ public CallbackData(String contentType, String messageType, String content) {\r
+ this.contentType = contentType;\r
+ this.messageType = messageType;\r
+ this.content = content;\r
+ }\r
+\r
+ /**\r
+ * Gets the callback HTTP content type, possibly null.\r
+ */\r
+ public String getContentType() {\r
+ return contentType;\r
+ }\r
+\r
+ /**\r
+ * Gets the callback message type, possibly null.\r
+ */\r
+ public String getMessageType() {\r
+ return messageType;\r
+ }\r
+\r
+ /**\r
+ * Gets the callback content.\r
+ */\r
+ public String getContent() {\r
+ return content;\r
+ }\r
+ }\r
+\r
/**\r
* A tool for evaluating XPath expressions.\r
*/\r
* Helper class to make it easier to create this type.\r
*/\r
private static class CreateVnfNotificationOutputs\r
- extends org.openecomp.mso.bpmn.common.adapter.vnf.CreateVnfNotification.Outputs {\r
+ extends CreateVnfNotification.Outputs {\r
public void add(String key, String value) {\r
Entry entry = new Entry();\r
entry.setKey(key);\r
* Helper class to make it easier to create this type.\r
*/\r
private static class UpdateVnfNotificationOutputs\r
- extends org.openecomp.mso.bpmn.common.adapter.vnf.UpdateVnfNotification.Outputs {\r
+ extends UpdateVnfNotification.Outputs {\r
public void add(String key, String value) {\r
Entry entry = new Entry();\r
entry.setKey(key);\r
--- Fix for https://itrack.web.att.com/browse/AJSCCMDA-90 --
-use camundabpmn;
-/*
-Drop a archive tables
-*/
-/*-- TMP_ARCHIVING_PROCINST */
-DROP TABLE IF EXISTS TMP_ARCHIVING_PROCINST;
-
-/*-- TMP_ARCHIVING_BYTEARRAY */
-DROP TABLE IF EXISTS TMP_ARCHIVING_BYTEARRAY;
-
-/*-- TMP LOG TABLE */
-DROP TABLE IF EXISTS TMPLOGTABLE;
-
-/* -- Camunda Hi Tables --*/
-DROP TABLE IF EXISTS Camunda_Hi_Tables;
-
-/* drop own extentions columns:
-alter table ARCHIVE_ACT_HI_PROCINST DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-alter table ARCHIVE_ACT_HI_ACTINST DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-alter table ARCHIVE_ACT_HI_TASKINST DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-alter table ARCHIVE_ACT_HI_VARINST DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-alter table ARCHIVE_ACT_HI_DETAIL DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-alter table ARCHIVE_ACT_HI_COMMENT DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-alter table ARCHIVE_ACT_HI_ATTACHMENT DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-alter table ARCHIVE_ACT_HI_OP_LOG DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-alter table ARCHIVE_ACT_HI_INCIDENT DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);
-*/
-
-/*--#1 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_PROCINST;
-/*--#2 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_ACTINST;
-/*--#3 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_TASKINST;
-/*--#4 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_VARINST;
-/*--#5 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_DETAIL;
-/*--#6 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_COMMENT;
-/*--#7 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_ATTACHMENT;
-/*--#8 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_OP_LOG;
-/*--#9 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_HI_INCIDENT;
-/*--#10 */
-DROP TABLE IF EXISTS ARCHIVE_ACT_GE_BYTEARRAY;
-
-/* drop PL SQL procedures: */
-DROP PROCEDURE IF EXISTS ARCHIVE_CAMUNDA_HISTORY;
-DROP PROCEDURE IF EXISTS ROLLB_ARCHIVE_CAMUNDA_HISTORY;
-
-/*-- Sequence */
--- as sequence drop doesn't work automatically in MariaDB, use this procedure to drop sequence
- DROP PROCEDURE IF EXISTS DropSequence;
-
- DELIMITER //
-
- CREATE PROCEDURE DropSequence (vname VARCHAR(30))
- BEGIN
- -- Drop the sequence
- DELETE FROM _sequences WHERE name = vname;
- END
- //
- DELIMITER ;
-
--- use the above procedure to drop sequence
-CALL DropSequence('STAT_EXECUTION_SEQ');
-
-/*-- To Drop the MariaDB specific user defined procedures and functions */
-DROP FUNCTION IF EXISTS NextVal;
-DROP PROCEDURE IF EXISTS CreateSequence;
-DROP PROCEDURE IF EXISTS DropSequence;
+use camundabpmn;\r
+/* \r
+Drop a archive tables\r
+*/\r
+/*-- TMP_ARCHIVING_PROCINST */\r
+DROP TABLE IF EXISTS TMP_ARCHIVING_PROCINST;\r
+\r
+/*-- TMP_ARCHIVING_BYTEARRAY */\r
+DROP TABLE IF EXISTS TMP_ARCHIVING_BYTEARRAY;\r
+\r
+/*-- TMP LOG TABLE */\r
+DROP TABLE IF EXISTS TMPLOGTABLE;\r
+\r
+/* -- Camunda Hi Tables --*/\r
+DROP TABLE IF EXISTS Camunda_Hi_Tables;\r
+\r
+/* drop own extentions columns:\r
+alter table ARCHIVE_ACT_HI_PROCINST DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+alter table ARCHIVE_ACT_HI_ACTINST DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+alter table ARCHIVE_ACT_HI_TASKINST DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+alter table ARCHIVE_ACT_HI_VARINST DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+alter table ARCHIVE_ACT_HI_DETAIL DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+alter table ARCHIVE_ACT_HI_COMMENT DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+alter table ARCHIVE_ACT_HI_ATTACHMENT DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+alter table ARCHIVE_ACT_HI_OP_LOG DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+alter table ARCHIVE_ACT_HI_INCIDENT DROP (STAT_EXECUTION_ID, STAT_EXECUTION_TS);\r
+*/\r
+\r
+/*--#1 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_PROCINST;\r
+/*--#2 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_ACTINST;\r
+/*--#3 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_TASKINST;\r
+/*--#4 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_VARINST;\r
+/*--#5 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_DETAIL;\r
+/*--#6 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_COMMENT;\r
+/*--#7 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_ATTACHMENT;\r
+/*--#8 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_OP_LOG;\r
+/*--#9 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_HI_INCIDENT;\r
+/*--#10 */\r
+DROP TABLE IF EXISTS ARCHIVE_ACT_GE_BYTEARRAY;\r
+\r
+/* drop PL SQL procedures: */\r
+DROP PROCEDURE IF EXISTS ARCHIVE_CAMUNDA_HISTORY;\r
+DROP PROCEDURE IF EXISTS ROLLB_ARCHIVE_CAMUNDA_HISTORY;\r
+ \r
+/*-- Sequence */\r
+-- as sequence drop doesn't work automatically in MariaDB, use this procedure to drop sequence\r
+ DROP PROCEDURE IF EXISTS DropSequence;\r
+ \r
+ DELIMITER //\r
+ \r
+ CREATE PROCEDURE DropSequence (vname VARCHAR(30))\r
+ BEGIN\r
+ -- Drop the sequence\r
+ DELETE FROM _sequences WHERE name = vname; \r
+ END\r
+ //\r
+ DELIMITER ;\r
+\r
+-- use the above procedure to drop sequence \r
+CALL DropSequence('STAT_EXECUTION_SEQ');\r
+\r
+/*-- To Drop the MariaDB specific user defined procedures and functions */\r
+DROP FUNCTION IF EXISTS NextVal;\r
+DROP PROCEDURE IF EXISTS CreateSequence;\r
+DROP PROCEDURE IF EXISTS DropSequence;\r
DROP TABLE IF EXISTS _sequences;
\ No newline at end of file
--- Fix for https://itrack.web.att.com/browse/AJSCCMDA-90 --
-use camundabpmn;
-/*
- 1. Add some Camunda Indexes to history schema part (for Archiving)
-*/
-create INDEX IF NOT EXISTS IDX_ACT_HI_TASKINST_PIID ON ACT_HI_TASKINST (PROC_INST_ID_);
-create INDEX IF NOT EXISTS IDX_ACT_HI_COMMENT_PIID ON ACT_HI_COMMENT (PROC_INST_ID_);
-create INDEX IF NOT EXISTS IDX_ACT_HI_ATTACHMENT_PIID ON ACT_HI_ATTACHMENT (PROC_INST_ID_);
-create INDEX IF NOT EXISTS IDX_ACT_HI_OP_LOG_PIID ON ACT_HI_OP_LOG (PROC_INST_ID_);
-create INDEX IF NOT EXISTS IDX_ACT_HI_INCIDENT_PIID ON ACT_HI_INCIDENT (PROC_INST_ID_);
-create INDEX IF NOT EXISTS IDX_ACT_HI_ACTINST_PIID ON ACT_HI_ACTINST(PROC_INST_ID_);
-
-
-/*
- 2. Create Archiving Tables in current schema
-*/
-
-/*-- TMP_ARCHIVING_PROCINST */
-CREATE TABLE TMP_ARCHIVING_PROCINST
-( PROC_INST_ID_ varchar(64) not null,
- END_TIME_ datetime(3)
-);
-CREATE INDEX AI_TMP_ARCH_PROCINST_PI_ID ON TMP_ARCHIVING_PROCINST(PROC_INST_ID_);
-
-/*-- TMP_ARCHIVING_BYTEARRAY */
-CREATE TABLE TMP_ARCHIVING_BYTEARRAY
-( BYTEARRAY_ID_ varchar(64) not null,
- PROC_INST_ID_ varchar(64)
-);
-CREATE INDEX AI_TMP_ARCH_BYTEARRAY_BAID ON TMP_ARCHIVING_BYTEARRAY(BYTEARRAY_ID_);
-
-
-/*--#1 ARCHIVE_ACT_HI_PROCINST; */
-create TABLE ARCHIVE_ACT_HI_PROCINST
-AS ( select * from ACT_HI_PROCINST where 1=0);
-
-create index AI_HI_PROCINST_END_TIME on ARCHIVE_ACT_HI_PROCINST(END_TIME_);
-ALTER TABLE ARCHIVE_ACT_HI_PROCINST ADD CONSTRAINT ARCHIVE_ACT_HI_PROCINST_UQ UNIQUE ( PROC_INST_ID_);
-
-/*--#2 ARCHIVE_ACT_HI_ACTINST; */
-create TABLE ARCHIVE_ACT_HI_ACTINST
-AS ( select * from ACT_HI_ACTINST where 1=0);
-
-create index AI_HI_ACTINST_PROC_INST_ID on ARCHIVE_ACT_HI_ACTINST(PROC_INST_ID_);
-create index AI_HI_ACTINST_END_TIME on ARCHIVE_ACT_HI_ACTINST(END_TIME_);
-
-/*--#3 ARCHIVE_ACT_HI_TASKINST; */
-create TABLE ARCHIVE_ACT_HI_TASKINST
-AS ( select * from ACT_HI_TASKINST where 1=0);
-
-create index AI_HI_TASKINST_PROC_INST_ID on ARCHIVE_ACT_HI_TASKINST(PROC_INST_ID_);
-create index AI_HI_TASKINST_END_TIME on ARCHIVE_ACT_HI_TASKINST(END_TIME_);
-
-/*--#4 ARCHIVE_ACT_HI_VARINST; */
-create TABLE ARCHIVE_ACT_HI_VARINST
-AS ( select * from ACT_HI_VARINST where 1=0);
-
-create index AI_HI_VARINST_PROC_INST_ID on ARCHIVE_ACT_HI_VARINST(PROC_INST_ID_);
-
-/*--#5 ARCHIVE_ACT_HI_DETAIL; */
-create TABLE ARCHIVE_ACT_HI_DETAIL
-AS ( select * from ACT_HI_DETAIL where 1=0);
-
-create index AI_HI_DETAIL_PROC_INST_ID on ARCHIVE_ACT_HI_DETAIL(PROC_INST_ID_);
-create index AI_HI_DETAIL_TIME on ARCHIVE_ACT_HI_DETAIL(TIME_);
-
-/*--#6 ARCHIVE_ACT_HI_COMMENT; */
-create TABLE ARCHIVE_ACT_HI_COMMENT
-AS ( select * from ACT_HI_COMMENT where 1=0);
-
-create index AI_HI_COMMENT_PROC_INST_ID on ARCHIVE_ACT_HI_COMMENT(PROC_INST_ID_);
-create index AI_HI_COMMENT_TIME on ARCHIVE_ACT_HI_COMMENT(TIME_);
-
-/*--#7 ARCHIVE_ACT_HI_ATTACHMENT; */
-create TABLE ARCHIVE_ACT_HI_ATTACHMENT
-AS ( select * from ACT_HI_ATTACHMENT where 1=0);
-
-create index AI_HI_ATTACHMENT_PROC_INST_ID on ARCHIVE_ACT_HI_ATTACHMENT(PROC_INST_ID_);
-
-/*--#8 ARCHIVE_ACT_HI_OP_LOG; */
-create TABLE ARCHIVE_ACT_HI_OP_LOG
-AS ( select * from ACT_HI_OP_LOG where 1=0);
-
-create index AI_HI_OP_LOG_PROC_INST_ID on ARCHIVE_ACT_HI_OP_LOG(PROC_INST_ID_);
-create index AI_HI_OP_LOG_TIMESTAMP on ARCHIVE_ACT_HI_OP_LOG(TIMESTAMP_);
-
-/*--#9 ARCHIVE_ACT_HI_INCIDENT; */
-create TABLE ARCHIVE_ACT_HI_INCIDENT
-AS ( select * from ACT_HI_INCIDENT where 1=0);
-
-create index AI_HI_INCIDENT_PROC_INST_ID on ARCHIVE_ACT_HI_INCIDENT(PROC_INST_ID_);
-
-/*--#10 ARCHIVE_ACT_GE_BYTEARRAY; */
-create TABLE ARCHIVE_ACT_GE_BYTEARRAY
-AS ( select * from ACT_GE_BYTEARRAY where 1=0);
-
-create index AI_GE_BYTEARRAY_ID_ on ARCHIVE_ACT_GE_BYTEARRAY(ID_);
-
-/* -----------------------------------------------------------------------------
-Extend a ARCHIVE: Table by two attributes: STAT_EXECUTION_ID, STAT_EXECUTION_TS
-*/
-
-/*
---TEMPLATE:
-alter table ARCHIVE_%TableName%
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_%TableName%_EXE_ID ON ARCHIVE_%TableName%(STAT_EXECUTION_ID);
-*/
-
-
-/*--#1 ACT_HI_PROCINST */
-alter table ARCHIVE_ACT_HI_PROCINST
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_PROCINST_EXE_ID ON ARCHIVE_ACT_HI_PROCINST(STAT_EXECUTION_ID);
-
-/*--#2 ACT_HI_ACTINST */
-alter table ARCHIVE_ACT_HI_ACTINST
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_ACTINST_EXE_ID ON ARCHIVE_ACT_HI_ACTINST(STAT_EXECUTION_ID);
-
-/*--#3 ACT_HI_TASKINST */
-alter table ARCHIVE_ACT_HI_TASKINST
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_TASKINST_EXE_ID ON ARCHIVE_ACT_HI_TASKINST(STAT_EXECUTION_ID);
-
-/*--#4 ACT_HI_VARINST */
-alter table ARCHIVE_ACT_HI_VARINST
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_VARINST_EXE_ID ON ARCHIVE_ACT_HI_VARINST(STAT_EXECUTION_ID);
-
-/*--#5 ACT_HI_DETAIL */
-alter table ARCHIVE_ACT_HI_DETAIL
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_DETAIL_EXE_ID ON ARCHIVE_ACT_HI_DETAIL(STAT_EXECUTION_ID);
-
-/*--#6 ACT_HI_COMMENT */
-alter table ARCHIVE_ACT_HI_COMMENT
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_COMMENT_EXE_ID ON ARCHIVE_ACT_HI_COMMENT(STAT_EXECUTION_ID);
-
-/*--#7 ACT_HI_ATTACHMENT */
-alter table ARCHIVE_ACT_HI_ATTACHMENT
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_ATTACHMENT_EXE_ID ON ARCHIVE_ACT_HI_ATTACHMENT(STAT_EXECUTION_ID);
-
-/*--#8 ACT_HI_OP_LOG */
-alter table ARCHIVE_ACT_HI_OP_LOG
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_OP_LOG_EXE_ID ON ARCHIVE_ACT_HI_OP_LOG(STAT_EXECUTION_ID);
-
-/*--#9 ACT_HI_INCIDENT */
-alter table ARCHIVE_ACT_HI_INCIDENT
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_HI_INCIDENT_EXE_ID ON ARCHIVE_ACT_HI_INCIDENT(STAT_EXECUTION_ID);
-
-/*--#10 ACT_GE_BYTEARRAY */
-alter table ARCHIVE_ACT_GE_BYTEARRAY
- add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );
-CREATE INDEX AI_ACT_GE_BYTEARRAY_EXE_ID ON ARCHIVE_ACT_GE_BYTEARRAY(STAT_EXECUTION_ID);
-
-
-/* -- Next Val as a user defined function needed only in MariaDB--*/
-DROP FUNCTION IF EXISTS NextVal;
- DELIMITER //
- CREATE FUNCTION NextVal (vname VARCHAR(30))
- RETURNS INT
- BEGIN
- -- Retrieve and update in single statement
- UPDATE _sequences
- SET next = next + 1
- WHERE name = vname;
-
- RETURN (SELECT next FROM _sequences LIMIT 1);
- END
- //
- DELIMITER ;
-
-/* -- History tables for use in archive procedure, there is no array type in MariaDB --*/
-Create Table Camunda_Hi_Tables (id_ MEDIUMINT NOT NULL AUTO_INCREMENT,
- TableName_ varchar(80) NOT NULL,
- PRIMARY KEY (id_));
-
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_PROCINST');
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_ACTINST');
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_TASKINST');
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_VARINST');
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_DETAIL');
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_COMMENT');
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_ATTACHMENT');
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_OP_LOG');
-Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_INCIDENT');
-
-/*-- log table --*/
-CREATE TABLE TMPLOGTABLE (LogMessage Varchar(700));
-
-
-/* -- Below user defined functions and procedures needed only in MariaDB, they are in-built in Oracle --*/
-/*-- Create a sequence SP */
-DROP PROCEDURE IF EXISTS CreateSequence;
- DELIMITER //
- CREATE PROCEDURE CreateSequence (name VARCHAR(30), start INT, inc INT)
- BEGIN
- -- Create a table to store sequences
- CREATE TABLE IF NOT EXISTS _sequences
- (
- name VARCHAR(70) NOT NULL UNIQUE,
- next INT NOT NULL,
- inc INT NOT NULL
- );
-
- -- Add the new sequence
- INSERT INTO _sequences VALUES (name, start, inc);
- END
- //
- DELIMITER ;
-
-/*--------------------------------------------------------------------------------------------------
- Add Meta to Archive
- -------------------------------------------------------------------------------------------------- */
-
-/* Create STAT_EXECUTION_SEQ: each Archive Entry has a same Execution ID during one Archiving Run */
-CALL CreateSequence('STAT_EXECUTION_SEQ', 1, 1);
+use camundabpmn;\r
+/*\r
+ 1. Add some Camunda Indexes to history schema part (for Archiving)\r
+*/\r
+create INDEX IF NOT EXISTS IDX_ACT_HI_TASKINST_PIID ON ACT_HI_TASKINST (PROC_INST_ID_); \r
+create INDEX IF NOT EXISTS IDX_ACT_HI_COMMENT_PIID ON ACT_HI_COMMENT (PROC_INST_ID_);\r
+create INDEX IF NOT EXISTS IDX_ACT_HI_ATTACHMENT_PIID ON ACT_HI_ATTACHMENT (PROC_INST_ID_);\r
+create INDEX IF NOT EXISTS IDX_ACT_HI_OP_LOG_PIID ON ACT_HI_OP_LOG (PROC_INST_ID_);\r
+create INDEX IF NOT EXISTS IDX_ACT_HI_INCIDENT_PIID ON ACT_HI_INCIDENT (PROC_INST_ID_);\r
+create INDEX IF NOT EXISTS IDX_ACT_HI_ACTINST_PIID ON ACT_HI_ACTINST(PROC_INST_ID_); \r
+\r
+\r
+/*\r
+ 2. Create Archiving Tables in current schema \r
+*/\r
+\r
+/*-- TMP_ARCHIVING_PROCINST */\r
+CREATE TABLE TMP_ARCHIVING_PROCINST\r
+( PROC_INST_ID_ varchar(64) not null,\r
+ END_TIME_ datetime(3)\r
+);\r
+CREATE INDEX AI_TMP_ARCH_PROCINST_PI_ID ON TMP_ARCHIVING_PROCINST(PROC_INST_ID_);\r
+\r
+/*-- TMP_ARCHIVING_BYTEARRAY */\r
+CREATE TABLE TMP_ARCHIVING_BYTEARRAY\r
+( BYTEARRAY_ID_ varchar(64) not null,\r
+ PROC_INST_ID_ varchar(64)\r
+);\r
+CREATE INDEX AI_TMP_ARCH_BYTEARRAY_BAID ON TMP_ARCHIVING_BYTEARRAY(BYTEARRAY_ID_);\r
+\r
+\r
+/*--#1 ARCHIVE_ACT_HI_PROCINST; */\r
+create TABLE ARCHIVE_ACT_HI_PROCINST\r
+AS ( select * from ACT_HI_PROCINST where 1=0);\r
+\r
+create index AI_HI_PROCINST_END_TIME on ARCHIVE_ACT_HI_PROCINST(END_TIME_);\r
+ALTER TABLE ARCHIVE_ACT_HI_PROCINST ADD CONSTRAINT ARCHIVE_ACT_HI_PROCINST_UQ UNIQUE ( PROC_INST_ID_);\r
+\r
+/*--#2 ARCHIVE_ACT_HI_ACTINST; */\r
+create TABLE ARCHIVE_ACT_HI_ACTINST\r
+AS ( select * from ACT_HI_ACTINST where 1=0);\r
+\r
+create index AI_HI_ACTINST_PROC_INST_ID on ARCHIVE_ACT_HI_ACTINST(PROC_INST_ID_);\r
+create index AI_HI_ACTINST_END_TIME on ARCHIVE_ACT_HI_ACTINST(END_TIME_);\r
+\r
+/*--#3 ARCHIVE_ACT_HI_TASKINST; */\r
+create TABLE ARCHIVE_ACT_HI_TASKINST\r
+AS ( select * from ACT_HI_TASKINST where 1=0);\r
+\r
+create index AI_HI_TASKINST_PROC_INST_ID on ARCHIVE_ACT_HI_TASKINST(PROC_INST_ID_);\r
+create index AI_HI_TASKINST_END_TIME on ARCHIVE_ACT_HI_TASKINST(END_TIME_);\r
+\r
+/*--#4 ARCHIVE_ACT_HI_VARINST; */\r
+create TABLE ARCHIVE_ACT_HI_VARINST\r
+AS ( select * from ACT_HI_VARINST where 1=0);\r
+\r
+create index AI_HI_VARINST_PROC_INST_ID on ARCHIVE_ACT_HI_VARINST(PROC_INST_ID_);\r
+\r
+/*--#5 ARCHIVE_ACT_HI_DETAIL; */\r
+create TABLE ARCHIVE_ACT_HI_DETAIL\r
+AS ( select * from ACT_HI_DETAIL where 1=0);\r
+\r
+create index AI_HI_DETAIL_PROC_INST_ID on ARCHIVE_ACT_HI_DETAIL(PROC_INST_ID_);\r
+create index AI_HI_DETAIL_TIME on ARCHIVE_ACT_HI_DETAIL(TIME_);\r
+\r
+/*--#6 ARCHIVE_ACT_HI_COMMENT; */\r
+create TABLE ARCHIVE_ACT_HI_COMMENT\r
+AS ( select * from ACT_HI_COMMENT where 1=0);\r
+\r
+create index AI_HI_COMMENT_PROC_INST_ID on ARCHIVE_ACT_HI_COMMENT(PROC_INST_ID_);\r
+create index AI_HI_COMMENT_TIME on ARCHIVE_ACT_HI_COMMENT(TIME_);\r
+\r
+/*--#7 ARCHIVE_ACT_HI_ATTACHMENT; */\r
+create TABLE ARCHIVE_ACT_HI_ATTACHMENT\r
+AS ( select * from ACT_HI_ATTACHMENT where 1=0);\r
+\r
+create index AI_HI_ATTACHMENT_PROC_INST_ID on ARCHIVE_ACT_HI_ATTACHMENT(PROC_INST_ID_);\r
+\r
+/*--#8 ARCHIVE_ACT_HI_OP_LOG; */\r
+create TABLE ARCHIVE_ACT_HI_OP_LOG\r
+AS ( select * from ACT_HI_OP_LOG where 1=0);\r
+\r
+create index AI_HI_OP_LOG_PROC_INST_ID on ARCHIVE_ACT_HI_OP_LOG(PROC_INST_ID_);\r
+create index AI_HI_OP_LOG_TIMESTAMP on ARCHIVE_ACT_HI_OP_LOG(TIMESTAMP_);\r
+\r
+/*--#9 ARCHIVE_ACT_HI_INCIDENT; */\r
+create TABLE ARCHIVE_ACT_HI_INCIDENT\r
+AS ( select * from ACT_HI_INCIDENT where 1=0);\r
+\r
+create index AI_HI_INCIDENT_PROC_INST_ID on ARCHIVE_ACT_HI_INCIDENT(PROC_INST_ID_);\r
+\r
+/*--#10 ARCHIVE_ACT_GE_BYTEARRAY; */\r
+create TABLE ARCHIVE_ACT_GE_BYTEARRAY\r
+AS ( select * from ACT_GE_BYTEARRAY where 1=0);\r
+\r
+create index AI_GE_BYTEARRAY_ID_ on ARCHIVE_ACT_GE_BYTEARRAY(ID_);\r
+\r
+/* -----------------------------------------------------------------------------\r
+Extend a ARCHIVE: Table by two attributes: STAT_EXECUTION_ID, STAT_EXECUTION_TS \r
+*/\r
+ \r
+/*\r
+--TEMPLATE:\r
+alter table ARCHIVE_%TableName%\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_%TableName%_EXE_ID ON ARCHIVE_%TableName%(STAT_EXECUTION_ID);\r
+*/\r
+\r
+\r
+/*--#1 ACT_HI_PROCINST */\r
+alter table ARCHIVE_ACT_HI_PROCINST\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_PROCINST_EXE_ID ON ARCHIVE_ACT_HI_PROCINST(STAT_EXECUTION_ID);\r
+\r
+/*--#2 ACT_HI_ACTINST */\r
+alter table ARCHIVE_ACT_HI_ACTINST\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_ACTINST_EXE_ID ON ARCHIVE_ACT_HI_ACTINST(STAT_EXECUTION_ID);\r
+\r
+/*--#3 ACT_HI_TASKINST */\r
+alter table ARCHIVE_ACT_HI_TASKINST\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_TASKINST_EXE_ID ON ARCHIVE_ACT_HI_TASKINST(STAT_EXECUTION_ID);\r
+\r
+/*--#4 ACT_HI_VARINST */\r
+alter table ARCHIVE_ACT_HI_VARINST\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_VARINST_EXE_ID ON ARCHIVE_ACT_HI_VARINST(STAT_EXECUTION_ID);\r
+\r
+/*--#5 ACT_HI_DETAIL */\r
+alter table ARCHIVE_ACT_HI_DETAIL\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_DETAIL_EXE_ID ON ARCHIVE_ACT_HI_DETAIL(STAT_EXECUTION_ID);\r
+\r
+/*--#6 ACT_HI_COMMENT */\r
+alter table ARCHIVE_ACT_HI_COMMENT\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_COMMENT_EXE_ID ON ARCHIVE_ACT_HI_COMMENT(STAT_EXECUTION_ID);\r
+\r
+/*--#7 ACT_HI_ATTACHMENT */\r
+alter table ARCHIVE_ACT_HI_ATTACHMENT\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_ATTACHMENT_EXE_ID ON ARCHIVE_ACT_HI_ATTACHMENT(STAT_EXECUTION_ID);\r
+\r
+/*--#8 ACT_HI_OP_LOG */\r
+alter table ARCHIVE_ACT_HI_OP_LOG\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_OP_LOG_EXE_ID ON ARCHIVE_ACT_HI_OP_LOG(STAT_EXECUTION_ID);\r
+\r
+/*--#9 ACT_HI_INCIDENT */\r
+alter table ARCHIVE_ACT_HI_INCIDENT\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_HI_INCIDENT_EXE_ID ON ARCHIVE_ACT_HI_INCIDENT(STAT_EXECUTION_ID);\r
+\r
+/*--#10 ACT_GE_BYTEARRAY */\r
+alter table ARCHIVE_ACT_GE_BYTEARRAY\r
+ add (STAT_EXECUTION_ID bigint, STAT_EXECUTION_TS timestamp(0) DEFAULT CURRENT_TIMESTAMP );\r
+CREATE INDEX AI_ACT_GE_BYTEARRAY_EXE_ID ON ARCHIVE_ACT_GE_BYTEARRAY(STAT_EXECUTION_ID);\r
+\r
+\r
+/* -- Next Val as a user defined function needed only in MariaDB--*/\r
+DROP FUNCTION IF EXISTS NextVal;\r
+ DELIMITER //\r
+ CREATE FUNCTION NextVal (vname VARCHAR(30))\r
+ RETURNS INT\r
+ BEGIN\r
+ -- Retrieve and update in single statement\r
+ UPDATE _sequences\r
+ SET next = next + 1\r
+ WHERE name = vname;\r
+ \r
+ RETURN (SELECT next FROM _sequences LIMIT 1);\r
+ END\r
+ //\r
+ DELIMITER ;\r
+ \r
+/* -- History tables for use in archive procedure, there is no array type in MariaDB --*/\r
+Create Table Camunda_Hi_Tables (id_ MEDIUMINT NOT NULL AUTO_INCREMENT,\r
+ TableName_ varchar(80) NOT NULL,\r
+ PRIMARY KEY (id_));\r
+ \r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_PROCINST');\r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_ACTINST');\r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_TASKINST');\r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_VARINST');\r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_DETAIL');\r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_COMMENT');\r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_ATTACHMENT');\r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_OP_LOG');\r
+Insert Into Camunda_Hi_Tables(TableName_) Values ('ACT_HI_INCIDENT');\r
+\r
+/*-- log table --*/\r
+CREATE TABLE TMPLOGTABLE (LogMessage Varchar(700));\r
+\r
+\r
+/* -- Below user defined functions and procedures needed only in MariaDB, they are in-built in Oracle --*/\r
+/*-- Create a sequence SP */\r
+DROP PROCEDURE IF EXISTS CreateSequence;\r
+ DELIMITER //\r
+ CREATE PROCEDURE CreateSequence (name VARCHAR(30), start INT, inc INT)\r
+ BEGIN\r
+ -- Create a table to store sequences\r
+ CREATE TABLE IF NOT EXISTS _sequences\r
+ (\r
+ name VARCHAR(70) NOT NULL UNIQUE,\r
+ next INT NOT NULL,\r
+ inc INT NOT NULL\r
+ );\r
+ \r
+ -- Add the new sequence\r
+ INSERT INTO _sequences VALUES (name, start, inc); \r
+ END\r
+ //\r
+ DELIMITER ;\r
+\r
+/*--------------------------------------------------------------------------------------------------\r
+ Add Meta to Archive\r
+ -------------------------------------------------------------------------------------------------- */\r
+\r
+/* Create STAT_EXECUTION_SEQ: each Archive Entry has a same Execution ID during one Archiving Run */\r
+CALL CreateSequence('STAT_EXECUTION_SEQ', 1, 1);\r
-<UpdateAAIVfModuleRequest>
- <vnf-id>skask</vnf-id>
- <vf-module-id>supercool</vf-module-id>
- <heat-stack-id>slowburn</heat-stack-id>
- <orchestration-status>complete</orchestration-status>
- <volume-group-id>78987</volume-group-id>
- <persona-model-id>introvert</persona-model-id>
- <persona-model-version>3.14</persona-model-version>
- <contrail-service-instance-fqdn>myhost.appl.com</contrail-service-instance-fqdn>
+<UpdateAAIVfModuleRequest>\r
+ <vnf-id>skask</vnf-id>\r
+ <vf-module-id>supercool</vf-module-id>\r
+ <heat-stack-id>slowburn</heat-stack-id>\r
+ <orchestration-status>complete</orchestration-status>\r
+ <volume-group-id>78987</volume-group-id>\r
+ <persona-model-id>introvert</persona-model-id>\r
+ <persona-model-version>3.14</persona-model-version>\r
+ <contrail-service-instance-fqdn>myhost.appl.com</contrail-service-instance-fqdn>\r
</UpdateAAIVfModuleRequest>
\ No newline at end of file
<orchestration-status>pending-create</orchestration-status>\r
<is-base-vf-module>false</is-base-vf-module>\r
<resource-version>330-89</resource-version>\r
- <persona-model-id>introvert</persona-model-id>\r
- <persona-model-version>2.0</persona-model-version>\r
+ <model-invariant-id>introvert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
<relationship-list>\r
<relationship>\r
<related-to>volume-group</related-to>\r
# Example to override default version for a resource:\r
#mso.workflow.default.aai.vce.version=6\r
#mso.workflow.default.aai.v6.vce.uri=/aai/v6/network/vces/vce\r
-\r
+mso.workflow.global.default.aai.namespace=http://org.openecomp.aai.inventory/\r
mso.workflow.global.default.aai.version=8\r
mso.workflow.default.aai.cloud-region.version=9\r
mso.workflow.default.aai.generic-vnf.version=9\r
log.debug.GenericGetService=true\r
log.debug.sdncAdapter=true\r
log.debug.UpdateNetworkInstanceInfra=true\r
-log.debug.VnfAdapterRestV1=true
\ No newline at end of file
+log.debug.VnfAdapterRestV1=true\r
+log.debug.GenericGetNetwork=true\r
+log.debug.GenericGetVnf=true\r
+log.debug.GenericDeleteService=true\r
+log.debug.GenericDeleteNetwork=true\r
+log.debug.GenericDeleteVnf=true\r
+log.debug.vnfAdapterCreateV1=true\r
+log.debug.vnfAdapterRestV1=true
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import org.codehaus.jackson.map.annotate.JsonRootName;\r
+\r
+@JsonRootName("allottedResource")\r
+public class AllottedResource extends ResourceDecomposition {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+\r
+ /*\r
+ * set resourceType for this object\r
+ */\r
+ public AllottedResource(){\r
+ resourceType = "allottedResource";\r
+ }\r
+\r
+ /*\r
+ * fields specific to VNF resource type\r
+ */\r
+ private String allottedResourceType;\r
+ private String allottedResourceRole;\r
+ \r
+ /*\r
+ * GET and SET\r
+ */\r
+ public String getAllottedResourceType() {\r
+ return allottedResourceType;\r
+ }\r
+ public void setAllottedResourceType(String allottedResourceType) {\r
+ this.allottedResourceType = allottedResourceType;\r
+ }\r
+ public String getAllottedResourceRole() {\r
+ return allottedResourceRole;\r
+ }\r
+ public void setAllottedResourceRole(String allottedResourceRole) {\r
+ this.allottedResourceRole = allottedResourceRole;\r
+ }\r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import java.io.Serializable;\r
+import java.util.List;\r
+\r
+public class HomingSolution extends JsonWrapper implements Serializable {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+ \r
+ private String infraServiceInstanceId;\r
+ private String aicCloudRegionId;\r
+ private String ucpeId;\r
+ private List<String> entitlementPool;\r
+ private List<String> entitlementKeyGroup;\r
+ \r
+ /*\r
+ * GET && SET\r
+ */\r
+ public String getInfraServiceInstanceId() {\r
+ return infraServiceInstanceId;\r
+ }\r
+ public void setInfraServiceInstanceId(String infraServiceInstanceId) {\r
+ this.infraServiceInstanceId = infraServiceInstanceId;\r
+ }\r
+ public String getAicCloudRegionId() {\r
+ return aicCloudRegionId;\r
+ }\r
+ public void setAicCloudRegionId(String aicCloudRegionId) {\r
+ this.aicCloudRegionId = aicCloudRegionId;\r
+ }\r
+ public String getUcpeId() {\r
+ return ucpeId;\r
+ }\r
+ public void setUcpeId(String ucpeId) {\r
+ this.ucpeId = ucpeId;\r
+ }\r
+ public List<String> getEntitlementPool() {\r
+ return entitlementPool;\r
+ }\r
+ public void setEntitlementPool(List<String> entitlementPool) {\r
+ this.entitlementPool = entitlementPool;\r
+ }\r
+ public List getEntitlementKeyGroup() {\r
+ return entitlementKeyGroup;\r
+ }\r
+ public void setEntitlementKeyGroup(List entitlementKeyGroup) {\r
+ this.entitlementKeyGroup = entitlementKeyGroup;\r
+ }\r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import java.io.Serializable;\r
+\r
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;\r
+\r
+@JsonIgnoreProperties\r
+public class InstanceData extends JsonWrapper implements Serializable {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+ \r
+ private String instanceId;\r
+ private String instanceName;\r
+ private HomingSolution homingSolution;\r
+ \r
+ /*\r
+ * GET && SET\r
+ */\r
+ public String getInstanceId() {\r
+ return instanceId;\r
+ }\r
+ public void setInstanceId(String instanceId) {\r
+ this.instanceId = instanceId;\r
+ }\r
+ public String getInstanceName() {\r
+ return instanceName;\r
+ }\r
+ public void setInstanceName(String instanceName) {\r
+ this.instanceName = instanceName;\r
+ }\r
+ public HomingSolution getHomingSolution() {\r
+ return homingSolution;\r
+ }\r
+ public void setHomingSolution(HomingSolution homingSolution) {\r
+ this.homingSolution = homingSolution;\r
+ }\r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import java.io.IOException;\r
+import java.util.List;\r
+\r
+import org.codehaus.jackson.JsonGenerationException;\r
+import org.codehaus.jackson.JsonParseException;\r
+import org.codehaus.jackson.map.JsonMappingException;\r
+import org.codehaus.jackson.map.ObjectMapper;\r
+import org.codehaus.jackson.map.ObjectWriter;\r
+import org.json.JSONException;\r
+import org.json.JSONObject;\r
+\r
+import com.fasterxml.jackson.annotation.JsonInclude;\r
+import com.fasterxml.jackson.annotation.JsonInclude.Include;\r
+import com.fasterxml.jackson.databind.DeserializationFeature;\r
+\r
+\r
+//import org.codehaus.jackson.map.SerializationConfig.Feature;\r
+import org.codehaus.jackson.map.DeserializationConfig.Feature;\r
+import org.codehaus.jackson.map.annotate.JsonSerialize;\r
+\r
+/**\r
+ * Wrapper encapsulates needed JSON functionality \r
+ * to be extended by MSO service decomposition objects\r
+ * providing ways to convert to and from JSON\r
+ * \r
+ * @author \r
+ *\r
+ */\r
+@JsonInclude(Include.NON_NULL)\r
+public abstract class JsonWrapper {\r
+\r
+ @JsonInclude(Include.NON_NULL)\r
+ public String toJsonString(){\r
+ \r
+ \r
+\r
+ String jsonString = "";\r
+ //convert with Jackson\r
+ ObjectMapper mapper = new ObjectMapper();\r
+ mapper.enable(org.codehaus.jackson.map.SerializationConfig.Feature.WRAP_ROOT_VALUE);\r
+ \r
+ mapper.setSerializationInclusion(JsonSerialize.Inclusion.NON_NULL);\r
+ \r
+ ObjectWriter ow = mapper.writer().withDefaultPrettyPrinter();\r
+ try {\r
+ jsonString = ow.writeValueAsString(this);\r
+ } catch (JsonGenerationException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (JsonMappingException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (IOException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ }\r
+ return jsonString;\r
+ }\r
+ \r
+ @JsonInclude(Include.NON_NULL)\r
+ public JSONObject toJsonObject(){\r
+\r
+ ObjectMapper mapper = new ObjectMapper();\r
+ // mapper.configure(SerializationConfig.Feature.WRAP_ROOT_VALUE, true);\r
+ //mapper.enable(SerializationFeature.WRAP_ROOT_VALUE);\r
+\r
+ mapper.enable(org.codehaus.jackson.map.SerializationConfig.Feature.WRAP_ROOT_VALUE);\r
+ // mapper.enable(org.codehaus.jackson.map.DeserializationConfig.Feature.UNWRAP_ROOT_VALUE);\r
+ JSONObject json = new JSONObject();\r
+ try {\r
+ json = new JSONObject(mapper.writeValueAsString(this));\r
+ } catch (JsonGenerationException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (JsonMappingException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (JSONException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (IOException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ }\r
+ return json; \r
+ }\r
+ \r
+ public String listToJson(List list) {\r
+ ObjectMapper mapper = new ObjectMapper();\r
+ mapper.enable(org.codehaus.jackson.map.SerializationConfig.Feature.WRAP_ROOT_VALUE);\r
+ \r
+ String jsonString = "";\r
+ try {\r
+ jsonString = mapper.writeValueAsString(list);\r
+ } catch (JsonGenerationException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (JsonMappingException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (IOException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ }\r
+ \r
+ return jsonString;\r
+ }\r
+ \r
+ /**\r
+ * Method to construct Service Decomposition object converting\r
+ * JSON structure\r
+ * \r
+ * @param jsonString - input in JSON format confirming ServiceDecomposition\r
+ * @return - ServiceDecomposition object\r
+ */\r
+ public ServiceDecomposition JsonToServiceDecomposition(String jsonString) {\r
+ \r
+ ServiceDecomposition serviceDecomposition = new ServiceDecomposition();\r
+ ObjectMapper om = new ObjectMapper();\r
+ om.configure(Feature.UNWRAP_ROOT_VALUE, true);\r
+ \r
+ try {\r
+ serviceDecomposition = om.readValue(jsonString, ServiceDecomposition.class);\r
+ } catch (JsonParseException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (JsonMappingException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ } catch (IOException e) {\r
+ // TODO Auto-generated catch block\r
+ e.printStackTrace();\r
+ }\r
+ \r
+ return serviceDecomposition;\r
+ }\r
+ \r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import java.io.Serializable;\r
+\r
+import org.codehaus.jackson.map.annotate.JsonRootName;\r
+\r
+@JsonRootName("modelInfo")\r
+public class ModelInfo extends JsonWrapper implements Serializable {\r
+\r
+ /**\r
+ * \r
+ */\r
+ private static final long serialVersionUID = 1L;\r
+ \r
+ private String modelName = "";\r
+ private String modelUuid = "";\r
+ private String modelInvariantId = "";\r
+ private String modelVersion = "";\r
+ //additionally on resource level\r
+ private String modelCustomizationUuid = "";\r
+ private String modelInstanceName = "";\r
+ \r
+ //TODO - those were present in original "modelInfo" object structure. Confirm.\r
+ private String modelCustomizationName = "";\r
+ private String modelVersionId = "";\r
+ private String modelType = "";\r
+ \r
+ public String getModelName() {\r
+ return modelName;\r
+ }\r
+ public void setModelName(String modelName) {\r
+ this.modelName = modelName;\r
+ }\r
+ public String getModelUuid() {\r
+ return modelUuid;\r
+ }\r
+ public void setModelUuid(String modelUuid) {\r
+ this.modelUuid = modelUuid;\r
+ }\r
+ public String getModelInvariantId() {\r
+ return modelInvariantId;\r
+ }\r
+ public void setModelInvariantId(String modelInvariantId) {\r
+ this.modelInvariantId = modelInvariantId;\r
+ }\r
+ public String getModelVersion() {\r
+ return modelVersion;\r
+ }\r
+ public void setModelVersion(String modelVersion) {\r
+ this.modelVersion = modelVersion;\r
+ }\r
+ public String getModelCustomizationUuid() {\r
+ return modelCustomizationUuid;\r
+ }\r
+ public void setModelCustomizationUuid(String modelCustomizationUuid) {\r
+ this.modelCustomizationUuid = modelCustomizationUuid;\r
+ }\r
+ public String getModelInstanceName() {\r
+ return modelInstanceName;\r
+ }\r
+ public void setModelInstanceName(String modelInstanceName) {\r
+ this.modelInstanceName = modelInstanceName;\r
+ }\r
+ public String getModelCustomizationName() {\r
+ return modelCustomizationName;\r
+ }\r
+ public void setModelCustomizationName(String modelCustomizationName) {\r
+ this.modelCustomizationName = modelCustomizationName;\r
+ }\r
+ public String getModelVersionId() {\r
+ return modelVersionId;\r
+ }\r
+ public void setModelVersionId(String modelVersionId) {\r
+ this.modelVersionId = modelVersionId;\r
+ }\r
+ public String getModelType() {\r
+ return modelType;\r
+ }\r
+ public void setModelType(String modelType) {\r
+ this.modelType = modelType;\r
+ }\r
+ \r
+ //TODO add convenience methods\r
+ \r
+ \r
+ //TODO - complete this manual\r
+ public String toString(){\r
+\r
+ String jsonString = "";\r
+ \r
+ //can try building manually\r
+ jsonString = "{" +\r
+ "\"modelName\":\"" + getModelName() + "\"," +\r
+ "\"modelUuid\":\"" + getModelUuid() + "\"" +\r
+ "\"modelInvariantId\":\"" + getModelInvariantId() + "\"" +\r
+ "}";\r
+ \r
+\r
+ return jsonString;\r
+ } \r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import org.codehaus.jackson.map.annotate.JsonRootName;\r
+\r
+@JsonRootName("vfModule")\r
+public class ModuleResource extends ResourceDecomposition {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+\r
+ /*\r
+ * set resourceType for this object\r
+ */\r
+ public ModuleResource(){\r
+ resourceType = "module";\r
+ }\r
+ \r
+ /*\r
+ * fields specific to VF Module resource type\r
+ */\r
+ private String vfModuleType;\r
+ private boolean hasVolumeGroup;\r
+ private boolean isBase;\r
+ private String vfModuleLabel;\r
+ private int initialCount;\r
+ \r
+ /*\r
+ * GET && SET\r
+ */\r
+ public boolean getIsBase() {\r
+ return isBase;\r
+ }\r
+ public void setIsBase(boolean isBase) {\r
+ this.isBase = isBase;\r
+ }\r
+ public String getVfModuleLabel() {\r
+ return vfModuleLabel;\r
+ }\r
+ public void setVfModuleLabel(String vfModuleLabel) {\r
+ this.vfModuleLabel = vfModuleLabel;\r
+ }\r
+ public int getInitialCount() {\r
+ return initialCount;\r
+ }\r
+ public void setInitialCount(int initialCount) {\r
+ this.initialCount = initialCount;\r
+ }\r
+ public String getVfModuleType() {\r
+ return vfModuleType;\r
+ }\r
+ public void setVfModuleType(String vfModuleType) {\r
+ this.vfModuleType = vfModuleType;\r
+ }\r
+ public boolean isHasVolumeGroup() {\r
+ return hasVolumeGroup;\r
+ }\r
+ public void setHasVolumeGroup(boolean hasVolumeGroup) {\r
+ this.hasVolumeGroup = hasVolumeGroup;\r
+ }\r
+ \r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import org.codehaus.jackson.map.annotate.JsonRootName;\r
+\r
+\r
+/**\r
+ * Encapsulates Network resource data set\r
+ * @author\r
+ *\r
+ */\r
+@JsonRootName("networkResource")\r
+public class NetworkResource extends ResourceDecomposition {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+ /*\r
+ * set resourceType for this object\r
+ */\r
+ public NetworkResource(){\r
+ resourceType = "networkResource";\r
+ }\r
+ /*\r
+ * fields specific to VNF resource type\r
+ */\r
+ private String networkType;\r
+ private String networkRole;\r
+ \r
+ /*\r
+ * GET and SET\r
+ */\r
+ public String getNetworkType() {\r
+ return networkType;\r
+ }\r
+ public void setNetworkType(String networkType) {\r
+ this.networkType = networkType;\r
+ }\r
+ public String getNetworkRole() {\r
+ return networkRole;\r
+ }\r
+ public void setNetworkRole(String networkRole) {\r
+ this.networkRole = networkRole;\r
+ }\r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import java.io.Serializable;\r
+\r
+import org.codehaus.jackson.annotate.JsonIgnore;\r
+import org.codehaus.jackson.annotate.JsonIgnoreProperties;\r
+import org.codehaus.jackson.map.annotate.JsonRootName;\r
+\r
+/**\r
+ * Abstract superclass for all individual decomposition resources\r
+ * \r
+ * @author\r
+ *\r
+ */\r
+//@JsonIgnoreProperties\r
+public abstract class ResourceDecomposition extends JsonWrapper implements Serializable {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+ \r
+ protected String resourceType; // Enum of vnf or network or allotted resource\r
+ private ModelInfo modelInfo;\r
+\r
+ //private List modules;\r
+ private InstanceData instanceData = new InstanceData();\r
+ \r
+ // GET and SET\r
+ public ModelInfo getModelInfo() {\r
+ return modelInfo;\r
+ }\r
+ public void setModelInfo(ModelInfo modelInfo) {\r
+ this.modelInfo = modelInfo;\r
+ }\r
+\r
+ public InstanceData getInstanceData() {\r
+ return instanceData;\r
+ }\r
+ public void setInstanceData(InstanceData instanceData) {\r
+ this.instanceData = instanceData;\r
+ }\r
+ public void setResourceType(String resourceType) {\r
+ this.resourceType = resourceType;\r
+ }\r
+\r
+ //Utility methods\r
+ @JsonIgnore\r
+ public ModelInfo getResourceModel() {\r
+ return modelInfo;\r
+ }\r
+ @JsonIgnore\r
+ public String getResourceInstanceId() {\r
+ return this.getInstanceData().getInstanceId();\r
+ }\r
+ @JsonIgnore\r
+ public String getResourceInstanceName() {\r
+ return this.getInstanceData().getInstanceName();\r
+ }\r
+// @JsonIgnore\r
+// public String getResourceHomingSolution() {\r
+// }\r
+ \r
+ public void setResourceInstanceId(String newInstanceId){\r
+ this.getInstanceData().setInstanceId(newInstanceId);\r
+ }\r
+ public void setResourceInstanceName(String newInstanceName){\r
+ this.getInstanceData().setInstanceName(newInstanceName);\r
+ }\r
+// @JsonIgnore\r
+// public String setResourceHomingSolution() {\r
+// }\r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+\r
+import java.io.Serializable;\r
+import java.util.ArrayList;\r
+import java.util.List;\r
+import org.codehaus.jackson.annotate.JsonIgnore;\r
+import org.codehaus.jackson.map.annotate.JsonRootName;\r
+import com.fasterxml.jackson.annotation.JsonProperty;\r
+\r
+import org.json.JSONObject;\r
+\r
+\r
+\r
+/**\r
+ * Service Decomposition Structure\r
+ * This Java object contains service information:\r
+ * - Service model info\r
+ * - list of VNF resource's decompositon\r
+ * - list of network resource's decompositon\r
+ * - list of allotted resource's decompositon\r
+ */\r
+@JsonRootName(value = "serviceResources")\r
+//@JsonTypeInfo(include=As.WRAPPER_OBJECT, use=Id.NAME)\r
+public class ServiceDecomposition extends JsonWrapper implements Serializable {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+\r
+ @JsonProperty("modelInfo")\r
+ private ModelInfo modelInfo;\r
+ private ServiceInstanceData serviceInstanceData;\r
+ @JsonProperty("vnfResource")\r
+ private List <VnfResource> vnfResources;\r
+ @JsonProperty("networkResource")\r
+ private List <NetworkResource> networkResources;\r
+ @JsonProperty("allottedResource")\r
+ private List <AllottedResource> allottedResources;\r
+ \r
+ public ServiceDecomposition () {\r
+ super();\r
+ }\r
+ \r
+ public ServiceDecomposition (ModelInfo modelInfo, ServiceInstanceData serviceInstanceData, List <VnfResource> vnfResources, List <NetworkResource> networkResources, List <AllottedResource> allottedResources ) {\r
+ //TODO provide constructor implementation\r
+// this.modelInfo = modelInfo;\r
+// this.serviceInstanceData = serviceInstanceData;\r
+// this.vnfResources = vnfResources;\r
+// this.networkResources = networkResources;\r
+// this.allottedResources = allottedResources;\r
+ \r
+ }\r
+ \r
+ public ServiceDecomposition (String catalogRestOutput, String serviceInstanceId) {\r
+ //TODO provide constructor implementation\r
+ \r
+ this.modelInfo = this.JsonToServiceDecomposition(catalogRestOutput).getModelInfo();\r
+ this.vnfResources = this.JsonToServiceDecomposition(catalogRestOutput).getServiceVnfs();\r
+ this.allottedResources = this.JsonToServiceDecomposition(catalogRestOutput).getServiceAllottedResources();\r
+ this.networkResources = this.JsonToServiceDecomposition(catalogRestOutput).getServiceNetworks();\r
+ this.serviceInstanceData = new ServiceInstanceData();\r
+ this.serviceInstanceData.setInstanceId(serviceInstanceId);\r
+ }\r
+ public ServiceDecomposition (JSONObject catalogRestOutput, String serviceInstanceId) {\r
+ //TODO provide constructor implementation\r
+ }\r
+ //GET and SET\r
+ public ModelInfo getModelInfo() {\r
+ return modelInfo;\r
+ }\r
+ public void setModelInfo(ModelInfo modelInfo) {\r
+ this.modelInfo = modelInfo;\r
+ }\r
+ public ServiceInstanceData getServiceInstanceData() {\r
+ return serviceInstanceData;\r
+ }\r
+ public void setServiceInstanceData(ServiceInstanceData serviceInstanceData) {\r
+ this.serviceInstanceData = serviceInstanceData;\r
+ }\r
+ public List<VnfResource> getServiceVnfs() {\r
+ return vnfResources;\r
+ }\r
+ public void setServiceVnfs(List<VnfResource> vnfResources) {\r
+ this.vnfResources = vnfResources;\r
+ }\r
+ public List<NetworkResource> getServiceNetworks() {\r
+ return networkResources;\r
+ }\r
+ public void setServiceNetworks(List<NetworkResource> networkResources) {\r
+ this.networkResources = networkResources;\r
+ }\r
+ public List<AllottedResource> getServiceAllottedResources() {\r
+ return allottedResources;\r
+ }\r
+ public void setServiceAllottedResources(List<AllottedResource> allottedResources) {\r
+ this.allottedResources = allottedResources;\r
+ }\r
+ \r
+ // methods to add to the list\r
+ public void addVnfResource(VnfResource vnfResource) {\r
+ if (vnfResources == null){\r
+ vnfResources = new ArrayList<VnfResource>();\r
+ }\r
+ this.vnfResources.add(vnfResource);\r
+ }\r
+ public void addNetworkResource(NetworkResource networkResource) {\r
+ if (networkResources == null){\r
+ networkResources = new ArrayList<NetworkResource>();\r
+ }\r
+ this.networkResources.add(networkResource);\r
+ }\r
+ public void addAllottedResource(AllottedResource allottedResource) {\r
+ if (allottedResources == null){\r
+ allottedResources = new ArrayList<AllottedResource>();\r
+ }\r
+ this.allottedResources.add(allottedResource);\r
+ }\r
+ \r
+// //TODO - IF NEEDED, update below methods to return one resource decomposition by (?) ID, not index - used temporarily\r
+// public VnfResource getnfResource(int index) {\r
+// \r
+//// Iterator<VnfResource> iter = vnfResources.iterator();\r
+//// while (iter.hasNext()) {\r
+//// VnfResource vnfResource = iter.next();\r
+//// vnfResource.getModelInfo().getModelInvariantId();\r
+//// }\r
+// return this.vnfResources.get(index);\r
+// }\r
+// public NetworkResource getNetworkResource( int index) {\r
+// return this.networkResources.get(index);\r
+// }\r
+// public AllottedResource getAllottedResource(int index) {\r
+// return this.allottedResources.get(index);\r
+// }\r
+ \r
+ @JsonIgnore\r
+ public List<ResourceDecomposition> getServiceResources(){\r
+ ArrayList serviceResources = new ArrayList();\r
+ serviceResources.addAll(this.getServiceNetworks());\r
+ serviceResources.addAll(this.getServiceVnfs());\r
+ serviceResources.addAll(this.getServiceAllottedResources());\r
+ return serviceResources;\r
+ }\r
+ \r
+ @JsonIgnore\r
+ public String getServiceResourcesJsonString(){\r
+ StringBuffer serviceResourcesJsonStringBuffer = new StringBuffer();\r
+ serviceResourcesJsonStringBuffer.append(listToJson((this.getServiceNetworks())));\r
+ serviceResourcesJsonStringBuffer.append(listToJson((this.getServiceVnfs())));\r
+ serviceResourcesJsonStringBuffer.append(listToJson((this.getServiceAllottedResources())));\r
+ return serviceResourcesJsonStringBuffer.toString();\r
+ }\r
+ \r
+ //return String representation of JSON\r
+ @Override\r
+ public String toString(){\r
+ return "string representation";\r
+ }\r
+\r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import java.io.Serializable;\r
+\r
+public class ServiceInstanceData extends JsonWrapper implements Serializable {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+ private String instanceId;\r
+ private String instanceName;\r
+ \r
+ public String getInstanceId() {\r
+ return instanceId;\r
+ }\r
+ public void setInstanceId(String instanceId) {\r
+ this.instanceId = instanceId;\r
+ }\r
+ public String getInstanceName() {\r
+ return instanceName;\r
+ }\r
+ public void setInstanceName(String instanceName) {\r
+ this.instanceName = instanceName;\r
+ }\r
+}\r
--- /dev/null
+package org.openecomp.mso.bpmn.core.decomposition;\r
+\r
+import java.util.ArrayList;\r
+import java.util.List;\r
+\r
+import org.codehaus.jackson.annotate.JsonIgnore;\r
+import org.codehaus.jackson.map.annotate.JsonRootName;\r
+\r
+import com.fasterxml.jackson.annotation.JsonProperty;\r
+\r
+/**\r
+ * Encapsulates VNF resource data set\r
+ * @author\r
+ *\r
+ */\r
+@JsonRootName("vnfResource")\r
+public class VnfResource extends ResourceDecomposition {\r
+\r
+ private static final long serialVersionUID = 1L;\r
+\r
+ /*\r
+ * set resourceType for this object\r
+ */\r
+ public VnfResource(){\r
+ resourceType = "vnfResource";\r
+ }\r
+ \r
+ /*\r
+ * fields specific to VNF resource type\r
+ */\r
+ @JsonProperty("vfModules")\r
+ private List <ModuleResource> vfModules;\r
+ private String vnfType;\r
+\r
+ /*\r
+ * GET and SET\r
+ */\r
+ public List<ModuleResource> getVfModules() {\r
+ return vfModules;\r
+ }\r
+ public void setModules(List<ModuleResource> moduleResources) {\r
+ this.vfModules = moduleResources;\r
+ }\r
+ public String getVnfType() {\r
+ return vnfType;\r
+ }\r
+ public void setVnfType(String vnfType) {\r
+ this.vnfType = vnfType;\r
+ }\r
+ \r
+ /*\r
+ * GET accessors per design requirements\r
+ */\r
+ \r
+ /**\r
+ * Returns a list of all VfModule objects.\r
+ * Base module is first entry in the list\r
+ * @return ordered list of ModuleResources objects\r
+ */\r
+ @JsonIgnore\r
+ public List<ModuleResource> getAllVfModuleObjects(){\r
+ \r
+ for (int i = 0; i < vfModules.size(); i++) {\r
+ ModuleResource moduleResource = vfModules.get(i);\r
+ if (moduleResource.getIsBase()){\r
+ vfModules.remove(moduleResource);\r
+ vfModules.add(0,moduleResource);\r
+ }\r
+ }\r
+ return vfModules;\r
+ }\r
+ \r
+ /**\r
+ * \r
+ * @return Returns JSON list of all VfModule structures.\r
+ */\r
+ @JsonIgnore\r
+ public String getAllVfModulesJson(){\r
+ \r
+ return listToJson(vfModules);\r
+ }\r
+ \r
+ // methods to add to the list\r
+ public void addVfModule(ModuleResource moduleResource) {\r
+ if (vfModules == null){\r
+ vfModules = new ArrayList<ModuleResource>();\r
+ }\r
+ this.vfModules.add(moduleResource);\r
+ }\r
+ \r
+}\r
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-\r
-import static org.apache.commons.lang3.StringUtils.*;\r
-import groovy.xml.XmlUtil\r
-import groovy.json.*\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.rest.APIResponse\r
-\r
-import java.util.UUID;\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution\r
-import org.apache.commons.lang3.*\r
-import org.apache.commons.codec.binary.Base64;\r
-import org.springframework.web.util.UriUtils\r
-\r
-/**\r
- * This groovy class supports the <class>CreateServiceInstance.bpmn</class> process.\r
- * AlaCarte flow for 1702 ServiceInstance Create\r
- *\r
- */\r
-public class CreateServiceInstance extends AbstractServiceTaskProcessor {\r
- String Prefix="CRESI_"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils()\r
-\r
- public void preProcessRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- String msg = ""\r
- utils.log("DEBUG", " *** preProcessRequest() *** ", isDebugEnabled)\r
-\r
- try {\r
-\r
- String siRequest = execution.getVariable("bpmnRequest")\r
- utils.logAudit(siRequest)\r
-\r
- String requestId = execution.getVariable("mso-request-id")\r
- execution.setVariable("msoRequestId", requestId)\r
- utils.log("DEBUG", "Input Request:" + siRequest + " reqId:" + requestId, isDebugEnabled)\r
-\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- if (isBlank(serviceInstanceId)) {\r
- serviceInstanceId = UUID.randomUUID().toString()\r
- }\r
- utils.log("DEBUG", "Generated new Service Instance:" + serviceInstanceId, isDebugEnabled)\r
- serviceInstanceId = UriUtils.encode(serviceInstanceId,"UTF-8")\r
- execution.setVariable("serviceInstanceId", serviceInstanceId)\r
-\r
- //subscriberInfo\r
- String globalSubscriberId = jsonUtil.getJsonValue(siRequest, "requestDetails.subscriberInfo.globalSubscriberId")\r
- if (isBlank(globalSubscriberId)) {\r
- msg = "Input globalSubscriberId' is null"\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- } else {\r
- execution.setVariable("globalSubscriberId", globalSubscriberId)\r
- }\r
-\r
- //requestInfo\r
- execution.setVariable("source", jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.source"))\r
- execution.setVariable("serviceInstanceName", jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.instanceName"))\r
- execution.setVariable("disableRollback", jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.suppressRollback"))\r
- String productFamilyId = jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.productFamilyId")\r
- if (isBlank(productFamilyId))\r
- {\r
- msg = "Input productFamilyId is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- //exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- } else {\r
- execution.setVariable("productFamilyId", productFamilyId)\r
- }\r
-\r
- //modelInfo\r
- String serviceModelInfo = jsonUtil.getJsonValue(siRequest, "requestDetails.modelInfo")\r
- if (isBlank(serviceModelInfo)) {\r
- msg = "Input serviceModelInfo is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- } else\r
- {\r
- execution.setVariable("serviceModelInfo", serviceModelInfo)\r
- }\r
-\r
- utils.log("DEBUG", "modelInfo" + serviceModelInfo, isDebugEnabled)\r
-\r
- //requestParameters\r
- String subscriptionServiceType = jsonUtil.getJsonValue(siRequest, "requestDetails.requestParameters.subscriptionServiceType")\r
- if (isBlank(subscriptionServiceType)) {\r
- msg = "Input subscriptionServiceType is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- } else {\r
- execution.setVariable("subscriptionServiceType", subscriptionServiceType)\r
- }\r
-\r
- //TODO\r
- //execution.setVariable("serviceInputParams", jsonUtil.getJsonValue(siRequest, "requestDetails.requestParameters.userParams"))\r
- //execution.setVariable("failExists", true)\r
-\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception ex){\r
- msg = "Exception in preProcessRequest " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
- }\r
- utils.log("DEBUG"," ***** Exit preProcessRequest *****", isDebugEnabled)\r
- }\r
-\r
- public void sendSyncResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** sendSyncResponse *** ", isDebugEnabled)\r
-\r
- try {\r
- String requestId = execution.getVariable("msoRequestId")\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- // RESTResponse for API Handler (APIH) Reply Task\r
- String createServiceRestRequest = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()\r
- utils.log("DEBUG", " sendSyncResponse to APIH:" + "\n" + createServiceRestRequest, isDebugEnabled)\r
- sendWorkflowResponse(execution, 202, createServiceRestRequest)\r
- execution.setVariable("sentSyncResponse", true)\r
-\r
- } catch (Exception ex) {\r
- String msg = "Exceptuion in sendSyncResponse:" + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
- }\r
- utils.log("DEBUG"," ***** Exit sendSyncResopnse *****", isDebugEnabled)\r
- }\r
-\r
-\r
- public void sendSyncError (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** sendSyncError *** ", isDebugEnabled)\r
-\r
- try {\r
- String errorMessage = ""\r
- if (execution.getVariable("WorkflowException") instanceof WorkflowException) {\r
- WorkflowException wfe = execution.getVariable("WorkflowException")\r
- errorMessage = wfe.getErrorMessage()\r
- } else {\r
- errorMessage = "Sending Sync Error."\r
- }\r
-\r
- String buildworkflowException =\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts;
+
+import static org.apache.commons.lang3.StringUtils.*;
+import groovy.xml.XmlUtil
+import groovy.json.*
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.rest.APIResponse
+
+import java.util.UUID;
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution
+import org.apache.commons.lang3.*
+import org.apache.commons.codec.binary.Base64;
+import org.springframework.web.util.UriUtils
+
+/**
+ * This groovy class supports the <class>CreateServiceInstance.bpmn</class> process.
+ * AlaCarte flow for 1702 ServiceInstance Create
+ *
+ */
+public class CreateGenericALaCarteServiceInstance extends AbstractServiceTaskProcessor {
+ String Prefix="CRESI_"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils()
+
+ public void preProcessRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ String msg = ""
+ utils.log("DEBUG", " *** preProcessRequest() *** ", isDebugEnabled)
+
+ try {
+
+ String siRequest = execution.getVariable("bpmnRequest")
+ utils.logAudit(siRequest)
+
+ String requestId = execution.getVariable("mso-request-id")
+ execution.setVariable("msoRequestId", requestId)
+ utils.log("DEBUG", "Input Request:" + siRequest + " reqId:" + requestId, isDebugEnabled)
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ if (isBlank(serviceInstanceId)) {
+ serviceInstanceId = UUID.randomUUID().toString()
+ }
+ utils.log("DEBUG", "Generated new Service Instance:" + serviceInstanceId, isDebugEnabled)
+ serviceInstanceId = UriUtils.encode(serviceInstanceId,"UTF-8")
+ execution.setVariable("serviceInstanceId", serviceInstanceId)
+
+ //subscriberInfo
+ String globalSubscriberId = jsonUtil.getJsonValue(siRequest, "requestDetails.subscriberInfo.globalSubscriberId")
+ if (isBlank(globalSubscriberId)) {
+ msg = "Input globalSubscriberId' is null"
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ } else {
+ execution.setVariable("globalSubscriberId", globalSubscriberId)
+ }
+
+ //requestInfo
+ execution.setVariable("source", jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.source"))
+ execution.setVariable("serviceInstanceName", jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.instanceName"))
+ execution.setVariable("disableRollback", jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.suppressRollback"))
+ String productFamilyId = jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.productFamilyId")
+ if (isBlank(productFamilyId))
+ {
+ msg = "Input productFamilyId is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ //exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ } else {
+ execution.setVariable("productFamilyId", productFamilyId)
+ }
+
+ //modelInfo
+ String serviceModelInfo = jsonUtil.getJsonValue(siRequest, "requestDetails.modelInfo")
+ if (isBlank(serviceModelInfo)) {
+ msg = "Input serviceModelInfo is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ } else
+ {
+ execution.setVariable("serviceModelInfo", serviceModelInfo)
+ }
+
+ utils.log("DEBUG", "modelInfo" + serviceModelInfo, isDebugEnabled)
+
+ //requestParameters
+ String subscriptionServiceType = jsonUtil.getJsonValue(siRequest, "requestDetails.requestParameters.subscriptionServiceType")
+ if (isBlank(subscriptionServiceType)) {
+ msg = "Input subscriptionServiceType is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ } else {
+ execution.setVariable("subscriptionServiceType", subscriptionServiceType)
+ }
+
+ //TODO
+ //execution.setVariable("serviceInputParams", jsonUtil.getJsonValue(siRequest, "requestDetails.requestParameters.userParams"))
+ //execution.setVariable("failExists", true)
+
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception ex){
+ msg = "Exception in preProcessRequest " + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG"," ***** Exit preProcessRequest *****", isDebugEnabled)
+ }
+
+ public void sendSyncResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** sendSyncResponse *** ", isDebugEnabled)
+
+ try {
+ String requestId = execution.getVariable("msoRequestId")
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ // RESTResponse for API Handler (APIH) Reply Task
+ String createServiceRestRequest = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()
+ utils.log("DEBUG", " sendSyncResponse to APIH:" + "\n" + createServiceRestRequest, isDebugEnabled)
+ sendWorkflowResponse(execution, 202, createServiceRestRequest)
+ execution.setVariable("sentSyncResponse", true)
+
+ } catch (Exception ex) {
+ String msg = "Exceptuion in sendSyncResponse:" + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG"," ***** Exit sendSyncResopnse *****", isDebugEnabled)
+ }
+
+
+ public void sendSyncError (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** sendSyncError *** ", isDebugEnabled)
+
+ try {
+ String errorMessage = ""
+ if (execution.getVariable("WorkflowException") instanceof WorkflowException) {
+ WorkflowException wfe = execution.getVariable("WorkflowException")
+ errorMessage = wfe.getErrorMessage()
+ } else {
+ errorMessage = "Sending Sync Error."
+ }
+
+ String buildworkflowException =
"""<aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>7000</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>"""\r
-\r
- utils.logAudit(buildworkflowException)\r
- sendWorkflowResponse(execution, 500, buildworkflowException)\r
-\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", " Sending Sync Error Activity Failed. " + "\n" + ex.getMessage(), isDebugEnabled)\r
- }\r
-\r
- }\r
-\r
- public void prepareCompletionRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** prepareCompletion *** ", isDebugEnabled)\r
-\r
- try {\r
- String requestId = execution.getVariable("msoRequestId")\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- String source = execution.getVariable("source")\r
- \r
- String msoCompletionRequest =\r
+ <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>7000</aetgt:ErrorCode>
+ </aetgt:WorkflowException>"""
+
+ utils.logAudit(buildworkflowException)
+ sendWorkflowResponse(execution, 500, buildworkflowException)
+
+ } catch (Exception ex) {
+ utils.log("DEBUG", " Sending Sync Error Activity Failed. " + "\n" + ex.getMessage(), isDebugEnabled)
+ }
+
+ }
+
+ public void prepareCompletionRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** prepareCompletion *** ", isDebugEnabled)
+
+ try {
+ String requestId = execution.getVariable("msoRequestId")
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ String source = execution.getVariable("source")
+
+ String msoCompletionRequest =
"""<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
xmlns:ns="http://org.openecomp/mso/request/types/v1">\r
<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>CREATE</action>\r
- <source>${source}</source>\r
- </request-info>\r
- <status-message>Service Instance was created successfully.</status-message>\r
- <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>\r
- <mso-bpel-name>CreateServiceInstance</mso-bpel-name>\r
- </aetgt:MsoCompletionRequest>"""\r
-\r
- // Format Response\r
- String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)\r
-\r
- execution.setVariable("completionRequest", xmlMsoCompletionRequest)\r
- utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)\r
-\r
- } catch (Exception ex) {\r
- String msg = " Exception in prepareCompletion:" + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
- }\r
- utils.log("DEBUG", "*** Exit prepareCompletionRequest ***", isDebugEnabled)\r
- }\r
-\r
- public void prepareFalloutRequest(Execution execution){\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** prepareFalloutRequest *** ", isDebugEnabled)\r
-\r
- try {\r
- WorkflowException wfex = execution.getVariable("WorkflowException")\r
- utils.log("DEBUG", " Input Workflow Exception: " + wfex.toString(), isDebugEnabled)\r
- String requestId = execution.getVariable("msoRequestId")\r
- String source = execution.getVariable("source")\r
- String requestInfo =\r
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>${source}</source>
+ </request-info>
+ <status-message>Service Instance was created successfully.</status-message>
+ <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>
+ <mso-bpel-name>CreateGenericALaCarteServiceInstance</mso-bpel-name>
+ </aetgt:MsoCompletionRequest>"""
+
+ // Format Response
+ String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)
+
+ execution.setVariable("completionRequest", xmlMsoCompletionRequest)
+ utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)
+
+ } catch (Exception ex) {
+ String msg = " Exception in prepareCompletion:" + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG", "*** Exit prepareCompletionRequest ***", isDebugEnabled)
+ }
+
+ public void prepareFalloutRequest(Execution execution){
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** prepareFalloutRequest *** ", isDebugEnabled)
+
+ try {
+ WorkflowException wfex = execution.getVariable("WorkflowException")
+ utils.log("DEBUG", " Input Workflow Exception: " + wfex.toString(), isDebugEnabled)
+ String requestId = execution.getVariable("msoRequestId")
+ String source = execution.getVariable("source")
+ String requestInfo =
"""<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>CREATE</action>\r
- <source>${source}</source>\r
- </request-info>"""\r
-\r
- String falloutRequest = exceptionUtil.processMainflowsBPMNException(execution, requestInfo)\r
- execution.setVariable("falloutRequest", falloutRequest)\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", "Exception prepareFalloutRequest:" + ex.getMessage(), isDebugEnabled)\r
- String errorException = " Bpmn error encountered in CreateServiceInstance flow. FalloutHandlerRequest, buildErrorResponse() - " + ex.getMessage()\r
- String requestId = execution.getVariable("msoRequestId")\r
- String falloutRequest =\r
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>${source}</source>
+ </request-info>"""
+
+ String falloutRequest = exceptionUtil.processMainflowsBPMNException(execution, requestInfo)
+ execution.setVariable("falloutRequest", falloutRequest)
+ } catch (Exception ex) {
+ utils.log("DEBUG", "Exception prepareFalloutRequest:" + ex.getMessage(), isDebugEnabled)
+ String errorException = " Bpmn error encountered in CreateGenericALaCarteServiceInstance flow. FalloutHandlerRequest, buildErrorResponse() - " + ex.getMessage()
+ String requestId = execution.getVariable("msoRequestId")
+ String falloutRequest =
"""<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>CREATE</action>\r
- <source>VID</source>\r
- </request-info>\r
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>VID</source>
+ </request-info>
<aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorException}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>7000</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>\r
- </aetgt:FalloutHandlerRequest>"""\r
-\r
- execution.setVariable("falloutRequest", falloutRequest)\r
- }\r
- utils.log("DEBUG", "*** Exit prepareFalloutRequest ***", isDebugEnabled)\r
- }\r
+ <aetgt:ErrorMessage>${errorException}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>7000</aetgt:ErrorCode>
+ </aetgt:WorkflowException>
+ </aetgt:FalloutHandlerRequest>"""
+
+ execution.setVariable("falloutRequest", falloutRequest)
+ }
+ utils.log("DEBUG", "*** Exit prepareFalloutRequest ***", isDebugEnabled)
+ }
}
\ No newline at end of file
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-\r
-import groovy.xml.XmlUtil\r
-import groovy.json.*\r
-\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse;\r
-import org.openecomp.mso.rest.RESTClient\r
-import org.openecomp.mso.rest.RESTConfig\r
-\r
-import java.util.UUID;\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution\r
-import org.json.JSONObject;\r
-import org.json.JSONArray;\r
-import org.apache.commons.lang3.*\r
-import org.apache.commons.codec.binary.Base64;\r
-import org.springframework.web.util.UriUtils;\r
-\r
-/**\r
- * This groovy class supports the <class>CreateGenericMacroServiceNetworkVnf.bpmn</class> process.\r
- *\r
- */\r
-public class CreateGenericMacroServiceNetworkVnf extends AbstractServiceTaskProcessor {\r
-\r
- String Prefix="CREVAS_"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils()\r
- CatalogDbUtils catalogDbUtils = new CatalogDbUtils()\r
-\r
- /**\r
- * This method is executed during the preProcessRequest task of the <class>CreateServiceInstance.bpmn</class> process.\r
- * @param execution\r
- */\r
- public InitializeProcessVariables(Execution execution){\r
- /* Initialize all the process variables in this block */\r
-\r
- execution.setVariable("createGenericMacroServiceNetworkVnfRequest", "")\r
- execution.setVariable("globalSubscriberId", "")\r
- execution.setVariable("serviceInstanceName", "")\r
- execution.setVariable("msoRequestId", "")\r
- execution.setVariable("CREVAS_NetworksCreatedCount", 0)\r
- execution.setVariable("CREVAS_VnfsCreatedCount", 0)\r
- execution.setVariable("productFamilyId", "")\r
- \r
- \r
- //TODO\r
- execution.setVariable("sdncVersion", "1702")\r
- }\r
-\r
- // **************************************************\r
- // Pre or Prepare Request Section\r
- // **************************************************\r
- /**\r
- * This method is executed during the preProcessRequest task of the <class>CreateServiceInstance.bpmn</class> process.\r
- * @param execution\r
- */\r
- public void preProcessRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- utils.log("DEBUG", " ***** Inside preProcessRequest CreateGenericMacroServiceNetworkVnf Request ***** ", isDebugEnabled)\r
-\r
- try {\r
- // initialize flow variables\r
- InitializeProcessVariables(execution)\r
-\r
- // check for incoming json message/input\r
- String createGenericMacroServiceNetworkVnfRequest = execution.getVariable("bpmnRequest")\r
- utils.logAudit(createGenericMacroServiceNetworkVnfRequest)\r
- execution.setVariable("createGenericMacroServiceNetworkVnfRequest", createGenericMacroServiceNetworkVnfRequest);\r
- println 'createGenericMacroServiceNetworkVnfRequest - ' + createGenericMacroServiceNetworkVnfRequest\r
-\r
- // extract requestId\r
- String requestId = execution.getVariable("mso-request-id")\r
- execution.setVariable("msoRequestId", requestId)\r
-\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
-\r
- if ((serviceInstanceId == null) || (serviceInstanceId.isEmpty())) {\r
- serviceInstanceId = UUID.randomUUID().toString()\r
- utils.log("DEBUG", " Generated new Service Instance: " + serviceInstanceId , isDebugEnabled)\r
- } else {\r
- utils.log("DEBUG", "Using provided Service Instance ID: " + serviceInstanceId , isDebugEnabled)\r
- }\r
-\r
- serviceInstanceId = UriUtils.encode(serviceInstanceId,"UTF-8")\r
- execution.setVariable("serviceInstanceId", serviceInstanceId)\r
- \r
- String requestAction = execution.getVariable("requestAction")\r
- execution.setVariable("requestAction", requestAction)\r
-\r
- String source = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.requestInfo.source")\r
- if ((source == null) || (source.isEmpty())) {\r
- execution.setVariable("source", "VID")\r
- } else {\r
- execution.setVariable("source", source)\r
- }\r
-\r
- // extract globalSubscriberId\r
- String globalSubscriberId = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.subscriberInfo.globalSubscriberId")\r
-\r
- // verify element global-customer-id is sent from JSON input, throw exception if missing\r
- if ((globalSubscriberId == null) || (globalSubscriberId.isEmpty())) {\r
- String dataErrorMessage = " Element 'globalSubscriberId' is missing. "\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)\r
-\r
- } else {\r
- execution.setVariable("globalSubscriberId", globalSubscriberId)\r
- execution.setVariable("globalCustomerId", globalSubscriberId)\r
- }\r
- \r
- // extract subscriptionServiceType\r
- String subscriptionServiceType = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.requestParameters.subscriptionServiceType")\r
- execution.setVariable("subscriptionServiceType", subscriptionServiceType)\r
- utils.log("DEBUG", "Incoming subscriptionServiceType is: " + subscriptionServiceType, isDebugEnabled)\r
-\r
- String suppressRollback = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.requestInfo.suppressRollback")\r
- execution.setVariable("disableRollback", suppressRollback)\r
- utils.log("DEBUG", "Incoming Suppress/Disable Rollback is: " + suppressRollback, isDebugEnabled)\r
- \r
- String productFamilyId = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.requestInfo.productFamilyId")\r
- execution.setVariable("productFamilyId", productFamilyId)\r
- utils.log("DEBUG", "Incoming productFamilyId is: " + productFamilyId, isDebugEnabled)\r
- \r
- //For Completion Handler & Fallout Handler\r
- String requestInfo =\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts;
+
+import groovy.xml.XmlUtil
+import groovy.json.*
+
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.decomposition.ModelInfo
+import org.openecomp.mso.bpmn.core.decomposition.NetworkResource
+import org.openecomp.mso.bpmn.core.decomposition.ServiceDecomposition
+import org.openecomp.mso.bpmn.core.decomposition.VnfResource
+import org.openecomp.mso.rest.APIResponse;
+import org.openecomp.mso.rest.RESTClient
+import org.openecomp.mso.rest.RESTConfig
+
+import java.util.UUID;
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution
+import org.json.JSONObject;
+import org.json.JSONArray;
+import org.apache.commons.lang3.*
+import org.apache.commons.codec.binary.Base64;
+import org.springframework.web.util.UriUtils;
+
+/**
+ * This groovy class supports the <class>CreateGenericMacroServiceNetworkVnf.bpmn</class> process.
+ *
+ */
+public class CreateGenericMacroServiceNetworkVnf extends AbstractServiceTaskProcessor {
+
+ String Prefix="CGMSNV_"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils()
+ CatalogDbUtils catalogDbUtils = new CatalogDbUtils()
+
+ /**
+ * This method is executed during the preProcessRequest task of the <class>CreateServiceInstance.bpmn</class> process.
+ * @param execution
+ */
+ public InitializeProcessVariables(Execution execution){
+ /* Initialize all the process variables in this block */
+
+ execution.setVariable("createViprServiceRequest", "")
+ execution.setVariable("globalSubscriberId", "")
+ execution.setVariable("serviceInstanceName", "")
+ execution.setVariable("msoRequestId", "")
+ execution.setVariable("CGMSNV_NetworksCreatedCount", 0)
+ execution.setVariable("CGMSNV_VnfsCreatedCount", 0)
+ execution.setVariable("productFamilyId", "")
+
+ //TODO
+ execution.setVariable("sdncVersion", "1707")
+ }
+
+ // **************************************************
+ // Pre or Prepare Request Section
+ // **************************************************
+ /**
+ * This method is executed during the preProcessRequest task of the <class>CreateServiceInstance.bpmn</class> process.
+ * @param execution
+ */
+ public void preProcessRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+
+ utils.log("DEBUG", " ***** Inside preProcessRequest CreateGenericMacroServiceNetworkVnf Request ***** ", isDebugEnabled)
+
+ try {
+ // initialize flow variables
+ InitializeProcessVariables(execution)
+
+ // check for incoming json message/input
+ String createViprServiceRequest = execution.getVariable("bpmnRequest")
+ utils.logAudit(createViprServiceRequest)
+ execution.setVariable("createViprServiceRequest", createViprServiceRequest);
+ println 'createViprServiceRequest - ' + createViprServiceRequest
+
+ // extract requestId
+ String requestId = execution.getVariable("mso-request-id")
+ execution.setVariable("msoRequestId", requestId)
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ if ((serviceInstanceId == null) || (serviceInstanceId.isEmpty())) {
+ serviceInstanceId = UUID.randomUUID().toString()
+ utils.log("DEBUG", " Generated new Service Instance: " + serviceInstanceId , isDebugEnabled)
+ } else {
+ utils.log("DEBUG", "Using provided Service Instance ID: " + serviceInstanceId , isDebugEnabled)
+ }
+
+ serviceInstanceId = UriUtils.encode(serviceInstanceId,"UTF-8")
+ execution.setVariable("serviceInstanceId", serviceInstanceId)
+
+ String requestAction = execution.getVariable("requestAction")
+ execution.setVariable("requestAction", requestAction)
+
+ String source = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.requestInfo.source")
+ if ((source == null) || (source.isEmpty())) {
+ execution.setVariable("source", "VID")
+ } else {
+ execution.setVariable("source", source)
+ }
+
+ // extract globalSubscriberId
+ String globalSubscriberId = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.subscriberInfo.globalSubscriberId")
+
+ // verify element global-customer-id is sent from JSON input, throw exception if missing
+ if ((globalSubscriberId == null) || (globalSubscriberId.isEmpty())) {
+ String dataErrorMessage = " Element 'globalSubscriberId' is missing. "
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
+
+ } else {
+ execution.setVariable("globalSubscriberId", globalSubscriberId)
+ execution.setVariable("globalCustomerId", globalSubscriberId)
+ }
+
+ // extract subscriptionServiceType
+ String subscriptionServiceType = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.requestParameters.subscriptionServiceType")
+ execution.setVariable("subscriptionServiceType", subscriptionServiceType)
+ utils.log("DEBUG", "Incoming subscriptionServiceType is: " + subscriptionServiceType, isDebugEnabled)
+
+ String suppressRollback = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.requestInfo.suppressRollback")
+ execution.setVariable("disableRollback", suppressRollback)
+ utils.log("DEBUG", "Incoming Suppress/Disable Rollback is: " + suppressRollback, isDebugEnabled)
+
+ String productFamilyId = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.requestInfo.productFamilyId")
+ execution.setVariable("productFamilyId", productFamilyId)
+ utils.log("DEBUG", "Incoming productFamilyId is: " + productFamilyId, isDebugEnabled)
+
+ //For Completion Handler & Fallout Handler
+ String requestInfo =
"""<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>CREATE</action>\r
- <source>${source}</source>\r
- </request-info>"""\r
-\r
- execution.setVariable("CREVAS_requestInfo", requestInfo)\r
- \r
- utils.log("DEBUG", " ***** Completed preProcessRequest CreateGenericMacroServiceNetworkVnf Request ***** ", isDebugEnabled)\r
-\r
- } catch (BpmnError e) {\r
- throw e;\r
-\r
- } catch (Exception ex){\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected from method preProcessRequest() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
-\r
- public void sendSyncResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- utils.log("DEBUG", " ***** Inside sendSyncResponse of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-\r
- try {\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- String requestId = execution.getVariable("mso-request-id")\r
-\r
- // RESTResponse (for API Handler (APIH) Reply Task)\r
- String syncResponse ="""{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()\r
-\r
- utils.log("DEBUG", " sendSynchResponse: xmlSyncResponse - " + "\n" + syncResponse, isDebugEnabled)\r
- sendWorkflowResponse(execution, 202, syncResponse)\r
-\r
- } catch (Exception ex) {\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected from method sendSyncResponse() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
-\r
- // *******************************\r
- // \r
- // *******************************\r
- public void prepareCreateServiceInstance(Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside prepareCreateServiceInstance of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-\r
- String createGenericMacroServiceNetworkVnfRequest = execution.getVariable("createGenericMacroServiceNetworkVnfRequest")\r
- String serviceModelInfo = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.modelInfo")\r
- execution.setVariable("serviceModelInfo", serviceModelInfo)\r
-\r
- String serviceInputParams = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.requestParameters")\r
- execution.setVariable("serviceInputParams", serviceInputParams)\r
- \r
- String serviceInstanceName = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.requestInfo.instanceName")\r
- execution.setVariable("serviceInstanceName", serviceInstanceName)\r
-\r
- utils.log("DEBUG", " ***** Completed prepareCreateServiceInstance of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareCreateService() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- \r
- public void postProcessServiceInstanceCreate (Execution execution){\r
- def method = getClass().getSimpleName() + '.postProcessServiceInstanceCreate(' +'execution=' + execution.getId() +')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
- \r
- String source = execution.getVariable("source")\r
- String requestId = execution.getVariable("mso-request-id")\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- String serviceInstanceName = execution.getVariable("serviceInstanceName")\r
- \r
- try {\r
-\r
- String payload = """\r
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>${source}</source>
+ </request-info>"""
+
+ execution.setVariable("CGMSNV_requestInfo", requestInfo)
+
+ utils.log("DEBUG", " ***** Completed preProcessRequest CreateGenericMacroServiceNetworkVnf Request ***** ", isDebugEnabled)
+
+ } catch (BpmnError e) {
+ throw e;
+
+ } catch (Exception ex){
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected from method preProcessRequest() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ public void sendSyncResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ utils.log("DEBUG", " ***** Inside sendSyncResponse of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ try {
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ String requestId = execution.getVariable("mso-request-id")
+
+ // RESTResponse (for API Handler (APIH) Reply Task)
+ String syncResponse ="""{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()
+
+ utils.log("DEBUG", " sendSynchResponse: xmlSyncResponse - " + "\n" + syncResponse, isDebugEnabled)
+ sendWorkflowResponse(execution, 202, syncResponse)
+
+ } catch (Exception ex) {
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected from method sendSyncResponse() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ //
+ // *******************************
+ public void prepareDecomposeService(Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside prepareDecomposeService of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ String createViprServiceRequest = execution.getVariable("createViprServiceRequest")
+ String serviceModelInfo = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.modelInfo")
+ execution.setVariable("serviceModelInfo", serviceModelInfo)
+
+ utils.log("DEBUG", " ***** Completed prepareDecomposeService of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareDecomposeService() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ //
+ // *******************************
+ public void prepareCreateServiceInstance(Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside prepareCreateServiceInstance of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ /*
+ * Service modelInfo is created in earlier step. This flow can use it as-is ... or, extract from DecompositionObject
+ * ServiceDecomposition serviceDecomposition = execution.getVariable("serviceDecomposition")
+ * ModelInfo modelInfo = serviceDecomposition.getModelInfo()
+ *
+ */
+ String createViprServiceRequest = execution.getVariable("createViprServiceRequest")
+ String serviceInputParams = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.requestParameters")
+ execution.setVariable("serviceInputParams", serviceInputParams)
+
+ String serviceInstanceName = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.requestInfo.instanceName")
+ execution.setVariable("serviceInstanceName", serviceInstanceName)
+
+ ServiceDecomposition serviceDecomposition = execution.getVariable("serviceDecomposition")
+ execution.setVariable("serviceDecompositionString", serviceDecomposition.toJsonString())
+
+ utils.log("DEBUG", " ***** Completed prepareCreateServiceInstance of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareCreateServiceInstance() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ public void postProcessServiceInstanceCreate (Execution execution){
+ def method = getClass().getSimpleName() + '.postProcessServiceInstanceCreate(' +'execution=' + execution.getId() +')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ String source = execution.getVariable("source")
+ String requestId = execution.getVariable("mso-request-id")
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ String serviceInstanceName = execution.getVariable("serviceInstanceName")
+
+ try {
+
+ String payload = """
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:req="http://org.openecomp.mso/requestsdb">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
- <req:updateInfraRequest>\r
- <requestId>${requestId}</requestId>\r
- <lastModifiedBy>BPEL</lastModifiedBy>\r
- <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>\r
- <serviceInstanceName>${serviceInstanceName}</serviceInstanceName>\r
- </req:updateInfraRequest>\r
- </soapenv:Body>\r
- </soapenv:Envelope>\r
- """\r
- execution.setVariable("CREVAS_setUpdateDbInstancePayload", payload)\r
- utils.logAudit("CREVAS_setUpdateDbInstancePayload: " + payload)\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- //println("CMSO_updateDBStatusToSuccessPayload --> " + execution.getVariable("CMSO_updateDBStatusToSuccessPayload"))\r
-\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2000, "Internal Error - Occured in" + method)\r
- }\r
- }\r
- \r
- \r
- public void callDBCatalog (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- utils.log("DEBUG", " ***** Inside callDBCatalog() of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
- \r
- try {\r
- \r
- // get variable within incoming json\r
- String createGenericMacroServiceNetworkVnfRequest = execution.getVariable("createGenericMacroServiceNetworkVnfRequest");\r
- \r
- String catalog_db_endpoint = execution.getVariable("URN_mso_catalog_db_endpoint")\r
- utils.log("DEBUG", "catalog_db_endpoint: "+catalog_db_endpoint, isDebugEnabled)\r
- \r
- String serviceModelInvariantId = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.modelInfo.modelInvariantId")\r
- String serviceModelVersion = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.modelInfo.modelVersion")\r
- utils.log("DEBUG", "getting network list ", isDebugEnabled)\r
- \r
- JSONArray networkList = catalogDbUtils.getAllNetworksByServiceModelInvariantUuidAndServiceModelVersion(catalog_db_endpoint, serviceModelInvariantId, serviceModelVersion)\r
-\r
- //utils.log("DEBUG", "got network list: "+ networkList.toString(), isDebugEnabled)\r
- execution.setVariable("networkList", networkList)\r
- execution.setVariable("networkListString", networkList.toString())\r
- \r
- networkList = execution.getVariable("networkList");\r
- utils.log("DEBUG", "networkList: "+ networkList, isDebugEnabled)\r
-\r
- if (networkList != null && networkList.length() > 0) {\r
-\r
- execution.setVariable("CREVAS_NetworksCount", networkList.length())\r
- utils.log("DEBUG", "networks to create: "+ networkList.length(), isDebugEnabled)\r
- } else {\r
- execution.setVariable("CREVAS_NetworksCount", 0)\r
- utils.log("DEBUG", "no networks to create based upon Catalog DB response", isDebugEnabled)\r
- } \r
- \r
- // VNFs\r
- JSONArray vnfList = catalogDbUtils.getAllVnfsByServiceModelInvariantUuidAndServiceModelVersion(catalog_db_endpoint, serviceModelInvariantId, serviceModelVersion)\r
- execution.setVariable("vnfList", vnfList) \r
- \r
- String vnfModelInfoString = ""\r
- if (vnfList != null && vnfList.length() > 0) {\r
- execution.setVariable("CREVAS_VNFsCount", vnfList.length())\r
- utils.log("DEBUG", "vnfs to create: "+ vnfList.length(), isDebugEnabled)\r
- JSONObject vnfModelInfo = vnfList.getJSONObject(0).getJSONObject("modelInfo")\r
- vnfModelInfoString = vnfModelInfo.toString()\r
- } else {\r
- execution.setVariable("CREVAS_VNFsCount", 0)\r
- utils.log("DEBUG", "no vnfs to create based upon Catalog DB response", isDebugEnabled)\r
- }\r
- \r
- execution.setVariable("vnfModelInfo", vnfModelInfoString)\r
- //utils.log("DEBUG", " vnfModelInfoString :" + vnfModelInfoString, isDebugEnabled)\r
-\r
- utils.log("DEBUG", " ***** Completed callDBCatalog() of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
- } catch (Exception ex) {\r
- sendSyncError(execution)\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. callDBCatalog() - " + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- // *******************************\r
- // Generate Network request Section\r
- // *******************************\r
- public void prepareNetworkCreate (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside preparenNetworkCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-\r
-// String disableRollback = execution.getVariable("disableRollback")\r
-// def backoutOnFailure = ""\r
-// if(disableRollback != null){\r
-// if ( disableRollback == true) {\r
-// backoutOnFailure = "false"\r
-// } else if ( disableRollback == false) {\r
-// backoutOnFailure = "true"\r
-// }\r
-// }\r
- //failIfExists - optional\r
-\r
- String createGenericMacroServiceNetworkVnfRequest = execution.getVariable("createGenericMacroServiceNetworkVnfRequest")\r
- \r
- JSONArray networkList = execution.getVariable("networkList")\r
- utils.log("DEBUG", "array networkList: "+ networkList, isDebugEnabled)\r
- \r
- if (networkList == null || networkList.length() < 1){\r
- networkList = new JSONArray(execution.getVariable("networkListString"))\r
- utils.log("DEBUG", "array from string networkList: "+ networkList, isDebugEnabled)\r
- }\r
- \r
- Integer networksCreatedCount = execution.getVariable("CREVAS_NetworksCreatedCount")\r
- String networkModelInfoString = ""\r
- \r
- if (networkList != null) {\r
- utils.log("DEBUG", " getting model info for network # :" + networksCreatedCount, isDebugEnabled)\r
- JSONObject networkModelInfo = networkList.getJSONObject(networksCreatedCount.intValue()).getJSONObject("modelInfo")\r
- networkModelInfoString = networkModelInfo.toString()\r
- } else {\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected number of networks to create - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- \r
- execution.setVariable("networkModelInfo", networkModelInfoString)\r
- utils.log("DEBUG", " networkModelInfoString :" + networkModelInfoString, isDebugEnabled)\r
- \r
-// String networkModelInfo = execution.getVariable("networkModelInfo")\r
- // extract cloud configuration\r
- String lcpCloudRegionId = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.cloudConfiguration.lcpCloudRegionId")\r
- execution.setVariable("lcpCloudRegionId", lcpCloudRegionId)\r
- utils.log("DEBUG","lcpCloudRegionId: "+ lcpCloudRegionId, isDebugEnabled)\r
- String tenantId = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.cloudConfiguration.tenantId")\r
- execution.setVariable("tenantId", tenantId)\r
- utils.log("DEBUG","tenantId: "+ tenantId, isDebugEnabled)\r
- \r
- String sdncVersion = execution.getVariable("sdncVersion")\r
- utils.log("DEBUG","sdncVersion: "+ sdncVersion, isDebugEnabled)\r
- \r
- JSONArray vnfList = execution.getVariable("vnfList")\r
- utils.log("DEBUG", "vnfList: "+ vnfList, isDebugEnabled)\r
- \r
- String vnfModelInfo = execution.getVariable("vnfModelInfo")\r
- utils.log("DEBUG", "vnfModelInfo: "+ vnfModelInfo, isDebugEnabled)\r
- \r
- networkList = execution.getVariable("networkList")\r
- utils.log("DEBUG", "networkList: "+ networkList, isDebugEnabled)\r
- \r
- utils.log("DEBUG", " ***** Completed preparenNetworkCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareNetworkCreate() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- // *******************************\r
- // Validate Network request Section -> increment count\r
- // *******************************\r
- public void validateNetworkCreate (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside validateNetworkCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-\r
- Integer networksCreatedCount = execution.getVariable("CREVAS_NetworksCreatedCount")\r
- networksCreatedCount++\r
- \r
- execution.setVariable("CREVAS_NetworksCreatedCount", networksCreatedCount)\r
- \r
- execution.setVariable("DCRENI_rollbackData"+networksCreatedCount, execution.getVariable("DCRENI_rollbackData"))\r
-\r
- utils.log("DEBUG", "networksCreatedCount: "+ networksCreatedCount, isDebugEnabled)\r
- utils.log("DEBUG", "DCRENI_rollbackData N : "+ execution.getVariable("DCRENI_rollbackData"+networksCreatedCount), isDebugEnabled)\r
- \r
- JSONArray vnfList = execution.getVariable("vnfList")\r
- utils.log("DEBUG", "vnfList: "+ vnfList, isDebugEnabled)\r
- \r
- String vnfModelInfo = execution.getVariable("vnfModelInfo")\r
- utils.log("DEBUG", "vnfModelInfo: "+ vnfModelInfo, isDebugEnabled)\r
- \r
- JSONArray networkList = execution.getVariable("networkList")\r
- utils.log("DEBUG", "networkList: "+ networkList, isDebugEnabled)\r
- \r
- utils.log("DEBUG", " ***** Completed validateNetworkCreate of CreateGenericMacroServiceNetworkVnf ***** "+" network # "+networksCreatedCount, isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method validateNetworkCreate() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- // *******************************\r
- // Generate Network request Section\r
- // *******************************\r
- public void prepareVnfAndModulesCreate (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside prepareVnfAndModulesCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-\r
- // String disableRollback = execution.getVariable("disableRollback")\r
- // def backoutOnFailure = ""\r
- // if(disableRollback != null){\r
- // if ( disableRollback == true) {\r
- // backoutOnFailure = "false"\r
- // } else if ( disableRollback == false) {\r
- // backoutOnFailure = "true"\r
- // }\r
- // }\r
- //failIfExists - optional\r
-\r
- String createGenericMacroServiceNetworkVnfRequest = execution.getVariable("createGenericMacroServiceNetworkVnfRequest")\r
- String productFamilyId = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.requestInfo.productFamilyId")\r
- execution.setVariable("productFamilyId", productFamilyId)\r
- utils.log("DEBUG","productFamilyId: "+ productFamilyId, isDebugEnabled)\r
-\r
- JSONArray vnfList = execution.getVariable("vnfList")\r
-\r
- Integer vnfsCreatedCount = execution.getVariable("CREVAS_VnfsCreatedCount")\r
- String vnfModelInfoString = null;\r
- \r
- if (vnfList != null && vnfList.length() > 0 ) {\r
- utils.log("DEBUG", "getting model info for vnf # " + vnfsCreatedCount, isDebugEnabled)\r
- JSONObject vnfModelInfo1 = vnfList.getJSONObject(0).getJSONObject("modelInfo")\r
- utils.log("DEBUG", "got 0 ", isDebugEnabled)\r
- JSONObject vnfModelInfo = vnfList.getJSONObject(vnfsCreatedCount.intValue()).getJSONObject("modelInfo")\r
- vnfModelInfoString = vnfModelInfo.toString()\r
- } else {\r
- //TODO: vnfList does not contain data. Need to investigate why ... . Fro VIPR use model stored\r
- vnfModelInfoString = execution.getVariable("vnfModelInfo")\r
- }\r
- \r
- utils.log("DEBUG", " vnfModelInfoString :" + vnfModelInfoString, isDebugEnabled)\r
- \r
- // extract cloud configuration\r
- String lcpCloudRegionId = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.cloudConfiguration.lcpCloudRegionId")\r
- execution.setVariable("lcpCloudRegionId", lcpCloudRegionId)\r
- utils.log("DEBUG","lcpCloudRegionId: "+ lcpCloudRegionId, isDebugEnabled)\r
- String tenantId = jsonUtil.getJsonValue(createGenericMacroServiceNetworkVnfRequest, "requestDetails.cloudConfiguration.tenantId")\r
- execution.setVariable("tenantId", tenantId)\r
- utils.log("DEBUG","tenantId: "+ tenantId, isDebugEnabled)\r
- \r
- String sdncVersion = execution.getVariable("sdncVersion")\r
- utils.log("DEBUG","sdncVersion: "+ sdncVersion, isDebugEnabled)\r
-\r
- utils.log("DEBUG", " ***** Completed prepareVnfAndModulesCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareVnfAndModulesCreate() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
-\r
- // *******************************\r
- // Validate Vnf request Section -> increment count\r
- // *******************************\r
- public void validateVnfCreate (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside validateVnfCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-\r
- Integer vnfsCreatedCount = execution.getVariable("CREVAS_VnfsCreatedCount")\r
- vnfsCreatedCount++\r
- \r
- execution.setVariable("CREVAS_VnfsCreatedCount", vnfsCreatedCount)\r
- \r
- utils.log("DEBUG", " ***** Completed validateVnfCreate of CreateGenericMacroServiceNetworkVnf ***** "+" vnf # "+vnfsCreatedCount, isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method validateVnfCreate() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- // *******************************\r
- // Validate Network request Section -> decrement count\r
- // *******************************\r
- public void validateNetworkRollback (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside validateNetworkRollback of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-\r
- Integer networksCreatedCount = execution.getVariable("CREVAS_NetworksCreatedCount")\r
- networksCreatedCount--\r
- \r
- execution.setVariable("CREVAS_NetworksCreatedCount", networksCreatedCount)\r
- \r
- execution.setVariable("DCRENI_rollbackData", execution.getVariable("DCRENI_rollbackData"+networksCreatedCount))\r
- \r
- utils.log("DEBUG", " ***** Completed validateNetworkRollback of CreateGenericMacroServiceNetworkVnf ***** "+" network # "+networksCreatedCount, isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method validateNetworkRollback() - " + ex.getMessage()\r
- //exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- execution.setVariable("CREVAS_NetworksCreatedCount", 0)\r
- utils.log("ERROR", exceptionMessage, true)\r
- }\r
- }\r
- // *******************************\r
- // Build DB request Section\r
- // *******************************\r
-// public void prepareDBRequest (Execution execution) {\r
-// def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-//\r
-// try {\r
-// utils.log("DEBUG", " ***** Inside prepareDBRequest of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-//\r
-// String requestId = execution.getVariable("CREVAS_requestId")\r
-// String statusMessage = "vIPR ATM Service Instance successfully created."\r
-// String serviceInstanceId = execution.getVariable("CREVAS_serviceInstanceId")\r
-//\r
-// //TODO - verify the format for Service Instance Create,\r
-// String dbRequest =\r
-// """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">\r
-// <soapenv:Header/>\r
-// <soapenv:Body>\r
+ <soapenv:Header/>
+ <soapenv:Body>
+ <req:updateInfraRequest>
+ <requestId>${requestId}</requestId>
+ <lastModifiedBy>BPEL</lastModifiedBy>
+ <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>
+ <serviceInstanceName>${serviceInstanceName}</serviceInstanceName>
+ </req:updateInfraRequest>
+ </soapenv:Body>
+ </soapenv:Envelope>
+ """
+ execution.setVariable("CGMSNV_setUpdateDbInstancePayload", payload)
+ utils.logAudit("CGMSNV_setUpdateDbInstancePayload: " + payload)
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ //println("CMSO_updateDBStatusToSuccessPayload --> " + execution.getVariable("CMSO_updateDBStatusToSuccessPayload"))
+
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2000, "Internal Error - Occured in" + method)
+ }
+ }
+
+
+ public void getDataFromDecomposition (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ utils.log("DEBUG", " ***** Inside getDataFromDecomposition() of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ try {
+
+ ServiceDecomposition serviceDecomposition = execution.getVariable("serviceDecomposition")
+
+ List<NetworkResource> networkList = serviceDecomposition.getServiceNetworks()
+
+ //utils.log("DEBUG", "got network list: "+ networkList.toString(), isDebugEnabled)
+ execution.setVariable("networkList", networkList)
+ execution.setVariable("networkListString", networkList.toString())
+
+ networkList = execution.getVariable("networkList");
+ utils.log("DEBUG", "networkList: "+ networkList, isDebugEnabled)
+
+ if (networkList != null && networkList.size() > 0) {
+
+ execution.setVariable("CGMSNV_NetworksCount", networkList.size())
+ utils.log("DEBUG", "networks to create: "+ networkList.size(), isDebugEnabled)
+ } else {
+ execution.setVariable("CGMSNV_NetworksCount", 0)
+ utils.log("DEBUG", "no networks to create based upon serviceDecomposition content", isDebugEnabled)
+ }
+
+ // VNFs
+ List<VnfResource> vnfList = serviceDecomposition.getServiceVnfs()
+ execution.setVariable("vnfList", vnfList)
+
+ String vnfModelInfoString = ""
+ if (vnfList != null && vnfList.size() > 0) {
+ execution.setVariable("CGMSNV_VNFsCount", vnfList.size())
+ utils.log("DEBUG", "vnfs to create: "+ vnfList.size(), isDebugEnabled)
+ ModelInfo vnfModelInfo = vnfList[0].getModelInfo()
+ String vnfModelInfoWithRoot = vnfModelInfo.toString()
+ vnfModelInfoString = jsonUtil.getJsonValue(vnfModelInfoWithRoot, "modelInfo")
+ } else {
+ execution.setVariable("CGMSNV_VNFsCount", 0)
+ utils.log("DEBUG", "no vnfs to create based upon Catalog DB response", isDebugEnabled)
+ }
+
+ execution.setVariable("vnfModelInfo", vnfModelInfoString)
+ //utils.log("DEBUG", " vnfModelInfoString :" + vnfModelInfoString, isDebugEnabled)
+
+ utils.log("DEBUG", " ***** Completed getDataFromDecomposition() of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ sendSyncError(execution)
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. getDataFromDecomposition() - " + ex.getMessage()
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ // Generate Network request Section
+ // *******************************
+ public void prepareNetworkCreate (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside preparenNetworkCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+// String disableRollback = execution.getVariable("disableRollback")
+// def backoutOnFailure = ""
+// if(disableRollback != null){
+// if ( disableRollback == true) {
+// backoutOnFailure = "false"
+// } else if ( disableRollback == false) {
+// backoutOnFailure = "true"
+// }
+// }
+ //failIfExists - optional
+
+ String createViprServiceRequest = execution.getVariable("createViprServiceRequest")
+
+ JSONArray networkList = execution.getVariable("networkList")
+ utils.log("DEBUG", "array networkList: "+ networkList, isDebugEnabled)
+
+ if (networkList == null || networkList.size() < 1){
+ networkList = new JSONArray(execution.getVariable("networkListString"))
+ utils.log("DEBUG", "array from string networkList: "+ networkList, isDebugEnabled)
+ }
+
+ Integer networksCreatedCount = execution.getVariable("CGMSNV_NetworksCreatedCount")
+ String networkModelInfoString = ""
+
+ if (networkList != null) {
+ utils.log("DEBUG", " getting model info for network # :" + networksCreatedCount, isDebugEnabled)
+ ModelInfo networkModelInfo = networkList[networksCreatedCount.intValue()].getModelInfo()
+ networkModelInfoString = networkModelInfo.toString()
+ } else {
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected number of networks to create - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+
+ execution.setVariable("networkModelInfo", networkModelInfoString)
+ utils.log("DEBUG", " networkModelInfoString :" + networkModelInfoString, isDebugEnabled)
+
+// String networkModelInfo = execution.getVariable("networkModelInfo")
+ // extract cloud configuration
+ String lcpCloudRegionId = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.cloudConfiguration.lcpCloudRegionId")
+ execution.setVariable("lcpCloudRegionId", lcpCloudRegionId)
+ utils.log("DEBUG","lcpCloudRegionId: "+ lcpCloudRegionId, isDebugEnabled)
+ String tenantId = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.cloudConfiguration.tenantId")
+ execution.setVariable("tenantId", tenantId)
+ utils.log("DEBUG","tenantId: "+ tenantId, isDebugEnabled)
+
+ String sdncVersion = execution.getVariable("sdncVersion")
+ utils.log("DEBUG","sdncVersion: "+ sdncVersion, isDebugEnabled)
+
+ List<VnfResource> vnfList = execution.getVariable("vnfList")
+ utils.log("DEBUG", "vnfList: "+ vnfList.toString(), isDebugEnabled)
+
+ String vnfModelInfo = execution.getVariable("vnfModelInfo")
+ utils.log("DEBUG", "vnfModelInfo: "+ vnfModelInfo, isDebugEnabled)
+
+ networkList = execution.getVariable("networkList")
+ utils.log("DEBUG", "networkList: "+ networkList, isDebugEnabled)
+
+ utils.log("DEBUG", " ***** Completed preparenNetworkCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareNetworkCreate() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ // Validate Network request Section -> increment count
+ // *******************************
+ public void validateNetworkCreate (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside validateNetworkCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ Integer networksCreatedCount = execution.getVariable("CGMSNV_NetworksCreatedCount")
+ networksCreatedCount++
+
+ execution.setVariable("CGMSNV_NetworksCreatedCount", networksCreatedCount)
+
+ execution.setVariable("DCRENI_rollbackData"+networksCreatedCount, execution.getVariable("DCRENI_rollbackData"))
+
+ utils.log("DEBUG", "networksCreatedCount: "+ networksCreatedCount, isDebugEnabled)
+ utils.log("DEBUG", "DCRENI_rollbackData N : "+ execution.getVariable("DCRENI_rollbackData"+networksCreatedCount), isDebugEnabled)
+
+ JSONArray vnfList = execution.getVariable("vnfList")
+ utils.log("DEBUG", "vnfList: "+ vnfList, isDebugEnabled)
+
+ String vnfModelInfo = execution.getVariable("vnfModelInfo")
+ utils.log("DEBUG", "vnfModelInfo: "+ vnfModelInfo, isDebugEnabled)
+
+ JSONArray networkList = execution.getVariable("networkList")
+ utils.log("DEBUG", "networkList: "+ networkList, isDebugEnabled)
+
+ utils.log("DEBUG", " ***** Completed validateNetworkCreate of CreateGenericMacroServiceNetworkVnf ***** "+" network # "+networksCreatedCount, isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method validateNetworkCreate() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ // Generate Network request Section
+ // *******************************
+ public void prepareVnfAndModulesCreate (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside prepareVnfAndModulesCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ // String disableRollback = execution.getVariable("disableRollback")
+ // def backoutOnFailure = ""
+ // if(disableRollback != null){
+ // if ( disableRollback == true) {
+ // backoutOnFailure = "false"
+ // } else if ( disableRollback == false) {
+ // backoutOnFailure = "true"
+ // }
+ // }
+ //failIfExists - optional
+
+ String createViprServiceRequest = execution.getVariable("createViprServiceRequest")
+ String productFamilyId = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.requestInfo.productFamilyId")
+ execution.setVariable("productFamilyId", productFamilyId)
+ utils.log("DEBUG","productFamilyId: "+ productFamilyId, isDebugEnabled)
+
+ List<VnfResource> vnfList = execution.getVariable("vnfList")
+
+ Integer vnfsCreatedCount = execution.getVariable("CGMSNV_VnfsCreatedCount")
+ String vnfModelInfoString = null;
+
+ if (vnfList != null && vnfList.size() > 0 ) {
+ utils.log("DEBUG", "getting model info for vnf # " + vnfsCreatedCount, isDebugEnabled)
+ ModelInfo vnfModelInfo1 = vnfList[0].getModelInfo()
+ utils.log("DEBUG", "got 0 ", isDebugEnabled)
+ ModelInfo vnfModelInfo = vnfList[vnfsCreatedCount.intValue()].getModelInfo()
+ vnfModelInfoString = vnfModelInfo.toString()
+ } else {
+ //TODO: vnfList does not contain data. Need to investigate why ... . Fro VIPR use model stored
+ vnfModelInfoString = execution.getVariable("vnfModelInfo")
+ }
+
+ utils.log("DEBUG", " vnfModelInfoString :" + vnfModelInfoString, isDebugEnabled)
+
+ // extract cloud configuration
+ String lcpCloudRegionId = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.cloudConfiguration.lcpCloudRegionId")
+ execution.setVariable("lcpCloudRegionId", lcpCloudRegionId)
+ utils.log("DEBUG","lcpCloudRegionId: "+ lcpCloudRegionId, isDebugEnabled)
+ String tenantId = jsonUtil.getJsonValue(createViprServiceRequest, "requestDetails.cloudConfiguration.tenantId")
+ execution.setVariable("tenantId", tenantId)
+ utils.log("DEBUG","tenantId: "+ tenantId, isDebugEnabled)
+
+ String sdncVersion = execution.getVariable("sdncVersion")
+ utils.log("DEBUG","sdncVersion: "+ sdncVersion, isDebugEnabled)
+
+ utils.log("DEBUG", " ***** Completed prepareVnfAndModulesCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareVnfAndModulesCreate() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ // Validate Vnf request Section -> increment count
+ // *******************************
+ public void validateVnfCreate (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside validateVnfCreate of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ Integer vnfsCreatedCount = execution.getVariable("CGMSNV_VnfsCreatedCount")
+ vnfsCreatedCount++
+
+ execution.setVariable("CGMSNV_VnfsCreatedCount", vnfsCreatedCount)
+
+ utils.log("DEBUG", " ***** Completed validateVnfCreate of CreateGenericMacroServiceNetworkVnf ***** "+" vnf # "+vnfsCreatedCount, isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method validateVnfCreate() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ // Validate Network request Section -> decrement count
+ // *******************************
+ public void validateNetworkRollback (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside validateNetworkRollback of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ Integer networksCreatedCount = execution.getVariable("CGMSNV_NetworksCreatedCount")
+ networksCreatedCount--
+
+ execution.setVariable("CGMSNV_NetworksCreatedCount", networksCreatedCount)
+
+ execution.setVariable("DCRENI_rollbackData", execution.getVariable("DCRENI_rollbackData"+networksCreatedCount))
+
+ utils.log("DEBUG", " ***** Completed validateNetworkRollback of CreateGenericMacroServiceNetworkVnf ***** "+" network # "+networksCreatedCount, isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method validateNetworkRollback() - " + ex.getMessage()
+ //exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ execution.setVariable("CGMSNV_NetworksCreatedCount", 0)
+ utils.log("ERROR", exceptionMessage, true)
+ }
+ }
+
+// public void extractServiceModelInfo (Execution execution) {
+// def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
+// String msg = ""
+// utils.log("DEBUG"," ***** extractServiceModelInfo of CreateGenericMacroServiceNetworkVnf *****", isDebugEnabled)
+//
+// try {
+//
+// // check for input
+// String requestId = execution.getVariable("msoRequestId")
+//
+// ServiceDecomposition serviceDecomposition = execution.getVariable("serviceDecomposition")
+// ModelInfo modelInfo = serviceDecomposition.getModelInfo()
+//
+// utils.log("DEBUG", "modelInfo: "+ modelInfo.toJsonString(), isDebugEnabled)
+// utils.log("DEBUG", "modelInfo: "+ modelInfo, isDebugEnabled)
+// execution.setVariable("serviceDecomposition", modelInfo)
+//
+// utils.log("DEBUG"," ***** Exit extractServiceModelInfo of CreateGenericMacroServiceNetworkVnf *****", isDebugEnabled)
+//
+// } catch (BpmnError e) {
+// throw e;
+// } catch (Exception ex){
+// msg = "Exception in extractServiceModelInfo " + ex.getMessage()
+// utils.log("DEBUG", msg, isDebugEnabled)
+// exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+// }
+// utils.log("DEBUG"," ***** Exit extractServiceModelInfo of DecomposeService *****", isDebugEnabled)
+// }
+
+ // *******************************
+ // Build DB request Section
+ // *******************************
+// public void prepareDBRequest (Execution execution) {
+// def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+//
+// try {
+// utils.log("DEBUG", " ***** Inside prepareDBRequest of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+//
+// String requestId = execution.getVariable("CGMSNV_requestId")
+// String statusMessage = "vIPR ATM Service Instance successfully created."
+// String serviceInstanceId = execution.getVariable("CGMSNV_serviceInstanceId")
+//
+// //TODO - verify the format for Service Instance Create,
+// String dbRequest =
+// """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
+// <soapenv:Header/>
+// <soapenv:Body>
// <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
-// <requestId>${requestId}</requestId>\r
-// <lastModifiedBy>BPMN</lastModifiedBy>\r
-// <statusMessage>${statusMessage}</statusMessage>\r
-// <responseBody></responseBody>\r
-// <requestStatus>COMPLETED</requestStatus>\r
-// <progress>100</progress>\r
-// <vnfOutputs/>\r
-// <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>\r
-// </ns:updateInfraRequest>\r
-// </soapenv:Body>\r
-// </soapenv:Envelope>"""\r
-//\r
-// String buildDeleteDBRequestAsString = utils.formatXml(dbRequest)\r
-// execution.setVariable("CREVAS_createDBRequest", buildDeleteDBRequestAsString)\r
-// utils.logAudit(buildDeleteDBRequestAsString)\r
-//\r
-// utils.log("DEBUG", " ***** Completed prepareDBRequest of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-// } catch (Exception ex) {\r
-// // try error in method block\r
-// String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareDBRequest() - " + ex.getMessage()\r
-// exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
-//\r
-// }\r
-//\r
-// }\r
-\r
-\r
- // *****************************************\r
- // Prepare Completion request Section\r
- // *****************************************\r
- public void postProcessResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- utils.log("DEBUG", " ***** Inside postProcessResponse of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
-\r
- try {\r
- String source = execution.getVariable("source")\r
- String requestId = execution.getVariable("mso-request-id")\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
-\r
- String msoCompletionRequest =\r
+// <requestId>${requestId}</requestId>
+// <lastModifiedBy>BPMN</lastModifiedBy>
+// <statusMessage>${statusMessage}</statusMessage>
+// <responseBody></responseBody>
+// <requestStatus>COMPLETED</requestStatus>
+// <progress>100</progress>
+// <vnfOutputs/>
+// <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>
+// </ns:updateInfraRequest>
+// </soapenv:Body>
+// </soapenv:Envelope>"""
+//
+// String buildDeleteDBRequestAsString = utils.formatXml(dbRequest)
+// execution.setVariable("CGMSNV_createDBRequest", buildDeleteDBRequestAsString)
+// utils.logAudit(buildDeleteDBRequestAsString)
+//
+// utils.log("DEBUG", " ***** Completed prepareDBRequest of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+// } catch (Exception ex) {
+// // try error in method block
+// String exceptionMessage = "Bpmn error encountered in CreateGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareDBRequest() - " + ex.getMessage()
+// exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+//
+// }
+//
+// }
+
+
+ // *****************************************
+ // Prepare Completion request Section
+ // *****************************************
+ public void postProcessResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ utils.log("DEBUG", " ***** Inside postProcessResponse of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ try {
+ String source = execution.getVariable("source")
+ String requestId = execution.getVariable("mso-request-id")
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ String msoCompletionRequest =
"""<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
xmlns:ns="http://org.openecomp/mso/request/types/v1">\r
<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>CREATE</action>\r
- <source>${source}</source>\r
- </request-info>\r
- <status-message>Service Instance has been created successfully via macro orchestration</status-message>\r
- <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>\r
- <mso-bpel-name>BPMN macro create</mso-bpel-name>\r
- </aetgt:MsoCompletionRequest>"""\r
-\r
- // Format Response\r
- String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)\r
-\r
- utils.logAudit(xmlMsoCompletionRequest)\r
- execution.setVariable("CREVAS_Success", true)\r
- execution.setVariable("CREVAS_CompleteMsoProcessRequest", xmlMsoCompletionRequest)\r
- utils.log("DEBUG", " SUCCESS flow, going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in CreateServiceInstance flow. Unexpected Error from method postProcessResponse() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
-\r
- public void preProcessRollback (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG"," ***** preProcessRollback of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
- try {\r
- \r
- Object workflowException = execution.getVariable("WorkflowException");\r
-\r
- if (workflowException instanceof WorkflowException) {\r
- utils.log("DEBUG", "Prev workflowException: " + workflowException.getErrorMessage(), isDebugEnabled)\r
- execution.setVariable("prevWorkflowException", workflowException);\r
- //execution.setVariable("WorkflowException", null);\r
- }\r
- } catch (BpmnError e) {\r
- utils.log("DEBUG", "BPMN Error during preProcessRollback", isDebugEnabled)\r
- } catch(Exception ex) {\r
- String msg = "Exception in preProcessRollback. " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- }\r
- utils.log("DEBUG"," *** Exit preProcessRollback of CreateGenericMacroServiceNetworkVnf *** ", isDebugEnabled)\r
- }\r
-\r
- public void postProcessRollback (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG"," ***** postProcessRollback of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)\r
- String msg = ""\r
- try {\r
- Object workflowException = execution.getVariable("prevWorkflowException");\r
- if (workflowException instanceof WorkflowException) {\r
- utils.log("DEBUG", "Setting prevException to WorkflowException: ", isDebugEnabled)\r
- execution.setVariable("WorkflowException", workflowException);\r
- }\r
- } catch (BpmnError b) {\r
- utils.log("DEBUG", "BPMN Error during postProcessRollback", isDebugEnabled)\r
- throw b;\r
- } catch(Exception ex) {\r
- msg = "Exception in postProcessRollback. " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- }\r
- utils.log("DEBUG"," *** Exit postProcessRollback of CreateGenericMacroServiceNetworkVnf *** ", isDebugEnabled)\r
- }\r
-\r
- public void prepareFalloutRequest(Execution execution){\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- utils.log("DEBUG", " *** STARTED CreateGenericMacroServiceNetworkVnf prepareFalloutRequest Process *** ", isDebugEnabled)\r
-\r
- try {\r
- WorkflowException wfex = execution.getVariable("WorkflowException")\r
- utils.log("DEBUG", " Incoming Workflow Exception: " + wfex.toString(), isDebugEnabled)\r
- String requestInfo = execution.getVariable("CREVAS_requestInfo")\r
- utils.log("DEBUG", " Incoming Request Info: " + requestInfo, isDebugEnabled)\r
- \r
- //TODO. hmmm. there is no way to UPDATE error message.\r
-// String errorMessage = wfex.getErrorMessage()\r
-// boolean successIndicator = execution.getVariable("DCRESI_rollbackSuccessful")\r
-// if (successIndicator){\r
-// errorMessage = errorMessage + ". Rollback successful."\r
-// } else {\r
-// errorMessage = errorMessage + ". Rollback not completed."\r
-// }\r
- \r
- String falloutRequest = exceptionUtil.processMainflowsBPMNException(execution, requestInfo)\r
-\r
- execution.setVariable("CREVAS_falloutRequest", falloutRequest)\r
-\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", "Error Occured in CreateGenericMacroServiceNetworkVnf prepareFalloutRequest Process " + ex.getMessage(), isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in CreateGenericMacroServiceNetworkVnf prepareFalloutRequest Process")\r
- }\r
- utils.log("DEBUG", "*** COMPLETED CreateGenericMacroServiceNetworkVnf prepareFalloutRequest Process ***", isDebugEnabled)\r
- }\r
-\r
-\r
- public void sendSyncError (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
-\r
- utils.log("DEBUG", " ***** Inside sendSyncError() of CreateServiceInstanceInfra ***** ", isDebugEnabled)\r
-\r
- try {\r
- String errorMessage = ""\r
- if (execution.getVariable("WorkflowException") instanceof WorkflowException) {\r
- WorkflowException wfe = execution.getVariable("WorkflowException")\r
- errorMessage = wfe.getErrorMessage()\r
- } else {\r
- errorMessage = "Sending Sync Error."\r
- }\r
-\r
- String buildworkflowException =\r
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>${source}</source>
+ </request-info>
+ <status-message>Service Instance has been created successfully via macro orchestration</status-message>
+ <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>
+ <mso-bpel-name>BPMN macro create</mso-bpel-name>
+ </aetgt:MsoCompletionRequest>"""
+
+ // Format Response
+ String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)
+
+ utils.logAudit(xmlMsoCompletionRequest)
+ execution.setVariable("CGMSNV_Success", true)
+ execution.setVariable("CGMSNV_CompleteMsoProcessRequest", xmlMsoCompletionRequest)
+ utils.log("DEBUG", " SUCCESS flow, going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in CreateServiceInstance flow. Unexpected Error from method postProcessResponse() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ public void preProcessRollback (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG"," ***** preProcessRollback of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ try {
+
+ Object workflowException = execution.getVariable("WorkflowException");
+
+ if (workflowException instanceof WorkflowException) {
+ utils.log("DEBUG", "Prev workflowException: " + workflowException.getErrorMessage(), isDebugEnabled)
+ execution.setVariable("prevWorkflowException", workflowException);
+ //execution.setVariable("WorkflowException", null);
+ }
+ } catch (BpmnError e) {
+ utils.log("DEBUG", "BPMN Error during preProcessRollback", isDebugEnabled)
+ } catch(Exception ex) {
+ String msg = "Exception in preProcessRollback. " + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ }
+ utils.log("DEBUG"," *** Exit preProcessRollback of CreateGenericMacroServiceNetworkVnf *** ", isDebugEnabled)
+ }
+
+ public void postProcessRollback (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG"," ***** postProcessRollback of CreateGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ String msg = ""
+ try {
+ Object workflowException = execution.getVariable("prevWorkflowException");
+ if (workflowException instanceof WorkflowException) {
+ utils.log("DEBUG", "Setting prevException to WorkflowException: ", isDebugEnabled)
+ execution.setVariable("WorkflowException", workflowException);
+ }
+ } catch (BpmnError b) {
+ utils.log("DEBUG", "BPMN Error during postProcessRollback", isDebugEnabled)
+ throw b;
+ } catch(Exception ex) {
+ msg = "Exception in postProcessRollback. " + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ }
+ utils.log("DEBUG"," *** Exit postProcessRollback of CreateGenericMacroServiceNetworkVnf *** ", isDebugEnabled)
+ }
+
+ public void prepareFalloutRequest(Execution execution){
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ utils.log("DEBUG", " *** STARTED CreateGenericMacroServiceNetworkVnf prepareFalloutRequest Process *** ", isDebugEnabled)
+
+ try {
+ WorkflowException wfex = execution.getVariable("WorkflowException")
+ utils.log("DEBUG", " Incoming Workflow Exception: " + wfex.toString(), isDebugEnabled)
+ String requestInfo = execution.getVariable("CGMSNV_requestInfo")
+ utils.log("DEBUG", " Incoming Request Info: " + requestInfo, isDebugEnabled)
+
+ //TODO. hmmm. there is no way to UPDATE error message.
+// String errorMessage = wfex.getErrorMessage()
+// boolean successIndicator = execution.getVariable("DCRESI_rollbackSuccessful")
+// if (successIndicator){
+// errorMessage = errorMessage + ". Rollback successful."
+// } else {
+// errorMessage = errorMessage + ". Rollback not completed."
+// }
+
+ String falloutRequest = exceptionUtil.processMainflowsBPMNException(execution, requestInfo)
+
+ execution.setVariable("CGMSNV_falloutRequest", falloutRequest)
+
+ } catch (Exception ex) {
+ utils.log("DEBUG", "Error Occured in CreateGenericMacroServiceNetworkVnf prepareFalloutRequest Process " + ex.getMessage(), isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in CreateGenericMacroServiceNetworkVnf prepareFalloutRequest Process")
+ }
+ utils.log("DEBUG", "*** COMPLETED CreateGenericMacroServiceNetworkVnf prepareFalloutRequest Process ***", isDebugEnabled)
+ }
+
+
+ public void sendSyncError (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+
+ utils.log("DEBUG", " ***** Inside sendSyncError() of CreateServiceInstanceInfra ***** ", isDebugEnabled)
+
+ try {
+ String errorMessage = ""
+ if (execution.getVariable("WorkflowException") instanceof WorkflowException) {
+ WorkflowException wfe = execution.getVariable("WorkflowException")
+ errorMessage = wfe.getErrorMessage()
+ } else {
+ errorMessage = "Sending Sync Error."
+ }
+
+ String buildworkflowException =
"""<aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>7000</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>"""\r
-\r
- utils.logAudit(buildworkflowException)\r
- sendWorkflowResponse(execution, 500, buildworkflowException)\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", " Sending Sync Error Activity Failed. " + "\n" + ex.getMessage(), isDebugEnabled)\r
- }\r
- }\r
-\r
- public void processJavaException(Execution execution){\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- try{\r
- utils.log("DEBUG", "Caught a Java Exception", isDebugEnabled)\r
- utils.log("DEBUG", "Started processJavaException Method", isDebugEnabled)\r
- utils.log("DEBUG", "Variables List: " + execution.getVariables(), isDebugEnabled)\r
- execution.setVariable("CRESI_unexpectedError", "Caught a Java Lang Exception") // Adding this line temporarily until this flows error handling gets updated\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Caught a Java Lang Exception")\r
- }catch(BpmnError b){\r
- utils.log("ERROR", "Rethrowing MSOWorkflowException", isDebugEnabled)\r
- throw b\r
- }catch(Exception e){\r
- utils.log("DEBUG", "Caught Exception during processJavaException Method: " + e, isDebugEnabled)\r
- execution.setVariable("CRESI_unexpectedError", "Exception in processJavaException method") // Adding this line temporarily until this flows error handling gets updated\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Exception in processJavaException method")\r
- }\r
- utils.log("DEBUG", "Completed processJavaException Method", isDebugEnabled)\r
- }\r
+ <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>7000</aetgt:ErrorCode>
+ </aetgt:WorkflowException>"""
+
+ utils.logAudit(buildworkflowException)
+ sendWorkflowResponse(execution, 500, buildworkflowException)
+ } catch (Exception ex) {
+ utils.log("DEBUG", " Sending Sync Error Activity Failed. " + "\n" + ex.getMessage(), isDebugEnabled)
+ }
+ }
+
+ public void processJavaException(Execution execution){
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ try{
+ utils.log("DEBUG", "Caught a Java Exception", isDebugEnabled)
+ utils.log("DEBUG", "Started processJavaException Method", isDebugEnabled)
+ utils.log("DEBUG", "Variables List: " + execution.getVariables(), isDebugEnabled)
+ execution.setVariable("CRESI_unexpectedError", "Caught a Java Lang Exception") // Adding this line temporarily until this flows error handling gets updated
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Caught a Java Lang Exception")
+ }catch(BpmnError b){
+ utils.log("ERROR", "Rethrowing MSOWorkflowException", isDebugEnabled)
+ throw b
+ }catch(Exception e){
+ utils.log("DEBUG", "Caught Exception during processJavaException Method: " + e, isDebugEnabled)
+ execution.setVariable("CRESI_unexpectedError", "Exception in processJavaException method") // Adding this line temporarily until this flows error handling gets updated
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Exception in processJavaException method")
+ }
+ utils.log("DEBUG", "Completed processJavaException Method", isDebugEnabled)
+ }
}
\ No newline at end of file
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts;
import groovy.json.JsonSlurper
+import groovy.json.JsonOutput
import org.camunda.bpm.engine.delegate.BpmnError
import org.camunda.bpm.engine.runtime.Execution
import org.apache.commons.lang3.*
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor;\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil;\r
-import org.openecomp.mso.bpmn.common.scripts.NetworkUtils;\r
-import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils;\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils;\r
-import org.openecomp.mso.bpmn.core.RollbackData\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-
-public class CreateVfModuleInfra extends AbstractServiceTaskProcessor {\r
-
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
-
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor;
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil;
+import org.openecomp.mso.bpmn.common.scripts.NetworkUtils;
+import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils;
+import org.openecomp.mso.bpmn.common.scripts.VidUtils;
+import org.openecomp.mso.bpmn.core.RollbackData
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+
+public class CreateVfModuleInfra extends AbstractServiceTaskProcessor {
+
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+
/**
* Validates the request message and sets up the workflow.
* @param execution the execution
// check if request is xml or json
try {
def jsonSlurper = new JsonSlurper()
+ def jsonOutput = new JsonOutput()
Map reqMap = jsonSlurper.parseText(incomingRequest)
utils.log("DEBUG", " Request is in JSON format.", isDebugLogEnabled)
def serviceInstanceId = execution.getVariable('serviceInstanceId')
def vnfId = execution.getVariable('vnfId')
-
- def vidUtils = new VidUtils(this)
-
- String requestInXmlFormat = vidUtils.createXmlVfModuleRequest(execution, reqMap, 'CREATE_VF_MODULE', serviceInstanceId)
-
- utils.log("DEBUG", " Request in XML format: " + requestInXmlFormat, isDebugLogEnabled)
-
- execution.setVariable(prefix + 'Request', requestInXmlFormat)
+
+ execution.setVariable(prefix + 'serviceInstanceId', serviceInstanceId)
execution.setVariable(prefix+'vnfId', vnfId)
execution.setVariable("isVidRequest", "true")
-
- }
- catch(groovy.json.JsonException je) {
- utils.log("DEBUG", " Request is not in JSON format.", isDebugLogEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 400, "Internal Error - During PreProcessRequest")
-
- }
- catch(Exception e) {
- String restFaultMessage = e.getMessage()
- //execution.setVariable("CVFMODVOL2_RESTFault", restFaultMessage)
- //execution.setVariable("CVFMODVOL2_isDataOk", false)
- utils.log("ERROR", " Exception Encountered - " + "\n" + restFaultMessage, isDebugLogEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 400, "Internal Error - During PreProcessRequest")
- }
-
- try {
- String request = validateInfraRequest(execution)
+
+ def vnfName = ''
+ def asdcServiceModelVersion = ''
+ def serviceModelInfo = null
+ def vnfModelInfo = null
+
+ def relatedInstanceList = reqMap.requestDetails?.relatedInstanceList
+
+ if (relatedInstanceList != null) {
+ relatedInstanceList.each {
+ if (it.relatedInstance.modelInfo?.modelType == 'service') {
+ asdcServiceModelVersion = it.relatedInstance.modelInfo?.modelVersion
+ serviceModelInfo = jsonOutput.toJson(it.relatedInstance.modelInfo)
+
+ }
+ if (it.relatedInstance.modelInfo.modelType == 'vnf') {
+ vnfName = it.relatedInstance.instanceName ?: ''
+ vnfModelInfo = jsonOutput.toJson(it.relatedInstance.modelInfo)
+ }
+ }
+ }
+
+ execution.setVariable(prefix + 'vnfName', vnfName)
+ execution.setVariable(prefix + 'asdcServiceModelVersion', asdcServiceModelVersion)
+ execution.setVariable(prefix + 'serviceModelInfo', serviceModelInfo)
+ execution.setVariable(prefix + 'vnfModelInfo', vnfModelInfo)
+
+
+ def vnfType = execution.getVariable('vnfType')
+ execution.setVariable(prefix + 'vnfType', vnfType)
+ def vfModuleId = execution.getVariable('vfModuleId')
+ execution.setVariable(prefix + 'vfModuleId', vfModuleId)
+ def volumeGroupId = execution.getVariable('volumeGroupId')
+ execution.setVariable(prefix + 'volumeGroupId', volumeGroupId)
+ def userParams = reqMap.requestDetails?.requestParameters?.userParams
+
+ Map<String, String> userParamsMap = [:]
+ if (userParams != null) {
+ userParams.each { userParam ->
+ userParamsMap.put(userParam.name, userParam.value)
+ }
+ }
+
+ utils.log("DEBUG", 'Processed user params: ' + userParamsMap, isDebugLogEnabled)
+
+ execution.setVariable(prefix + 'vfModuleInputParams', userParamsMap)
+
+ def isBaseVfModule = "false"
+ if (execution.getVariable('isBaseVfModule') == true) {
+ isBaseVfModule = "true"
+ }
+
+ execution.setVariable(prefix + 'isBaseVfModule', isBaseVfModule)
+
+ def requestId = execution.getVariable("mso-request-id")
+ execution.setVariable(prefix + 'requestId', requestId)
+
+ def vfModuleModelInfo = jsonOutput.toJson(reqMap.requestDetails?.modelInfo)
+ execution.setVariable(prefix + 'vfModuleModelInfo', vfModuleModelInfo)
+
+ def suppressRollback = reqMap.requestDetails?.requestInfo?.suppressRollback
+
+
+ def backoutOnFailure = ""
+ if(suppressRollback != null){
+ if ( suppressRollback == true) {
+ backoutOnFailure = "false"
+ } else if ( suppressRollback == false) {
+ backoutOnFailure = "true"
+ }
+ }
+
+ execution.setVariable(prefix + 'disableRollback', suppressRollback)
+
+ def vfModuleName = reqMap.requestDetails?.requestInfo?.instanceName ?: null
+ execution.setVariable(prefix + 'vfModuleName', vfModuleName)
+
+ def serviceId = reqMap.requestDetails?.requestParameters?.serviceId ?: ''
+ execution.setVariable(prefix + 'serviceId', serviceId)
+
+ def usePreload = reqMap.requestDetails?.requestParameters?.usePreload
+ execution.setVariable(prefix + 'usePreload', usePreload)
+
+ def cloudConfiguration = reqMap.requestDetails?.cloudConfiguration
+ def lcpCloudRegionId = cloudConfiguration.lcpCloudRegionId
+ execution.setVariable(prefix + 'lcpCloudRegionId', lcpCloudRegionId)
+ def tenantId = cloudConfiguration.tenantId
+ execution.setVariable(prefix + 'tenantId', tenantId)
+
+ def globalSubscriberId = reqMap.requestDetails?.subscriberInfo?.globalSubscriberId ?: ''
+ execution.setVariable(prefix + 'globalSubscriberId', globalSubscriberId)
+
+ execution.setVariable(prefix + 'sdncVersion', '1702')
execution.setVariable("CreateVfModuleInfraSuccessIndicator", false)
execution.setVariable("RollbackCompleted", false)
- execution.setVariable("DoCreateVfModuleRequest", request)
+
execution.setVariable("isDebugLogEnabled", isDebugLogEnabled)
- execution.setVariable("CVFMI_requestInfo",utils.getNodeXml(request,"request-info"))
- execution.setVariable("CVFMI_requestId",utils.getNodeText1(request,"request-id"))
- execution.setVariable("CVFMI_source",utils.getNodeText1(request,"source"))
- execution.setVariable("CVFMI_serviceInstanceId", utils.getNodeText1(request, "service-instance-id"))
- execution.setVariable("CVFMI_vnfInputs",utils.getNodeXml(request,"vnf-inputs"))
+
+
+ def source = reqMap.requestDetails?.requestInfo?.source
+ execution.setVariable("CVFMI_source", source)
+
+ //For Completion Handler & Fallout Handler
+ String requestInfo =
+ """<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>${source}</source>
+ </request-info>"""
+
+ execution.setVariable("CVFMI_requestInfo", requestInfo)
+
//backoutOnFailure
- NetworkUtils networkUtils = new NetworkUtils()
- execution.setVariable("CVFMI_rollbackEnabled", networkUtils.isRollbackEnabled(execution,request))
+ //NetworkUtils networkUtils = new NetworkUtils()
+ //execution.setVariable("CVFMI_rollbackEnabled", networkUtils.isRollbackEnabled(execution,request))
execution.setVariable("CVFMI_originalWorkflowException", null)
- def vnfParams = ""
- if (utils.nodeExists(request, "vnf-params")) {
- vnfParams = utils.getNodeXml(request,"vnf-params")
- }
- execution.setVariable("CVFMI_vnfParams", vnfParams)
+
def newVfModuleId = UUID.randomUUID().toString()
execution.setVariable("newVfModuleId", newVfModuleId)
+ execution.setVariable(prefix + 'vfModuleId', newVfModuleId)
- logDebug('RequestInfo: ' + execution.getVariable("CVFMI_requestInfo"), isDebugLogEnabled)
- logDebug('VnfInputs: ' + execution.getVariable("CVFMI_vnfInputs"), isDebugLogEnabled)
- logDebug('VnfParams: ' + execution.getVariable("CVFMI_vnfParams"), isDebugLogEnabled)
+ logDebug('RequestInfo: ' + execution.getVariable("CVFMI_requestInfo"), isDebugLogEnabled)
+
logDebug('rollbackEnabled: ' + execution.getVariable("CVFMI_rollbackEnabled"), isDebugLogEnabled)
logDebug('Exited ' + method, isDebugLogEnabled)
} catch (BpmnError bpmnError) {
throw bpmnError
- } catch (Exception exception) {
+ }
+ catch(groovy.json.JsonException je) {
+ utils.log("DEBUG", " Request is not in JSON format.", isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 400, "Internal Error - During PreProcessRequest")
+ }
+ catch(Exception e) {
+ String restFaultMessage = e.getMessage()
+ //execution.setVariable("CVFMODVOL2_RESTFault", restFaultMessage)
+ //execution.setVariable("CVFMODVOL2_isDataOk", false)
+ utils.log("ERROR", " Exception Encountered - " + "\n" + restFaultMessage, isDebugLogEnabled)
exceptionUtil.buildAndThrowWorkflowException(execution, 400, "Internal Error - During PreProcessRequest")
}
+
}
/**
try {
def requestInfo = execution.getVariable('CVFMI_requestInfo')
def requestId = execution.getVariable('CVFMI_requestId')
- def source = execution.getVariable('CVFMI_source')
- def progress = getNodeTextForce(requestInfo, 'progress')
- if (progress.isEmpty()) {
- progress = '0'
- }
- def startTime = getNodeTextForce(requestInfo, 'start-time')
- if (startTime.isEmpty()) {
- startTime = System.currentTimeMillis()
- }
-
+ def source = execution.getVariable('CVFMI_source')
+
// RESTResponse (for API Handler (APIH) Reply Task)
def newVfModuleId = execution.getVariable("newVfModuleId")
String synchResponse = """{"requestReferences":{"instanceId":"${newVfModuleId}","requestId":"${requestId}"}}""".trim()
def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
utils.log("DEBUG", " ======== STARTED PostProcessResponse Process ======== ", isDebugEnabled)
- try{
- def request = execution.getVariable("DoCreateVfModuleRequest")
- def requestInfo = utils.getNodeXml(request, 'request-info', false)
+ try{
+ def requestInfo = execution.getVariable("CVFMI_requestInfo")
def action = utils.getNodeText1(requestInfo, "action")
utils.log("DEBUG", "requestInfo is: " + requestInfo, isDebugEnabled)
}\r
\r
String payload =
- """ <aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:ns8="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
+ """ <aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:ns="http://org.openecomp/mso/request/types/v1"
+ xmlns:ns8="http://org.openecomp/mso/workflow/schema/v1">
+ <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
${requestInfo}
</request-info>
<ns8:status-message>Vf Module has been created successfully.</ns8:status-message>
/*
- def requestId = execution.getVariable("mso-request-id")\r
+ def requestId = execution.getVariable("mso-request-id")
if (requestId == null) {
exceptionUtil.buildAndThrowWorkflowException(execution, 1002, processKey + " request has no mso-request-id")
setVariable(execution, prefix + 'requestId', requestId)
- def serviceInstanceId = execution.getVariable("mso-service-instance-id")\r
+ def serviceInstanceId = execution.getVariable("mso-service-instance-id")
if (serviceInstanceId == null) {
exceptionUtil.buildAndThrowWorkflowException(execution, 1002, processKey + " request message has no mso-service-instance-id")
utils.log("DEBUG", " ======== STARTED prepareUpdateInfraRequest Process ======== ", isDebugEnabled)
try{
-
- String vnfInputs = execution.getVariable("CVFMI_vnfInputs")
- String requestInfo = execution.getVariable("CVFMI_requestInfo")
- def aicCloudRegion = utils.getNodeText1(vnfInputs, "aic-cloud-region")
- def tenantId = utils.getNodeText1(vnfInputs, "tenant-id")
+
+
+ String requestInfo = execution.getVariable("CVFMI_requestInfo")
+ def aicCloudRegion = execution.getVariable("CVFMI_lcpCloudRegionId")
+ def tenantId = execution.getVariable("CVFMI_tenantId")
def requestId = utils.getNodeText1(requestInfo, "request-id")
def vnfId = execution.getVariable("CVFMI_vnfId")
def vfModuleId = execution.getVariable("CVFMI_vfModuleId")
+ // vfModuleName may be generated by DoCreateVfModule subprocess if it is not specified on the input
+ def vfModuleName = execution.getVariable("CVFMI_vfModuleName")
def dbAdapterEndpoint = execution.getVariable("URN_mso_adapters_db_endpoint")
execution.setVariable("CVFMI_dbAdapterEndpoint", dbAdapterEndpoint)
\r
String payload =
"""<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
- xmlns:ns="http://org.openecomp.mso/requestsdb">\r
+ xmlns:ns="http://org.openecomp.mso/requestsdb">
<soapenv:Header/>
<soapenv:Body>
- <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
+ <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">
<requestId>${requestId}</requestId>
<lastModifiedBy>BPMN</lastModifiedBy>
<statusMessage>VF Module successfully created</statusMessage>
<responseBody></responseBody>
<requestStatus>COMPLETE</requestStatus>
<progress>100</progress>
- <vnfOutputs><vnf-outputs xmlns="http://org.openecomp/mso/infra/vnf-request/v1" xmlns:aetgt="http://org.openecomp/mso/infra/vnf-request/v1" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"><vnf-id>${vnfId}</vnf-id><vf-module-id>${vfModuleId}</vf-module-id></vnf-outputs></vnfOutputs>\r
+ <vnfOutputs><vnf-outputs xmlns="http://org.openecomp/mso/infra/vnf-request/v1" xmlns:aetgt="http://org.openecomp/mso/infra/vnf-request/v1" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"><vnf-id>${vnfId}</vnf-id><vf-module-id>${vfModuleId}</vf-module-id></vnf-outputs></vnfOutputs>
<vfModuleId>${vfModuleId}</vfModuleId>
+ <vfModuleName>${vfModuleName}</vfModuleName>
</ns:updateInfraRequest>
</soapenv:Body>
</soapenv:Envelope>"""
try {
- def WorkflowException workflowException = execution.getVariable("WorkflowException")
- def request = execution.getVariable("DoCreateVfModuleRequest")
- def requestInformation = utils.getNodeXml(request, 'request-info', false)
+ def WorkflowException workflowException = execution.getVariable("WorkflowException")
+ def requestInformation = execution.getVariable("CVFMI_requestInfo")
def errorResponseCode = workflowException.getErrorCode()
def errorResponseMsg = workflowException.getErrorMessage()
def encErrorResponseMsg = ""
}
String content = """
- <aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:reqtype="http://org.openecomp/mso/request/types/v1"\r
- xmlns:msoservtypes="http://org.openecomp/mso/request/types/v1"\r
- xmlns:structuredtypes="http://org.openecomp/mso/structured/types/v1">\r
+ <aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:reqtype="http://org.openecomp/mso/request/types/v1"
+ xmlns:msoservtypes="http://org.openecomp/mso/request/types/v1"
+ xmlns:structuredtypes="http://org.openecomp/mso/structured/types/v1">
${requestInformation}
<aetgt:WorkflowException>
<aetgt:ErrorMessage>${encErrorResponseMsg}</aetgt:ErrorMessage>
execution.setVariable("RollbackCompleted", true)
}
+
+
}
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts\r
-\r
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil;\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor;\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil;\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils;\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse\r
-\r
-import groovy.json.JsonSlurper\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution;\r
-import org.apache.commons.lang3.*\r
-\r
-class CreateVfModuleVolumeInfraV1 extends AbstractServiceTaskProcessor {\r
-\r
- public static final String prefix='CVMVINFRAV1_'\r
-\r
- /**\r
- * Perform initial processing, such as request validation, initialization of variables, etc.\r
- * * @param execution\r
- */\r
- public void preProcessRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- preProcessRequest(execution, isDebugEnabled)\r
- }\r
-\r
-\r
- /**\r
- * Perform initial processing, such as request validation, initialization of variables, etc.\r
- * @param execution\r
- * @param isDebugEnabled\r
- */\r
- public void preProcessRequest (Execution execution, isDebugEnabled) {\r
-\r
- execution.setVariable("prefix",prefix)\r
- setSuccessIndicator(execution, false)\r
- execution.setVariable(prefix+'syncResponseSent', false)\r
-\r
- String createVolumeIncoming = validateRequest(execution, 'vnfId')\r
- utils.logAudit(createVolumeIncoming)\r
-\r
- try {\r
- def jsonSlurper = new JsonSlurper()\r
- Map reqMap = jsonSlurper.parseText(createVolumeIncoming)\r
-\r
- def serviceInstanceId = execution.getVariable('serviceInstanceId')\r
- def vnfId = execution.getVariable('vnfId')\r
-\r
- def vidUtils = new VidUtils(this)\r
- createVolumeIncoming = vidUtils.createXmlVolumeRequest(reqMap, 'CREATE_VF_MODULE_VOL', serviceInstanceId)\r
-\r
- execution.setVariable(prefix+'Request', createVolumeIncoming)\r
- execution.setVariable(prefix+'vnfId', vnfId)\r
- execution.setVariable(prefix+'isVidRequest', true)\r
-\r
- utils.log("DEBUG", "XML request:\n" + createVolumeIncoming, isDebugEnabled)\r
-\r
- }\r
- catch(groovy.json.JsonException je) {\r
- (new ExceptionUtil()).buildAndThrowWorkflowException(execution, 2500, 'Request is not a valid JSON document')\r
- }\r
-\r
- execution.setVariable(prefix+'source', utils.getNodeText1(createVolumeIncoming, "source"))\r
- execution.setVariable(prefix+'volumeGroupName', utils.getNodeText1(createVolumeIncoming, 'volume-group-name'))\r
- execution.setVariable(prefix+'volumeOutputs', utils.getNodeXml(createVolumeIncoming, 'volume-outputs', false))\r
-\r
- execution.setVariable(prefix+'serviceType', 'service-instance')\r
- execution.setVariable(prefix+'serviceInstanceId', utils.getNodeText1(createVolumeIncoming, "service-instance-id"))\r
-\r
- // Generate volume group id\r
- String volumeGroupId = UUID.randomUUID()\r
- utils.log("DEBUG", "Generated volume group id: " + volumeGroupId, isDebugEnabled)\r
-\r
- def testGroupId = execution.getVariable('test-volume-group-id')\r
- if (testGroupId != null && testGroupId.trim() != '') {\r
- volumeGroupId = testGroupId\r
- }\r
-\r
- execution.setVariable(prefix+'volumeGroupId', volumeGroupId)\r
-\r
- }\r
-\r
-\r
- public void sendSyncResponse (Execution execution, isDebugEnabled) {\r
- def volumeGroupId = execution.getVariable(prefix+'volumeGroupId')\r
- def requestId = execution.getVariable("mso-request-id")\r
- def serviceInstanceId = execution.getVariable("serviceInstanceId")\r
-\r
- String syncResponse = """{"requestReferences":{"instanceId":"${volumeGroupId}","requestId":"${requestId}"}}""".trim()\r
-\r
- utils.log("DEBUG", "Sync Response: " + "\n" + syncResponse, isDebugEnabled)\r
- sendWorkflowResponse(execution, 200, syncResponse)\r
-\r
- execution.setVariable(prefix+'syncResponseSent', true)\r
- }\r
-\r
-\r
- public void sendSyncError (Execution execution, isDebugEnabled) {\r
- WorkflowException we = execution.getVariable('WorkflowException')\r
- def errorCode = we?.getErrorCode()\r
- def errorMessage = we?.getErrorMessage()\r
- //default to 400 since only invalid request will trigger this method\r
- sendWorkflowResponse(execution, 400, errorMessage)\r
- }\r
-\r
-\r
- /**\r
- * Create a WorkflowException\r
- * @param execution\r
- * @param isDebugEnabled\r
- */\r
- public void buildWorkflowException(Execution execution, int errorCode, errorMessage, isDebugEnabled) {\r
- utils.log("DEBUG", errorMessage, isDebugEnabled)\r
- (new ExceptionUtil()).buildWorkflowException(execution, 2500, errorMessage)\r
- }\r
-\r
-\r
- public void prepareDbInfraSuccessRequest(Execution execution, isDebugEnabled) {\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- def dbVnfOutputs = execution.getVariable(prefix+'volumeOutputs')\r
- def requestId = execution.getVariable('mso-request-id')\r
- def statusMessage = "VolumeGroup successfully created."\r
- def requestStatus = "COMPLETED"\r
- def progress = "100"\r
-\r
- try {\r
- String basicAuthValueDB = execution.getVariable("URN_mso_adapters_db_auth")\r
- utils.log("DEBUG", " Obtained BasicAuth userid password for Catalog DB adapter: " + basicAuthValueDB, isDebugEnabled)\r
- \r
- def encodedString = utils.getBasicAuth(basicAuthValueDB, execution.getVariable("URN_mso_msoKey"))\r
- execution.setVariable("BasicAuthHeaderValueDB",encodedString)\r
- } catch (IOException ex) {\r
- String dataErrorMessage = " Unable to encode Catalog DB user/password string - " + ex.getMessage()\r
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)\r
- }\r
- \r
- /*\r
- from: $gVolumeGroup/aai:volume-group-id/text()\r
- to: vnfreq:volume-outputs/vnfreq:volume-group-id\r
- */\r
- // for now assume, generated volumeGroupId is accepted\r
- def volumeGroupId = execution.getVariable(prefix+'volumeGroupId')\r
-\r
- String dbRequest =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
- <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <requestId>${requestId}</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>${statusMessage}</statusMessage>\r
- <responseBody></responseBody>\r
- <requestStatus>${requestStatus}</requestStatus>\r
- <progress>${progress}</progress>\r
- <vnfOutputs>${dbVnfOutputs}</vnfOutputs>\r
- <volumeGroupId>${volumeGroupId}</volumeGroupId>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
- </soapenv:Envelope>"""\r
-\r
- String buildDeleteDBRequestAsString = utils.formatXml(dbRequest)\r
- execution.setVariable(prefix+"createDBRequest", buildDeleteDBRequestAsString)\r
-\r
- utils.logAudit(buildDeleteDBRequestAsString)\r
- }\r
-\r
-\r
-\r
-\r
-\r
- public void postProcessResponse (Execution execution, isDebugEnabled) {\r
-\r
- def dbReturnCode = execution.getVariable(prefix+'dbReturnCode')\r
- def createDBResponse = execution.getVariable(prefix+'createDBResponse')\r
-\r
- utils.logAudit('DB return code: ' + dbReturnCode)\r
- utils.logAudit('DB response: ' + createDBResponse)\r
-\r
- def requestId = execution.getVariable("mso-request-id")\r
- def source = execution.getVariable(prefix+'source')\r
-\r
- String msoCompletionRequest =\r
- """<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>CREATE</action>\r
- <source>${source}</source>\r
- </request-info>\r
- <aetgt:status-message>Volume Group has been created successfully.</aetgt:status-message>\r
- <aetgt:mso-bpel-name>BPMN VF Module Volume action: CREATE</aetgt:mso-bpel-name>\r
- </aetgt:MsoCompletionRequest>"""\r
-\r
- String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)\r
-\r
- utils.logAudit(createDBResponse)\r
- utils.logAudit(xmlMsoCompletionRequest)\r
- execution.setVariable(prefix+'Success', true)\r
- execution.setVariable(prefix+'CompleteMsoProcessRequest', xmlMsoCompletionRequest)\r
- utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)\r
-\r
- }\r
-\r
- public void prepareFalloutHandlerRequest(Execution execution, isDebugEnabled) {\r
-\r
- WorkflowException we = execution.getVariable('WorkflowException')\r
- def errorCode = we?.getErrorCode()\r
- def errorMessage = we?.getErrorMessage()\r
-\r
- def requestId = execution.getVariable("mso-request-id")\r
- def source = execution.getVariable(prefix+'source')\r
-\r
- String falloutHandlerRequest =\r
- """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>CREATE</action>\r
- <source>${source}</source>\r
- </request-info>\r
- <aetgt:WorkflowException>\r
- <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>${errorCode}</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>\r
-\r
- </aetgt:FalloutHandlerRequest>"""\r
-\r
- // Format Response\r
- String xmlHandlerRequest = utils.formatXml(falloutHandlerRequest)\r
- utils.logAudit(xmlHandlerRequest)\r
-\r
- execution.setVariable(prefix+'FalloutHandlerRequest', xmlHandlerRequest)\r
- utils.log("ERROR", "Overall Error Response going to FalloutHandler: " + "\n" + xmlHandlerRequest, isDebugEnabled)\r
- }\r
-\r
-\r
- /**\r
- * Query AAI service instance\r
- * @param execution\r
- * @param isDebugEnabled\r
- */\r
- public void callRESTQueryAAIServiceInstance(Execution execution, isDebugEnabled) {\r
-\r
- def request = execution.getVariable(prefix+"Request")\r
- def serviceInstanceId = utils.getNodeText1(request, "service-instance-id")\r
-\r
- AaiUtil aaiUtil = new AaiUtil(this)\r
- String aaiEndpoint = aaiUtil.getSearchNodesQueryEndpoint(execution)\r
-\r
- def String queryAAIRequest = aaiEndpoint + "?search-node-type=service-instance&filter=service-instance-id:EQUALS:" + serviceInstanceId\r
- utils.logAudit("AAI query service instance request: " + queryAAIRequest)\r
-\r
- APIResponse response = aaiUtil.executeAAIGetCall(execution, queryAAIRequest)\r
-\r
- String returnCode = response.getStatusCode()\r
- String aaiResponseAsString = response.getResponseBodyAsString()\r
- aaiResponseAsString = StringEscapeUtils.unescapeXml(aaiResponseAsString)\r
-\r
- utils.logAudit("AAI query service instance return code: " + returnCode)\r
- utils.logAudit("AAI query service instance response: " + aaiResponseAsString)\r
-\r
- utils.log("DEBUG", "AAI query service instance return code: " + returnCode, isDebugEnabled)\r
- utils.log("DEBUG", "AAI query service instance response: " + aaiResponseAsString, isDebugEnabled)\r
-\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
-\r
- if (returnCode=='200') {\r
- utils.log("DEBUG", 'Service instance ' + serviceInstanceId + ' found in AAI.', isDebugEnabled)\r
- } else {\r
- if (returnCode=='404') {\r
- def message = 'Service instance ' + serviceInstanceId + ' was not found in AAI. Return code: 404.'\r
- utils.log("DEBUG", message, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, message)\r
- } else {\r
- WorkflowException aWorkflowException = exceptionUtil.MapAAIExceptionToWorkflowException(aaiResponseAsString, execution)\r
- throw new BpmnError("MSOWorkflowException")\r
- }\r
- }\r
- }\r
-}\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts
+
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil;
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor;
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil;
+import org.openecomp.mso.bpmn.common.scripts.VidUtils;
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.rest.APIResponse
+
+import groovy.json.JsonSlurper
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution;
+import org.apache.commons.lang3.*
+
+class CreateVfModuleVolumeInfraV1 extends AbstractServiceTaskProcessor {
+
+ public static final String prefix='CVMVINFRAV1_'
+
+ /**
+ * Perform initial processing, such as request validation, initialization of variables, etc.
+ * * @param execution
+ */
+ public void preProcessRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ preProcessRequest(execution, isDebugEnabled)
+ }
+
+
+ /**
+ * Perform initial processing, such as request validation, initialization of variables, etc.
+ * @param execution
+ * @param isDebugEnabled
+ */
+ public void preProcessRequest (Execution execution, isDebugEnabled) {
+
+ execution.setVariable("prefix",prefix)
+ setSuccessIndicator(execution, false)
+ execution.setVariable(prefix+'syncResponseSent', false)
+
+ String createVolumeIncoming = validateRequest(execution, 'vnfId')
+ utils.logAudit(createVolumeIncoming)
+
+ try {
+ def jsonSlurper = new JsonSlurper()
+ Map reqMap = jsonSlurper.parseText(createVolumeIncoming)
+
+ def serviceInstanceId = execution.getVariable('serviceInstanceId')
+ def vnfId = execution.getVariable('vnfId')
+
+ def vidUtils = new VidUtils(this)
+ createVolumeIncoming = vidUtils.createXmlVolumeRequest(reqMap, 'CREATE_VF_MODULE_VOL', serviceInstanceId)
+
+ execution.setVariable(prefix+'Request', createVolumeIncoming)
+ execution.setVariable(prefix+'vnfId', vnfId)
+ execution.setVariable(prefix+'isVidRequest', true)
+
+ utils.log("DEBUG", "XML request:\n" + createVolumeIncoming, isDebugEnabled)
+
+ }
+ catch(groovy.json.JsonException je) {
+ (new ExceptionUtil()).buildAndThrowWorkflowException(execution, 2500, 'Request is not a valid JSON document')
+ }
+
+ execution.setVariable(prefix+'source', utils.getNodeText1(createVolumeIncoming, "source"))
+ execution.setVariable(prefix+'volumeGroupName', utils.getNodeText1(createVolumeIncoming, 'volume-group-name'))
+ execution.setVariable(prefix+'volumeOutputs', utils.getNodeXml(createVolumeIncoming, 'volume-outputs', false))
+
+ execution.setVariable(prefix+'serviceType', 'service-instance')
+ execution.setVariable(prefix+'serviceInstanceId', utils.getNodeText1(createVolumeIncoming, "service-instance-id"))
+
+ // Generate volume group id
+ String volumeGroupId = UUID.randomUUID()
+ utils.log("DEBUG", "Generated volume group id: " + volumeGroupId, isDebugEnabled)
+
+ def testGroupId = execution.getVariable('test-volume-group-id')
+ if (testGroupId != null && testGroupId.trim() != '') {
+ volumeGroupId = testGroupId
+ }
+
+ execution.setVariable(prefix+'volumeGroupId', volumeGroupId)
+
+ }
+
+
+ public void sendSyncResponse (Execution execution, isDebugEnabled) {
+ def volumeGroupId = execution.getVariable(prefix+'volumeGroupId')
+ def requestId = execution.getVariable("mso-request-id")
+ def serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ String syncResponse = """{"requestReferences":{"instanceId":"${volumeGroupId}","requestId":"${requestId}"}}""".trim()
+
+ utils.log("DEBUG", "Sync Response: " + "\n" + syncResponse, isDebugEnabled)
+ sendWorkflowResponse(execution, 200, syncResponse)
+
+ execution.setVariable(prefix+'syncResponseSent', true)
+ }
+
+
+ public void sendSyncError (Execution execution, isDebugEnabled) {
+ WorkflowException we = execution.getVariable('WorkflowException')
+ def errorCode = we?.getErrorCode()
+ def errorMessage = we?.getErrorMessage()
+ //default to 400 since only invalid request will trigger this method
+ sendWorkflowResponse(execution, 400, errorMessage)
+ }
+
+
+ /**
+ * Create a WorkflowException
+ * @param execution
+ * @param isDebugEnabled
+ */
+ public void buildWorkflowException(Execution execution, int errorCode, errorMessage, isDebugEnabled) {
+ utils.log("DEBUG", errorMessage, isDebugEnabled)
+ (new ExceptionUtil()).buildWorkflowException(execution, 2500, errorMessage)
+ }
+
+
+ public void prepareDbInfraSuccessRequest(Execution execution, isDebugEnabled) {
+ def dbVnfOutputs = execution.getVariable(prefix+'volumeOutputs')
+ def requestId = execution.getVariable('mso-request-id')
+ def statusMessage = "VolumeGroup successfully created."
+ def requestStatus = "COMPLETED"
+ def progress = "100"
+
+ try {
+ String basicAuthValueDB = execution.getVariable("URN_mso_adapters_db_auth")
+ utils.log("DEBUG", " Obtained BasicAuth userid password for Catalog DB adapter: " + basicAuthValueDB, isDebugEnabled)
+
+ def encodedString = utils.getBasicAuth(basicAuthValueDB, execution.getVariable("URN_mso_msoKey"))
+ execution.setVariable("BasicAuthHeaderValueDB",encodedString)
+ } catch (IOException ex) {
+ String dataErrorMessage = " Unable to encode Catalog DB user/password string - " + ex.getMessage()
+ utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
+ }
+
+ /*
+ from: $gVolumeGroup/aai:volume-group-id/text()
+ to: vnfreq:volume-outputs/vnfreq:volume-group-id
+ */
+ // for now assume, generated volumeGroupId is accepted
+ def volumeGroupId = execution.getVariable(prefix+'volumeGroupId')
+
+ String dbRequest =
+ """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">
+ <requestId>${requestId}</requestId>
+ <lastModifiedBy>BPMN</lastModifiedBy>
+ <statusMessage>${statusMessage}</statusMessage>
+ <responseBody></responseBody>
+ <requestStatus>${requestStatus}</requestStatus>
+ <progress>${progress}</progress>
+ <vnfOutputs>${dbVnfOutputs}</vnfOutputs>
+ <volumeGroupId>${volumeGroupId}</volumeGroupId>
+ </ns:updateInfraRequest>
+ </soapenv:Body>
+ </soapenv:Envelope>"""
+
+ String buildDeleteDBRequestAsString = utils.formatXml(dbRequest)
+ execution.setVariable(prefix+"createDBRequest", buildDeleteDBRequestAsString)
+
+ utils.logAudit(buildDeleteDBRequestAsString)
+ }
+
+
+
+
+
+ public void postProcessResponse (Execution execution, isDebugEnabled) {
+
+ def dbReturnCode = execution.getVariable(prefix+'dbReturnCode')
+ def createDBResponse = execution.getVariable(prefix+'createDBResponse')
+
+ utils.logAudit('DB return code: ' + dbReturnCode)
+ utils.logAudit('DB response: ' + createDBResponse)
+
+ def requestId = execution.getVariable("mso-request-id")
+ def source = execution.getVariable(prefix+'source')
+
+ String msoCompletionRequest =
+ """<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:ns="http://org.openecomp/mso/request/types/v1">
+ <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>${source}</source>
+ </request-info>
+ <aetgt:status-message>Volume Group has been created successfully.</aetgt:status-message>
+ <aetgt:mso-bpel-name>BPMN VF Module Volume action: CREATE</aetgt:mso-bpel-name>
+ </aetgt:MsoCompletionRequest>"""
+
+ String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)
+
+ utils.logAudit(createDBResponse)
+ utils.logAudit(xmlMsoCompletionRequest)
+ execution.setVariable(prefix+'Success', true)
+ execution.setVariable(prefix+'CompleteMsoProcessRequest', xmlMsoCompletionRequest)
+ utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)
+
+ }
+
+ public void prepareFalloutHandlerRequest(Execution execution, isDebugEnabled) {
+
+ WorkflowException we = execution.getVariable('WorkflowException')
+ def errorCode = we?.getErrorCode()
+ def errorMessage = we?.getErrorMessage()
+
+ def requestId = execution.getVariable("mso-request-id")
+ def source = execution.getVariable(prefix+'source')
+
+ String falloutHandlerRequest =
+ """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:ns="http://org.openecomp/mso/request/types/v1"
+ xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">
+ <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>${source}</source>
+ </request-info>
+ <aetgt:WorkflowException>
+ <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>${errorCode}</aetgt:ErrorCode>
+ </aetgt:WorkflowException>
+
+ </aetgt:FalloutHandlerRequest>"""
+
+ // Format Response
+ String xmlHandlerRequest = utils.formatXml(falloutHandlerRequest)
+ utils.logAudit(xmlHandlerRequest)
+
+ execution.setVariable(prefix+'FalloutHandlerRequest', xmlHandlerRequest)
+ utils.log("ERROR", "Overall Error Response going to FalloutHandler: " + "\n" + xmlHandlerRequest, isDebugEnabled)
+ }
+
+
+ /**
+ * Query AAI service instance
+ * @param execution
+ * @param isDebugEnabled
+ */
+ public void callRESTQueryAAIServiceInstance(Execution execution, isDebugEnabled) {
+
+ def request = execution.getVariable(prefix+"Request")
+ def serviceInstanceId = utils.getNodeText1(request, "service-instance-id")
+
+ AaiUtil aaiUtil = new AaiUtil(this)
+ String aaiEndpoint = aaiUtil.getSearchNodesQueryEndpoint(execution)
+
+ def String queryAAIRequest = aaiEndpoint + "?search-node-type=service-instance&filter=service-instance-id:EQUALS:" + serviceInstanceId
+ utils.logAudit("AAI query service instance request: " + queryAAIRequest)
+
+ APIResponse response = aaiUtil.executeAAIGetCall(execution, queryAAIRequest)
+
+ String returnCode = response.getStatusCode()
+ String aaiResponseAsString = response.getResponseBodyAsString()
+ aaiResponseAsString = StringEscapeUtils.unescapeXml(aaiResponseAsString)
+
+ utils.logAudit("AAI query service instance return code: " + returnCode)
+ utils.logAudit("AAI query service instance response: " + aaiResponseAsString)
+
+ utils.log("DEBUG", "AAI query service instance return code: " + returnCode, isDebugEnabled)
+ utils.log("DEBUG", "AAI query service instance response: " + aaiResponseAsString, isDebugEnabled)
+
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+
+ if (returnCode=='200') {
+ utils.log("DEBUG", 'Service instance ' + serviceInstanceId + ' found in AAI.', isDebugEnabled)
+ } else {
+ if (returnCode=='404') {
+ def message = 'Service instance ' + serviceInstanceId + ' was not found in AAI. Return code: 404.'
+ utils.log("DEBUG", message, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, message)
+ } else {
+ WorkflowException aWorkflowException = exceptionUtil.MapAAIExceptionToWorkflowException(aaiResponseAsString, execution)
+ throw new BpmnError("MSOWorkflowException")
+ }
+ }
+ }
+}
utils.log("DEBUG", "*** COMPLETED CreateVnfInfra SendSyncResponse Process ***", isDebugEnabled)
}
- public void prepareCreateGenericVnf (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix",Prefix)
-
- utils.log("DEBUG", " *** STARTED CreateVnfInfra PrepareCreateGenericVnf Process *** ", isDebugEnabled)
- try {
- //Get Vnf Info
- String vnfId = execution.getVariable("CREVI_vnfId")
- def vnfName = execution.getVariable("CREVI_vnfName")
- def vnfType = execution.getVariable("CREVI_vnfType")
- def serviceId = execution.getVariable("CREVI_serviceId")
- def orchStatus = execution.getVariable("CREVI_orchStatus")
- def modelInvariantId = execution.getVariable("CREVI_modelInvariantId")
- def modelVersion = execution.getVariable("CREVI_modelVersion")
- // TODO: 1702 Variable
- def equipmentRole = execution.getVariable("CREVI_equipmentRole")
-
- //Get Service Instance Info
- def serviceInstanceId = execution.getVariable("CREVI_serviceInstanceId")
- String siRelatedLink = execution.getVariable("GENGS_siResourceLink")
-
- int custStart = siRelatedLink.indexOf("customer/")
- int custEnd = siRelatedLink.indexOf("/service-subscriptions")
- String globalCustId = siRelatedLink.substring(custStart + 9, custEnd)
- int serviceStart = siRelatedLink.indexOf("service-subscription/")
- int serviceEnd = siRelatedLink.indexOf("/service-instances/")
- String serviceType = siRelatedLink.substring(serviceStart + 21, serviceEnd)
-
- //Get Namespace
- AaiUtil aaiUtil = new AaiUtil(this)
- def aai_uri = aaiUtil.getNetworkGenericVnfUri(execution)
- String namespace = aaiUtil.getNamespaceFromUri(aai_uri)
-
- String payload =
- """<generic-vnf xmlns="${namespace}">
- <vnf-id>${vnfId}</vnf-id>
- <vnf-name>${vnfName}</vnf-name>
- <service-id>${serviceId}</service-id>
- <vnf-type>${vnfType}</vnf-type>
- <orchestration-status>${orchStatus}</orchestration-status>
- <persona-model-id>${modelInvariantId}</persona-model-id>
- <persona-model-version>${modelVersion}</persona-model-version>
- <relationship-list>
- <relationship>
- <related-to>service-instance</related-to>
- <related-link>${siRelatedLink}</related-link>
- <relationship-data>
- <relationship-key>customer.global-customer-id</relationship-key>
- <relationship-value>${globalCustId}</relationship-value>
- </relationship-data>
- <relationship-data>
- <relationship-key>service-subscription.service-type</relationship-key>
- <relationship-value>${serviceType}</relationship-value>
- </relationship-data>
- <relationship-data>
- <relationship-key>service-instance.service-instance-id</relationship-key>
- <relationship-value>${serviceInstanceId}</relationship-value>
- </relationship-data>
- </relationship>
- </relationship-list>
- </generic-vnf>"""
-
- execution.setVariable("CREVI_genericVnfPayload", payload)
-
- }catch(Exception ex) {
- utils.log("DEBUG", "Error Occured in CreateVnfInfra PrepareCreateGenericVnf Process " + ex.getMessage(), isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in CreateVnfInfra PrepareCreateGenericVnf Process")
- }
- utils.log("DEBUG", "*** COMPLETED CreateVnfInfra PrepareCreateGenericVnf Process ***", isDebugEnabled)
- }
public void preProcessSDNCAssignRequest(Execution execution){
def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-\r
-import groovy.xml.XmlUtil\r
-import groovy.json.*\r
-\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse;\r
-\r
-import java.util.UUID;\r
-import javax.xml.parsers.DocumentBuilder\r
-import javax.xml.parsers.DocumentBuilderFactory\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution\r
-import org.json.JSONObject;\r
-import org.apache.commons.lang3.*\r
-import org.apache.commons.codec.binary.Base64;\r
-import org.w3c.dom.Document\r
-import org.w3c.dom.Element\r
-import org.w3c.dom.Node\r
-import org.w3c.dom.NodeList\r
-import org.xml.sax.InputSource\r
-import static org.apache.commons.lang3.StringUtils.*;\r
-\r
-import org.springframework.web.util.UriUtils;\r
-\r
-/**\r
- * This groovy class supports the <class>DelServiceInstance.bpmn</class> process.\r
- *\r
- */\r
-public class DelServiceInstance extends AbstractServiceTaskProcessor {\r
-\r
- String Prefix="DELSI_"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils()\r
- \r
- public void preProcessRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- String msg = ""\r
- \r
- utils.log("DEBUG", " *** preProcessRequest Request *** ", isDebugEnabled)\r
-\r
- try {\r
- // check for incoming json message/input\r
- String siRequest = execution.getVariable("bpmnRequest")\r
- utils.logAudit(siRequest)\r
- \r
-\r
- String requestId = execution.getVariable("mso-request-id")\r
- execution.setVariable("msoRequestId", requestId)\r
- utils.log("DEBUG", "Input Request:" + siRequest + " reqId:" + requestId, isDebugEnabled)\r
- \r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- if (isBlank(serviceInstanceId)) {\r
- msg = "Input serviceInstanceId' is null"\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- }\r
- \r
- //String xmlRequestDetails = vidUtils.getJsonRequestDetailstoXml(siRequest)\r
- //execution.setVariable("requestDetails", xmlRequestDetails)\r
- \r
- //modelInfo\r
- String serviceModelInfo = jsonUtil.getJsonValue(siRequest, "requestDetails.modelInfo")\r
- if (isBlank(serviceModelInfo)) {\r
- msg = "Input serviceModelInfo is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- } else\r
- {\r
- execution.setVariable("serviceModelInfo", serviceModelInfo)\r
- //utils.log("DEBUG", "modelInfo" + serviceModelInfo, isDebugEnabled)\r
- }\r
- \r
- //requestInfo\r
- String productFamilyId = jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.productFamilyId")\r
- if (isBlank(productFamilyId))\r
- {\r
- msg = "Input productFamilyId is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- //exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- } else {\r
- execution.setVariable("productFamilyId", productFamilyId)\r
- }\r
- String source = jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.source")\r
- execution.setVariable("source", source)\r
- \r
- //subscriberInfo\r
- String globalSubscriberId = jsonUtil.getJsonValue(siRequest, "requestDetails.subscriberInfo.globalSubscriberId")\r
- if (isBlank(globalSubscriberId)) {\r
- msg = "Input globalSubscriberId' is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- } else {\r
- execution.setVariable("globalSubscriberId", globalSubscriberId)\r
- }\r
- \r
- //requestParameters\r
- String subscriptionServiceType = jsonUtil.getJsonValue(siRequest, "requestDetails.requestParameters.subscriptionServiceType")\r
- if (isBlank(subscriptionServiceType)) {\r
- msg = "Input subscriptionServiceType is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- //exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- } else {\r
- execution.setVariable("subscriptionServiceType", subscriptionServiceType)\r
- }\r
-\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception ex){\r
- msg = "Exception in preProcessRequest " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
- }\r
- utils.log("DEBUG"," ***** Exit preProcessRequest *****", isDebugEnabled)\r
- }\r
-\r
- public void sendSyncResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** sendSyncResponse *** ", isDebugEnabled)\r
-\r
- try {\r
- String requestId = execution.getVariable("msoRequestId")\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
-\r
- // RESTResponse (for API Handler (APIH) Reply Task)\r
- String syncResponse = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()\r
- utils.log("DEBUG", " sendSynchResponse: xmlSyncResponse - " + "\n" + syncResponse, isDebugEnabled)\r
- sendWorkflowResponse(execution, 202, syncResponse)\r
-\r
- } catch (Exception ex) {\r
- String msg = "Exception in sendSyncResponse: " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- utils.log("DEBUG"," ***** Exit sendSyncResopnse *****", isDebugEnabled)\r
- }\r
- \r
- public void sendSyncError (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** sendSyncError *** ", isDebugEnabled)\r
-\r
- try {\r
- String errorMessage = ""\r
- if (execution.getVariable("WorkflowException") instanceof WorkflowException) {\r
- WorkflowException wfe = execution.getVariable("WorkflowException")\r
- errorMessage = wfe.getErrorMessage()\r
- } else {\r
- errorMessage = "Sending Sync Error."\r
- }\r
-\r
- String buildworkflowException =\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+package org.openecomp.mso.bpmn.infrastructure.scripts;
+
+import groovy.xml.XmlUtil
+import groovy.json.*
+
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.rest.APIResponse;
+
+import java.util.UUID;
+import javax.xml.parsers.DocumentBuilder
+import javax.xml.parsers.DocumentBuilderFactory
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution
+import org.json.JSONObject;
+import org.apache.commons.lang3.*
+import org.apache.commons.codec.binary.Base64;
+import org.w3c.dom.Document
+import org.w3c.dom.Element
+import org.w3c.dom.Node
+import org.w3c.dom.NodeList
+import org.xml.sax.InputSource
+import static org.apache.commons.lang3.StringUtils.*;
+
+import org.springframework.web.util.UriUtils;
+
+/**
+ * This groovy class supports the <class>DelServiceInstance.bpmn</class> process.
+ *
+ */
+public class DeleteGenericALaCarteServiceInstance extends AbstractServiceTaskProcessor {
+
+ String Prefix="DELSI_"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils()
+
+ public void preProcessRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ String msg = ""
+
+ utils.log("DEBUG", " *** preProcessRequest Request *** ", isDebugEnabled)
+
+ try {
+ // check for incoming json message/input
+ String siRequest = execution.getVariable("bpmnRequest")
+ utils.logAudit(siRequest)
+
+
+ String requestId = execution.getVariable("mso-request-id")
+ execution.setVariable("msoRequestId", requestId)
+ utils.log("DEBUG", "Input Request:" + siRequest + " reqId:" + requestId, isDebugEnabled)
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ if (isBlank(serviceInstanceId)) {
+ msg = "Input serviceInstanceId' is null"
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ }
+
+ //String xmlRequestDetails = vidUtils.getJsonRequestDetailstoXml(siRequest)
+ //execution.setVariable("requestDetails", xmlRequestDetails)
+
+ //modelInfo
+ String serviceModelInfo = jsonUtil.getJsonValue(siRequest, "requestDetails.modelInfo")
+ if (isBlank(serviceModelInfo)) {
+ msg = "Input serviceModelInfo is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ } else
+ {
+ execution.setVariable("serviceModelInfo", serviceModelInfo)
+ //utils.log("DEBUG", "modelInfo" + serviceModelInfo, isDebugEnabled)
+ }
+
+ //requestInfo
+ String productFamilyId = jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.productFamilyId")
+ if (isBlank(productFamilyId))
+ {
+ msg = "Input productFamilyId is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ //exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ } else {
+ execution.setVariable("productFamilyId", productFamilyId)
+ }
+ String source = jsonUtil.getJsonValue(siRequest, "requestDetails.requestInfo.source")
+ execution.setVariable("source", source)
+
+ //subscriberInfo
+ String globalSubscriberId = jsonUtil.getJsonValue(siRequest, "requestDetails.subscriberInfo.globalSubscriberId")
+ if (isBlank(globalSubscriberId)) {
+ msg = "Input globalSubscriberId' is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ } else {
+ execution.setVariable("globalSubscriberId", globalSubscriberId)
+ }
+
+ //requestParameters
+ String subscriptionServiceType = jsonUtil.getJsonValue(siRequest, "requestDetails.requestParameters.subscriptionServiceType")
+ if (isBlank(subscriptionServiceType)) {
+ msg = "Input subscriptionServiceType is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ //exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ } else {
+ execution.setVariable("subscriptionServiceType", subscriptionServiceType)
+ }
+
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception ex){
+ msg = "Exception in preProcessRequest " + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG"," ***** Exit preProcessRequest *****", isDebugEnabled)
+ }
+
+ public void sendSyncResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** sendSyncResponse *** ", isDebugEnabled)
+
+ try {
+ String requestId = execution.getVariable("msoRequestId")
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ // RESTResponse (for API Handler (APIH) Reply Task)
+ String syncResponse = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()
+ utils.log("DEBUG", " sendSynchResponse: xmlSyncResponse - " + "\n" + syncResponse, isDebugEnabled)
+ sendWorkflowResponse(execution, 202, syncResponse)
+
+ } catch (Exception ex) {
+ String msg = "Exception in sendSyncResponse: " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ utils.log("DEBUG"," ***** Exit sendSyncResopnse *****", isDebugEnabled)
+ }
+
+ public void sendSyncError (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** sendSyncError *** ", isDebugEnabled)
+
+ try {
+ String errorMessage = ""
+ if (execution.getVariable("WorkflowException") instanceof WorkflowException) {
+ WorkflowException wfe = execution.getVariable("WorkflowException")
+ errorMessage = wfe.getErrorMessage()
+ } else {
+ errorMessage = "Sending Sync Error."
+ }
+
+ String buildworkflowException =
"""<aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>7000</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>"""\r
-\r
- utils.logAudit(buildworkflowException)\r
- sendWorkflowResponse(execution, 500, buildworkflowException)\r
-\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", " Sending Sync Error Activity Failed. " + "\n" + ex.getMessage(), isDebugEnabled)\r
- }\r
-\r
- }\r
- \r
- public void prepareCompletionRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** prepareCompletion *** ", isDebugEnabled)\r
-\r
- try {\r
- String requestId = execution.getVariable("msoRequestId")\r
- String source = execution.getVariable("source")\r
- String msoCompletionRequest =\r
+ <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>7000</aetgt:ErrorCode>
+ </aetgt:WorkflowException>"""
+
+ utils.logAudit(buildworkflowException)
+ sendWorkflowResponse(execution, 500, buildworkflowException)
+
+ } catch (Exception ex) {
+ utils.log("DEBUG", " Sending Sync Error Activity Failed. " + "\n" + ex.getMessage(), isDebugEnabled)
+ }
+
+ }
+
+ public void prepareCompletionRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** prepareCompletion *** ", isDebugEnabled)
+
+ try {
+ String requestId = execution.getVariable("msoRequestId")
+ String source = execution.getVariable("source")
+ String msoCompletionRequest =
"""<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
xmlns:ns="http://org.openecomp/mso/request/types/v1">\r
<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>DELETE</action>\r
- <source>${source}</source>\r
- </request-info>\r
- <aetgt:status-message>Service Instance was deleted successfully.</aetgt:status-message>\r
- <aetgt:mso-bpel-name>DelServiceInstance</aetgt:mso-bpel-name>\r
- </aetgt:MsoCompletionRequest>"""\r
-\r
- // Format Response\r
- String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)\r
-\r
- execution.setVariable("completionRequest", xmlMsoCompletionRequest)\r
- utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)\r
-\r
- } catch (Exception ex) {\r
- String msg = " Exception in prepareCompletion:" + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
- }\r
- utils.log("DEBUG", "*** Exit prepareCompletionRequest ***", isDebugEnabled)\r
- }\r
- \r
- public void prepareFalloutRequest(Execution execution){\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** prepareFalloutRequest *** ", isDebugEnabled)\r
-\r
- try {\r
- WorkflowException wfex = execution.getVariable("WorkflowException")\r
- utils.log("DEBUG", " Input Workflow Exception: " + wfex.toString(), isDebugEnabled)\r
- String requestId = execution.getVariable("msoRequestId")\r
- String source = execution.getVariable("source")\r
- String requestInfo =\r
+ <request-id>${requestId}</request-id>
+ <action>DELETE</action>
+ <source>${source}</source>
+ </request-info>
+ <aetgt:status-message>Service Instance was deleted successfully.</aetgt:status-message>
+ <aetgt:mso-bpel-name>DeleteGenericALaCarteServiceInstance</aetgt:mso-bpel-name>
+ </aetgt:MsoCompletionRequest>"""
+
+ // Format Response
+ String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)
+
+ execution.setVariable("completionRequest", xmlMsoCompletionRequest)
+ utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)
+
+ } catch (Exception ex) {
+ String msg = " Exception in prepareCompletion:" + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG", "*** Exit prepareCompletionRequest ***", isDebugEnabled)
+ }
+
+ public void prepareFalloutRequest(Execution execution){
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** prepareFalloutRequest *** ", isDebugEnabled)
+
+ try {
+ WorkflowException wfex = execution.getVariable("WorkflowException")
+ utils.log("DEBUG", " Input Workflow Exception: " + wfex.toString(), isDebugEnabled)
+ String requestId = execution.getVariable("msoRequestId")
+ String source = execution.getVariable("source")
+ String requestInfo =
"""<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>DELETE</action>\r
- <source>${source}</source>\r
- </request-info>"""\r
-\r
- String falloutRequest = exceptionUtil.processMainflowsBPMNException(execution, requestInfo)\r
- execution.setVariable("falloutRequest", falloutRequest)\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", "Exception prepareFalloutRequest:" + ex.getMessage(), isDebugEnabled)\r
- String errorException = " Bpmn error encountered in CreateServiceInstance flow. FalloutHandlerRequest, buildErrorResponse() - " + ex.getMessage()\r
- String requestId = execution.getVariable("msoRequestId")\r
- String falloutRequest =\r
+ <request-id>${requestId}</request-id>
+ <action>DELETE</action>
+ <source>${source}</source>
+ </request-info>"""
+
+ String falloutRequest = exceptionUtil.processMainflowsBPMNException(execution, requestInfo)
+ execution.setVariable("falloutRequest", falloutRequest)
+ } catch (Exception ex) {
+ utils.log("DEBUG", "Exception prepareFalloutRequest:" + ex.getMessage(), isDebugEnabled)
+ String errorException = " Bpmn error encountered in CreateServiceInstance flow. FalloutHandlerRequest, buildErrorResponse() - " + ex.getMessage()
+ String requestId = execution.getVariable("msoRequestId")
+ String falloutRequest =
"""<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>DELETE</action>\r
- <source>VID</source>\r
- </request-info>\r
+ <request-id>${requestId}</request-id>
+ <action>DELETE</action>
+ <source>VID</source>
+ </request-info>
<aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorException}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>7000</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>\r
- </aetgt:FalloutHandlerRequest>"""\r
-\r
- execution.setVariable("falloutRequest", falloutRequest)\r
- }\r
- utils.log("DEBUG", "*** Exit prepareFalloutRequest ***", isDebugEnabled)\r
- }\r
- \r
-\r
- // *******************************\r
- // Build DB request Section\r
- // *******************************\r
- public void prepareDBRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside prepareDBRequest of DeleteServiceInstance ***** ", isDebugEnabled)\r
-\r
- String requestId = execution.getVariable("DELSI_requestId")\r
- String statusMessage = "Service Instance successfully deleted."\r
-\r
- //TODO - verify the format for Service Instance Delete,\r
- String dbRequest =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
+ <aetgt:ErrorMessage>${errorException}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>7000</aetgt:ErrorCode>
+ </aetgt:WorkflowException>
+ </aetgt:FalloutHandlerRequest>"""
+
+ execution.setVariable("falloutRequest", falloutRequest)
+ }
+ utils.log("DEBUG", "*** Exit prepareFalloutRequest ***", isDebugEnabled)
+ }
+
+
+ // *******************************
+ // Build DB request Section
+ // *******************************
+ public void prepareDBRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+
+ try {
+ utils.log("DEBUG", " ***** Inside prepareDBRequest of DeleteGenericALaCarteServiceInstance ***** ", isDebugEnabled)
+
+ String requestId = execution.getVariable("DELSI_requestId")
+ String statusMessage = "Service Instance successfully deleted."
+
+ //TODO - verify the format for Service Instance Delete,
+ String dbRequest =
+ """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
+ <soapenv:Header/>
+ <soapenv:Body>
<ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <requestId>${requestId}</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>${statusMessage}</statusMessage>\r
- <responseBody></responseBody>\r
- <requestStatus>COMPLETED</requestStatus>\r
- <progress>100</progress>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
- </soapenv:Envelope>"""\r
-\r
- String buildDeleteDBRequestAsString = utils.formatXml(dbRequest)\r
- execution.setVariable("DELSI_createDBRequest", buildDeleteDBRequestAsString)\r
- utils.logAudit(buildDeleteDBRequestAsString)\r
-\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in DeleteServiceInstance flow. Unexpected Error from method prepareDBRequest() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
-\r
- }\r
-\r
- }\r
-\r
- // *******************************\r
- // Build Error Section\r
- // *******************************\r
- public void prepareDBRequestError (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
-\r
- utils.log("DEBUG", " ***** Inside prepareDBRequestError of DeleteServiceInstanceInfra ***** ", isDebugEnabled)\r
-\r
- try {\r
- String requestId = execution.getVariable("DELSI_requestId")\r
- String statusMessage = ""\r
- if (execution.getVariable("WorkflowException") instanceof WorkflowException) {\r
- WorkflowException wfe = execution.getVariable("WorkflowException")\r
- statusMessage = wfe.getErrorMessage()\r
-\r
- } else {\r
- statusMessage = "Encountered Error during DeleteServiceInstanceInfra proccessing. "\r
- }\r
-\r
- //TODO - verify the format for Service Instance Create,\r
- String dbRequest =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
+ <requestId>${requestId}</requestId>
+ <lastModifiedBy>BPMN</lastModifiedBy>
+ <statusMessage>${statusMessage}</statusMessage>
+ <responseBody></responseBody>
+ <requestStatus>COMPLETED</requestStatus>
+ <progress>100</progress>
+ </ns:updateInfraRequest>
+ </soapenv:Body>
+ </soapenv:Envelope>"""
+
+ String buildDeleteDBRequestAsString = utils.formatXml(dbRequest)
+ execution.setVariable("DELSI_createDBRequest", buildDeleteDBRequestAsString)
+ utils.logAudit(buildDeleteDBRequestAsString)
+
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in DeleteGenericALaCarteServiceInstance flow. Unexpected Error from method prepareDBRequest() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+
+ }
+
+ }
+
+ // *******************************
+ // Build Error Section
+ // *******************************
+ public void prepareDBRequestError (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+
+ utils.log("DEBUG", " ***** Inside prepareDBRequestError of DeleteGenericALaCarteServiceInstance ***** ", isDebugEnabled)
+
+ try {
+ String requestId = execution.getVariable("DELSI_requestId")
+ String statusMessage = ""
+ if (execution.getVariable("WorkflowException") instanceof WorkflowException) {
+ WorkflowException wfe = execution.getVariable("WorkflowException")
+ statusMessage = wfe.getErrorMessage()
+
+ } else {
+ statusMessage = "Encountered Error during DeleteGenericALaCarteServiceInstance proccessing. "
+ }
+
+ //TODO - verify the format for Service Instance Create,
+ String dbRequest =
+ """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
+ <soapenv:Header/>
+ <soapenv:Body>
<ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <requestId>${requestId}</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>${statusMessage}</statusMessage>\r
- <responseBody></responseBody>\r
- <requestStatus>FAILED</requestStatus>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
- </soapenv:Envelope>"""\r
-\r
- String buildDBRequestAsString = utils.formatXml(dbRequest)\r
- execution.setVariable("DELSI_createDBInfraErrorRequest", buildDBRequestAsString)\r
- utils.logAudit(buildDBRequestAsString)\r
-\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in DeleteServiceInstanceInfra flow. Unexpected Error from method prepareDBRequestError() - " + ex.getMessage()\r
- exceptionUtil.buildWorkflowException(execution, 7000, exceptionMessage)\r
-\r
- }\r
-\r
- }\r
-}\r
+ <requestId>${requestId}</requestId>
+ <lastModifiedBy>BPMN</lastModifiedBy>
+ <statusMessage>${statusMessage}</statusMessage>
+ <responseBody></responseBody>
+ <requestStatus>FAILED</requestStatus>
+ </ns:updateInfraRequest>
+ </soapenv:Body>
+ </soapenv:Envelope>"""
+
+ String buildDBRequestAsString = utils.formatXml(dbRequest)
+ execution.setVariable("DELSI_createDBInfraErrorRequest", buildDBRequestAsString)
+ utils.logAudit(buildDBRequestAsString)
+
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in DeleteGenericALaCarteServiceInstance flow. Unexpected Error from method prepareDBRequestError() - " + ex.getMessage()
+ exceptionUtil.buildWorkflowException(execution, 7000, exceptionMessage)
+
+ }
+
+ }
+}
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-\r
-import groovy.xml.XmlUtil\r
-import groovy.json.*\r
-\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.NetworkUtils\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse;\r
-\r
-\r
-import java.util.UUID;\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution\r
-import org.json.JSONObject;\r
-import org.json.JSONArray;\r
-import org.apache.commons.lang3.*\r
-import org.apache.commons.codec.binary.Base64;\r
-import org.springframework.web.util.UriUtils;\r
-\r
-/**\r
- * This groovy class supports the <class>DeleteViprAtmService.bpmn</class> process.\r
- *\r
- */\r
-public class DeleteGenericMacroServiceNetworkVnf extends AbstractServiceTaskProcessor {\r
-\r
- String Prefix="DELVAS_"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils()\r
- CatalogDbUtils catalogDbUtils = new CatalogDbUtils()\r
- NetworkUtils networkUtils = new NetworkUtils()\r
-\r
- /**\r
- * This method is executed during the preProcessRequest task of the <class>DeleteViprAtmService.bpmn</class> process.\r
- * @param execution\r
- */\r
- public InitializeProcessVariables(Execution execution){\r
- /* Initialize all the process variables in this block */\r
-\r
- execution.setVariable("deleteViprAtmServiceRequest", "")\r
- execution.setVariable("msoRequestId", "")\r
- execution.setVariable("DELVAS_vnfsDeletedCount", 0)\r
- execution.setVariable("DELVAS_vnfsCount", 0)\r
- execution.setVariable("DELVAS_networksCount", 0)\r
- execution.setVariable("DELVAS_networksDeletedCount", 0)\r
- }\r
-\r
- // **************************************************\r
- // Pre or Prepare Request Section\r
- // **************************************************\r
- /**\r
- * This method is executed during the preProcessRequest task of the <class>CreateServiceInstance.bpmn</class> process.\r
- * @param execution\r
- */\r
- public void preProcessRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- utils.log("DEBUG", " ***** Inside preProcessRequest DeleteViprAtmService Request ***** ", isDebugEnabled)\r
-\r
- try {\r
- // initialize flow variables\r
- InitializeProcessVariables(execution)\r
-\r
- // check for incoming json message/input\r
- String deleteViprAtmServiceRequest = execution.getVariable("bpmnRequest")\r
- utils.logAudit(deleteViprAtmServiceRequest)\r
- execution.setVariable("deleteViprAtmServiceRequest", deleteViprAtmServiceRequest);\r
- println 'deleteViprAtmServiceRequest - ' + deleteViprAtmServiceRequest\r
-\r
- // extract requestId\r
- String requestId = execution.getVariable("mso-request-id")\r
- execution.setVariable("msoRequestId", requestId)\r
-\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- if ((serviceInstanceId == null) || (serviceInstanceId.isEmpty())) {\r
- String dataErrorMessage = " Element 'serviceInstanceId' is missing. "\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)\r
- }\r
- \r
- String requestAction = execution.getVariable("requestAction")\r
- execution.setVariable("requestAction", requestAction)\r
-\r
- String source = jsonUtil.getJsonValue(deleteViprAtmServiceRequest, "requestDetails.requestInfo.source")\r
- if ((source == null) || (source.isEmpty())) {\r
- execution.setVariable("source", "VID")\r
- } else {\r
- execution.setVariable("source", source)\r
- }\r
-\r
- // extract globalSubscriberId\r
- String globalSubscriberId = jsonUtil.getJsonValue(deleteViprAtmServiceRequest, "requestDetails.subscriberInfo.globalSubscriberId")\r
-\r
- // global-customer-id is optional on Delete\r
-\r
- execution.setVariable("globalSubscriberId", globalSubscriberId)\r
- execution.setVariable("globalCustomerId", globalSubscriberId)\r
- \r
- String suppressRollback = jsonUtil.getJsonValue(deleteViprAtmServiceRequest, "requestDetails.requestInfo.suppressRollback")\r
- execution.setVariable("disableRollback", suppressRollback)\r
- utils.log("DEBUG", "Incoming Suppress/Disable Rollback is: " + suppressRollback, isDebugEnabled)\r
- \r
- String productFamilyId = jsonUtil.getJsonValue(deleteViprAtmServiceRequest, "requestDetails.requestInfo.productFamilyId")\r
- execution.setVariable("productFamilyId", productFamilyId)\r
- utils.log("DEBUG", "Incoming productFamilyId is: " + productFamilyId, isDebugEnabled)\r
- \r
- // extract subscriptionServiceType\r
- String subscriptionServiceType = jsonUtil.getJsonValue(deleteViprAtmServiceRequest, "requestDetails.requestParameters.subscriptionServiceType")\r
- execution.setVariable("subscriptionServiceType", subscriptionServiceType)\r
- utils.log("DEBUG", "Incoming subscriptionServiceType is: " + subscriptionServiceType, isDebugEnabled)\r
- \r
- // extract cloud configuration\r
- String lcpCloudRegionId = jsonUtil.getJsonValue(deleteViprAtmServiceRequest, "requestDetails.cloudConfiguration.lcpCloudRegionId")\r
- execution.setVariable("lcpCloudRegionId", lcpCloudRegionId)\r
- utils.log("DEBUG","lcpCloudRegionId: "+ lcpCloudRegionId, isDebugEnabled)\r
- String tenantId = jsonUtil.getJsonValue(deleteViprAtmServiceRequest, "requestDetails.cloudConfiguration.tenantId")\r
- execution.setVariable("tenantId", tenantId)\r
- utils.log("DEBUG","tenantId: "+ tenantId, isDebugEnabled)\r
-\r
- String sdncVersion = "1702"\r
- execution.setVariable("sdncVersion", sdncVersion)\r
- utils.log("DEBUG","sdncVersion: "+ sdncVersion, isDebugEnabled)\r
- \r
- //For Completion Handler & Fallout Handler\r
- String requestInfo =\r
- """<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>DELETE</action>\r
- <source>${source}</source>\r
- </request-info>"""\r
-\r
- execution.setVariable("DELVAS_requestInfo", requestInfo)\r
- \r
- //Setting for Generic Sub Flows\r
- execution.setVariable("GENGS_type", "service-instance")\r
- \r
- utils.log("DEBUG", " ***** Completed preProcessRequest DeleteViprAtmService Request ***** ", isDebugEnabled)\r
-\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception ex){\r
- String exceptionMessage = "Bpmn error encountered in DeleteViprAtmService flow. Unexpected from method preProcessRequest() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
-\r
- public void sendSyncResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- utils.log("DEBUG", " ***** Inside sendSyncResponse of DeleteViprAtmService ***** ", isDebugEnabled)\r
-\r
- try {\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- String requestId = execution.getVariable("mso-request-id")\r
-\r
- // RESTResponse (for API Handler (APIH) Reply Task)\r
- String syncResponse ="""{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()\r
-\r
- utils.log("DEBUG", " sendSynchResponse: xmlSyncResponse - " + "\n" + syncResponse, isDebugEnabled)\r
- sendWorkflowResponse(execution, 202, syncResponse)\r
- } catch (Exception ex) {\r
- String exceptionMessage = "Bpmn error encountered in DeleteViprAtmService flow. Unexpected from method sendSyncResponse() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
-\r
- public void prepareServiceInstanceDelete (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " ***** Inside prepareServiceInstanceDelete() of DeleteViprAtmService ***** ", isDebugEnabled)\r
- \r
- try {\r
- \r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- \r
- // confirm if ServiceInstance was found\r
- if ( !execution.getVariable("GENGS_FoundIndicator") )\r
- {\r
- String exceptionMessage = "Bpmn error encountered in DeleteViprAtmService flow. Service Instance was not found in AAI by id: " + serviceInstanceId\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- \r
- // get variable within incoming json\r
- String deleteViprAtmServiceRequest = execution.getVariable("deleteViprAtmServiceRequest");\r
- \r
- // get SI extracted by GenericGetService\r
- String serviceInstanceAaiRecord = execution.getVariable("GENGS_service");\r
- \r
- utils.log("DEBUG", "serviceInstanceAaiRecord: "+serviceInstanceAaiRecord, isDebugEnabled)\r
- \r
- String relationship = ""\r
- try {\r
- relationship = networkUtils.getFirstNodeXml(serviceInstanceAaiRecord, "relationship-list")\r
- } catch (Exception ex) {\r
- //no relationships found\r
- }\r
- utils.log("DEBUG", " relationship string - " + relationship, isDebugEnabled)\r
- \r
- int vnfsCount = 0\r
- int networksCount = 0\r
- \r
- if (relationship != null && relationship.length() > 0){\r
- relationship = relationship.trim().replace("tag0:","").replace(":tag0","")\r
- \r
- // Check if Network TableREf is present, then build a List of network policy\r
- List relatedVnfIdList = networkUtils.getRelatedVnfIdList(relationship)\r
- vnfsCount = relatedVnfIdList.size()\r
- execution.setVariable("DELVAS_vnfsCount", vnfsCount)\r
- utils.log("DEBUG", " DELVAS_vnfsCount : " + vnfsCount, isDebugEnabled)\r
- execution.setVariable("DELVAS_relatedVnfIdList", relatedVnfIdList)\r
- \r
- // Check if Network TableREf is present, then build a List of network policy\r
- List relatedNetworkIdList = networkUtils.getRelatedNetworkIdList(relationship)\r
- networksCount = relatedNetworkIdList.size()\r
- execution.setVariable("DELVAS_networksCount", networksCount)\r
- utils.log("DEBUG", " DELVAS_networksCount : " + networksCount, isDebugEnabled)\r
- execution.setVariable("DELVAS_relatedNetworkIdList", relatedNetworkIdList)\r
- } else {\r
- execution.setVariable("DELVAS_vnfsCount", 0)\r
- utils.log("DEBUG", " DELVAS_vnfsCount : " + vnfsCount, isDebugEnabled)\r
- execution.setVariable("DELVAS_networksCount", 0)\r
- utils.log("DEBUG", " DELVAS_networksCount : " + networksCount, isDebugEnabled)\r
- }\r
- \r
- utils.log("DEBUG", " ***** Completed prepareServiceInstanceDelete() of DeleteViprAtmService ***** ", isDebugEnabled)\r
- } catch (Exception ex) {\r
- sendSyncError(execution)\r
- String exceptionMessage = "Bpmn error encountered in DeleteViprAtmService flow. prepareServiceInstanceDelete() - " + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- \r
- // *******************************\r
- // \r
- // *******************************\r
- public void prepareVnfAndModulesDelete (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside prepareVnfAndModulesDelete of DeleteServiceInstanceMacro ***** ", isDebugEnabled)\r
-\r
- List vnfList = execution.getVariable("DELVAS_relatedVnfIdList")\r
- Integer vnfsDeletedCount = execution.getVariable("DELVAS_vnfsDeletedCount")\r
- String vnfModelInfoString = ""\r
- String vnfId = ""\r
- if (vnfList.size() > 0 ) {\r
- vnfId = vnfList.get(vnfsDeletedCount.intValue())\r
- }\r
- \r
- execution.setVariable("vnfId", vnfId)\r
- utils.log("DEBUG", "need to delete vnfId:" + vnfId, isDebugEnabled)\r
-\r
- utils.log("DEBUG", " ***** Completed prepareVnfAndModulesDelete of DeleteServiceInstanceMacro ***** ", isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in DeleteServiceInstanceMacro flow. Unexpected Error from method prepareVnfAndModulesDelete() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- // *******************************\r
- // Validate Vnf request Section -> increment count\r
- // *******************************\r
- public void validateVnfDelete (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside validateVnfDelete of DeleteViprAtmService ***** ", isDebugEnabled)\r
-\r
- String vnfsDeletedCount = execution.getVariable("DELVAS_vnfsDeletedCount")\r
- vnfsDeletedCount++\r
- \r
- execution.setVariable("DELVAS_vnfsDeletedCount", vnfsDeletedCount)\r
- \r
- utils.log("DEBUG", " ***** Completed validateVnfDelete of DeleteViprAtmService ***** "+" vnf # "+vnfsDeletedCount, isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in DeleteViprAtmService flow. Unexpected Error from method validateVnfDelete() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- // *******************************\r
- // Generate Network request Section\r
- // *******************************\r
- public void prepareNetworkDelete (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside prepareNetworkDelete of DeleteViprAtmService ***** ", isDebugEnabled)\r
-\r
- List networkList = execution.getVariable("DELVAS_relatedNetworkIdList")\r
- Integer networksDeletedCount = execution.getVariable("DELVAS_networksDeletedCount")\r
-\r
- String networkId = ""\r
- if (networkList.size() > 0) {\r
- networkId = networkList.get(networksDeletedCount.intValue())\r
- }\r
- \r
- execution.setVariable("networkId", networkId)\r
- utils.log("DEBUG", "need to delete networkId:" + networkId, isDebugEnabled)\r
- \r
- utils.log("DEBUG", " ***** Completed prepareNetworkDelete of DeleteViprAtmService ***** ", isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = q"Bpmn error encountered in DeleteViprAtmService flow. Unexpected Error from method prepareNetworkDelete() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
- \r
- // *******************************\r
- // Validate Network request Section\r
- // *******************************\r
- public void validateNetworkDelete (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside validateNetworkDelete of DeleteViprAtmService ***** ", isDebugEnabled)\r
-\r
- Integer networksDeletedCount = execution.getVariable("DELVAS_networksDeletedCount")\r
- networksDeletedCount++\r
- \r
- execution.setVariable("DELVAS_networksDeletedCount", networksDeletedCount)\r
- \r
- utils.log("DEBUG", " ***** Completed validateNetworkDelete of DeleteViprAtmService ***** ", isDebugEnabled)\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in DeleteViprAtmService flow. Unexpected Error from method validateNetworkDelete() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
-\r
- \r
- // *****************************************\r
- // Prepare Completion request Section\r
- // *****************************************\r
- public void postProcessResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " ***** Inside postProcessResponse of DeleteViprAtmService ***** ", isDebugEnabled)\r
-\r
- try {\r
- String source = execution.getVariable("source")\r
- String requestId = execution.getVariable("msoRequestId")\r
-\r
- String msoCompletionRequest =\r
- """<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>DELETE</action>\r
- <source>${source}</source>\r
- </request-info>\r
- <aetgt:status-message>vIPR ATM Service Instance has been deleted successfully.</aetgt:status-message>\r
- <aetgt:mso-bpel-name>BPMN Service Instance macro action: DELETE</aetgt:mso-bpel-name>\r
- </aetgt:MsoCompletionRequest>"""\r
-\r
- // Format Response\r
- String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)\r
-\r
- utils.logAudit(xmlMsoCompletionRequest)\r
- execution.setVariable("DELVAS_Success", true)\r
- execution.setVariable("DELVAS_CompleteMsoProcessRequest", xmlMsoCompletionRequest)\r
- utils.log("DEBUG", " SUCCESS flow, going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
-\r
- } catch (Exception ex) {\r
- // try error in method block\r
- String exceptionMessage = "Bpmn error encountered in DeleteServiceInstance flow. Unexpected Error from method postProcessResponse() - " + ex.getMessage()\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- }\r
- }\r
-\r
- public void prepareFalloutRequest(Execution execution){\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " *** STARTED DeleteViprAtmService prepareFalloutRequest Process *** ", isDebugEnabled)\r
-\r
- try {\r
- WorkflowException wfex = execution.getVariable("WorkflowException")\r
- utils.log("DEBUG", " Incoming Workflow Exception: " + wfex.toString(), isDebugEnabled)\r
- String requestInfo = execution.getVariable("DELVAS_requestInfo")\r
- utils.log("DEBUG", " Incoming Request Info: " + requestInfo, isDebugEnabled)\r
-\r
- String falloutRequest = exceptionUtil.processMainflowsBPMNException(execution, requestInfo)\r
-\r
- execution.setVariable("DELVAS_falloutRequest", falloutRequest)\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", "Error Occured in DeleteViprAtmService prepareFalloutRequest Process " + ex.getMessage(), isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DeleteViprAtmService prepareFalloutRequest Process")\r
- }\r
- utils.log("DEBUG", "*** COMPLETED DeleteViprAtmService prepareFalloutRequest Process ***", isDebugEnabled)\r
- }\r
-\r
-\r
- public void sendSyncError (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG", " ***** Inside sendSyncError() of DeleteServiceInstanceInfra ***** ", isDebugEnabled)\r
-\r
- try {\r
- String errorMessage = ""\r
- if (execution.getVariable("WorkflowException") instanceof WorkflowException) {\r
- WorkflowException wfe = execution.getVariable("WorkflowException")\r
- errorMessage = wfe.getErrorMessage()\r
- } else {\r
- errorMessage = "Sending Sync Error."\r
- }\r
-\r
- String buildworkflowException =\r
- """<aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>7000</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>"""\r
-\r
- utils.logAudit(buildworkflowException)\r
- sendWorkflowResponse(execution, 500, buildworkflowException)\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", " Sending Sync Error Activity Failed. " + "\n" + ex.getMessage(), isDebugEnabled)\r
- }\r
- }\r
-\r
- public void processJavaException(Execution execution){\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- try{\r
- utils.log("DEBUG", "Caught a Java Exception", isDebugEnabled)\r
- utils.log("DEBUG", "Started processJavaException Method", isDebugEnabled)\r
- utils.log("DEBUG", "Variables List: " + execution.getVariables(), isDebugEnabled)\r
- execution.setVariable("DELVAS_unexpectedError", "Caught a Java Lang Exception") // Adding this line temporarily until this flows error handling gets updated\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Caught a Java Lang Exception")\r
- }catch(BpmnError b){\r
- utils.log("ERROR", "Rethrowing MSOWorkflowException", isDebugEnabled)\r
- throw b\r
- }catch(Exception e){\r
- utils.log("DEBUG", "Caught Exception during processJavaException Method: " + e, isDebugEnabled)\r
- execution.setVariable("DELVAS_unexpectedError", "Exception in processJavaException method") // Adding this line temporarily until this flows error handling gets updated\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Exception in processJavaException method")\r
- }\r
- utils.log("DEBUG", "Completed processJavaException Method", isDebugEnabled)\r
- }\r
-\r
-\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+package org.openecomp.mso.bpmn.infrastructure.scripts;
+
+import groovy.xml.XmlUtil
+import groovy.json.*
+
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.NetworkUtils
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.rest.APIResponse;
+
+
+import java.util.UUID;
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution
+import org.json.JSONObject;
+import org.json.JSONArray;
+import org.apache.commons.lang3.*
+import org.apache.commons.codec.binary.Base64;
+import org.springframework.web.util.UriUtils;
+
+/**
+ * This groovy class supports the <class>DeleteViprAtmService.bpmn</class> process.
+ *
+ */
+public class DeleteGenericMacroServiceNetworkVnf extends AbstractServiceTaskProcessor {
+
+ String Prefix="DELVAS_"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils()
+ CatalogDbUtils catalogDbUtils = new CatalogDbUtils()
+ NetworkUtils networkUtils = new NetworkUtils()
+
+ /**
+ * This method is executed during the preProcessRequest task of the <class>DeleteGenericMacroServiceNetworkVnf.bpmn</class> process.
+ * @param execution
+ */
+ public InitializeProcessVariables(Execution execution){
+ /* Initialize all the process variables in this block */
+
+ execution.setVariable("DeleteGenericMacroServiceNetworkVnfRequest", "")
+ execution.setVariable("msoRequestId", "")
+ execution.setVariable("DELVAS_vnfsDeletedCount", 0)
+ execution.setVariable("DELVAS_vnfsCount", 0)
+ execution.setVariable("DELVAS_networksCount", 0)
+ execution.setVariable("DELVAS_networksDeletedCount", 0)
+ }
+
+ // **************************************************
+ // Pre or Prepare Request Section
+ // **************************************************
+ /**
+ * This method is executed during the preProcessRequest task of the <class>CreateServiceInstance.bpmn</class> process.
+ * @param execution
+ */
+ public void preProcessRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+
+ utils.log("DEBUG", " ***** Inside preProcessRequest DeleteGenericMacroServiceNetworkVnf Request ***** ", isDebugEnabled)
+
+ try {
+ // initialize flow variables
+ InitializeProcessVariables(execution)
+
+ // check for incoming json message/input
+ String DeleteGenericMacroServiceNetworkVnfRequest = execution.getVariable("bpmnRequest")
+ utils.logAudit(DeleteGenericMacroServiceNetworkVnfRequest)
+ execution.setVariable("DeleteGenericMacroServiceNetworkVnfRequest", DeleteGenericMacroServiceNetworkVnfRequest);
+ println 'DeleteGenericMacroServiceNetworkVnfRequest - ' + DeleteGenericMacroServiceNetworkVnfRequest
+
+ // extract requestId
+ String requestId = execution.getVariable("mso-request-id")
+ execution.setVariable("msoRequestId", requestId)
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ if ((serviceInstanceId == null) || (serviceInstanceId.isEmpty())) {
+ String dataErrorMessage = " Element 'serviceInstanceId' is missing. "
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
+ }
+
+ String requestAction = execution.getVariable("requestAction")
+ execution.setVariable("requestAction", requestAction)
+
+ String source = jsonUtil.getJsonValue(DeleteGenericMacroServiceNetworkVnfRequest, "requestDetails.requestInfo.source")
+ if ((source == null) || (source.isEmpty())) {
+ execution.setVariable("source", "VID")
+ } else {
+ execution.setVariable("source", source)
+ }
+
+ // extract globalSubscriberId
+ String globalSubscriberId = jsonUtil.getJsonValue(DeleteGenericMacroServiceNetworkVnfRequest, "requestDetails.subscriberInfo.globalSubscriberId")
+
+ // global-customer-id is optional on Delete
+
+ execution.setVariable("globalSubscriberId", globalSubscriberId)
+ execution.setVariable("globalCustomerId", globalSubscriberId)
+
+ String suppressRollback = jsonUtil.getJsonValue(DeleteGenericMacroServiceNetworkVnfRequest, "requestDetails.requestInfo.suppressRollback")
+ execution.setVariable("disableRollback", suppressRollback)
+ utils.log("DEBUG", "Incoming Suppress/Disable Rollback is: " + suppressRollback, isDebugEnabled)
+
+ String productFamilyId = jsonUtil.getJsonValue(DeleteGenericMacroServiceNetworkVnfRequest, "requestDetails.requestInfo.productFamilyId")
+ execution.setVariable("productFamilyId", productFamilyId)
+ utils.log("DEBUG", "Incoming productFamilyId is: " + productFamilyId, isDebugEnabled)
+
+ // extract subscriptionServiceType
+ String subscriptionServiceType = jsonUtil.getJsonValue(DeleteGenericMacroServiceNetworkVnfRequest, "requestDetails.requestParameters.subscriptionServiceType")
+ execution.setVariable("subscriptionServiceType", subscriptionServiceType)
+ utils.log("DEBUG", "Incoming subscriptionServiceType is: " + subscriptionServiceType, isDebugEnabled)
+
+ // extract cloud configuration
+ String lcpCloudRegionId = jsonUtil.getJsonValue(DeleteGenericMacroServiceNetworkVnfRequest, "requestDetails.cloudConfiguration.lcpCloudRegionId")
+ execution.setVariable("lcpCloudRegionId", lcpCloudRegionId)
+ utils.log("DEBUG","lcpCloudRegionId: "+ lcpCloudRegionId, isDebugEnabled)
+ String tenantId = jsonUtil.getJsonValue(DeleteGenericMacroServiceNetworkVnfRequest, "requestDetails.cloudConfiguration.tenantId")
+ execution.setVariable("tenantId", tenantId)
+ utils.log("DEBUG","tenantId: "+ tenantId, isDebugEnabled)
+
+ String sdncVersion = "1707"
+ execution.setVariable("sdncVersion", sdncVersion)
+ utils.log("DEBUG","sdncVersion: "+ sdncVersion, isDebugEnabled)
+
+ //For Completion Handler & Fallout Handler
+ String requestInfo =
+ """<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
+ <request-id>${requestId}</request-id>
+ <action>DELETE</action>
+ <source>${source}</source>
+ </request-info>"""
+
+ execution.setVariable("DELVAS_requestInfo", requestInfo)
+
+ //Setting for Generic Sub Flows
+ execution.setVariable("GENGS_type", "service-instance")
+
+ utils.log("DEBUG", " ***** Completed preProcessRequest DeleteGenericMacroServiceNetworkVnf Request ***** ", isDebugEnabled)
+
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception ex){
+ String exceptionMessage = "Bpmn error encountered in DeleteGenericMacroServiceNetworkVnf flow. Unexpected from method preProcessRequest() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ public void sendSyncResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ utils.log("DEBUG", " ***** Inside sendSyncResponse of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ try {
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ String requestId = execution.getVariable("mso-request-id")
+
+ // RESTResponse (for API Handler (APIH) Reply Task)
+ String syncResponse ="""{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()
+
+ utils.log("DEBUG", " sendSynchResponse: xmlSyncResponse - " + "\n" + syncResponse, isDebugEnabled)
+ sendWorkflowResponse(execution, 202, syncResponse)
+ } catch (Exception ex) {
+ String exceptionMessage = "Bpmn error encountered in DeleteGenericMacroServiceNetworkVnf flow. Unexpected from method sendSyncResponse() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ public void prepareServiceInstanceDelete (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " ***** Inside prepareServiceInstanceDelete() of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ try {
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ // confirm if ServiceInstance was found
+ if ( !execution.getVariable("GENGS_FoundIndicator") )
+ {
+ String exceptionMessage = "Bpmn error encountered in DeleteGenericMacroServiceNetworkVnf flow. Service Instance was not found in AAI by id: " + serviceInstanceId
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+
+ // get variable within incoming json
+ String DeleteGenericMacroServiceNetworkVnfRequest = execution.getVariable("DeleteGenericMacroServiceNetworkVnfRequest");
+
+ // get SI extracted by GenericGetService
+ String serviceInstanceAaiRecord = execution.getVariable("GENGS_service");
+
+ utils.log("DEBUG", "serviceInstanceAaiRecord: "+serviceInstanceAaiRecord, isDebugEnabled)
+
+ String relationship = ""
+ try {
+ relationship = networkUtils.getFirstNodeXml(serviceInstanceAaiRecord, "relationship-list")
+ } catch (Exception ex) {
+ //no relationships found
+ }
+ utils.log("DEBUG", " relationship string - " + relationship, isDebugEnabled)
+
+ int vnfsCount = 0
+ int networksCount = 0
+
+ if (relationship != null && relationship.length() > 0){
+ relationship = relationship.trim().replace("tag0:","").replace(":tag0","")
+
+ // Check if Network TableREf is present, then build a List of network policy
+ List relatedVnfIdList = networkUtils.getRelatedVnfIdList(relationship)
+ vnfsCount = relatedVnfIdList.size()
+ execution.setVariable("DELVAS_vnfsCount", vnfsCount)
+ utils.log("DEBUG", " DELVAS_vnfsCount : " + vnfsCount, isDebugEnabled)
+ execution.setVariable("DELVAS_relatedVnfIdList", relatedVnfIdList)
+
+ // Check if Network TableREf is present, then build a List of network policy
+ List relatedNetworkIdList = networkUtils.getRelatedNetworkIdList(relationship)
+ networksCount = relatedNetworkIdList.size()
+ execution.setVariable("DELVAS_networksCount", networksCount)
+ utils.log("DEBUG", " DELVAS_networksCount : " + networksCount, isDebugEnabled)
+ execution.setVariable("DELVAS_relatedNetworkIdList", relatedNetworkIdList)
+ } else {
+ execution.setVariable("DELVAS_vnfsCount", 0)
+ utils.log("DEBUG", " DELVAS_vnfsCount : " + vnfsCount, isDebugEnabled)
+ execution.setVariable("DELVAS_networksCount", 0)
+ utils.log("DEBUG", " DELVAS_networksCount : " + networksCount, isDebugEnabled)
+ }
+
+ utils.log("DEBUG", " ***** Completed prepareServiceInstanceDelete() of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ sendSyncError(execution)
+ String exceptionMessage = "Bpmn error encountered in DeleteGenericMacroServiceNetworkVnf flow. prepareServiceInstanceDelete() - " + ex.getMessage()
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+
+ // *******************************
+ //
+ // *******************************
+ public void prepareVnfAndModulesDelete (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside prepareVnfAndModulesDelete of DeleteServiceInstanceMacro ***** ", isDebugEnabled)
+
+ List vnfList = execution.getVariable("DELVAS_relatedVnfIdList")
+ Integer vnfsDeletedCount = execution.getVariable("DELVAS_vnfsDeletedCount")
+ String vnfModelInfoString = ""
+ String vnfId = ""
+ if (vnfList.size() > 0 ) {
+ vnfId = vnfList.get(vnfsDeletedCount.intValue())
+ }
+
+ execution.setVariable("vnfId", vnfId)
+ utils.log("DEBUG", "need to delete vnfId:" + vnfId, isDebugEnabled)
+
+ utils.log("DEBUG", " ***** Completed prepareVnfAndModulesDelete of DeleteServiceInstanceMacro ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in DeleteServiceInstanceMacro flow. Unexpected Error from method prepareVnfAndModulesDelete() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ // Validate Vnf request Section -> increment count
+ // *******************************
+ public void validateVnfDelete (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside validateVnfDelete of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ String vnfsDeletedCount = execution.getVariable("DELVAS_vnfsDeletedCount")
+ vnfsDeletedCount++
+
+ execution.setVariable("DELVAS_vnfsDeletedCount", vnfsDeletedCount)
+
+ utils.log("DEBUG", " ***** Completed validateVnfDelete of DeleteGenericMacroServiceNetworkVnf ***** "+" vnf # "+vnfsDeletedCount, isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in DeleteGenericMacroServiceNetworkVnf flow. Unexpected Error from method validateVnfDelete() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ // Generate Network request Section
+ // *******************************
+ public void prepareNetworkDelete (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside prepareNetworkDelete of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ List networkList = execution.getVariable("DELVAS_relatedNetworkIdList")
+ Integer networksDeletedCount = execution.getVariable("DELVAS_networksDeletedCount")
+
+ String networkId = ""
+ if (networkList.size() > 0) {
+ networkId = networkList.get(networksDeletedCount.intValue())
+ }
+
+ execution.setVariable("networkId", networkId)
+ utils.log("DEBUG", "need to delete networkId:" + networkId, isDebugEnabled)
+
+ utils.log("DEBUG", " ***** Completed prepareNetworkDelete of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = q"Bpmn error encountered in DeleteGenericMacroServiceNetworkVnf flow. Unexpected Error from method prepareNetworkDelete() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ // *******************************
+ // Validate Network request Section
+ // *******************************
+ public void validateNetworkDelete (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+
+ try {
+ utils.log("DEBUG", " ***** Inside validateNetworkDelete of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ Integer networksDeletedCount = execution.getVariable("DELVAS_networksDeletedCount")
+ networksDeletedCount++
+
+ execution.setVariable("DELVAS_networksDeletedCount", networksDeletedCount)
+
+ utils.log("DEBUG", " ***** Completed validateNetworkDelete of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in DeleteGenericMacroServiceNetworkVnf flow. Unexpected Error from method validateNetworkDelete() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+
+ // *****************************************
+ // Prepare Completion request Section
+ // *****************************************
+ public void postProcessResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " ***** Inside postProcessResponse of DeleteGenericMacroServiceNetworkVnf ***** ", isDebugEnabled)
+
+ try {
+ String source = execution.getVariable("source")
+ String requestId = execution.getVariable("msoRequestId")
+
+ String msoCompletionRequest =
+ """<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:ns="http://org.openecomp/mso/request/types/v1">
+ <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
+ <request-id>${requestId}</request-id>
+ <action>DELETE</action>
+ <source>${source}</source>
+ </request-info>
+ <aetgt:status-message>vIPR ATM Service Instance has been deleted successfully.</aetgt:status-message>
+ <aetgt:mso-bpel-name>BPMN Service Instance macro action: DELETE</aetgt:mso-bpel-name>
+ </aetgt:MsoCompletionRequest>"""
+
+ // Format Response
+ String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)
+
+ utils.logAudit(xmlMsoCompletionRequest)
+ execution.setVariable("DELVAS_Success", true)
+ execution.setVariable("DELVAS_CompleteMsoProcessRequest", xmlMsoCompletionRequest)
+ utils.log("DEBUG", " SUCCESS flow, going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)
+ } catch (BpmnError e) {
+ throw e;
+
+ } catch (Exception ex) {
+ // try error in method block
+ String exceptionMessage = "Bpmn error encountered in DeleteServiceInstance flow. Unexpected Error from method postProcessResponse() - " + ex.getMessage()
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+ }
+ }
+
+ public void prepareFalloutRequest(Execution execution){
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " *** STARTED DeleteGenericMacroServiceNetworkVnf prepareFalloutRequest Process *** ", isDebugEnabled)
+
+ try {
+ WorkflowException wfex = execution.getVariable("WorkflowException")
+ utils.log("DEBUG", " Incoming Workflow Exception: " + wfex.toString(), isDebugEnabled)
+ String requestInfo = execution.getVariable("DELVAS_requestInfo")
+ utils.log("DEBUG", " Incoming Request Info: " + requestInfo, isDebugEnabled)
+
+ String falloutRequest = exceptionUtil.processMainflowsBPMNException(execution, requestInfo)
+
+ execution.setVariable("DELVAS_falloutRequest", falloutRequest)
+ } catch (Exception ex) {
+ utils.log("DEBUG", "Error Occured in DeleteGenericMacroServiceNetworkVnf prepareFalloutRequest Process " + ex.getMessage(), isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DeleteGenericMacroServiceNetworkVnf prepareFalloutRequest Process")
+ }
+ utils.log("DEBUG", "*** COMPLETED DeleteGenericMacroServiceNetworkVnf prepareFalloutRequest Process ***", isDebugEnabled)
+ }
+
+
+ public void sendSyncError (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG", " ***** Inside sendSyncError() of DeleteServiceInstanceInfra ***** ", isDebugEnabled)
+
+ try {
+ String errorMessage = ""
+ if (execution.getVariable("WorkflowException") instanceof WorkflowException) {
+ WorkflowException wfe = execution.getVariable("WorkflowException")
+ errorMessage = wfe.getErrorMessage()
+ } else {
+ errorMessage = "Sending Sync Error."
+ }
+
+ String buildworkflowException =
+ """<aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">
+ <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>7000</aetgt:ErrorCode>
+ </aetgt:WorkflowException>"""
+
+ utils.logAudit(buildworkflowException)
+ sendWorkflowResponse(execution, 500, buildworkflowException)
+ } catch (Exception ex) {
+ utils.log("DEBUG", " Sending Sync Error Activity Failed. " + "\n" + ex.getMessage(), isDebugEnabled)
+ }
+ }
+
+ public void processJavaException(Execution execution){
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ try{
+ utils.log("DEBUG", "Caught a Java Exception", isDebugEnabled)
+ utils.log("DEBUG", "Started processJavaException Method", isDebugEnabled)
+ utils.log("DEBUG", "Variables List: " + execution.getVariables(), isDebugEnabled)
+ execution.setVariable("DELVAS_unexpectedError", "Caught a Java Lang Exception") // Adding this line temporarily until this flows error handling gets updated
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Caught a Java Lang Exception")
+ }catch(BpmnError b){
+ utils.log("ERROR", "Rethrowing MSOWorkflowException", isDebugEnabled)
+ throw b
+ }catch(Exception e){
+ utils.log("DEBUG", "Caught Exception during processJavaException Method: " + e, isDebugEnabled)
+ execution.setVariable("DELVAS_unexpectedError", "Exception in processJavaException method") // Adding this line temporarily until this flows error handling gets updated
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, "Exception in processJavaException method")
+ }
+ utils.log("DEBUG", "Completed processJavaException Method", isDebugEnabled)
+ }
+
+
}
\ No newline at end of file
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.NetworkUtils\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils;\r
-import org.openecomp.mso.rest.APIResponse\r
-import java.util.UUID;\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution\r
-import org.apache.commons.lang3.*\r
-import org.apache.commons.codec.binary.Base64;\r
-import org.springframework.web.util.UriUtils\r
-import groovy.xml.XmlUtil\r
-import groovy.json.*\r
-\r
-public class DeleteNetworkInstance extends AbstractServiceTaskProcessor {\r
- String Prefix="DELNI_"\r
- String groovyClassName = "DeleteNetworkInstance"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils(this)\r
- NetworkUtils networkUtils = new NetworkUtils()\r
-\r
-\r
- public InitializeProcessVariables(Execution execution){\r
- \r
- execution.setVariable(Prefix + "Success", false)\r
- \r
- execution.setVariable(Prefix + "CompleteMsoProcessRequest", "")\r
- execution.setVariable(Prefix + "FalloutHandlerRequest", "")\r
- execution.setVariable(Prefix + "isSilentSuccess", false)\r
- \r
- }\r
- \r
- // **************************************************\r
- // Pre or Prepare Request Section\r
- // **************************************************\r
-\r
- public void preProcessRequest (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- utils.log("DEBUG", " ***** Inside preProcessRequest() of " + groovyClassName + " ***** ", isDebugEnabled)\r
-\r
- try {\r
- // initialize flow variables\r
- InitializeProcessVariables(execution)\r
- \r
- String sdncVersion = execution.getVariable("sdncVersion")\r
- if (sdncVersion == null || sdncVersion == '1610') { \r
- // 'a-la-cart' default, sdncVersion = '1610' \r
- execution.setVariable("sdncVersion", "1610")\r
- String bpmnRequest = execution.getVariable("bpmnRequest")\r
- // set 'disableRollback'\r
- if (bpmnRequest != null) {\r
- String disableRollback = jsonUtil.getJsonValue(bpmnRequest, "requestDetails.requestInfo.suppressRollback")\r
- if (disableRollback != null) {\r
- execution.setVariable("disableRollback", disableRollback)\r
- utils.log("DEBUG", "Received 'suppressRollback': " + disableRollback , isDebugEnabled)\r
- } else {\r
- execution.setVariable("disableRollback", false)\r
- }\r
- utils.log("DEBUG", " Set 'disableRollback' : " + execution.getVariable("disableRollback") , isDebugEnabled)\r
- } else {\r
- String dataErrorMessage = " Invalid 'bpmnRequest' request."\r
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)\r
- }\r
-\r
- } else {\r
- // 'macro' test ONLY, sdncVersion = '1702'\r
- utils.log("DEBUG", " 'disableRollback' : " + execution.getVariable("disableRollback") , isDebugEnabled)\r
- } \r
- \r
- // get/set 'msoRequestId' and 'mso-request-id'\r
- String requestId = execution.getVariable("msoRequestId")\r
- if (requestId != null) {\r
- execution.setVariable("mso-request-id", requestId)\r
- } else {\r
- requestId = execution.getVariable("mso-request-id")\r
- }\r
- execution.setVariable(Prefix + "requestId", requestId)\r
- \r
- // get/set 'requestId' \r
- if (execution.getVariable("requestId") == null) {\r
- execution.setVariable("requestId", requestId)\r
- }\r
- \r
- // set action to "DELETE"\r
- execution.setVariable("action", "DELETE")\r
- \r
- //Place holder for additional code.\r
-\r
- // TODO ???\r
- // userParams??? 1) pre-loads indicator, 2) 'auto-activation' \r
- // Tag/Value parameters\r
- //\r
- // Map: 'networkInputParams': 'auto-activation''\r
- // Sample format? \r
- // "requestParameters": {\r
- // "userParams": [ \r
- // {\r
- // "name": "someUserParam1",\r
- // "value": "someValue1"\r
- // }\r
- // ]\r
- // }\r
- // \r
- // String userParams = //use json util to extract "userParams"// \r
- // execution.setVariable("networkInputParams", userParams)\r
- // else: execution.setVariable("networkInputParams", null)\r
- //\r
-\r
-\r
- } catch (Exception ex){\r
- sendSyncError(execution)\r
- String exceptionMessage = "Exception Encountered in " + groovyClassName + ", PreProcessRequest() - " + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
-\r
- }\r
-\r
- }\r
-\r
- public void getNetworkModelInfo (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
-\r
- utils.log("DEBUG", " ***** Inside getNetworkModelInfo() of DeleteNetworkInstance ***** ", isDebugEnabled)\r
- \r
- try {\r
- \r
- // "networkModelInfo" is expected to be sent\r
- String networkModelInfo = execution.getVariable("networkModelInfo")\r
- utils.log("DEBUG", " networkModelInfo - " + networkModelInfo, isDebugEnabled)\r
- \r
- \r
- } catch (Exception ex) {\r
- sendSyncError(execution)\r
- String exceptionMessage = "Bpmn error encountered in DeleteNetworkInstance flow. getNetworkModelInfo() - " + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- \r
- }\r
-\r
- }\r
- \r
- public void sendSyncResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- utils.log("DEBUG", " ***** Inside sendSyncResponse() of DeleteNetworkInstance ***** ", isDebugEnabled)\r
-\r
- try {\r
- String requestId = execution.getVariable("mso-request-id")\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
-\r
- // RESTResponse (for API Handler (APIH) Reply Task)\r
- String deleteNetworkRestRequest = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()\r
-\r
- utils.log("DEBUG", " sendSyncResponse to APIH - " + "\n" + deleteNetworkRestRequest, isDebugEnabled)\r
-\r
- sendWorkflowResponse(execution, 202, deleteNetworkRestRequest)\r
-\r
- } catch (Exception ex) {\r
- // caught exception\r
- String exceptionMessage = "Exception Encountered in DeleteNetworkInstance, sendSyncResponse() - " + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
-\r
- }\r
-\r
- }\r
-\r
- public void prepareCompletion (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- utils.log("DEBUG", " ***** Inside prepareCompletion() of CreateNetworkInstance ***** ", isDebugEnabled)\r
-\r
- try {\r
-\r
- String requestId = execution.getVariable("mso-request-id")\r
- String source = execution.getVariable(Prefix + "source")\r
-\r
- String msoCompletionRequest =\r
- """<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>DELETE</action>\r
- <source>VID</source>\r
- </request-info>\r
- <aetgt:status-message>Network has been deleted successfully.</aetgt:status-message>\r
- <aetgt:mso-bpel-name>BPMN Network action: DELETE</aetgt:mso-bpel-name>\r
- </aetgt:MsoCompletionRequest>"""\r
-\r
- // Format Response\r
- String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)\r
-\r
- // normal path\r
- execution.setVariable(Prefix + "CompleteMsoProcessRequest", xmlMsoCompletionRequest)\r
- utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)\r
- \r
- } catch (Exception ex) {\r
- String exceptionMessage = " Bpmn error encountered in CreateNetworkInstance flow. prepareCompletion() - " + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
-\r
- }\r
-\r
-\r
- }\r
- \r
- public void prepareDBRequestError (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
-\r
- try {\r
- utils.log("DEBUG", " ***** Inside prepareDBRequestError of DeleteNetworkInstance ***** ", isDebugEnabled)\r
-\r
- WorkflowException wfe = execution.getVariable("WorkflowException")\r
- String statusMessage = wfe.getErrorMessage()\r
- String requestId = execution.getVariable(Prefix +"requestId")\r
-\r
- String dbRequest =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
- <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <requestId>${requestId}</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>${statusMessage}</statusMessage>\r
- <responseBody></responseBody>\r
- <requestStatus>FAILED</requestStatus>\r
- <progress></progress>\r
- <vnfOutputs><network-outputs xmlns="http://org.openecomp/mso/infra/vnf-request/v1" xmlns:aetgt="http://org.openecomp/mso/infra/vnf-request/v1" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"/></vnfOutputs>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
- </soapenv:Envelope>"""\r
-\r
- execution.setVariable(Prefix + "deleteDBRequest", dbRequest)\r
- utils.log("DEBUG", " DB Adapter Request - " + "\n" + dbRequest, isDebugEnabled)\r
-\r
- } catch (Exception ex) {\r
- // caught exception\r
- String exceptionMessage = "Bpmn error encountered in DeleteNetworkInstance, prepareDBRequestError() - " + ex.getMessage()\r
- logError(exceptionMessage)\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildWorkflowException(execution, 7000, exceptionMessage)\r
-\r
- }\r
-\r
- }\r
-\r
- // **************************************************\r
- // Post or Validate Response Section\r
- // **************************************************\r
-\r
- public void postProcessResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
- \r
- utils.log("DEBUG", " ***** Inside postProcessResponse() of DeleteNetworkInstance ***** ", isDebugEnabled)\r
- \r
- try {\r
- if (execution.getVariable("CMSO_ResponseCode") == "200") {\r
- execution.setVariable(Prefix + "Success", true)\r
- utils.log("DEBUG", " ***** DeleteNetworkInstance Success ***** ", isDebugEnabled)\r
- // Place holder for additional code.\r
- \r
- } else {\r
- execution.setVariable(Prefix + "Success", false)\r
- utils.log("DEBUG", " ***** DeleteNetworkInstance Failed in CompletionMsoProces flow!. ***** ", isDebugEnabled)\r
- \r
- } \r
- \r
- \r
- } catch (Exception ex) {\r
- String exceptionMessage = " Bpmn error encountered in DeleteNetworkInstance flow. postProcessResponse() - " + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)\r
- \r
- }\r
- \r
- }\r
-\r
-\r
- // *******************************\r
- // Build Error Section\r
- // *******************************\r
-\r
- // Prepare for FalloutHandler\r
- public void buildErrorResponse (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
-\r
- utils.log("DEBUG", " ***** Prepare for FalloutHandler. FAILURE - prepare request for sub-process FalloutHandler. *****", isDebugEnabled)\r
-\r
- String dbReturnCode = execution.getVariable(Prefix + "dbReturnCode")\r
- utils.log("DEBUG", " ***** DB Update Response Code : " + dbReturnCode, isDebugEnabled)\r
- utils.log("DEBUG", " ***** DB Update Response String: " + '\n' + execution.getVariable(Prefix + "deleteDBResponse"), isDebugEnabled)\r
-\r
- String falloutHandlerRequest = ""\r
- String requestId = execution.getVariable("mso-request-id")\r
- String source = execution.getVariable(Prefix + "source")\r
- execution.setVariable(Prefix + "Success", false)\r
- try {\r
- WorkflowException wfe = execution.getVariable("WorkflowException")\r
- String errorCode = String.valueOf(wfe.getErrorCode())\r
- String errorMessage = wfe.getErrorMessage()\r
-\r
- falloutHandlerRequest =\r
- """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>DELETE</action>\r
- <source>${source}</source>\r
- </request-info>\r
- <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>${errorCode}</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>\r
- </aetgt:FalloutHandlerRequest>"""\r
-\r
- utils.logAudit(falloutHandlerRequest)\r
- execution.setVariable(Prefix + "FalloutHandlerRequest", falloutHandlerRequest)\r
- utils.log("ERROR", " Overall Error Response going to FalloutHandler: " + "\n" + falloutHandlerRequest, isDebugEnabled)\r
-\r
- } catch (Exception ex) {\r
- // caught exception\r
- String exceptionMessage = "Bpmn error encountered in DeleteNetworkInstance, buildErrorResponse() - " + ex.getMessage()\r
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)\r
- falloutHandlerRequest =\r
- """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>\r
- <action>DELEtE</action>\r
- <source>${source}</source>\r
- </request-info>\r
- <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${exceptionMessage}</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>9999</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>\r
- </aetgt:FalloutHandlerRequest>"""\r
- execution.setVariable(Prefix + "FalloutHandlerRequest", falloutHandlerRequest)\r
- utils.log("DEBUG", " Overall Error Response going to FalloutHandler: " + "\n" + falloutHandlerRequest, isDebugEnabled)\r
- }\r
- }\r
-\r
-\r
- public void sendSyncError (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
-\r
- try {\r
- String requestId = execution.getVariable("mso-request-id")\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
-\r
- // RESTResponse (for API Handler (APIH) Reply Task)\r
- String deleteNetworkRestError = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()\r
-\r
- utils.log("DEBUG", " sendSyncResponse to APIH - " + "\n" + deleteNetworkRestError, isDebugEnabled)\r
-\r
- sendWorkflowResponse(execution, 500, deleteNetworkRestError)\r
-\r
- } catch (Exception ex) {\r
- utils.log("DEBUG", " Sending Sync Error Activity Failed - DeleteNetworkInstance, sendSyncError(): " + "\n" + ex.getMessage(), isDebugEnabled)\r
- }\r
- }\r
-\r
- public void processJavaException(Execution execution){\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- try{\r
- utils.log("DEBUG", "Caught a Java Exception", isDebugEnabled)\r
- utils.log("DEBUG", "Started processJavaException Method", isDebugEnabled)\r
- utils.log("DEBUG", "Variables List: " + execution.getVariables(), isDebugEnabled)\r
- execution.setVariable("UnexpectedError", "Caught a Java Lang Exception") // Adding this line temporarily until this flows error handling gets updated\r
- exceptionUtil.buildWorkflowException(execution, 500, "Caught a Java Lang Exception")\r
- \r
- }catch(Exception e){\r
- utils.log("DEBUG", "Caught Exception during processJavaException Method: " + e, isDebugEnabled)\r
- execution.setVariable("UnexpectedError", "Exception in processJavaException method") // Adding this line temporarily until this flows error handling gets updated\r
- exceptionUtil.buildWorkflowException(execution, 500, "Exception in processJavaException method")\r
- }\r
- utils.log("DEBUG", "Completed processJavaException Method of " + Prefix, isDebugEnabled)\r
- }\r
-\r
-}\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts;
+
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.NetworkUtils
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.json.JsonUtils;
+import org.openecomp.mso.rest.APIResponse
+import java.util.UUID;
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution
+import org.apache.commons.lang3.*
+import org.apache.commons.codec.binary.Base64;
+import org.springframework.web.util.UriUtils
+import groovy.xml.XmlUtil
+import groovy.json.*
+
+public class DeleteNetworkInstance extends AbstractServiceTaskProcessor {
+ String Prefix="DELNI_"
+ String groovyClassName = "DeleteNetworkInstance"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils(this)
+ NetworkUtils networkUtils = new NetworkUtils()
+
+
+ public InitializeProcessVariables(Execution execution){
+
+ execution.setVariable(Prefix + "Success", false)
+
+ execution.setVariable(Prefix + "CompleteMsoProcessRequest", "")
+ execution.setVariable(Prefix + "FalloutHandlerRequest", "")
+ execution.setVariable(Prefix + "isSilentSuccess", false)
+
+ }
+
+ // **************************************************
+ // Pre or Prepare Request Section
+ // **************************************************
+
+ public void preProcessRequest (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+
+ utils.log("DEBUG", " ***** Inside preProcessRequest() of " + groovyClassName + " ***** ", isDebugEnabled)
+
+ try {
+ // initialize flow variables
+ InitializeProcessVariables(execution)
+
+ String sdncVersion = execution.getVariable("sdncVersion")
+ if (sdncVersion == null || sdncVersion == '1610') {
+ // 'a-la-cart' default, sdncVersion = '1610'
+ execution.setVariable("sdncVersion", "1610")
+ String bpmnRequest = execution.getVariable("bpmnRequest")
+ // set 'disableRollback'
+ if (bpmnRequest != null) {
+ String disableRollback = jsonUtil.getJsonValue(bpmnRequest, "requestDetails.requestInfo.suppressRollback")
+ if (disableRollback != null) {
+ execution.setVariable("disableRollback", disableRollback)
+ utils.log("DEBUG", "Received 'suppressRollback': " + disableRollback , isDebugEnabled)
+ } else {
+ execution.setVariable("disableRollback", false)
+ }
+ utils.log("DEBUG", " Set 'disableRollback' : " + execution.getVariable("disableRollback") , isDebugEnabled)
+ } else {
+ String dataErrorMessage = " Invalid 'bpmnRequest' request."
+ utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
+ }
+
+ } else {
+ // 'macro' test ONLY, sdncVersion = '1702'
+ utils.log("DEBUG", " 'disableRollback' : " + execution.getVariable("disableRollback") , isDebugEnabled)
+ }
+
+ // get/set 'msoRequestId' and 'mso-request-id'
+ String requestId = execution.getVariable("msoRequestId")
+ if (requestId != null) {
+ execution.setVariable("mso-request-id", requestId)
+ } else {
+ requestId = execution.getVariable("mso-request-id")
+ }
+ execution.setVariable(Prefix + "requestId", requestId)
+
+ // get/set 'requestId'
+ if (execution.getVariable("requestId") == null) {
+ execution.setVariable("requestId", requestId)
+ }
+
+ // set action to "DELETE"
+ execution.setVariable("action", "DELETE")
+
+ //Place holder for additional code.
+
+ // TODO ???
+ // userParams??? 1) pre-loads indicator, 2) 'auto-activation'
+ // Tag/Value parameters
+ //
+ // Map: 'networkInputParams': 'auto-activation''
+ // Sample format?
+ // "requestParameters": {
+ // "userParams": [
+ // {
+ // "name": "someUserParam1",
+ // "value": "someValue1"
+ // }
+ // ]
+ // }
+ //
+ // String userParams = //use json util to extract "userParams"//
+ // execution.setVariable("networkInputParams", userParams)
+ // else: execution.setVariable("networkInputParams", null)
+ //
+
+
+ } catch (Exception ex){
+ sendSyncError(execution)
+ String exceptionMessage = "Exception Encountered in " + groovyClassName + ", PreProcessRequest() - " + ex.getMessage()
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+
+ }
+
+ }
+
+ public void getNetworkModelInfo (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+
+ utils.log("DEBUG", " ***** Inside getNetworkModelInfo() of DeleteNetworkInstance ***** ", isDebugEnabled)
+
+ try {
+
+ // "networkModelInfo" is expected to be sent
+ String networkModelInfo = execution.getVariable("networkModelInfo")
+ utils.log("DEBUG", " networkModelInfo - " + networkModelInfo, isDebugEnabled)
+
+
+ } catch (Exception ex) {
+ sendSyncError(execution)
+ String exceptionMessage = "Bpmn error encountered in DeleteNetworkInstance flow. getNetworkModelInfo() - " + ex.getMessage()
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+
+ }
+
+ }
+
+ public void sendSyncResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+
+ utils.log("DEBUG", " ***** Inside sendSyncResponse() of DeleteNetworkInstance ***** ", isDebugEnabled)
+
+ try {
+ String requestId = execution.getVariable("mso-request-id")
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ // RESTResponse (for API Handler (APIH) Reply Task)
+ String deleteNetworkRestRequest = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()
+
+ utils.log("DEBUG", " sendSyncResponse to APIH - " + "\n" + deleteNetworkRestRequest, isDebugEnabled)
+
+ sendWorkflowResponse(execution, 202, deleteNetworkRestRequest)
+
+ } catch (Exception ex) {
+ // caught exception
+ String exceptionMessage = "Exception Encountered in DeleteNetworkInstance, sendSyncResponse() - " + ex.getMessage()
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+
+ }
+
+ }
+
+ public void prepareCompletion (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+
+ utils.log("DEBUG", " ***** Inside prepareCompletion() of CreateNetworkInstance ***** ", isDebugEnabled)
+
+ try {
+
+ String requestId = execution.getVariable("mso-request-id")
+ String source = execution.getVariable(Prefix + "source")
+
+ String msoCompletionRequest =
+ """<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:ns="http://org.openecomp/mso/request/types/v1">
+ <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
+ <request-id>${requestId}</request-id>
+ <action>DELETE</action>
+ <source>VID</source>
+ </request-info>
+ <aetgt:status-message>Network has been deleted successfully.</aetgt:status-message>
+ <aetgt:mso-bpel-name>BPMN Network action: DELETE</aetgt:mso-bpel-name>
+ </aetgt:MsoCompletionRequest>"""
+
+ // Format Response
+ String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)
+
+ // normal path
+ execution.setVariable(Prefix + "CompleteMsoProcessRequest", xmlMsoCompletionRequest)
+ utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)
+
+ } catch (Exception ex) {
+ String exceptionMessage = " Bpmn error encountered in CreateNetworkInstance flow. prepareCompletion() - " + ex.getMessage()
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+
+ }
+
+
+ }
+
+ public void prepareDBRequestError (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+
+ try {
+ utils.log("DEBUG", " ***** Inside prepareDBRequestError of DeleteNetworkInstance ***** ", isDebugEnabled)
+
+ WorkflowException wfe = execution.getVariable("WorkflowException")
+ String statusMessage = wfe.getErrorMessage()
+ String requestId = execution.getVariable(Prefix +"requestId")
+
+ String dbRequest =
+ """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">
+ <requestId>${requestId}</requestId>
+ <lastModifiedBy>BPMN</lastModifiedBy>
+ <statusMessage>${statusMessage}</statusMessage>
+ <responseBody></responseBody>
+ <requestStatus>FAILED</requestStatus>
+ <progress></progress>
+ <vnfOutputs><network-outputs xmlns="http://org.openecomp/mso/infra/vnf-request/v1" xmlns:aetgt="http://org.openecomp/mso/infra/vnf-request/v1" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"/></vnfOutputs>
+ </ns:updateInfraRequest>
+ </soapenv:Body>
+ </soapenv:Envelope>"""
+
+ execution.setVariable(Prefix + "deleteDBRequest", dbRequest)
+ utils.log("DEBUG", " DB Adapter Request - " + "\n" + dbRequest, isDebugEnabled)
+
+ } catch (Exception ex) {
+ // caught exception
+ String exceptionMessage = "Bpmn error encountered in DeleteNetworkInstance, prepareDBRequestError() - " + ex.getMessage()
+ logError(exceptionMessage)
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ exceptionUtil.buildWorkflowException(execution, 7000, exceptionMessage)
+
+ }
+
+ }
+
+ // **************************************************
+ // Post or Validate Response Section
+ // **************************************************
+
+ public void postProcessResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+
+ utils.log("DEBUG", " ***** Inside postProcessResponse() of DeleteNetworkInstance ***** ", isDebugEnabled)
+
+ try {
+ if (execution.getVariable("CMSO_ResponseCode") == "200") {
+ execution.setVariable(Prefix + "Success", true)
+ utils.log("DEBUG", " ***** DeleteNetworkInstance Success ***** ", isDebugEnabled)
+ // Place holder for additional code.
+
+ } else {
+ execution.setVariable(Prefix + "Success", false)
+ utils.log("DEBUG", " ***** DeleteNetworkInstance Failed in CompletionMsoProces flow!. ***** ", isDebugEnabled)
+
+ }
+
+
+ } catch (Exception ex) {
+ String exceptionMessage = " Bpmn error encountered in DeleteNetworkInstance flow. postProcessResponse() - " + ex.getMessage()
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
+
+ }
+
+ }
+
+
+ // *******************************
+ // Build Error Section
+ // *******************************
+
+ // Prepare for FalloutHandler
+ public void buildErrorResponse (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+
+ utils.log("DEBUG", " ***** Prepare for FalloutHandler. FAILURE - prepare request for sub-process FalloutHandler. *****", isDebugEnabled)
+
+ String dbReturnCode = execution.getVariable(Prefix + "dbReturnCode")
+ utils.log("DEBUG", " ***** DB Update Response Code : " + dbReturnCode, isDebugEnabled)
+ utils.log("DEBUG", " ***** DB Update Response String: " + '\n' + execution.getVariable(Prefix + "deleteDBResponse"), isDebugEnabled)
+
+ String falloutHandlerRequest = ""
+ String requestId = execution.getVariable("mso-request-id")
+ String source = execution.getVariable(Prefix + "source")
+ execution.setVariable(Prefix + "Success", false)
+ try {
+ WorkflowException wfe = execution.getVariable("WorkflowException")
+ String errorCode = String.valueOf(wfe.getErrorCode())
+ String errorMessage = wfe.getErrorMessage()
+
+ falloutHandlerRequest =
+ """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:ns="http://org.openecomp/mso/request/types/v1"
+ xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">
+ <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
+ <request-id>${requestId}</request-id>
+ <action>DELETE</action>
+ <source>${source}</source>
+ </request-info>
+ <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">
+ <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>${errorCode}</aetgt:ErrorCode>
+ </aetgt:WorkflowException>
+ </aetgt:FalloutHandlerRequest>"""
+
+ utils.logAudit(falloutHandlerRequest)
+ execution.setVariable(Prefix + "FalloutHandlerRequest", falloutHandlerRequest)
+ utils.log("ERROR", " Overall Error Response going to FalloutHandler: " + "\n" + falloutHandlerRequest, isDebugEnabled)
+
+ } catch (Exception ex) {
+ // caught exception
+ String exceptionMessage = "Bpmn error encountered in DeleteNetworkInstance, buildErrorResponse() - " + ex.getMessage()
+ utils.log("DEBUG", exceptionMessage, isDebugEnabled)
+ falloutHandlerRequest =
+ """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:ns="http://org.openecomp/mso/request/types/v1"
+ xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">
+ <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
+ <request-id>${requestId}</request-id>
+ <action>DELEtE</action>
+ <source>${source}</source>
+ </request-info>
+ <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">
+ <aetgt:ErrorMessage>${exceptionMessage}</aetgt:ErrorMessage>
+ <aetgt:ErrorCode>9999</aetgt:ErrorCode>
+ </aetgt:WorkflowException>
+ </aetgt:FalloutHandlerRequest>"""
+ execution.setVariable(Prefix + "FalloutHandlerRequest", falloutHandlerRequest)
+ utils.log("DEBUG", " Overall Error Response going to FalloutHandler: " + "\n" + falloutHandlerRequest, isDebugEnabled)
+ }
+ }
+
+
+ public void sendSyncError (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+
+ try {
+ String requestId = execution.getVariable("mso-request-id")
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ // RESTResponse (for API Handler (APIH) Reply Task)
+ String deleteNetworkRestError = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()
+
+ utils.log("DEBUG", " sendSyncResponse to APIH - " + "\n" + deleteNetworkRestError, isDebugEnabled)
+
+ sendWorkflowResponse(execution, 500, deleteNetworkRestError)
+
+ } catch (Exception ex) {
+ utils.log("DEBUG", " Sending Sync Error Activity Failed - DeleteNetworkInstance, sendSyncError(): " + "\n" + ex.getMessage(), isDebugEnabled)
+ }
+ }
+
+ public void processJavaException(Execution execution){
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ try{
+ utils.log("DEBUG", "Caught a Java Exception", isDebugEnabled)
+ utils.log("DEBUG", "Started processJavaException Method", isDebugEnabled)
+ utils.log("DEBUG", "Variables List: " + execution.getVariables(), isDebugEnabled)
+ execution.setVariable("UnexpectedError", "Caught a Java Lang Exception") // Adding this line temporarily until this flows error handling gets updated
+ exceptionUtil.buildWorkflowException(execution, 500, "Caught a Java Lang Exception")
+
+ }catch(Exception e){
+ utils.log("DEBUG", "Caught Exception during processJavaException Method: " + e, isDebugEnabled)
+ execution.setVariable("UnexpectedError", "Exception in processJavaException method") // Adding this line temporarily until this flows error handling gets updated
+ exceptionUtil.buildWorkflowException(execution, 500, "Exception in processJavaException method")
+ }
+ utils.log("DEBUG", "Completed processJavaException Method of " + Prefix, isDebugEnabled)
+ }
+
+}
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
*/
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
+package org.openecomp.mso.bpmn.infrastructure.scripts;
import groovy.xml.XmlUtil
import groovy.json.*
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.NetworkUtils\r
-import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse;\r
-import org.openecomp.mso.rest.RESTClient\r
-import org.openecomp.mso.rest.RESTConfig\r
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.NetworkUtils
+import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.rest.APIResponse;
+import org.openecomp.mso.rest.RESTClient
+import org.openecomp.mso.rest.RESTConfig
import java.util.HashMap;
import java.util.Map;
String networkInputs = execution.getVariable(Prefix + "networkInputs")
String networkName = utils.getNodeText1(networkInputs, "network-name")
networkName = UriUtils.encode(networkName,"UTF-8")
- String messageId = execution.getVariable("messageId")
// Prepare AA&I url with network-name
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
execution.setVariable(Prefix + "queryNameAAIRequest", queryAAINameRequest)
utils.log("DEBUG", Prefix + "queryNameAAIRequest - " + "\n" + queryAAINameRequest, isDebugEnabled)
- RESTConfig config = new RESTConfig(queryAAINameRequest);
-
try {
- RESTClient client = new RESTClient(config).addHeader("X-TransactionId", messageId)
- .addHeader("X-FromAppId", "MSO")
- .addHeader("Content-Type", "application/xml")
- .addHeader("Accept","application/xml");
- APIResponse response = client.get()
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryAAINameRequest)
String returnCode = response.getStatusCode()
execution.setVariable(Prefix + "aaiNameReturnCode", returnCode)
utils.log("DEBUG", " ***** AAI Query Name Response Code : " + returnCode, isDebugEnabled)
execution.setVariable(Prefix + "networkName", networkName)
networkId = UriUtils.encode(networkId,"UTF-8")
- String messageId = execution.getVariable(Prefix + "messageId")
// Prepare AA&I url
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
execution.setVariable(Prefix + "queryIdAAIRequest", queryIdAAIRequest)
utils.log("DEBUG", Prefix + "queryIdAAIRequest - " + "\n" + queryIdAAIRequest, isDebugEnabled)
- RESTConfig config = new RESTConfig(queryIdAAIRequest);
- RESTClient client = new RESTClient(config).addHeader("X-TransactionId", messageId)
- .addHeader("X-FromAppId", "MSO")
- .addHeader("Content-Type", "application/xml")
- .addHeader("Accept","application/xml");
- APIResponse response = client.get()
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryIdAAIRequest)
String returnCode = response.getStatusCode()
execution.setVariable(Prefix + "aaiIdReturnCode", returnCode)
String networkId = execution.getVariable(Prefix + "networkId")
String netId = networkId
networkId = UriUtils.encode(networkId,"UTF-8")
- String messageId = execution.getVariable(Prefix + "messageId")
// Prepare AA&I url
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
execution.setVariable(Prefix + "requeryIdAAIRequest", requeryIdAAIRequest)
utils.log("DEBUG", Prefix + "requeryIdAAIRequest - " + "\n" + requeryIdAAIRequest, isDebugEnabled)
- RESTConfig config = new RESTConfig(requeryIdAAIRequest);
- RESTClient client = new RESTClient(config).addHeader("X-TransactionId", messageId)
- .addHeader("X-FromAppId", "MSO")
- .addHeader("Content-Type", "application/xml")
- .addHeader("Accept","application/xml");
- APIResponse response = client.get()
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, requeryIdAAIRequest)
String returnCode = response.getStatusCode()
execution.setVariable(Prefix + "aaiRequeryIdReturnCode", returnCode)
utils.log("DEBUG", " ***** AAI ReQuery Response Code : " + returnCode, isDebugEnabled)
try {
// get variables
- String messageId = execution.getVariable(Prefix + "messageId")
String queryIdAAIResponse = execution.getVariable(Prefix + "queryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
execution.setVariable(Prefix + "queryVpnBindingAAIRequest", queryVpnBindingAAIRequest)
utils.log("DEBUG", Prefix + "queryVpnBindingAAIRequest, , vpnBinding #" + counting + " : " + "\n" + queryVpnBindingAAIRequest, isDebugEnabled)
- RESTConfig config = new RESTConfig(queryVpnBindingAAIRequest);
- RESTClient client = new RESTClient(config).addHeader("X-TransactionId", messageId)
- .addHeader("X-FromAppId", "MSO")
- .addHeader("Content-Type", "application/xml")
- .addHeader("Accept","application/xml");
- APIResponse response = client.get()
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryVpnBindingAAIRequest)
String returnCode = response.getStatusCode()
execution.setVariable(Prefix + "aaiQqueryVpnBindingReturnCode", returnCode)
utils.log("DEBUG", " ***** AAI query vpn binding Response Code, vpnBinding #" + counting + " : " + returnCode, isDebugEnabled)
// reset return code to success
execution.setVariable(Prefix + "aaiQqueryVpnBindingReturnCode", "200")
String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String schemaVersion = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
String aaiStubResponse =
""" <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
<vpn-binding xmlns="${schemaVersion}">
try {
// get variables
- String messageId = execution.getVariable(Prefix + "messageId")
String queryIdAAIResponse = execution.getVariable(Prefix + "queryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
execution.setVariable(Prefix + "queryNetworkPolicyAAIRequest", queryNetworkPolicyAAIRequest)
utils.log("DEBUG", Prefix + "queryNetworkPolicyAAIRequest, , NetworkPolicy #" + counting + " : " + "\n" + queryNetworkPolicyAAIRequest, isDebugEnabled)
- RESTConfig config = new RESTConfig(queryNetworkPolicyAAIRequest);
- RESTClient client = new RESTClient(config).addHeader("X-TransactionId", messageId)
- .addHeader("X-FromAppId", "MSO")
- .addHeader("Content-Type", "application/xml")
- .addHeader("Accept","application/xml");
- APIResponse response = client.get()
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryNetworkPolicyAAIRequest)
String returnCode = response.getStatusCode()
execution.setVariable(Prefix + "aaiQqueryNetworkPolicyReturnCode", returnCode)
utils.log("DEBUG", " ***** AAI query network policy Response Code, NetworkPolicy #" + counting + " : " + returnCode, isDebugEnabled)
// reset return code to success
execution.setVariable(Prefix + "aaiQqueryNetworkPolicyReturnCode", "200")
String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String schemaVersion = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
String aaiStubResponse =
""" <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
<network-policy xmlns="${schemaVersion}">
try {
// get variables
- String messageId = execution.getVariable(Prefix + "messageId")
String queryIdAAIResponse = execution.getVariable(Prefix + "queryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
execution.setVariable(Prefix + "queryNetworkTableRefAAIRequest", queryNetworkTableRefAAIRequest)
utils.log("DEBUG", Prefix + "queryNetworkTableRefAAIRequest, , NetworkTableRef #" + counting + " : " + "\n" + queryNetworkTableRefAAIRequest, isDebugEnabled)
- RESTConfig config = new RESTConfig(queryNetworkTableRefAAIRequest);
- RESTClient client = new RESTClient(config).addHeader("X-TransactionId", messageId)
- .addHeader("X-FromAppId", "MSO")
- .addHeader("Content-Type", "application/xml")
- .addHeader("Accept","application/xml");
- APIResponse response = client.get()
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryNetworkTableRefAAIRequest)
String returnCode = response.getStatusCode()
execution.setVariable(Prefix + "aaiQqueryNetworkTableRefReturnCode", returnCode)
utils.log("DEBUG", " ***** AAI query network Table Reference Response Code, NetworkTableRef #" + counting + " : " + returnCode, isDebugEnabled)
// reset return code to success
execution.setVariable(Prefix + "aaiQqueryNetworkTableRefReturnCode", "200")
String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String schemaVersion = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
String aaiStubResponse =
""" <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
<route-table-references xmlns="${schemaVersion}">
networkId = UriUtils.encode(networkId,"UTF-8")
String requeryIdAAIResponse = execution.getVariable(Prefix + "requeryIdAAIResponse")
String createNetworkResponse = execution.getVariable(Prefix + "createNetworkResponse")
- String messageId = execution.getVariable(Prefix + "messageId")
// Prepare url
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
utils.log("DEBUG", Prefix + "updateContrailAAIUrlRequest - " + "\n" + updateContrailAAIUrlRequest, isDebugEnabled)
//Prepare payload (PUT)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String schemaVersion = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
String payload = networkUtils.ContrailNetworkCreatedUpdate(requeryIdAAIResponse, createNetworkResponse, schemaVersion)
String payloadXml = utils.formatXml(payload)
utils.logAudit(payloadXml)
execution.setVariable(Prefix + "aaiUpdateContrailReturnCode", returnCode)
utils.log("DEBUG", " ***** AAI Update Contrail Response Code : " + returnCode, isDebugEnabled)
String aaiUpdateContrailResponseAsString = response.getResponseBodyAsString()
-
if (returnCode=='200') {
utils.logAudit(aaiUpdateContrailResponseAsString)
execution.setVariable(Prefix + "updateContrailAAIResponse", aaiUpdateContrailResponseAsString)
// aai all errors
String errorMessage = "Unexpected Response from UpdateContrailAAINetwork - " + returnCode
utils.log("DEBUG", errorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, "2500", errorMessage)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, errorMessage)
}
}
}
// get variables
String requestId = execution.getVariable("msoRequestId")
if (requestId == null) {
- requestId = execution.getVariable("mso-request-id") \r
+ requestId = execution.getVariable("mso-request-id")
}
String messageId = execution.getVariable(Prefix + "messageId")
String source = execution.getVariable(Prefix + "source")
String networkId = execution.getVariable(Prefix + "networkId")
String serviceInstanceId = execution.getVariable(Prefix + "serviceInstanceId")
- // get/set 'msoRequestId' and 'mso-request-id'\r
+ // get/set 'msoRequestId' and 'mso-request-id'
String requestId = execution.getVariable("msoRequestId")
if (requestId != null) {
- execution.setVariable("mso-request-id", requestId)\r
+ execution.setVariable("mso-request-id", requestId)
} else {
- requestId = execution.getVariable("mso-request-id")\r
+ requestId = execution.getVariable("mso-request-id")
}
execution.setVariable(Prefix + "requestId", requestId)
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
*/
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
+package org.openecomp.mso.bpmn.infrastructure.scripts;
import static org.apache.commons.lang3.StringUtils.*;
import groovy.xml.XmlUtil
import groovy.json.*
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.RollbackData\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse;\r
-import org.openecomp.mso.rest.RESTClient\r
-import org.openecomp.mso.rest.RESTConfig\r
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.RollbackData
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.rest.APIResponse;
+import org.openecomp.mso.rest.RESTClient
+import org.openecomp.mso.rest.RESTConfig
import java.util.UUID;
execution.setVariable("sdncCallbackUrl", sdncCallbackUrl)
utils.log("DEBUG","SDNC Callback URL: " + sdncCallbackUrl, isDebugEnabled)
- String personaModelId = jsonUtil.getJsonValue(serviceModelInfo, "modelInvariantId")
- String personaModelVersion = jsonUtil.getJsonValue(serviceModelInfo, "modelVersion")
+ String modelInvariantId = jsonUtil.getJsonValue(serviceModelInfo, "modelInvariantId")
+ String modelVersionId = jsonUtil.getJsonValue(serviceModelInfo, "modelVersionId")
- if (personaModelId == null) {
- personaModelId = ""
+ if (modelInvariantId == null) {
+ modelInvariantId = ""
}
- if (personaModelVersion == null) {
- personaModelVersion = ""
+ if (modelVersionId == null) {
+ modelVersionId = ""
}
if (serviceInstanceName == null) {
execution.setVariable("serviceInstanceName", "")
String serviceInstanceData =
"""<service-instance xmlns=\"${namespace}\">
<service-instance-name>${serviceInstanceName}</service-instance-name>
- <orchestration-status>active</orchestration-status>
- <persona-model-id>${personaModelId}</persona-model-id>
- <persona-model-version>${personaModelVersion}</persona-model-version>
+ <orchestration-status>Active</orchestration-status>
+ <model-invariant-id>${modelInvariantId}</model-invariant-id>
+ <model-version-id>${modelVersionId}</model-version-id>
</service-instance>""".trim()
execution.setVariable("serviceInstanceData", serviceInstanceData)
}
String sdncAssignRequest =
- """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
+ """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
<sdncadapter:RequestHeader>
<sdncadapter:RequestId>${sdncRequestId}</sdncadapter:RequestId>
<sdncadapter:SvcInstanceId>${serviceInstanceId}</sdncadapter:SvcInstanceId>
utils.logAudit("sdncAssignRequest: " + sdncAssignRequest)
def sdncRequestId2 = UUID.randomUUID().toString()
- String sdncRollbackRequest = sdncAssignRequest.replace(">assign<", ">delete<").replace(">CreateServiceInstance<", ">DeleteServiceInstance<").replace(">${sdncRequestId}<", ">${sdncRequestId2}<")
+ String sdncDelete = sdncAssignRequest.replace(">assign<", ">delete<").replace(">CreateServiceInstance<", ">DeleteServiceInstance<").replace(">${sdncRequestId}<", ">${sdncRequestId2}<")
+ def sdncRequestId3 = UUID.randomUUID().toString()
+ String sdncDeactivate = sdncDelete.replace(">delete<", ">deactivate<").replace(">${sdncRequestId2}<", ">${sdncRequestId3}<")
def rollbackData = execution.getVariable("rollbackData")
- rollbackData.put("SERVICEINSTANCE", "sdncRollbackRequest", sdncRollbackRequest)
+ rollbackData.put("SERVICEINSTANCE", "sdncDeactivate", sdncDeactivate)
+ rollbackData.put("SERVICEINSTANCE", "sdncDelete", sdncDelete)
execution.setVariable("rollbackData", rollbackData)
- utils.log("DEBUG","sdncRollbackRequest:\n" + sdncRollbackRequest, isDebugEnabled)
utils.log("DEBUG","rollbackData:\n" + rollbackData.toString(), isDebugEnabled)
} catch (BpmnError e) {
execution.setVariable("skipRollback", true)\r
}\r
\r
- def sdncRollbackRequest = rollbackData.get("SERVICEINSTANCE", "sdncRollbackRequest")\r
- execution.setVariable("sdncRollbackRequest", sdncRollbackRequest)\r
+ def sdncDelete = rollbackData.get("SERVICEINSTANCE", "sdncDelete")\r
+ execution.setVariable("sdncDelete", sdncDelete)\r
+ def sdncDeactivate = rollbackData.get("SERVICEINSTANCE", "sdncDeactivate")\r
+ execution.setVariable("sdncDeactivate", sdncDeactivate)\r
+ utils.log("DEBUG","sdncDeactivate:\n" + sdncDeactivate, isDebugEnabled)\r
+ utils.log("DEBUG","sdncDelete:\n" + sdncDelete, isDebugEnabled)\r
}\r
else {\r
execution.setVariable("skipRollback", true)\r
utils.log("DEBUG"," ***** Exit preProcessRequest *****", isDebugEnabled)\r
}\r
\r
- public void validateSDNCResponse(Execution execution) {\r
+ public void validateSDNCResponse(Execution execution, String response, String method) {\r
def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
utils.log("DEBUG"," ***** validateSDNCResponse ***** ", isDebugEnabled)\r
String msg = ""\r
try {\r
WorkflowException workflowException = execution.getVariable("WorkflowException")\r
-\r
boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")\r
- String response = execution.getVariable("sdncAdapterResponse")\r
-\r
+ utils.log("DEBUG", "SDNCResponse: " + response, isDebugEnabled)\r
+ utils.log("DEBUG", "workflowException: " + workflowException, isDebugEnabled)\r
+ \r
SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)\r
sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)\r
\r
if(execution.getVariable(Prefix + 'sdncResponseSuccess') == true){\r
- utils.log("DEBUG", "SDNC Adapter for service-instance delete for rollback successful. response", isDebugEnabled)\r
+ msg = "SDNC Adapter service-instance rollback successful for " + method\r
+ utils.log("DEBUG", msg, isDebugEnabled)\r
}else{\r
execution.setVariable("rolledBack", false)\r
- execution.setVariable("rollbackError", "Error Response from SDNC Adapter for service-instance delete for rollback")\r
- utils.log("DEBUG","Error Response from SDNC Adapter for service-instance delete for rollback", isDebugEnabled)\r
+ msg = "Error Response from SDNC Adapter service-instance rollback for " + method\r
+ execution.setVariable("rollbackError", msg)\r
+ utils.log("DEBUG", msg, isDebugEnabled)\r
throw new BpmnError("MSOWorkflowException")\r
}\r
} catch (BpmnError e) {\r
throw e;\r
} catch (Exception ex){\r
- msg = "Exception in Create ServiceInstance Rollback validateSDNCResponse " + ex.getMessage()\r
+ msg = "Exception in Create ServiceInstance rollback for " + method + " Exception:" + ex.getMessage()\r
utils.log("DEBUG", msg, isDebugEnabled)\r
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
}\r
utils.log("DEBUG","*** Exit postProcessRequest ***", isDebugEnabled)\r
\r
} catch (BpmnError e) {\r
- msg = "Exception in Create ServiceInstance Rollback postProcessRequest. " + ex.getMessage()\r
+ msg = "Exception in Create ServiceInstance Rollback postProcessRequest. " + e.getMessage()\r
utils.log("DEBUG", msg, isDebugEnabled)\r
} catch (Exception ex) {\r
msg = "Exception in Create ServiceInstance Rollback postProcessRequest. " + ex.getMessage()\r
* limitations under the License.
* ============LICENSE_END=========================================================
*/
-\r
+
package org.openecomp.mso.bpmn.infrastructure.scripts;
-\r
-import javax.xml.parsers.DocumentBuilder\r
-import javax.xml.parsers.DocumentBuilderFactory\r
-\r
+
+import javax.xml.parsers.DocumentBuilder
+import javax.xml.parsers.DocumentBuilderFactory
+
import org.apache.commons.lang3.*
import org.camunda.bpm.engine.delegate.BpmnError
import org.camunda.bpm.engine.runtime.Execution
import org.openecomp.mso.rest.APIResponse
import org.openecomp.mso.rest.RESTClient
import org.openecomp.mso.rest.RESTConfig
-import org.springframework.web.util.UriUtils\r
-import org.w3c.dom.Document\r
-import org.w3c.dom.Element\r
-import org.w3c.dom.NamedNodeMap\r
-import org.w3c.dom.Node\r
+import org.springframework.web.util.UriUtils
+import org.w3c.dom.Document
+import org.w3c.dom.Element
+import org.w3c.dom.NamedNodeMap
+import org.w3c.dom.Node
import org.w3c.dom.NodeList
-import org.xml.sax.InputSource\r
-\r
-\r
+import org.xml.sax.InputSource
+
+
public class DoCreateVfModule extends VfModuleBase {
def requestId = execution.getVariable("msoRequestId")
execution.setVariable("DCVFM_requestId", requestId)
logDebug("requestId: " + requestId, isDebugLogEnabled)
- // Set mso-request-id to request-id for VNF Adapter interface
+ // Set mso-request-id to request-id for VNF Adapter interface
execution.setVariable("mso-request-id", requestId)
//serviceId
def serviceId = execution.getVariable("serviceId")
//personaModelId
execution.setVariable("DCVFM_personaModelId", jsonUtil.getJsonValue(vfModuleModelInfo, "modelInvariantId"))
//personaModelVersion
- execution.setVariable("DCVFM_personaModelVersion", jsonUtil.getJsonValue(vfModuleModelInfo, "modelVersion"))
+ execution.setVariable("DCVFM_personaModelVersion", jsonUtil.getJsonValue(vfModuleModelInfo, "modelVersionId"))
//vfModuleLabel
def vfModuleLabel = execution.getVariable("vfModuleLabel")
if (vfModuleLabel != null) {
String uuid = execution.getVariable('testReqId') // for junits
if(uuid==null){
- uuid = execution.getVariable("mso-request-id") + "-" + System.currentTimeMillis()
+ uuid = execution.getVariable("mso-request-id") + "-" + System.currentTimeMillis()
}
def callbackUrl = execution.getVariable("DCVFM_sdncCallbackUrl")
else {
svcInstId = serviceInstanceId
}
+
+ def msoAction = ""
+ if (!sdncVersion.equals("1707")) {
+ msoAction = "mobility"
+ }
+ else {
+ msoAction = "vfmodule"
+ }
// For VNF, serviceOperation (URI for topology GET) will be retrieved from "selflink" element
// in the response from GenericGetVnf
// For VF Module, in 1707 serviceOperation will be retrieved from "object-path" element
<sdncadapter:SvcAction>query</sdncadapter:SvcAction>
<sdncadapter:SvcOperation>${serviceOperation}</sdncadapter:SvcOperation>
<sdncadapter:CallbackUrl>${callbackUrl}</sdncadapter:CallbackUrl>
- <sdncadapter:MsoAction>mobility</sdncadapter:MsoAction>
+ <sdncadapter:MsoAction>${msoAction}</sdncadapter:MsoAction>
</sdncadapter:RequestHeader>
<sdncadapterworkflow:SDNCRequestData></sdncadapterworkflow:SDNCRequestData>
</sdncadapterworkflow:SDNCAdapterWorkflowRequest>"""
def requestId = execution.getVariable("mso-request-id")
if (requestId == null) {
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, processKey + " request has no mso-request-id")\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, processKey + " request has no mso-request-id")
}
def serviceInstanceId = execution.getVariable("mso-service-instance-id")
if (serviceInstanceId == null) {
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, processKey + " request message has no mso-service-instance-id")\r
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, processKey + " request message has no mso-service-instance-id")
}
utils.logContext(requestId, serviceInstanceId)
if (!sdncVersion.equals("1707")) {
sdncRequest =
- """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
+ """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
<sdncadapter:RequestHeader>
<sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
<sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>
else {
sdncRequest =
- """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
+ """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
<sdncadapter:RequestHeader>
<sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
<sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>
<sdncadapter:SvcAction>${action}</sdncadapter:SvcAction>
- <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>
+ <sdncadapter:SvcOperation>vf-module-topology-operation</sdncadapter:SvcOperation>
<sdncadapter:CallbackUrl>${callbackURL}</sdncadapter:CallbackUrl>
<sdncadapter:MsoAction>generic-resource</sdncadapter:MsoAction>
</sdncadapter:RequestHeader>
${serviceEcompModelInformation}
<service-instance-id>${svcInstId}</service-instance-id>
<global-customer-id>${globalSubscriberId}</global-customer-id>
- </service-information>
- <vnf-request-information>
- <vnf-type>${vfModuleModelName}</vnf-type>
- </vnf-request-information>
+ </service-information>
<vnf-information>
<vnf-id>${vnfId}</vnf-id>
<vnf-type>${vnfType}</vnf-type>
<vf-module-type>${vfModuleModelName}</vf-module-type>
${vfModuleEcompModelInformation}
</vf-module-information>
- <vf-module-request-input>
- <request-version>${sdncVersion}</request-version>
+ <vf-module-request-input>
<vf-module-name>${vfModuleName}</vf-module-name>
<tenant>${tenantId}</tenant>
- <aic-cloud-region>${cloudSiteId}</aic-cloud-region>
+ <aic-cloud-region>${cloudSiteId}</aic-cloud-region>
${sdncVNFParamsXml}
</vf-module-request-input>
</sdncadapterworkflow:SDNCRequestData>
/*
sdncRequest =
- """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
+ """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
<sdncadapter:RequestHeader>
<sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
<sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>
<vf-module-type>${vfModuleModelName}</vf-module-type>
${vfModuleEcompModelInformation}
</vf-module-information>
- <vf-module-request-input>
- <request-version>${sdncVersion}</request-version>
+ <vf-module-request-input>
<vf-module-name>${vfModuleName}</vf-module-name>
<tenant>${tenantId}</tenant>
<aic-cloud-region>${cloudSiteId}</aic-cloud-region>
def networkPolicyId = UUID.randomUUID().toString()
logDebug("Adding network-policy with network-policy-id " + networkPolicyId, isDebugLogEnabled)
- String aaiNamespace = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String aaiNamespace = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
logDebug('AAI namespace is: ' + aaiNamespace, isDebugLogEnabled)
String payload = """<network-policy xmlns="${aaiNamespace}">
<network-policy-id>${networkPolicyId}</network-policy-id>
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-
-package org.openecomp.mso.bpmn.infrastructure.scripts\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts
import org.camunda.bpm.engine.delegate.BpmnError
import org.camunda.bpm.engine.runtime.Execution
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse\r
-import org.springframework.web.util.UriUtils\r
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.rest.APIResponse
+import org.springframework.web.util.UriUtils
execution.setVariable("DCVFMR_cloudSiteId", cloudSiteId)
String heatStackId = rollbackData.get("VFMODULE", "heatstackid")
execution.setVariable("DCVFMR_heatStackId", heatStackId)
- String requestId = rollbackData.get("VFMODULE", "msorequestid")\r
+ String requestId = rollbackData.get("VFMODULE", "attmsorequestid")
execution.setVariable("DCVFMR_requestId", requestId)
List createdNetworkPolicyFqdnList = []
int i = 0
execution.setVariable("DCVFMR_oamManagementV4Address", oamManagementV4Address)
String oamManagementV6Address = rollbackData.get("VFMODULE", "oamManagementV6Address")
execution.setVariable("DCVFMR_oamManagementV6Address", oamManagementV6Address)
- //String serviceInstanceId = rollbackData.get("VFMODULE", "msoserviceinstanceid")\r
+ //String serviceInstanceId = rollbackData.get("VFMODULE", "attmsoserviceinstanceid")
//execution.setVariable("DCVFMR_serviceInstanceId", serviceInstanceId)
execution.setVariable("DCVFMR_rollbackPrepareUpdateVfModule", rollbackData.get("VFMODULE", "rollbackPrepareUpdateVfModule"))
execution.setVariable("DCVFMR_rollbackUpdateAAIVfModule", rollbackData.get("VFMODULE", "rollbackUpdateAAIVfModule"))
return
- String request = """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
+ String request = """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
<sdncadapter:RequestHeader>
<sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
<sdncadapter:SvcInstanceId>${vfModuleId}</sdncadapter:SvcInstanceId>
String vfModuleId = execution.getVariable("DCVFMR_vfModuleId")
String vfModuleStackId = execution.getVariable("DCVFMR_heatStackId")
String tenantId = execution.getVariable("DCVFMR_tenantId")
- def messageId = execution.getVariable('mso-request-id') + '-' +\r
+ def messageId = execution.getVariable('mso-request-id') + '-' +
System.currentTimeMillis()
def notificationUrl = createCallbackURL(execution, "VNFAResponse", messageId)
def useQualifiedHostName = execution.getVariable("URN_mso_use_qualified_host")
def vnfId = utils.getNodeText1(aaiGenericVnfResponse, 'vnf-id')
def vnfName = utils.getNodeText1(aaiGenericVnfResponse, 'vnf-name')
def modelCustomizationId = getNodeTextForce(volumeRequest, "model-customization-id")
-
+
String messageId = UUID.randomUUID()
utils.log("DEBUG", "messageId to be used is generated: " + messageId, isDebugEnabled)
utils.logAudit("AAI query generic vnf return code: " + returnCode)
utils.logAudit("AAI query generic vnf response: " + aaiResponseAsString)
+ //utils.log("DEBUG", "AAI query generic vnf return code: " + returnCode, isDebugEnabled)
+ //utils.log("DEBUG", "AAI query generic vnf response: " + aaiResponseAsString, isDebugEnabled)
+
ExceptionUtil exceptionUtil = new ExceptionUtil()
if (returnCode=='200') {
* See the License for the specific language governing permissions and
* limitations under the License.
* ============LICENSE_END=========================================================
- */\r
+ */
package org.openecomp.mso.bpmn.infrastructure.scripts
-\r
+
import static org.apache.commons.lang3.StringUtils.*
-import org.openecomp.mso.bpmn.core.RollbackData\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
+import org.openecomp.mso.bpmn.core.RollbackData
+import org.camunda.bpm.engine.delegate.BpmnError
import org.camunda.bpm.engine.runtime.Execution
import org.openecomp.mso.bpmn.common.scripts.AaiUtil
import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
import org.openecomp.mso.bpmn.common.scripts.VidUtils
import org.openecomp.mso.bpmn.core.WorkflowException
import org.openecomp.mso.bpmn.core.json.JsonUtils
-\r
-\r
-/**\r
- * This class supports the DoCreateVnf building block subflow\r
- * with the creation of a generic vnf for\r
- * infrastructure.\r
- *\r
- */\r
-class DoCreateVnf extends AbstractServiceTaskProcessor {\r
-\r
- String Prefix="DoCVNF_"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils(this)\r
- SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)\r
-\r
- /**\r
- * This method gets and validates the incoming\r
- * request.\r
- *\r
- * @param - execution\r
- *\r
- */\r
- public void preProcessRequest(Execution execution) {\r
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- utils.log("DEBUG", " *** STARTED DoCreateVnf PreProcessRequest Process*** ", isDebugEnabled)\r
- \r
- // DISABLE SDNC INTERACTION FOR NOW\r
- execution.setVariable("SDNCInteractionEnabled", false)\r
- \r
- \r
- /*******************/\r
- try{\r
- // Get Variables\r
- \r
- String cloudConfiguration = execution.getVariable("cloudConfiguration")\r
- String vnfModelInfo = execution.getVariable("vnfModelInfo") \r
- String serviceModelInfo = execution.getVariable("serviceModelInfo")\r
- \r
- String requestId = execution.getVariable("requestId")\r
- execution.setVariable("DoCVNF_requestId", requestId)\r
+
+
+/**
+ * This class supports the DoCreateVnf building block subflow
+ * with the creation of a generic vnf for
+ * infrastructure.
+ *
+ */
+class DoCreateVnf extends AbstractServiceTaskProcessor {
+
+ String Prefix="DoCVNF_"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils(this)
+ SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)
+
+ /**
+ * This method gets and validates the incoming
+ * request.
+ *
+ * @param - execution
+ *
+ */
+ public void preProcessRequest(Execution execution) {
+ def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ utils.log("DEBUG", " *** STARTED DoCreateVnf PreProcessRequest Process*** ", isDebugEnabled)
+
+ // DISABLE SDNC INTERACTION FOR NOW
+ execution.setVariable("SDNCInteractionEnabled", false)
+
+
+ /*******************/
+ try{
+ // Get Variables
+
+ String vnfModelInfo = execution.getVariable("vnfModelInfo")
+ String serviceModelInfo = execution.getVariable("serviceModelInfo")
+
+ String requestId = execution.getVariable("msoRequestId")
+ execution.setVariable("DoCVNF_requestId", requestId)
execution.setVariable("mso-request-id", requestId)
- utils.log("DEBUG", "Incoming Request Id is: " + requestId, isDebugEnabled)\r
-\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- execution.setVariable("DoCVNF_serviceInstanceId", serviceInstanceId)\r
- utils.log("DEBUG", "Incoming Service Instance Id is: " + serviceInstanceId, isDebugEnabled)\r
-\r
- String vnfType = execution.getVariable("vnfType")\r
- execution.setVariable("DoCVNF_vnfType", vnfType)\r
- utils.log("DEBUG", "Incoming Vnf Type is: " + vnfType, isDebugEnabled)\r
-\r
- String vnfName = execution.getVariable("vnfName")\r
- execution.setVariable("DoCVNF_vnfName", vnfName)\r
- utils.log("DEBUG", "Incoming Vnf Name is: " + vnfName, isDebugEnabled)\r
-\r
- String serviceId = execution.getVariable("productFamilyId")\r
- execution.setVariable("DoCVNF_serviceId", serviceId)\r
- utils.log("DEBUG", "Incoming Service Id is: " + serviceId, isDebugEnabled)\r
-\r
- String source = "VID"\r
- execution.setVariable("DoCVNF_source", source)\r
- utils.log("DEBUG", "Incoming Source is: " + source, isDebugEnabled)\r
-\r
- String suppressRollback = execution.getVariable("disableRollback")\r
- execution.setVariable("DoCVNF_suppressRollback", suppressRollback)\r
- utils.log("DEBUG", "Incoming Suppress Rollback is: " + suppressRollback, isDebugEnabled)\r
- \r
- String modelInvariantId = jsonUtil.getJsonValue(vnfModelInfo, "modelInvariantId")\r
- execution.setVariable("DoCVNF_modelInvariantId", modelInvariantId)\r
- utils.log("DEBUG", "Incoming Invariant Id is: " + modelInvariantId, isDebugEnabled)\r
- \r
- String modelVersionId = jsonUtil.getJsonValue(vnfModelInfo, "modelVersionId")\r
- if (modelVersionId == null) {\r
- modelVersionId = ""\r
- }\r
- execution.setVariable("DoCVNF_modelVersionId", modelVersionId)\r
- utils.log("DEBUG", "Incoming Version Id is: " + modelVersionId, isDebugEnabled)\r
-\r
- String modelVersion = jsonUtil.getJsonValue(vnfModelInfo, "modelVersion")\r
- execution.setVariable("DoCVNF_modelVersion", modelVersion)\r
- utils.log("DEBUG", "Incoming Model Version is: " + modelVersion, isDebugEnabled)\r
- \r
- String modelName = jsonUtil.getJsonValue(vnfModelInfo, "modelName")\r
- execution.setVariable("DoCVNF_modelName", modelName)\r
- utils.log("DEBUG", "Incoming Model Name is: " + modelName, isDebugEnabled)\r
- \r
- String modelCustomizationId = jsonUtil.getJsonValue(vnfModelInfo, "modelCustomizationId")\r
- if (modelCustomizationId == null) {\r
- modelCustomizationId = ""\r
- }\r
- execution.setVariable("DoCVNF_modelCustomizationId", modelCustomizationId)\r
- utils.log("DEBUG", "Incoming Model Customization Id is: " + modelCustomizationId, isDebugEnabled)\r
- \r
- String cloudSiteId = jsonUtil.getJsonValue(cloudConfiguration, "lcpCloudRegionId")\r
- execution.setVariable("DoCVNF_cloudSiteId", cloudSiteId)\r
- utils.log("DEBUG", "Incoming Cloud Site Id is: " + cloudSiteId, isDebugEnabled)\r
- \r
- String tenantId = jsonUtil.getJsonValue(cloudConfiguration, "tenantId")\r
- execution.setVariable("DoCVNF_tenantId", tenantId)\r
- utils.log("DEBUG", "Incoming Tenant Id is: " + tenantId, isDebugEnabled) \r
- \r
- String globalSubscriberId = execution.getVariable("globalSubscriberId")\r
- if (globalSubscriberId == null) {\r
- globalSubscriberId = ""\r
- }\r
- execution.setVariable("DoCVNF_globalSubscriberId", globalSubscriberId)\r
- utils.log("DEBUG", "Incoming Global Subscriber Id is: " + globalSubscriberId, isDebugEnabled)\r
- \r
- String sdncVersion = execution.getVariable("sdncVersion")\r
- if (sdncVersion == null) {\r
- sdncVersion = "1702"\r
- }\r
- execution.setVariable("DoCVNF_sdncVersion", sdncVersion)\r
- utils.log("DEBUG", "Incoming Sdnc Version is: " + sdncVersion, isDebugEnabled)\r
-\r
- //For Completion Handler & Fallout Handler\r
- String requestInfo =\r
+ utils.log("DEBUG", "Incoming Request Id is: " + requestId, isDebugEnabled)
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ execution.setVariable("DoCVNF_serviceInstanceId", serviceInstanceId)
+ utils.log("DEBUG", "Incoming Service Instance Id is: " + serviceInstanceId, isDebugEnabled)
+
+ String vnfType = execution.getVariable("vnfType")
+ execution.setVariable("DoCVNF_vnfType", vnfType)
+ utils.log("DEBUG", "Incoming Vnf Type is: " + vnfType, isDebugEnabled)
+
+ String vnfName = execution.getVariable("vnfName")
+ if (vnfName.equals("") || vnfName.equals("null")) {
+ vnfName = null
+ }
+ execution.setVariable("DoCVNF_vnfName", vnfName)
+ utils.log("DEBUG", "Incoming Vnf Name is: " + vnfName, isDebugEnabled)
+
+ String serviceId = execution.getVariable("productFamilyId")
+ execution.setVariable("DoCVNF_serviceId", serviceId)
+ utils.log("DEBUG", "Incoming Service Id is: " + serviceId, isDebugEnabled)
+
+ String source = "VID"
+ execution.setVariable("DoCVNF_source", source)
+ utils.log("DEBUG", "Incoming Source is: " + source, isDebugEnabled)
+
+ String suppressRollback = execution.getVariable("disableRollback")
+ execution.setVariable("DoCVNF_suppressRollback", suppressRollback)
+ utils.log("DEBUG", "Incoming Suppress Rollback is: " + suppressRollback, isDebugEnabled)
+
+ String modelInvariantId = jsonUtil.getJsonValue(vnfModelInfo, "modelInvariantId")
+ execution.setVariable("DoCVNF_modelInvariantId", modelInvariantId)
+ utils.log("DEBUG", "Incoming Invariant Id is: " + modelInvariantId, isDebugEnabled)
+
+ String modelVersionId = jsonUtil.getJsonValue(vnfModelInfo, "modelVersionId")
+ if (modelVersionId == null) {
+ modelVersionId = ""
+ }
+ execution.setVariable("DoCVNF_modelVersionId", modelVersionId)
+ utils.log("DEBUG", "Incoming Version Id is: " + modelVersionId, isDebugEnabled)
+
+ String modelVersion = jsonUtil.getJsonValue(vnfModelInfo, "modelVersion")
+ execution.setVariable("DoCVNF_modelVersion", modelVersion)
+ utils.log("DEBUG", "Incoming Model Version is: " + modelVersion, isDebugEnabled)
+
+ String modelName = jsonUtil.getJsonValue(vnfModelInfo, "modelName")
+ execution.setVariable("DoCVNF_modelName", modelName)
+ utils.log("DEBUG", "Incoming Model Name is: " + modelName, isDebugEnabled)
+
+ String modelCustomizationId = jsonUtil.getJsonValue(vnfModelInfo, "modelCustomizationId")
+ if (modelCustomizationId == null) {
+ modelCustomizationId = ""
+ }
+ execution.setVariable("DoCVNF_modelCustomizationId", modelCustomizationId)
+ utils.log("DEBUG", "Incoming Model Customization Id is: " + modelCustomizationId, isDebugEnabled)
+
+ String cloudSiteId = execution.getVariable("lcpCloudRegionId")
+ execution.setVariable("DoCVNF_cloudSiteId", cloudSiteId)
+ utils.log("DEBUG", "Incoming Cloud Site Id is: " + cloudSiteId, isDebugEnabled)
+
+ String tenantId = execution.getVariable("tenantId")
+ execution.setVariable("DoCVNF_tenantId", tenantId)
+ utils.log("DEBUG", "Incoming Tenant Id is: " + tenantId, isDebugEnabled)
+
+ String globalSubscriberId = execution.getVariable("globalSubscriberId")
+ if (globalSubscriberId == null) {
+ globalSubscriberId = ""
+ }
+ execution.setVariable("DoCVNF_globalSubscriberId", globalSubscriberId)
+ utils.log("DEBUG", "Incoming Global Subscriber Id is: " + globalSubscriberId, isDebugEnabled)
+
+ String sdncVersion = execution.getVariable("sdncVersion")
+ if (sdncVersion == null) {
+ sdncVersion = "1702"
+ }
+ execution.setVariable("DoCVNF_sdncVersion", sdncVersion)
+ utils.log("DEBUG", "Incoming Sdnc Version is: " + sdncVersion, isDebugEnabled)
+
+ //For Completion Handler & Fallout Handler
+ String requestInfo =
"""<request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
- <request-id>${requestId}</request-id>\r
- <action>CREATE</action>\r
- <source>${source}</source>\r
- </request-info>"""\r
-\r
- execution.setVariable("DoCVNF_requestInfo", requestInfo)\r
- //TODO: Orch Status - TBD, will come from SDN-C Response in 1702\r
- String orchStatus = "Created"\r
- execution.setVariable("DoCVNF_orchStatus", orchStatus)\r
-\r
- //TODO: Equipment Role - Should come from SDN-C Response in 1702\r
- String equipmentRole = " "\r
- execution.setVariable("DoCVNF_equipmentRole", equipmentRole)\r
- String vnfId = execution.getVariable("testVnfId") // for junits\r
- if(isBlank(vnfId)){\r
- vnfId = execution.getVariable("vnfId")\r
- if (isBlank(vnfId)) {\r
- vnfId = UUID.randomUUID().toString()\r
- utils.log("DEBUG", "Generated Vnf Id is: " + vnfId, isDebugEnabled)\r
- }\r
- }\r
- execution.setVariable("DoCVNF_vnfId", vnfId)\r
-\r
- // Setting for Sub Flow Calls\r
- execution.setVariable("DoCVNF_type", "generic-vnf")\r
- execution.setVariable("GENGS_type", "service-instance")\r
- \r
- String sdncCallbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')\r
- if (sdncCallbackUrl == null || sdncCallbackUrl.trim().isEmpty()) {\r
- def msg = 'Required variable \'URN_mso_workflow_sdncadapter_callback\' is missing'\r
- logError(msg)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2000, msg)\r
- }\r
- execution.setVariable("DoCVNF_sdncCallbackUrl", sdncCallbackUrl)\r
- utils.logAudit("SDNC Callback URL: " + sdncCallbackUrl)\r
- logDebug("SDNC Callback URL is: " + sdncCallbackUrl, isDebugEnabled)\r
- \r
- def rollbackData = execution.getVariable("RollbackData")\r
- if (rollbackData == null) {\r
- rollbackData = new RollbackData()\r
- }\r
- \r
- execution.setVariable("RollbackData", rollbackData)\r
- \r
- }catch(BpmnError b){\r
- utils.log("DEBUG", "Rethrowing MSOWorkflowException", isDebugEnabled)\r
- throw b\r
- }catch(Exception e){\r
- utils.log("DEBUG", " Error Occured in DoCreateVnf PreProcessRequest method!" + e.getMessage(), isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PreProcessRequest")\r
-\r
- }\r
- utils.log("DEBUG", "*** COMPLETED DoCreateVnf PreProcessRequest Process ***", isDebugEnabled)\r
- }\r
-\r
- \r
- public void prepareCreateGenericVnf (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- utils.log("DEBUG", " *** STARTED DoCreateVnf PrepareCreateGenericVnf Process *** ", isDebugEnabled)\r
- try {\r
- //Get Vnf Info\r
- String vnfId = execution.getVariable("DoCVNF_vnfId")\r
- def vnfName = execution.getVariable("DoCVNF_vnfName")\r
- def vnfType = execution.getVariable("DoCVNF_vnfType")\r
- def serviceId = execution.getVariable("DoCVNF_serviceId")\r
- def orchStatus = execution.getVariable("DoCVNF_orchStatus")\r
- def modelInvariantId = execution.getVariable("DoCVNF_modelInvariantId")\r
- def modelVersion = execution.getVariable("DoCVNF_modelVersion")\r
- def modelCustomizationId = execution.getVariable("DoCVNF_modelCustomizationId")\r
- // TODO: 1702 Variable\r
- def equipmentRole = execution.getVariable("DoCVNF_equipmentRole")\r
-\r
- //Get Service Instance Info\r
- def serviceInstanceId = execution.getVariable("DoCVNF_serviceInstanceId")\r
- String siRelatedLink = execution.getVariable("GENGS_siResourceLink")\r
-\r
- int custStart = siRelatedLink.indexOf("customer/")\r
- int custEnd = siRelatedLink.indexOf("/service-subscriptions")\r
- String globalCustId = siRelatedLink.substring(custStart + 9, custEnd)\r
- int serviceStart = siRelatedLink.indexOf("service-subscription/")\r
- int serviceEnd = siRelatedLink.indexOf("/service-instances/")\r
- String serviceType = siRelatedLink.substring(serviceStart + 21, serviceEnd)\r
-\r
- //Get Namespace\r
- AaiUtil aaiUtil = new AaiUtil(this)\r
- def aai_uri = aaiUtil.getNetworkGenericVnfUri(execution)\r
- String namespace = aaiUtil.getNamespaceFromUri(aai_uri)\r
-\r
- String payload =\r
- """<generic-vnf xmlns="${namespace}">\r
- <vnf-id>${vnfId}</vnf-id>\r
- <vnf-name>${vnfName}</vnf-name>\r
- <service-id>${serviceId}</service-id>\r
- <vnf-type>${vnfType}</vnf-type>\r
- <prov-status>PREPROV</prov-status>\r
- <orchestration-status>${orchStatus}</orchestration-status>\r
- <persona-model-id>${modelInvariantId}</persona-model-id>\r
- <persona-model-version>${modelVersion}</persona-model-version>\r
- <persona-model-customization-id>${modelCustomizationId}</persona-model-customization-id>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>service-instance</related-to>\r
- <related-link>${siRelatedLink}</related-link>\r
- <relationship-data>\r
- <relationship-key>customer.global-customer-id</relationship-key>\r
- <relationship-value>${globalCustId}</relationship-value>\r
- </relationship-data>\r
- <relationship-data>\r
- <relationship-key>service-subscription.service-type</relationship-key>\r
- <relationship-value>${serviceType}</relationship-value>\r
- </relationship-data>\r
- <relationship-data>\r
- <relationship-key>service-instance.service-instance-id</relationship-key>\r
- <relationship-value>${serviceInstanceId}</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- </relationship-list>\r
- </generic-vnf>"""\r
-\r
- execution.setVariable("DoCVNF_genericVnfPayload", payload)\r
-\r
- }catch(Exception ex) {\r
- utils.log("DEBUG", "Error Occured in DoCreateVnf PrepareCreateGenericVnf Process " + ex.getMessage(), isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PrepareCreateGenericVnf Process")\r
- }\r
- utils.log("DEBUG", "*** COMPLETED DoCreateVnf PrepareCreateGenericVnf Process ***", isDebugEnabled)\r
- }\r
- \r
- public void postProcessCreateGenericVnf (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- utils.log("DEBUG", " *** STARTED DoCreateVnf PostProcessCreateGenericVnf Process *** ", isDebugEnabled)\r
- try {\r
- //Get Vnf Info\r
- String vnfId = execution.getVariable("DoCVNF_vnfId")\r
- def rollbackData = execution.getVariable("RollbackData")\r
- rollbackData.put("VNF", "vnfId", vnfId)\r
- execution.setVariable("RollbackData", rollbackData)\r
- }catch(Exception ex) {\r
- utils.log("DEBUG", "Error Occured in DoCreateVnf PostProcessCreateGenericVnf Process " + ex.getMessage(), isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PostProcessCreateGenericVnf Process")\r
- }\r
- utils.log("DEBUG", "*** COMPLETED DoCreateVnf PostProcessCreateGenericVnf Process ***", isDebugEnabled)\r
- }\r
- \r
- \r
- public void preProcessSDNCAssignRequest(Execution execution){\r
- def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
- logDebug(" ======== STARTED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)\r
- def vnfId = execution.getVariable("DoCVNF_vnfId")\r
- def serviceInstanceId = execution.getVariable("DoCVNF_serviceInstanceId")\r
- logDebug("NEW VNF ID: " + vnfId, isDebugLogEnabled)\r
- utils.logAudit("NEW VNF ID: " + vnfId)\r
-\r
- try{\r
- //Build SDNC Request\r
- \r
- String assignSDNCRequest = buildSDNCRequest(execution, serviceInstanceId, "assign")\r
-\r
- assignSDNCRequest = utils.formatXml(assignSDNCRequest)\r
- execution.setVariable("DoCVNF_assignSDNCRequest", assignSDNCRequest)\r
- logDebug("Outgoing AssignSDNCRequest is: \n" + assignSDNCRequest, isDebugLogEnabled)\r
- utils.logAudit("Outgoing AssignSDNCRequest is: \n" + assignSDNCRequest)\r
-\r
- }catch(Exception e){\r
- utils.log("ERROR", "Exception Occured Processing preProcessSDNCAssignRequest. Exception is:\n" + e, isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessSDNCAssignRequest Method:\n" + e.getMessage())\r
- }\r
- logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)\r
- }\r
- \r
- public void preProcessSDNCActivateRequest(Execution execution) {\r
- def method = getClass().getSimpleName() + '.preProcessSDNCActivateRequest(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
- execution.setVariable("prefix", Prefix)\r
- logDebug(" ======== STARTED preProcessSDNCActivateRequest Process ======== ", isDebugLogEnabled)\r
- try{\r
- String vnfId = execution.getVariable("DoCVNF_vnfId")\r
- String serviceInstanceId = execution.getVariable("DoCVNF_serviceInstanceId")\r
-\r
- String activateSDNCRequest = buildSDNCRequest(execution, serviceInstanceId, "activate")\r
-\r
- execution.setVariable("DoCVNF_activateSDNCRequest", activateSDNCRequest)\r
- logDebug("Outgoing CommitSDNCRequest is: \n" + activateSDNCRequest, isDebugLogEnabled)\r
- utils.logAudit("Outgoing CommitSDNCRequest is: \n" + activateSDNCRequest)\r
-\r
- }catch(Exception e){\r
- log.debug("Exception Occured Processing preProcessSDNCActivateRequest. Exception is:\n" + e, isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occured during preProcessSDNCActivateRequest Method:\n" + e.getMessage())\r
- }\r
- logDebug("======== COMPLETED preProcessSDNCActivateRequest Process ======== ", isDebugLogEnabled)\r
- }\r
- \r
- public String buildSDNCRequest(Execution execution, String svcInstId, String action){\r
- \r
- String uuid = execution.getVariable('testReqId') // for junits\r
- if(uuid==null){\r
+ <request-id>${requestId}</request-id>
+ <action>CREATE</action>
+ <source>${source}</source>
+ </request-info>"""
+
+ execution.setVariable("DoCVNF_requestInfo", requestInfo)
+ //TODO: Orch Status - TBD, will come from SDN-C Response in 1702
+ String orchStatus = "Created"
+ execution.setVariable("DoCVNF_orchStatus", orchStatus)
+
+ //TODO: Equipment Role - Should come from SDN-C Response in 1702
+ String equipmentRole = " "
+ execution.setVariable("DoCVNF_equipmentRole", equipmentRole)
+ String vnfId = execution.getVariable("testVnfId") // for junits
+ if(isBlank(vnfId)){
+ vnfId = execution.getVariable("vnfId")
+ if (isBlank(vnfId)) {
+ vnfId = UUID.randomUUID().toString()
+ utils.log("DEBUG", "Generated Vnf Id is: " + vnfId, isDebugEnabled)
+ }
+ }
+ execution.setVariable("DoCVNF_vnfId", vnfId)
+
+ // Setting for Sub Flow Calls
+ execution.setVariable("DoCVNF_type", "generic-vnf")
+ execution.setVariable("GENGS_type", "service-instance")
+
+ String sdncCallbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')
+ if (sdncCallbackUrl == null || sdncCallbackUrl.trim().isEmpty()) {
+ def msg = 'Required variable \'URN_mso_workflow_sdncadapter_callback\' is missing'
+ logError(msg)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2000, msg)
+ }
+ execution.setVariable("DoCVNF_sdncCallbackUrl", sdncCallbackUrl)
+ utils.logAudit("SDNC Callback URL: " + sdncCallbackUrl)
+ logDebug("SDNC Callback URL is: " + sdncCallbackUrl, isDebugEnabled)
+
+ def rollbackData = execution.getVariable("RollbackData")
+ if (rollbackData == null) {
+ rollbackData = new RollbackData()
+ }
+
+ execution.setVariable("RollbackData", rollbackData)
+
+ }catch(BpmnError b){
+ utils.log("DEBUG", "Rethrowing MSOWorkflowException", isDebugEnabled)
+ throw b
+ }catch(Exception e){
+ utils.log("DEBUG", " Error Occured in DoCreateVnf PreProcessRequest method!" + e.getMessage(), isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PreProcessRequest")
+
+ }
+ utils.log("DEBUG", "*** COMPLETED DoCreateVnf PreProcessRequest Process ***", isDebugEnabled)
+ }
+
+
+ public void prepareCreateGenericVnf (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+
+ utils.log("DEBUG", " *** STARTED DoCreateVnf PrepareCreateGenericVnf Process *** ", isDebugEnabled)
+ try {
+ //Get Vnf Info
+ String vnfId = execution.getVariable("DoCVNF_vnfId")
+ def vnfName = execution.getVariable("DoCVNF_vnfName")
+ if (vnfName == null) {
+ vnfName = "sdncGenerated"
+ utils.log("DEBUG", "Sending a dummy VNF name to AAI - the name will be generated by SDNC: " + vnfName, isDebugEnabled)
+ }
+ def vnfType = execution.getVariable("DoCVNF_vnfType")
+ def serviceId = execution.getVariable("DoCVNF_serviceId")
+ def orchStatus = execution.getVariable("DoCVNF_orchStatus")
+ def modelInvariantId = execution.getVariable("DoCVNF_modelInvariantId")
+ def modelVersionId = execution.getVariable("DoCVNF_modelVersionId")
+ def modelCustomizationId = execution.getVariable("DoCVNF_modelCustomizationId")
+ // TODO: 1702 Variable
+ def equipmentRole = execution.getVariable("DoCVNF_equipmentRole")
+
+ //Get Service Instance Info
+ def serviceInstanceId = execution.getVariable("DoCVNF_serviceInstanceId")
+ String siRelatedLink = execution.getVariable("GENGS_siResourceLink")
+
+ int custStart = siRelatedLink.indexOf("customer/")
+ int custEnd = siRelatedLink.indexOf("/service-subscriptions")
+ String globalCustId = siRelatedLink.substring(custStart + 9, custEnd)
+ int serviceStart = siRelatedLink.indexOf("service-subscription/")
+ int serviceEnd = siRelatedLink.indexOf("/service-instances/")
+ String serviceType = siRelatedLink.substring(serviceStart + 21, serviceEnd)
+
+ //Get Namespace
+ AaiUtil aaiUtil = new AaiUtil(this)
+ def aai_uri = aaiUtil.getNetworkGenericVnfUri(execution)
+ String namespace = aaiUtil.getNamespaceFromUri(execution, aai_uri)
+
+ String payload =
+ """<generic-vnf xmlns="${namespace}">
+ <vnf-id>${vnfId}</vnf-id>
+ <vnf-name>${vnfName}</vnf-name>
+ <service-id>${serviceId}</service-id>
+ <vnf-type>${vnfType}</vnf-type>
+ <prov-status>PREPROV</prov-status>
+ <orchestration-status>${orchStatus}</orchestration-status>
+ <model-invariant-id>${modelInvariantId}</model-invariant-id>
+ <model-version-id>${modelVersionId}</model-version-id>
+ <model-customization-id>${modelCustomizationId}</model-customization-id>
+ <relationship-list>
+ <relationship>
+ <related-to>service-instance</related-to>
+ <related-link>${siRelatedLink}</related-link>
+ <relationship-data>
+ <relationship-key>customer.global-customer-id</relationship-key>
+ <relationship-value>${globalCustId}</relationship-value>
+ </relationship-data>
+ <relationship-data>
+ <relationship-key>service-subscription.service-type</relationship-key>
+ <relationship-value>${serviceType}</relationship-value>
+ </relationship-data>
+ <relationship-data>
+ <relationship-key>service-instance.service-instance-id</relationship-key>
+ <relationship-value>${serviceInstanceId}</relationship-value>
+ </relationship-data>
+ </relationship>
+ </relationship-list>
+ </generic-vnf>"""
+
+ execution.setVariable("DoCVNF_genericVnfPayload", payload)
+
+ }catch(Exception ex) {
+ utils.log("DEBUG", "Error Occured in DoCreateVnf PrepareCreateGenericVnf Process " + ex.getMessage(), isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PrepareCreateGenericVnf Process")
+ }
+ utils.log("DEBUG", "*** COMPLETED DoCreateVnf PrepareCreateGenericVnf Process ***", isDebugEnabled)
+ }
+
+ public void postProcessCreateGenericVnf (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+
+ utils.log("DEBUG", " *** STARTED DoCreateVnf PostProcessCreateGenericVnf Process *** ", isDebugEnabled)
+ try {
+ //Get Vnf Info
+ String vnfId = execution.getVariable("DoCVNF_vnfId")
+ def rollbackData = execution.getVariable("RollbackData")
+ rollbackData.put("VNF", "vnfId", vnfId)
+ execution.setVariable("RollbackData", rollbackData)
+ }catch(Exception ex) {
+ utils.log("DEBUG", "Error Occured in DoCreateVnf PostProcessCreateGenericVnf Process " + ex.getMessage(), isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PostProcessCreateGenericVnf Process")
+ }
+ utils.log("DEBUG", "*** COMPLETED DoCreateVnf PostProcessCreateGenericVnf Process ***", isDebugEnabled)
+ }
+
+
+ public void preProcessSDNCAssignRequest(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)
+ def vnfId = execution.getVariable("DoCVNF_vnfId")
+ def serviceInstanceId = execution.getVariable("DoCVNF_serviceInstanceId")
+ logDebug("NEW VNF ID: " + vnfId, isDebugLogEnabled)
+ utils.logAudit("NEW VNF ID: " + vnfId)
+
+ try{
+ //Build SDNC Request
+
+ String assignSDNCRequest = buildSDNCRequest(execution, serviceInstanceId, "assign")
+
+ assignSDNCRequest = utils.formatXml(assignSDNCRequest)
+ execution.setVariable("DoCVNF_assignSDNCRequest", assignSDNCRequest)
+ logDebug("Outgoing AssignSDNCRequest is: \n" + assignSDNCRequest, isDebugLogEnabled)
+ utils.logAudit("Outgoing AssignSDNCRequest is: \n" + assignSDNCRequest)
+
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occured Processing preProcessSDNCAssignRequest. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessSDNCAssignRequest Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)
+ }
+
+ public void preProcessSDNCActivateRequest(Execution execution) {
+ def method = getClass().getSimpleName() + '.preProcessSDNCActivateRequest(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED preProcessSDNCActivateRequest Process ======== ", isDebugLogEnabled)
+ try{
+ String vnfId = execution.getVariable("DoCVNF_vnfId")
+ String serviceInstanceId = execution.getVariable("DoCVNF_serviceInstanceId")
+
+ String activateSDNCRequest = buildSDNCRequest(execution, serviceInstanceId, "activate")
+
+ execution.setVariable("DoCVNF_activateSDNCRequest", activateSDNCRequest)
+ logDebug("Outgoing CommitSDNCRequest is: \n" + activateSDNCRequest, isDebugLogEnabled)
+ utils.logAudit("Outgoing CommitSDNCRequest is: \n" + activateSDNCRequest)
+
+ }catch(Exception e){
+ log.debug("Exception Occured Processing preProcessSDNCActivateRequest. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occured during preProcessSDNCActivateRequest Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED preProcessSDNCActivateRequest Process ======== ", isDebugLogEnabled)
+ }
+
+ public String buildSDNCRequest(Execution execution, String svcInstId, String action){
+
+ String uuid = execution.getVariable('testReqId') // for junits
+ if(uuid==null){
uuid = execution.getVariable("mso-request-id") + "-" + System.currentTimeMillis()
- }\r
- def callbackURL = execution.getVariable("DoCVNF_sdncCallbackUrl")\r
- def requestId = execution.getVariable("DoCVNF_requestId")\r
- def serviceId = execution.getVariable("DoCVNF_serviceId")\r
- def vnfType = execution.getVariable("DoCVNF_vnfType")\r
- def vnfName = execution.getVariable("DoCVNF_vnfName")\r
- def tenantId = execution.getVariable("DoCVNF_tenantId")\r
- def source = execution.getVariable("DoCVNF_source")\r
- def vnfId = execution.getVariable("DoCVNF_vnfId")\r
- def cloudSiteId = execution.getVariable("DoCVNF_cloudSiteId") \r
- def modelCustomizationId = execution.getVariable("DoCVNF_modelCustomizationId")\r
- def serviceModelInfo = execution.getVariable("serviceModelInfo")\r
- def vnfModelInfo = execution.getVariable("vnfModelInfo")\r
- String serviceEcompModelInformation = sdncAdapterUtils.modelInfoToEcompModelInformation(serviceModelInfo)\r
- String vnfEcompModelInformation = sdncAdapterUtils.modelInfoToEcompModelInformation(vnfModelInfo) \r
- def globalSubscriberId = execution.getVariable("DoCVNF_globalSubscriberId")\r
- def sdncVersion = execution.getVariable("DoCVNF_sdncVersion")\r
- \r
- String sdncVNFParamsXml = ""\r
- \r
- if(execution.getVariable("DoCVNF_vnfParamsExistFlag") == true){\r
- sdncVNFParamsXml = buildSDNCParamsXml(execution)\r
- }else{\r
- sdncVNFParamsXml = ""\r
- }\r
- \r
- String sdncRequest =\r
+ }
+ def callbackURL = execution.getVariable("DoCVNF_sdncCallbackUrl")
+ def requestId = execution.getVariable("DoCVNF_requestId")
+ def serviceId = execution.getVariable("DoCVNF_serviceId")
+ def vnfType = execution.getVariable("DoCVNF_vnfType")
+ def vnfName = execution.getVariable("DoCVNF_vnfName")
+ // Only send vnfName to SDNC if it is not null, otherwise it will get generated by SDNC on Assign
+ String vnfNameString = ""
+ if (vnfName != null) {
+ vnfNameString = """<vnf-name>${vnfName}</vnf-name>"""
+ }
+ def tenantId = execution.getVariable("DoCVNF_tenantId")
+ def source = execution.getVariable("DoCVNF_source")
+ def vnfId = execution.getVariable("DoCVNF_vnfId")
+ def cloudSiteId = execution.getVariable("DoCVNF_cloudSiteId")
+ def modelCustomizationId = execution.getVariable("DoCVNF_modelCustomizationId")
+ def serviceModelInfo = execution.getVariable("serviceModelInfo")
+ def vnfModelInfo = execution.getVariable("vnfModelInfo")
+ String serviceEcompModelInformation = sdncAdapterUtils.modelInfoToEcompModelInformation(serviceModelInfo)
+ String vnfEcompModelInformation = sdncAdapterUtils.modelInfoToEcompModelInformation(vnfModelInfo)
+ def globalSubscriberId = execution.getVariable("DoCVNF_globalSubscriberId")
+ def sdncVersion = execution.getVariable("DoCVNF_sdncVersion")
+
+ String sdncVNFParamsXml = ""
+
+ if(execution.getVariable("DoCVNF_vnfParamsExistFlag") == true){
+ sdncVNFParamsXml = buildSDNCParamsXml(execution)
+ }else{
+ sdncVNFParamsXml = ""
+ }
+
+ String sdncRequest =
"""<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
- <sdncadapter:RequestHeader>\r
- <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>\r
- <sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>\r
- <sdncadapter:SvcAction>${action}</sdncadapter:SvcAction>\r
- <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>\r
- <sdncadapter:CallbackUrl>${callbackURL}</sdncadapter:CallbackUrl>\r
- <sdncadapter:MsoAction>generic-resource</sdncadapter:MsoAction>\r
- </sdncadapter:RequestHeader>\r
- <sdncadapterworkflow:SDNCRequestData>\r
- <request-information>\r
- <request-id>${requestId}</request-id>\r
- <request-action>CreateVnfInstance</request-action>\r
- <source>${source}</source>\r
- <notification-url/>\r
- <order-number/>\r
- <order-version/>\r
- </request-information>\r
- <service-information>\r
- <service-id>${serviceId}</service-id>\r
- <subscription-service-type>${serviceId}</subscription-service-type>\r
- ${serviceEcompModelInformation} \r
- <service-instance-id>${svcInstId}</service-instance-id>\r
- <global-customer-id>${globalSubscriberId}</global-customer-id> \r
- </service-information>\r
- <vnf-information>\r
- <vnf-id>${vnfId}</vnf-id>\r
- <vnf-type>${vnfType}</vnf-type>\r
- ${vnfEcompModelInformation} \r
- </vnf-information>\r
- <vnf-request-input>\r
- <request-version>${sdncVersion}</request-version>\r
- <vnf-name></vnf-name>\r
- <tenant>${tenantId}</tenant> \r
- <aic-cloud-region>${cloudSiteId}</aic-cloud-region> \r
- ${sdncVNFParamsXml}\r
- </vnf-request-input>\r
- </sdncadapterworkflow:SDNCRequestData>\r
- </sdncadapterworkflow:SDNCAdapterWorkflowRequest>"""\r
- \r
- utils.logAudit("sdncRequest: " + sdncRequest)\r
- return sdncRequest\r
- }\r
- \r
- public void validateSDNCResponse(Execution execution, String response, String method){\r
- def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- logDebug(" *** STARTED ValidateSDNCResponse Process*** ", isDebugLogEnabled)\r
-\r
- WorkflowException workflowException = execution.getVariable("WorkflowException")\r
- boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")\r
-\r
- utils.logAudit("workflowException: " + workflowException)\r
-\r
- SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)\r
- sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)\r
-\r
- utils.logAudit("SDNCResponse: " + response)\r
-\r
- String sdncResponse = response\r
- if(execution.getVariable(Prefix + 'sdncResponseSuccess') == true){\r
- logDebug("Received a Good Response from SDNC Adapter for " + method + " SDNC Call. Response is: \n" + sdncResponse, isDebugLogEnabled)\r
- \r
- }else{\r
- logDebug("Received a BAD Response from SDNC Adapter for " + method + " SDNC Call.", isDebugLogEnabled)\r
- throw new BpmnError("MSOWorkflowException")\r
- }\r
- logDebug(" *** COMPLETED ValidateSDNCResponse Process*** ", isDebugLogEnabled)\r
- }\r
-\r
- \r
-}\r
+ <sdncadapter:RequestHeader>
+ <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
+ <sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>
+ <sdncadapter:SvcAction>${action}</sdncadapter:SvcAction>
+ <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>
+ <sdncadapter:CallbackUrl>${callbackURL}</sdncadapter:CallbackUrl>
+ <sdncadapter:MsoAction>generic-resource</sdncadapter:MsoAction>
+ </sdncadapter:RequestHeader>
+ <sdncadapterworkflow:SDNCRequestData>
+ <request-information>
+ <request-id>${requestId}</request-id>
+ <request-action>CreateVnfInstance</request-action>
+ <source>${source}</source>
+ <notification-url/>
+ <order-number/>
+ <order-version/>
+ </request-information>
+ <service-information>
+ <service-id>${serviceId}</service-id>
+ <subscription-service-type>${serviceId}</subscription-service-type>
+ ${serviceEcompModelInformation}
+ <service-instance-id>${svcInstId}</service-instance-id>
+ <global-customer-id>${globalSubscriberId}</global-customer-id>
+ </service-information>
+ <vnf-information>
+ <vnf-id>${vnfId}</vnf-id>
+ <vnf-type>${vnfType}</vnf-type>
+ ${vnfEcompModelInformation}
+ </vnf-information>
+ <vnf-request-input>
+ ${vnfNameString}
+ <tenant>${tenantId}</tenant>
+ <aic-cloud-region>${cloudSiteId}</aic-cloud-region>
+ ${sdncVNFParamsXml}
+ </vnf-request-input>
+ </sdncadapterworkflow:SDNCRequestData>
+ </sdncadapterworkflow:SDNCAdapterWorkflowRequest>"""
+
+ utils.logAudit("sdncRequest: " + sdncRequest)
+ return sdncRequest
+ }
+
+ public void validateSDNCResponse(Execution execution, String response, String method){
+ def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ logDebug(" *** STARTED ValidateSDNCResponse Process*** ", isDebugLogEnabled)
+
+ WorkflowException workflowException = execution.getVariable("WorkflowException")
+ boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")
+
+ utils.logAudit("workflowException: " + workflowException)
+
+ SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)
+ sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)
+
+ utils.logAudit("SDNCResponse: " + response)
+
+ String sdncResponse = response
+ if(execution.getVariable(Prefix + 'sdncResponseSuccess') == true){
+ logDebug("Received a Good Response from SDNC Adapter for " + method + " SDNC Call. Response is: \n" + sdncResponse, isDebugLogEnabled)
+ if(method.equals("get")){
+ String topologyGetResponse = execution.getVariable("DoCVNF_getSDNCAdapterResponse")
+ String data = utils.getNodeXml(topologyGetResponse, "response-data")
+ data = data.replaceAll("<", "<")
+ data = data.replaceAll(">", ">")
+ utils.log("DEBUG", "topologyGetResponseData: " + data, isDebugLogEnabled)
+ String vnfName = utils.getNodeText1(data, "vnf-name")
+ utils.log("DEBUG", "vnfName received from SDNC: " + vnfName, isDebugLogEnabled)
+ execution.setVariable("vnfName", vnfName)
+ execution.setVariable("DoCVNF_vnfName", vnfName)
+ }
+
+ }else{
+ logDebug("Received a BAD Response from SDNC Adapter for " + method + " SDNC Call.", isDebugLogEnabled)
+ throw new BpmnError("MSOWorkflowException")
+ }
+ logDebug(" *** COMPLETED ValidateSDNCResponse Process*** ", isDebugLogEnabled)
+ }
+
+ public void preProcessSDNCGetRequest(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ utils.log("DEBUG", " ======== STARTED preProcessSDNCGetRequest Process ======== ", isDebugLogEnabled)
+ try{
+ def serviceInstanceId = execution.getVariable('DoCVNF_serviceInstanceId')
+
+ String uuid = execution.getVariable('testReqId') // for junits
+ if(uuid==null){
+ uuid = execution.getVariable("mso-request-id") + "-" + System.currentTimeMillis()
+ }
+
+ def callbackUrl = execution.getVariable("DoCVFM_sdncCallbackUrl")
+ utils.logAudit("callbackUrl:" + callbackUrl)
+
+ def vnfId = execution.getVariable('DCVFM_vnfId')
+
+ def svcInstId = ""
+ if (serviceInstanceId == null || serviceInstanceId.isEmpty()) {
+ svcInstId = vnfId
+ }
+ else {
+ svcInstId = serviceInstanceId
+ }
+ // serviceOperation will be retrieved from "object-path" element
+ // in SDNC Assign Response for VNF
+ String response = execution.getVariable("DoCVNF_assignSDNCAdapterResponse")
+ utils.logAudit("DoCVNF_assignSDNCAdapterResponse is: \n" + response)
+
+ String serviceOperation = ""
+
+ String data = utils.getNodeXml(response, "response-data")
+ data = data.replaceAll("<", "<")
+ data = data.replaceAll(">", ">")
+ utils.log("DEBUG", "responseData: " + data, isDebugLogEnabled)
+ serviceOperation = utils.getNodeText1(data, "object-path")
+ utils.log("DEBUG", "VNF with sdncVersion of 1707 or later - service operation: " + serviceOperation, isDebugLogEnabled)
+
+
+ //!!!! TEMPORARY WORKAROUND FOR SDNC REPLICATION ISSUE
+ sleep(5000)
+
+ String SDNCGetRequest =
+ """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
+ <sdncadapter:RequestHeader>
+ <sdncadapter:RequestId>${uuid}</sdncadapter:RequestId>
+ <sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>
+ <sdncadapter:SvcAction>query</sdncadapter:SvcAction>
+ <sdncadapter:SvcOperation>${serviceOperation}</sdncadapter:SvcOperation>
+ <sdncadapter:CallbackUrl>${callbackUrl}</sdncadapter:CallbackUrl>
+ <sdncadapter:MsoAction>vfmodule</sdncadapter:MsoAction>
+ </sdncadapter:RequestHeader>
+ <sdncadapterworkflow:SDNCRequestData></sdncadapterworkflow:SDNCRequestData>
+ </sdncadapterworkflow:SDNCAdapterWorkflowRequest>"""
+
+ utils.logAudit("SDNCGetRequest: \n" + SDNCGetRequest)
+ execution.setVariable("DoCVNF_getSDNCRequest", SDNCGetRequest)
+ utils.log("DEBUG", "Outgoing GetSDNCRequest is: \n" + SDNCGetRequest, isDebugLogEnabled)
+
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occurred Processing preProcessSDNCGetRequest. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occured during prepareProvision Method:\n" + e.getMessage())
+ }
+ utils.log("DEBUG", "======== COMPLETED preProcessSDNCGetRequest Process ======== ", isDebugLogEnabled)
+ }
+
+ /**
+ * Prepare a Request for invoking the UpdateAAIGenericVnf subflow.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepUpdateAAIGenericVnf(Execution execution) {
+ def method = getClass().getSimpleName() + '.prepUpdateAAIGenericVnf(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def vnfId = execution.getVariable('DoCVNF_vnfId')
+ logDebug("VNF ID: " + vnfId, isDebugLogEnabled)
+
+ String updateAAIGenericVnfRequest = """
+ <UpdateAAIGenericVnfRequest>
+ <vnf-id>${vnfId}</vnf-id>
+ <orchestration-status>Active</orchestration-status>
+ </UpdateAAIGenericVnfRequest>
+ """
+ updateAAIGenericVnfRequest = utils.formatXml(updateAAIGenericVnfRequest)
+ execution.setVariable('DoCVNF_updateAAIGenericVnfRequest', updateAAIGenericVnfRequest)
+ utils.logAudit("updateAAIGenericVnfRequest : " + updateAAIGenericVnfRequest)
+ logDebug('Request for UpdateAAIGenericVnf:\n' + updateAAIGenericVnfRequest, isDebugLogEnabled)
+
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepUpdateAAIGenericVnf(): ' + e.getMessage())
+ }
+ }
+
+
+
+
+}
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-package org.openecomp.mso.bpmn.infrastructure.scripts\r
-\r
-import java.util.UUID;\r
-\r
-import org.json.JSONObject;\r
-import org.json.JSONArray;\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution;\r
-\r
-import static org.apache.commons.lang3.StringUtils.*;\r
-\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.RollbackData\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-\r
-\r
-\r
-/**\r
-* This class supports the macro VID Flow\r
-* with the creation of a generic vnf and related VF modules.\r
-*/\r
-class DoCreateVnfAndModules extends AbstractServiceTaskProcessor {\r
-\r
- String Prefix="DCVAM_"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils(this)\r
- CatalogDbUtils cutils = new CatalogDbUtils()\r
-\r
- /**\r
- * This method gets and validates the incoming\r
- * request.\r
- *\r
- * @param - execution\r
- */\r
- public void preProcessRequest(Execution execution) {\r
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- utils.log("DEBUG", " *** STARTED DoCreateVnfAndModules PreProcessRequest Process*** ", isDebugEnabled)\r
-\r
- try{\r
- // Get Variables\r
- \r
- \r
- String cloudConfiguration = execution.getVariable("cloudConfiguration")\r
- String vnfModelInfo = execution.getVariable("vnfModelInfo")\r
- \r
- String requestId = execution.getVariable("requestId")\r
- execution.setVariable("mso-request-id", requestId)\r
- utils.log("DEBUG", "Incoming Request Id is: " + requestId, isDebugEnabled)\r
-\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- utils.log("DEBUG", "Incoming Service Instance Id is: " + serviceInstanceId, isDebugEnabled)\r
-\r
- String vnfType = execution.getVariable("vnfType")\r
- utils.log("DEBUG", "Incoming Vnf Type is: " + vnfType, isDebugEnabled)\r
-\r
- String vnfName = execution.getVariable("vnfName")\r
- execution.setVariable("CREVI_vnfName", vnfName)\r
- utils.log("DEBUG", "Incoming Vnf Name is: " + vnfName, isDebugEnabled)\r
-\r
- String productFamilyId = execution.getVariable("productFamilyId")\r
- utils.log("DEBUG", "Incoming Product Family Id is: " + productFamilyId, isDebugEnabled)\r
-\r
- String source = "VID"\r
- execution.setVariable("source", source)\r
- utils.log("DEBUG", "Incoming Source is: " + source, isDebugEnabled)\r
-\r
- String disableRollback = execution.getVariable("disableRollback")\r
- utils.log("DEBUG", "Incoming Disable Rollback is: " + disableRollback, isDebugEnabled)\r
- \r
- String asdcServiceModelVersion = execution.getVariable("asdcServiceModelVersion")\r
- utils.log("DEBUG", "Incoming asdcServiceModelVersion: " + asdcServiceModelVersion, isDebugEnabled)\r
-\r
- String vnfId = execution.getVariable("testVnfId") // for junits\r
- if(isBlank(vnfId)){\r
- vnfId = execution.getVariable("vnfId")\r
- if (isBlank(vnfId)) {\r
- vnfId = UUID.randomUUID().toString()\r
- utils.log("DEBUG", "Generated Vnf Id is: " + vnfId, isDebugEnabled)\r
- }\r
- }\r
- execution.setVariable("vnfId", vnfId)\r
- \r
- def rollbackData = execution.getVariable("RollbackData")\r
- if (rollbackData == null) {\r
- rollbackData = new RollbackData()\r
- }\r
- \r
- execution.setVariable("numOfCreatedAddOnModules", 0)\r
- \r
- rollbackData.put("VNFANDMODULES", "numOfCreatedAddOnModules", 0)\r
- execution.setVariable("RollbackData", rollbackData)\r
- \r
- }catch(BpmnError b){\r
- utils.log("DEBUG", "Rethrowing MSOWorkflowException", isDebugEnabled)\r
- throw b\r
- }catch(Exception e){\r
- utils.log("DEBUG", " Error Occured in DoCreateVnfAndModules PreProcessRequest method!" + e.getMessage(), isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PreProcessRequest")\r
-\r
- }\r
- utils.log("DEBUG", "*** COMPLETED DoCreateVnfAndModules PreProcessRequest Process ***", isDebugEnabled)\r
- }\r
-\r
- \r
- public void queryCatalogDB (Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- utils.log("DEBUG", " *** STARTED DoCreateVnfAndModules QueryCatalogDB Process *** ", isDebugEnabled)\r
- try {\r
- //Get Vnf Info\r
- String vnfModelInfo = execution.getVariable("vnfModelInfo")\r
- String vnfModelCustomizationUuid = jsonUtil.getJsonValueForKey(vnfModelInfo, "modelCustomizationId")\r
- utils.log("DEBUG", "querying Catalog DB by vnfModelCustomizationUuid: " + vnfModelCustomizationUuid)\r
- String catalogDbEndpoint = execution.getVariable("URN_mso_catalog_db_endpoint")\r
- \r
- JSONArray vnfs = cutils.getAllVnfsByVnfModelCustomizationUuid(catalogDbEndpoint,\r
- vnfModelCustomizationUuid)\r
- utils.log("DEBUG", "obtained VNF list")\r
- // Only one match here\r
- JSONObject vnf = vnfs[0]\r
- JSONArray vfModules = vnf.getJSONArray("vfModules")\r
- JSONArray addOnModules = new JSONArray()\r
- \r
- // Set up base Vf Module info\r
- for (int i = 0; i < vfModules.length(); i++) {\r
- utils.log("DEBUG", "handling VF Module ")\r
- JSONObject vfModule = vfModules[i]\r
- String isBase = jsonUtil.getJsonValueForKey(vfModule, "isBase")\r
- if (isBase.equals("true")) {\r
- JSONObject baseVfModuleModelInfoObject = vfModule.getJSONObject("modelInfo")\r
- String baseVfModuleModelInfo = baseVfModuleModelInfoObject.toString()\r
- execution.setVariable("baseVfModuleModelInfo", baseVfModuleModelInfo)\r
- String baseVfModuleLabel = jsonUtil.getJsonValueForKey(vfModule, "vfModuleLabel")\r
- execution.setVariable("baseVfModuleLabel", baseVfModuleLabel)\r
- String basePersonaModelId = jsonUtil.getJsonValueForKey(baseVfModuleModelInfoObject, "modelInvariantId")\r
- execution.setVariable("basePersonaModelId", basePersonaModelId)\r
- }\r
- else {\r
- addOnModules.add(vfModules[i])\r
- }\r
- }\r
- \r
- execution.setVariable("addOnModules", addOnModules)\r
- execution.setVariable("addOnModulesToDeploy", addOnModules.length())\r
- execution.setVariable("addOnModulesDeployed", 0)\r
- \r
- }catch(Exception ex) {\r
- utils.log("DEBUG", "Error Occured in DoCreateVnfAndModules QueryCatalogDB Process " + ex.getMessage(), isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnfAndModules QueryCatalogDB Process")\r
- }\r
- \r
- // Generate vfModuleId for base VF Module\r
- def baseVfModuleId = UUID.randomUUID().toString()\r
- execution.setVariable("baseVfModuleId", baseVfModuleId)\r
- utils.log("DEBUG", "*** COMPLETED CreateVnfInfra PrepareCreateGenericVnf Process ***", isDebugEnabled)\r
- }\r
- \r
- public void preProcessAddOnModule(Execution execution){\r
- def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
- logDebug(" ======== STARTED preProcessAddOnModule ======== ", isDebugLogEnabled)\r
- \r
- try {\r
- JSONArray addOnModules = (JSONArray) execution.getVariable("addOnModules")\r
- int addOnIndex = (int) execution.getVariable("addOnModulesDeployed")\r
- \r
- JSONObject addOnModule = addOnModules[addOnIndex]\r
- \r
- def newVfModuleId = UUID.randomUUID().toString()\r
- execution.setVariable("addOnVfModuleId", newVfModuleId)\r
- \r
- execution.setVariable("instancesOfThisModelDeployed", 0)\r
- \r
- JSONObject addOnVfModuleModelInfoObject = jsonUtil.getJsonValueForKey(addOnModule, "modelInfo")\r
- String addOnVfModuleModelInfo = addOnVfModuleModelInfoObject.toString()\r
- execution.setVariable("addOnVfModuleModelInfo", addOnVfModuleModelInfo)\r
- String addOnVfModuleLabel = jsonUtil.getJsonValueForKey(addOnModule, "vfModuleLabel")\r
- execution.setVariable("addOnVfModuleLabel", addOnVfModuleLabel)\r
- String addOnPersonaModelId = jsonUtil.getJsonValueForKey(addOnVfModuleModelInfoObject, "modelInvariantId")\r
- execution.setVariable("addOnPersonaModelId", addOnPersonaModelId)\r
- String addOnInitialCount = jsonUtil.getJsonValueForKey(addOnModule, "initialCount")\r
- execution.setVariable("initialCount", addOnInitialCount)\r
- \r
- \r
- }catch(Exception e){\r
- utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())\r
- }\r
- logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)\r
- }\r
- \r
- public void validateBaseModule(Execution execution){\r
- def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
- logDebug(" ======== STARTED validateBaseModule ======== ", isDebugLogEnabled)\r
- \r
- try {\r
- def baseRollbackData = execution.getVariable("DCVAM_baseRollbackData")\r
- def rollbackData = execution.getVariable("RollbackData")\r
- \r
- def baseModuleMap = baseRollbackData.get("VFMODULE")\r
- baseModuleMap.each{ k, v -> rollbackData.put("VFMODULE_BASE", "${k}","${v}") }\r
- execution.setVariable("RollbackData", rollbackData)\r
- \r
- }catch(Exception e){\r
- utils.log("ERROR", "Exception Occured Processing validateBaseModule. Exception is:\n" + e, isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during validateBaseModule Method:\n" + e.getMessage())\r
- }\r
- logDebug("======== COMPLETED validateBaseModule ======== ", isDebugLogEnabled)\r
- }\r
- \r
- public void validateAddOnModule(Execution execution){\r
- def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
- logDebug(" ======== STARTED validateAddOnModule ======== ", isDebugLogEnabled)\r
- \r
- try {\r
- int instancesOfThisModuleDeployed = execution.getVariable("instancesOfThisModuleDeployed")\r
- int numOfCreatedAddOnModules = execution.getVariable("numOfCreatedAddOnModules")\r
- def addOnRollbackData = execution.getVariable("DCVAM_addOnRollbackData")\r
- def rollbackData = execution.getVariable("RollbackData")\r
- \r
- def addOnModuleMap = addOnRollbackData.get("VFMODULE")\r
- numOfCreatedAddOnModules = numOfCreatedAddOnModules + 1\r
- addOnModuleMap.each{ k, v -> rollbackData.put("VFMODULE_ADDON_" + numOfCreatedAddOnModules, "${k}","${v}") }\r
- \r
- execution.setVariable("DCVAM_addOnRollbackData", null)\r
- \r
- execution.setVariable("instancesOfThisModuleDeployed", instancesOfThisModuleDeployed + 1)\r
- \r
- execution.setVariable("numOfCreatedAddOnModules", numOfCreatedAddOnModules)\r
- rollbackData.put("VNFANDMODULES", "numOfCreatedAddOnModules", numOfCreatedAddOnModules)\r
- execution.setVariable("RollbackData", rollbackData)\r
- }catch(Exception e){\r
- utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())\r
- }\r
- logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)\r
- }\r
- \r
- public void finishProcessingInitialCountDeployment(Execution execution){\r
- def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
- logDebug(" ======== STARTED finishProcessingInitialCountDeployment ======== ", isDebugLogEnabled)\r
- \r
- try {\r
- int addOnModulesDeployed = execution.getVariable("addOnModulesDeployed")\r
- execution.setVariable("addOnModulesDeployed", addOnModulesDeployed + 1)\r
- }catch(Exception e){\r
- utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())\r
- }\r
- logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)\r
- }\r
- \r
- \r
- \r
-}\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+package org.openecomp.mso.bpmn.infrastructure.scripts
+
+import java.util.UUID;
+
+import org.json.JSONObject;
+import org.json.JSONArray;
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution;
+
+import static org.apache.commons.lang3.StringUtils.*;
+
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.RollbackData
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.decomposition.ModelInfo
+import org.openecomp.mso.bpmn.core.decomposition.ModuleResource
+import org.openecomp.mso.bpmn.core.decomposition.ServiceDecomposition
+import org.openecomp.mso.bpmn.core.decomposition.VnfResource
+
+
+
+/**
+* This class supports the macro VID Flow
+* with the creation of a generic vnf and related VF modules.
+*/
+class DoCreateVnfAndModules extends AbstractServiceTaskProcessor {
+
+ String Prefix="DCVAM_"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils(this)
+ CatalogDbUtils cutils = new CatalogDbUtils()
+
+ /**
+ * This method gets and validates the incoming
+ * request.
+ *
+ * @param - execution
+ */
+ public void preProcessRequest(Execution execution) {
+ def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ utils.log("DEBUG", " *** STARTED DoCreateVnfAndModules PreProcessRequest Process*** ", isDebugEnabled)
+
+ try{
+ // Get Variables
+
+ ServiceDecomposition serviceDecomposition = execution.getVariable("serviceDecomposition")
+
+ String vnfModelInfo = execution.getVariable("vnfModelInfo")
+
+ String requestId = execution.getVariable("msoRequestId")
+ execution.setVariable("requestId", requestId)
+ execution.setVariable("mso-request-id", requestId)
+ utils.log("DEBUG", "Incoming Request Id is: " + requestId, isDebugEnabled)
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ utils.log("DEBUG", "Incoming Service Instance Id is: " + serviceInstanceId, isDebugEnabled)
+
+ String vnfType = execution.getVariable("vnfType")
+ utils.log("DEBUG", "Incoming Vnf Type is: " + vnfType, isDebugEnabled)
+
+ String vnfName = execution.getVariable("vnfName")
+ execution.setVariable("CREVI_vnfName", vnfName)
+ utils.log("DEBUG", "Incoming Vnf Name is: " + vnfName, isDebugEnabled)
+
+ String productFamilyId = execution.getVariable("productFamilyId")
+ utils.log("DEBUG", "Incoming Product Family Id is: " + productFamilyId, isDebugEnabled)
+
+ String source = "VID"
+ execution.setVariable("source", source)
+ utils.log("DEBUG", "Incoming Source is: " + source, isDebugEnabled)
+
+ String lcpCloudRegionId = execution.getVariable("lcpCloudRegionId")
+ utils.log("DEBUG", "Incoming LCP Cloud Region Id is: " + lcpCloudRegionId)
+
+ String tenantId = execution.getVariable("tenantId")
+ utils.log("DEBUG", "Incoming Tenant Id is: " + tenantId)
+
+ String disableRollback = execution.getVariable("disableRollback")
+ utils.log("DEBUG", "Incoming Disable Rollback is: " + disableRollback, isDebugEnabled)
+
+ String asdcServiceModelVersion = execution.getVariable("asdcServiceModelVersion")
+ utils.log("DEBUG", "Incoming asdcServiceModelVersion: " + asdcServiceModelVersion, isDebugEnabled)
+
+ String vnfId = execution.getVariable("testVnfId") // for junits
+ if(isBlank(vnfId)){
+ vnfId = execution.getVariable("vnfId")
+ if (isBlank(vnfId)) {
+ vnfId = UUID.randomUUID().toString()
+ utils.log("DEBUG", "Generated Vnf Id is: " + vnfId, isDebugEnabled)
+ }
+ }
+ execution.setVariable("vnfId", vnfId)
+
+ def rollbackData = execution.getVariable("RollbackData")
+ if (rollbackData == null) {
+ rollbackData = new RollbackData()
+ }
+
+ execution.setVariable("numOfCreatedAddOnModules", 0)
+
+ rollbackData.put("VNFANDMODULES", "numOfCreatedAddOnModules", "0")
+ execution.setVariable("RollbackData", rollbackData)
+
+ sleep (20000)
+
+
+ }catch(BpmnError b){
+ utils.log("DEBUG", "Rethrowing MSOWorkflowException", isDebugEnabled)
+ throw b
+ }catch(Exception e){
+ utils.log("DEBUG", " Error Occured in DoCreateVnfAndModules PreProcessRequest method!" + e.getMessage(), isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PreProcessRequest")
+
+ }
+ utils.log("DEBUG", "*** COMPLETED DoCreateVnfAndModules PreProcessRequest Process ***", isDebugEnabled)
+ }
+
+
+ public void queryCatalogDB (Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+
+ utils.log("DEBUG", " *** STARTED DoCreateVnfAndModules QueryCatalogDB Process *** ", isDebugEnabled)
+ try {
+ ServiceDecomposition serviceDecomposition = execution.getVariable("serviceDecomposition")
+ // if serviceDecomposition is specified, get info from serviceDecomposition
+ if (serviceDecomposition != null) {
+ utils.log("DEBUG", "Getting Catalog DB data from ServiceDecomposition object: " + serviceDecomposition.toJsonString(), isDebugEnabled)
+ List<VnfResource> vnfs = serviceDecomposition.getServiceVnfs()
+ utils.log("DEBUG", "Read vnfs", isDebugEnabled)
+ if (vnfs == null) {
+ utils.log("DEBUG", "Error - vnfs are empty in serviceDecomposition object", isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf queryCatalogDB, vnfs are empty")
+ }
+ VnfResource vnf = vnfs[0]
+ utils.log("DEBUG", "Read vnfResource", isDebugEnabled)
+ if (vnf == null) {
+ utils.log("DEBUG", "Error - vnf is empty in serviceDecomposition object", isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf queryCatalogDB, vnf is null")
+ }
+
+ List<ModuleResource> vfModules = vnf.getAllVfModuleObjects()
+ utils.log("DEBUG", "Read vfModules", isDebugEnabled)
+ if (vfModules == null) {
+ utils.log("DEBUG", "Error - vfModules are empty in serviceDecomposition object", isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf queryCatalogDB, vf modules are empty")
+ }
+ JSONArray addOnModules = new JSONArray()
+
+ for (int i = 0; i < vfModules.size; i++) {
+ utils.log("DEBUG", "handling VF Module ", isDebugEnabled)
+ ModuleResource vfModule = vfModules[i]
+ boolean isBase = vfModule.getIsBase()
+ if (isBase) {
+ ModelInfo baseVfModuleModelInfoObject = vfModule.getModelInfo()
+ String baseVfModuleModelInfoWithRoot = baseVfModuleModelInfoObject.toString()
+ String baseVfModuleModelInfo = jsonUtil.getJsonValue(baseVfModuleModelInfoWithRoot, "modelInfo")
+ execution.setVariable("baseVfModuleModelInfo", baseVfModuleModelInfo)
+ String baseVfModuleLabel = vfModule.getVfModuleLabel()
+ execution.setVariable("baseVfModuleLabel", baseVfModuleLabel)
+ String basePersonaModelId = baseVfModuleModelInfoObject.getModelInvariantId()
+ execution.setVariable("basePersonaModelId", basePersonaModelId)
+ }
+ else {
+ addOnModules.put(vfModules[i])
+ }
+ }
+
+ execution.setVariable("addOnModules", addOnModules)
+ execution.setVariable("addOnModulesToDeploy", addOnModules.length())
+ execution.setVariable("addOnModulesDeployed", 0)
+
+ }
+ else {
+ //Get Vnf Info
+ String vnfModelInfo = execution.getVariable("vnfModelInfo")
+ utils.log("DEBUG", "vnfModelInfo: " + vnfModelInfo, isDebugEnabled)
+ String vnfModelCustomizationUuid = jsonUtil.getJsonValueForKey(vnfModelInfo, "modelCustomizationId")
+ if (vnfModelCustomizationUuid == null) {
+ vnfModelCustomizationUuid = jsonUtil.getJsonValueForKey(vnfModelInfo, "modelCustomizationUuid")
+ }
+ utils.log("DEBUG", "querying Catalog DB by vnfModelCustomizationUuid: " + vnfModelCustomizationUuid, isDebugEnabled)
+ String catalogDbEndpoint = execution.getVariable("URN_mso_catalog_db_endpoint")
+
+ JSONArray vnfs = cutils.getAllVnfsByVnfModelCustomizationUuid(catalogDbEndpoint,
+ vnfModelCustomizationUuid)
+ utils.log("DEBUG", "obtained VNF list")
+ // Only one match here
+ JSONObject vnf = vnfs[0]
+ JSONArray vfModules = vnf.getJSONArray("vfModules")
+ JSONArray addOnModules = new JSONArray()
+
+ // Set up base Vf Module info
+ for (int i = 0; i < vfModules.length(); i++) {
+ utils.log("DEBUG", "handling VF Module ")
+ JSONObject vfModule = vfModules[i]
+ String isBase = jsonUtil.getJsonValueForKey(vfModule, "isBase")
+ if (isBase.equals("true")) {
+ JSONObject baseVfModuleModelInfoObject = vfModule.getJSONObject("modelInfo")
+ String baseVfModuleModelInfo = baseVfModuleModelInfoObject.toString()
+ execution.setVariable("baseVfModuleModelInfo", baseVfModuleModelInfo)
+ String baseVfModuleLabel = jsonUtil.getJsonValueForKey(vfModule, "vfModuleLabel")
+ execution.setVariable("baseVfModuleLabel", baseVfModuleLabel)
+ String basePersonaModelId = jsonUtil.getJsonValueForKey(baseVfModuleModelInfoObject, "modelInvariantId")
+ execution.setVariable("basePersonaModelId", basePersonaModelId)
+ }
+ else {
+ addOnModules.put(vfModules[i])
+ }
+ }
+
+ execution.setVariable("addOnModules", addOnModules)
+ execution.setVariable("addOnModulesToDeploy", addOnModules.length())
+ execution.setVariable("addOnModulesDeployed", 0)
+ }
+
+ }catch(Exception ex) {
+ utils.log("DEBUG", "Error Occured in DoCreateVnfAndModules QueryCatalogDB Process " + ex.getMessage(), isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnfAndModules QueryCatalogDB Process")
+ }
+
+ // Generate vfModuleId for base VF Module
+ def baseVfModuleId = UUID.randomUUID().toString()
+ execution.setVariable("baseVfModuleId", baseVfModuleId)
+ // For JUnits
+ String requestId = execution.getVariable("requestId")
+ if (requestId.equals("testRequestId123")) {
+ execution.setVariable("vnfId", "skask")
+ }
+
+ utils.log("DEBUG", "*** COMPLETED CreateVnfInfra PrepareCreateGenericVnf Process ***", isDebugEnabled)
+ }
+
+ public void preProcessAddOnModule(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED preProcessAddOnModule ======== ", isDebugLogEnabled)
+
+ try {
+ JSONArray addOnModules = (JSONArray) execution.getVariable("addOnModules")
+ int addOnIndex = (int) execution.getVariable("addOnModulesDeployed")
+
+ JSONObject addOnModule = addOnModules[addOnIndex]
+
+ def newVfModuleId = UUID.randomUUID().toString()
+ execution.setVariable("addOnVfModuleId", newVfModuleId)
+
+ execution.setVariable("instancesOfThisModelDeployed", 0)
+
+ JSONObject addOnVfModuleModelInfoObject = jsonUtil.getJsonValueForKey(addOnModule, "modelInfo")
+ String addOnVfModuleModelInfoWithRoot = addOnVfModuleModelInfoObject.toString()
+ String addOnVfModuleModelInfo = jsonUtil.getJsonValue(addOnVfModuleModelInfoWithRoot, "modelInfo")
+ execution.setVariable("addOnVfModuleModelInfo", addOnVfModuleModelInfo)
+ String addOnVfModuleLabel = jsonUtil.getJsonValueForKey(addOnModule, "vfModuleLabel")
+ execution.setVariable("addOnVfModuleLabel", addOnVfModuleLabel)
+ String addOnPersonaModelId = jsonUtil.getJsonValueForKey(addOnVfModuleModelInfoObject, "modelInvariantId")
+ execution.setVariable("addOnPersonaModelId", addOnPersonaModelId)
+ String addOnInitialCount = jsonUtil.getJsonValueForKey(addOnModule, "initialCount")
+ execution.setVariable("initialCount", addOnInitialCount)
+
+
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)
+ }
+
+ public void validateBaseModule(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED validateBaseModule ======== ", isDebugLogEnabled)
+
+ try {
+ def baseRollbackData = execution.getVariable("DCVAM_baseRollbackData")
+ def rollbackData = execution.getVariable("RollbackData")
+
+ def baseModuleMap = baseRollbackData.get("VFMODULE")
+ baseModuleMap.each{ k, v -> rollbackData.put("VFMODULE_BASE", "${k}","${v}") }
+ execution.setVariable("RollbackData", rollbackData)
+ logDebug("addOnModulesDeployed: " + execution.getVariable("addOnModulesDeployed"), isDebugLogEnabled)
+ logDebug("addOnModulesToDeploy: " + execution.getVariable("addOnModulesToDeploy"), isDebugLogEnabled)
+ if (execution.getVariable("addOnModulesDeployed") < execution.getVariable("addOnModulesToDeploy")) {
+ logDebug("More add on modules to deploy", isDebugLogEnabled)
+ }
+ else {
+ logDebug("No more add on modules to deploy", isDebugLogEnabled)
+ }
+
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occured Processing validateBaseModule. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during validateBaseModule Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED validateBaseModule ======== ", isDebugLogEnabled)
+ }
+
+ public void validateAddOnModule(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED validateAddOnModule ======== ", isDebugLogEnabled)
+
+ try {
+ int instancesOfThisModuleDeployed = execution.getVariable("instancesOfThisModuleDeployed")
+ int numOfCreatedAddOnModules = execution.getVariable("numOfCreatedAddOnModules")
+ def addOnRollbackData = execution.getVariable("DCVAM_addOnRollbackData")
+ def rollbackData = execution.getVariable("RollbackData")
+
+ def addOnModuleMap = addOnRollbackData.get("VFMODULE")
+ numOfCreatedAddOnModules = numOfCreatedAddOnModules + 1
+ addOnModuleMap.each{ k, v -> rollbackData.put("VFMODULE_ADDON_" + numOfCreatedAddOnModules, "${k}","${v}") }
+
+ execution.setVariable("DCVAM_addOnRollbackData", null)
+
+ execution.setVariable("instancesOfThisModuleDeployed", instancesOfThisModuleDeployed + 1)
+
+ execution.setVariable("numOfCreatedAddOnModules", numOfCreatedAddOnModules)
+ rollbackData.put("VNFANDMODULES", "numOfCreatedAddOnModules", "${numOfCreatedAddOnModules}")
+ execution.setVariable("RollbackData", rollbackData)
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)
+ }
+
+ public void finishProcessingInitialCountDeployment(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED finishProcessingInitialCountDeployment ======== ", isDebugLogEnabled)
+
+ try {
+ int addOnModulesDeployed = execution.getVariable("addOnModulesDeployed")
+ execution.setVariable("addOnModulesDeployed", addOnModulesDeployed + 1)
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)
+ }
+
+
+
+}
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.NetworkUtils\r
-import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse;\r
-import org.openecomp.mso.rest.RESTClient\r
-import org.openecomp.mso.rest.RESTConfig\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+package org.openecomp.mso.bpmn.infrastructure.scripts;
+
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.NetworkUtils
+import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.rest.APIResponse;
+import org.openecomp.mso.rest.RESTClient
+import org.openecomp.mso.rest.RESTConfig
import java.util.UUID;
String networkInputs = execution.getVariable(Prefix + "networkInputs")
String networkId = utils.getNodeText(networkInputs, "network-id")
networkId = UriUtils.encode(networkId,"UTF-8")
- String messageId = execution.getVariable(Prefix + "messageId")
// Prepare AA&I url
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
ExceptionUtil exceptionUtil = new ExceptionUtil()
Boolean isVfRelationshipExist = false
try {
- RESTClient client = new RESTClient(config).addHeader("X-TransactionId", messageId)
- .addHeader("X-FromAppId", "MSO")
- .addHeader("Content-Type", "application/xml")
- .addHeader("Accept","application/xml");
- APIResponse response = client.get()
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryAAIRequest)
String returnCode = response.getStatusCode()
execution.setVariable(Prefix + "aaiReturnCode", returnCode)
String serviceInstanceId = utils.getNodeText1(deleteNetworkInput, "service-instance-id")
- // get/set 'msoRequestId' and 'mso-request-id'\r
+ // get/set 'msoRequestId' and 'mso-request-id'
String requestId = execution.getVariable("msoRequestId")
if (requestId != null) {
- execution.setVariable("mso-request-id", requestId)\r
+ execution.setVariable("mso-request-id", requestId)
} else {
- requestId = execution.getVariable("mso-request-id")\r
+ requestId = execution.getVariable("mso-request-id")
}
execution.setVariable(Prefix + "requestId", requestId)
- \r
utils.log("DEBUG", Prefix + "requestId " + requestId, isDebugEnabled)
String queryAAIResponse = execution.getVariable(Prefix + "queryAAIResponse")
execution.setVariable(Prefix + "rollbackNetworkRequest", "")
} else {
String rollbackNetwork =
- """<NetworkAdapter:rollbackNetwork xmlns:NetworkAdapter="http://org.openecomp.mso/network">\r
+ """<NetworkAdapter:rollbackNetwork xmlns:NetworkAdapter="http://org.openecomp.mso/network">
${rollbackData}
</NetworkAdapter:rollbackNetwork>"""
String rollbackNetworkXml = utils.formatXml(rollbackNetwork)
String serviceInstanceId = utils.getNodeText1(deleteNetworkInput, "service-instance-id")
- // get/set 'msoRequestId' and 'mso-request-id'\r
+ // get/set 'msoRequestId' and 'mso-request-id'
String requestId = execution.getVariable("msoRequestId")
if (requestId != null) {
- execution.setVariable("mso-request-id", requestId)\r
+ execution.setVariable("mso-request-id", requestId)
} else {
- requestId = execution.getVariable("mso-request-id")\r
+ requestId = execution.getVariable("mso-request-id")
}
execution.setVariable(Prefix + "requestId", requestId)
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-\r
-import static org.apache.commons.lang3.StringUtils.*;\r
-import groovy.xml.XmlUtil\r
-import groovy.json.*\r
-\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.rest.APIResponse;\r
-import org.openecomp.mso.rest.RESTClient\r
-import org.openecomp.mso.rest.RESTConfig\r
-\r
-import java.util.UUID;\r
-import javax.xml.parsers.DocumentBuilder\r
-import javax.xml.parsers.DocumentBuilderFactory\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution\r
-import org.json.JSONObject;\r
-import org.apache.commons.lang3.*\r
-import org.apache.commons.codec.binary.Base64;\r
-import org.springframework.web.util.UriUtils;\r
-import org.w3c.dom.Document\r
-import org.w3c.dom.Element\r
-import org.w3c.dom.Node\r
-import org.w3c.dom.NodeList\r
-import org.xml.sax.InputSource\r
-\r
-/**\r
- * This groovy class supports the <class>DoDeleteServiceInstance.bpmn</class> process.\r
- * \r
- * Inputs:\r
- * @param - msoRequestId\r
- * @param - globalSubscriberId - O\r
- * @param - subscriptionServiceType - O\r
- * @param - serviceInstanceId\r
- * @param - serviceInstanceName - O\r
- * @param - serviceModelInfo - O\r
- * @param - productFamilyId\r
- * @param - sdncVersion \r
- * @param - failNotFound - TODO\r
- * @param - serviceInputParams - TODO\r
- *\r
- * Outputs:\r
- * @param - WorkflowException\r
- * \r
- * Rollback - Deferred\r
- */\r
-public class DoDeleteServiceInstance extends AbstractServiceTaskProcessor {\r
-\r
- String Prefix="DDELSI_"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils()\r
-\r
- public void preProcessRequest (Execution execution) {\r
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG"," ***** preProcessRequest *****", isDebugEnabled)\r
- String msg = ""\r
-\r
- try {\r
- String requestId = execution.getVariable("msoRequestId")\r
- execution.setVariable("prefix",Prefix)\r
-\r
- //Inputs\r
- //requestDetails.subscriberInfo. for AAI GET & PUT & SDNC assignToplology\r
- String globalSubscriberId = execution.getVariable("globalSubscriberId") //globalCustomerId\r
- if (globalSubscriberId == null)\r
- {\r
- execution.setVariable("globalSubscriberId", "")\r
- }\r
-\r
- //requestDetails.requestParameters. for AAI PUT & SDNC assignTopology\r
- String subscriptionServiceType = execution.getVariable("subscriptionServiceType")\r
- if (subscriptionServiceType == null)\r
- {\r
- execution.setVariable("subscriptionServiceType", "")\r
- }\r
-\r
- //Generated in parent for AAI PUT\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- if (isBlank(serviceInstanceId)){\r
- msg = "Input serviceInstanceId is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- }\r
-\r
- String sdncCallbackUrl = execution.getVariable('URN_mso_workflow_sdncadapter_callback')\r
- if (isBlank(sdncCallbackUrl)) {\r
- msg = "URN_mso_workflow_sdncadapter_callback is null"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- }\r
- execution.setVariable("sdncCallbackUrl", sdncCallbackUrl)\r
- utils.log("DEBUG","SDNC Callback URL: " + sdncCallbackUrl, isDebugEnabled)\r
-\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception ex){\r
- msg = "Exception in preProcessRequest " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
- }\r
- utils.log("DEBUG"," ***** Exit preProcessRequest *****", isDebugEnabled)\r
- }\r
-\r
- public void preProcessSDNCDelete (Execution execution) {\r
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG"," ***** preProcessSDNCDelete *****", isDebugEnabled)\r
- String msg = ""\r
-\r
- try {\r
- /*\r
- String uuid = execution.getVariable('testReqId') // for junits\r
- if(uuid==null){\r
- uuid = execution.getVariable("msoRequestId") + "-" + System.currentTimeMillis()\r
- }\r
- */\r
- def serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- def serviceInstanceName = execution.getVariable("serviceInstanceName")\r
- def callbackURL = execution.getVariable("sdncCallbackUrl")\r
- def requestId = execution.getVariable("msoRequestId")\r
- def serviceId = execution.getVariable("productFamilyId")\r
- def subscriptionServiceType = execution.getVariable("subscriptionServiceType")\r
- def globalSubscriberId = execution.getVariable("globalSubscriberId") //globalCustomerId\r
-\r
- String serviceModelInfo = execution.getVariable("serviceModelInfo")\r
- def modelInvariantId = ""\r
- def modelVersion = ""\r
- def modelUUId = ""\r
- def modelName = ""\r
- if (!isBlank(serviceModelInfo))\r
- {\r
- modelInvariantId = jsonUtil.getJsonValue(serviceModelInfo, "modelInvariantId")\r
- modelVersion = jsonUtil.getJsonValue(serviceModelInfo, "modelVersion")\r
- modelUUId = jsonUtil.getJsonValue(serviceModelInfo, "modelVersionId")\r
- modelName = jsonUtil.getJsonValue(serviceModelInfo, "modelName")\r
- \r
- if (modelInvariantId == null) {\r
- modelInvariantId = ""\r
- }\r
- if (modelVersion == null) {\r
- modelVersion = ""\r
- }\r
- if (modelUUId == null) {\r
- modelUUId = ""\r
- }\r
- if (modelName == null) {\r
- modelName = ""\r
- }\r
- }\r
- if (serviceInstanceName == null) {\r
- serviceInstanceName = ""\r
- }\r
- if (serviceId == null) {\r
- serviceId = ""\r
- }\r
- \r
- def sdncRequestId = UUID.randomUUID().toString()\r
-\r
- String sdncDelete =\r
- """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
- <sdncadapter:RequestHeader>\r
- <sdncadapter:RequestId>${sdncRequestId}</sdncadapter:RequestId>\r
- <sdncadapter:SvcInstanceId>${serviceInstanceId}</sdncadapter:SvcInstanceId>\r
- <sdncadapter:SvcAction>delete</sdncadapter:SvcAction>\r
- <sdncadapter:SvcOperation>service-topology-operation</sdncadapter:SvcOperation>\r
- <sdncadapter:CallbackUrl>${callbackURL}</sdncadapter:CallbackUrl>\r
- </sdncadapter:RequestHeader>\r
- <sdncadapterworkflow:SDNCRequestData>\r
- <request-information>\r
- <request-id>${requestId}</request-id>\r
- <source>MSO</source>\r
- <notification-url/>\r
- <order-number/>\r
- <order-version/>\r
- <request-action>DeleteServiceInstance</request-action>\r
- </request-information>\r
- <service-information>\r
- <service-id>${serviceId}</service-id>\r
- <subscription-service-type>${subscriptionServiceType}</subscription-service-type>\r
- <ecomp-model-information>\r
- <model-invariant-uuid>${modelInvariantId}</model-invariant-uuid>\r
- <model-uuid>${modelUUId}</model-uuid>\r
- <model-version>${modelVersion}</model-version>\r
- <model-name>${modelName}</model-name>\r
- </ecomp-model-information>\r
- <service-instance-id>${serviceInstanceId}</service-instance-id>\r
- <subscriber-name/>\r
- <global-customer-id>${globalSubscriberId}</global-customer-id>\r
- </service-information>\r
- <service-request-input>\r
- <service-instance-name>${serviceInstanceName}</service-instance-name>\r
- </service-request-input>\r
- </sdncadapterworkflow:SDNCRequestData>\r
- </sdncadapterworkflow:SDNCAdapterWorkflowRequest>"""\r
-\r
- utils.log("DEBUG","sdncDelete:\n" + sdncDelete, isDebugEnabled)\r
- sdncDelete = utils.formatXml(sdncDelete)\r
- execution.setVariable("sdncDelete", sdncDelete)\r
- utils.logAudit("sdncDelete: " + sdncDelete)\r
-\r
-\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch(Exception ex) {\r
- msg = "Exception in preProcessSDNCDelete. " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, "Exception Occured in preProcessSDNCDelete.\n" + ex.getMessage())\r
- }\r
- utils.log("DEBUG"," *****Exit preProcessSDNCDelete *****", isDebugEnabled)\r
- }\r
-\r
- public void postProcessSDNCDelete(Execution execution) {\r
-\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG"," ***** postProcessSDNCDelete ***** ", isDebugEnabled)\r
- String msg = ""\r
-\r
- try {\r
- WorkflowException workflowException = execution.getVariable("WorkflowException")\r
- utils.logAudit("workflowException: " + workflowException)\r
-\r
- boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")\r
- String response = execution.getVariable("sdncAdapterResponse")\r
- utils.logAudit("SDNCResponse: " + response)\r
-\r
- SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)\r
- sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)\r
-\r
- if(execution.getVariable(Prefix + 'sdncResponseSuccess') == true){\r
- utils.log("DEBUG","Good response from SDNC Adapter for service-instance topology assign: \n" + response, isDebugEnabled)\r
-\r
- }else{\r
- msg = "Bad Response from SDNC Adapter for service-instance delete"\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 3500, msg)\r
- }\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch(Exception ex) {\r
- msg = "Exception in postProcessSDNCDelete. " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, "Exception Occured in preProcessSDNCDelete.\n" + ex.getMessage())\r
- }\r
- utils.log("DEBUG"," *** Exit postProcessSDNCDelete *** ", isDebugEnabled)\r
- }\r
-\r
- public void postProcessAAIGET(Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG"," ***** postProcessAAIGET ***** ", isDebugEnabled)\r
- String msg = ""\r
-\r
- try {\r
-\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")\r
-\r
- if(foundInAAI == true){\r
- utils.log("DEBUG","Found Service-instance in AAI", isDebugEnabled)\r
-\r
- //Extract GlobalSubscriberId\r
- String siRelatedLink = execution.getVariable("GENGS_siResourceLink")\r
- if (isBlank(siRelatedLink))\r
- {\r
- msg = "Could not retrive ServiceInstance data from AAI to delete id:" + serviceInstanceId\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- }\r
- else\r
- {\r
- utils.log("DEBUG","Found Service-instance in AAI. link: " + siRelatedLink, isDebugEnabled)\r
- String globalSubscriberId = execution.getVariable("globalSubscriberId")\r
- if(isBlank(globalSubscriberId)){\r
- int custStart = siRelatedLink.indexOf("customer/")\r
- int custEnd = siRelatedLink.indexOf("/service-subscriptions")\r
- globalSubscriberId = siRelatedLink.substring(custStart + 9, custEnd)\r
- execution.setVariable("globalSubscriberId", globalSubscriberId)\r
- }\r
-\r
- //Extract Service Type if not provided on request\r
- String serviceType = execution.getVariable("subscriptionServiceType")\r
- if(isBlank(serviceType)){\r
- int serviceStart = siRelatedLink.indexOf("service-subscription/")\r
- int serviceEnd = siRelatedLink.indexOf("/service-instances/")\r
- String serviceTypeEncoded = siRelatedLink.substring(serviceStart + 21, serviceEnd)\r
- serviceType = UriUtils.decode(serviceTypeEncoded, "UTF-8")\r
- execution.setVariable("subscriptionServiceType", serviceType)\r
- }\r
-\r
- if (isBlank(globalSubscriberId) || isBlank(serviceType))\r
- {\r
- msg = "Could not retrive global-customer-id & service-type from AAI to delete id:" + serviceInstanceId\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- }\r
- }\r
-\r
- String siData = execution.getVariable("GENGS_service")\r
- utils.log("DEBUG", "SI Data", isDebugEnabled)\r
- if (isBlank(siData))\r
- {\r
- msg = "Could not retrive ServiceInstance data from AAI to delete id:" + serviceInstanceId\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)\r
- }\r
- else\r
- {\r
- utils.log("DEBUG", "SI Data" + siData, isDebugEnabled)\r
- //Confirm there are no related service instances (vnf/network or volume)\r
- if (utils.nodeExists(siData, "relationship-list")) {\r
- utils.log("DEBUG", "SI Data relationship-list exists:", isDebugEnabled)\r
- InputSource source = new InputSource(new StringReader(siData));\r
- DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();\r
- DocumentBuilder docBuilder = docFactory.newDocumentBuilder()\r
- Document serviceXml = docBuilder.parse(source)\r
-\r
- NodeList nodeList = serviceXml.getElementsByTagName("relationship")\r
- for (int x = 0; x < nodeList.getLength(); x++) {\r
- Node node = nodeList.item(x)\r
- if (node.getNodeType() == Node.ELEMENT_NODE) {\r
- Element eElement = (Element) node\r
- def e = eElement.getElementsByTagName("related-to").item(0).getTextContent()\r
- if(e.equals("generic-vnf") || e.equals("l3-network")){\r
- utils.log("DEBUG", "ServiceInstance still has relationship(s) to generic-vnfs or l3-networks", isDebugEnabled)\r
- execution.setVariable("siInUse", true)\r
- //there are relationship dependencies to this Service Instance\r
- msg = " Stopped deleting Service Instance, it has dependencies. Service instance id: " + serviceInstanceId\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)\r
- }else{\r
- utils.log("DEBUG", "Relationship NOT related to OpenStack", isDebugEnabled)\r
- }\r
- }\r
- }\r
- }\r
- }\r
- }else{\r
- boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")\r
- if(succInAAI != true){\r
- utils.log("DEBUG","Error getting Service-instance from AAI", + serviceInstanceId, isDebugEnabled)\r
- WorkflowException workflowException = execution.getVariable("WorkflowException")\r
- utils.logAudit("workflowException: " + workflowException)\r
- if(workflowException != null){\r
- exceptionUtil.buildAndThrowWorkflowException(execution, workflowException.getErrorCode(), workflowException.getErrorMessage())\r
- }\r
- else\r
- {\r
- msg = "Failure in postProcessAAIGET GENGS_SuccessIndicator:" + succInAAI\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)\r
- }\r
- }\r
- utils.log("DEBUG","Service-instance NOT found in AAI. Silent Success", isDebugEnabled)\r
- }\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception ex) {\r
- msg = "Exception in DoDeleteServiceInstance.postProcessAAIGET. " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
- }\r
- utils.log("DEBUG"," *** Exit postProcessAAIGET *** ", isDebugEnabled)\r
- }\r
- \r
- public void postProcessAAIDEL(Execution execution) {\r
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")\r
- utils.log("DEBUG"," ***** postProcessAAIDEL ***** ", isDebugEnabled)\r
- String msg = ""\r
- try {\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- boolean succInAAI = execution.getVariable("GENDS_SuccessIndicator")\r
- if(succInAAI != true){\r
- msg = "Error deleting Service-instance in AAI" + serviceInstanceId\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- WorkflowException workflowException = execution.getVariable("WorkflowException")\r
- utils.logAudit("workflowException: " + workflowException)\r
- if(workflowException != null){\r
- exceptionUtil.buildAndThrowWorkflowException(execution, workflowException.getErrorCode(), workflowException.getErrorMessage())\r
- }\r
- else\r
- {\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)\r
- }\r
- }\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception ex) {\r
- msg = "Exception in DoDeleteServiceInstance.postProcessAAIDEL. " + ex.getMessage()\r
- utils.log("DEBUG", msg, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)\r
- }\r
- utils.log("DEBUG"," *** Exit postProcessAAIDEL *** ", isDebugEnabled)\r
- }\r
-}\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+package org.openecomp.mso.bpmn.infrastructure.scripts;
+
+import static org.apache.commons.lang3.StringUtils.*;
+import groovy.xml.XmlUtil
+import groovy.json.*
+
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.rest.APIResponse;
+import org.openecomp.mso.rest.RESTClient
+import org.openecomp.mso.rest.RESTConfig
+
+import java.util.UUID;
+import javax.xml.parsers.DocumentBuilder
+import javax.xml.parsers.DocumentBuilderFactory
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution
+import org.json.JSONObject;
+import org.apache.commons.lang3.*
+import org.apache.commons.codec.binary.Base64;
+import org.springframework.web.util.UriUtils;
+import org.w3c.dom.Document
+import org.w3c.dom.Element
+import org.w3c.dom.Node
+import org.w3c.dom.NodeList
+import org.xml.sax.InputSource
+
+/**
+ * This groovy class supports the <class>DoDeleteServiceInstance.bpmn</class> process.
+ *
+ * Inputs:
+ * @param - msoRequestId
+ * @param - globalSubscriberId - O
+ * @param - subscriptionServiceType - O
+ * @param - serviceInstanceId
+ * @param - serviceInstanceName - O
+ * @param - serviceModelInfo - O
+ * @param - productFamilyId
+ * @param - sdncVersion
+ * @param - failNotFound - TODO
+ * @param - serviceInputParams - TODO
+ *
+ * Outputs:
+ * @param - WorkflowException
+ *
+ * Rollback - Deferred
+ */
+public class DoDeleteServiceInstance extends AbstractServiceTaskProcessor {
+
+ String Prefix="DDELSI_"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils()
+
+ public void preProcessRequest (Execution execution) {
+ def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG"," ***** preProcessRequest *****", isDebugEnabled)
+ String msg = ""
+
+ try {
+ String requestId = execution.getVariable("msoRequestId")
+ execution.setVariable("prefix",Prefix)
+
+ //Inputs
+ //requestDetails.subscriberInfo. for AAI GET & PUT & SDNC assignToplology
+ String globalSubscriberId = execution.getVariable("globalSubscriberId") //globalCustomerId
+ if (globalSubscriberId == null)
+ {
+ execution.setVariable("globalSubscriberId", "")
+ }
+
+ //requestDetails.requestParameters. for AAI PUT & SDNC assignTopology
+ String subscriptionServiceType = execution.getVariable("subscriptionServiceType")
+ if (subscriptionServiceType == null)
+ {
+ execution.setVariable("subscriptionServiceType", "")
+ }
+
+ //Generated in parent for AAI PUT
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ if (isBlank(serviceInstanceId)){
+ msg = "Input serviceInstanceId is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ }
+
+ String sdncCallbackUrl = execution.getVariable('URN_mso_workflow_sdncadapter_callback')
+ if (isBlank(sdncCallbackUrl)) {
+ msg = "URN_mso_workflow_sdncadapter_callback is null"
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ }
+ execution.setVariable("sdncCallbackUrl", sdncCallbackUrl)
+ utils.log("DEBUG","SDNC Callback URL: " + sdncCallbackUrl, isDebugEnabled)
+
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception ex){
+ msg = "Exception in preProcessRequest " + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG"," ***** Exit preProcessRequest *****", isDebugEnabled)
+ }
+
+ public void preProcessSDNCDelete (Execution execution) {
+ def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG"," ***** preProcessSDNCDelete *****", isDebugEnabled)
+ String msg = ""
+
+ try {
+ /*
+ String uuid = execution.getVariable('testReqId') // for junits
+ if(uuid==null){
+ uuid = execution.getVariable("msoRequestId") + "-" + System.currentTimeMillis()
+ }
+ */
+ def serviceInstanceId = execution.getVariable("serviceInstanceId")
+ def serviceInstanceName = execution.getVariable("serviceInstanceName")
+ def callbackURL = execution.getVariable("sdncCallbackUrl")
+ def requestId = execution.getVariable("msoRequestId")
+ def serviceId = execution.getVariable("productFamilyId")
+ def subscriptionServiceType = execution.getVariable("subscriptionServiceType")
+ def globalSubscriberId = execution.getVariable("globalSubscriberId") //globalCustomerId
+
+ String serviceModelInfo = execution.getVariable("serviceModelInfo")
+ def modelInvariantId = ""
+ def modelVersion = ""
+ def modelUUId = ""
+ def modelName = ""
+ if (!isBlank(serviceModelInfo))
+ {
+ modelInvariantId = jsonUtil.getJsonValue(serviceModelInfo, "modelInvariantId")
+ modelVersion = jsonUtil.getJsonValue(serviceModelInfo, "modelVersion")
+ modelUUId = jsonUtil.getJsonValue(serviceModelInfo, "modelVersionId")
+ modelName = jsonUtil.getJsonValue(serviceModelInfo, "modelName")
+
+ if (modelInvariantId == null) {
+ modelInvariantId = ""
+ }
+ if (modelVersion == null) {
+ modelVersion = ""
+ }
+ if (modelUUId == null) {
+ modelUUId = ""
+ }
+ if (modelName == null) {
+ modelName = ""
+ }
+ }
+ if (serviceInstanceName == null) {
+ serviceInstanceName = ""
+ }
+ if (serviceId == null) {
+ serviceId = ""
+ }
+
+ def sdncRequestId = UUID.randomUUID().toString()
+
+ String sdncDelete =
+ """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
+ <sdncadapter:RequestHeader>
+ <sdncadapter:RequestId>${sdncRequestId}</sdncadapter:RequestId>
+ <sdncadapter:SvcInstanceId>${serviceInstanceId}</sdncadapter:SvcInstanceId>
+ <sdncadapter:SvcAction>delete</sdncadapter:SvcAction>
+ <sdncadapter:SvcOperation>service-topology-operation</sdncadapter:SvcOperation>
+ <sdncadapter:CallbackUrl>${callbackURL}</sdncadapter:CallbackUrl>
+ </sdncadapter:RequestHeader>
+ <sdncadapterworkflow:SDNCRequestData>
+ <request-information>
+ <request-id>${requestId}</request-id>
+ <source>MSO</source>
+ <notification-url/>
+ <order-number/>
+ <order-version/>
+ <request-action>DeleteServiceInstance</request-action>
+ </request-information>
+ <service-information>
+ <service-id>${serviceId}</service-id>
+ <subscription-service-type>${subscriptionServiceType}</subscription-service-type>
+ <ecomp-model-information>
+ <model-invariant-uuid>${modelInvariantId}</model-invariant-uuid>
+ <model-uuid>${modelUUId}</model-uuid>
+ <model-version>${modelVersion}</model-version>
+ <model-name>${modelName}</model-name>
+ </ecomp-model-information>
+ <service-instance-id>${serviceInstanceId}</service-instance-id>
+ <subscriber-name/>
+ <global-customer-id>${globalSubscriberId}</global-customer-id>
+ </service-information>
+ <service-request-input>
+ <service-instance-name>${serviceInstanceName}</service-instance-name>
+ </service-request-input>
+ </sdncadapterworkflow:SDNCRequestData>
+ </sdncadapterworkflow:SDNCAdapterWorkflowRequest>"""
+
+ sdncDelete = utils.formatXml(sdncDelete)
+ def sdncRequestId2 = UUID.randomUUID().toString()
+ String sdncDeactivate = sdncDelete.replace(">delete<", ">deactivate<").replace(">${sdncRequestId}<", ">${sdncRequestId2}<")
+ execution.setVariable("sdncDelete", sdncDelete)
+ execution.setVariable("sdncDeactivate", sdncDeactivate)
+ utils.log("DEBUG","sdncDeactivate:\n" + sdncDeactivate, isDebugEnabled)
+ utils.log("DEBUG","sdncDelete:\n" + sdncDelete, isDebugEnabled)
+
+ } catch (BpmnError e) {
+ throw e;
+ } catch(Exception ex) {
+ msg = "Exception in preProcessSDNCDelete. " + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, "Exception Occured in preProcessSDNCDelete.\n" + ex.getMessage())
+ }
+ utils.log("DEBUG"," *****Exit preProcessSDNCDelete *****", isDebugEnabled)
+ }
+
+ public void postProcessSDNCDelete(Execution execution, String response, String method) {
+
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG"," ***** postProcessSDNC " + method + " *****", isDebugEnabled)
+ String msg = ""
+
+ try {
+ WorkflowException workflowException = execution.getVariable("WorkflowException")
+ boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")
+ utils.log("DEBUG", "SDNCResponse: " + response, isDebugEnabled)
+ utils.log("DEBUG", "workflowException: " + workflowException, isDebugEnabled)
+
+ SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)
+ sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)
+
+ if(execution.getVariable(Prefix + 'sdncResponseSuccess') == true){
+ utils.log("DEBUG","Good response from SDNC Adapter for service-instance " + method + "response:\n" + response, isDebugEnabled)
+
+ }else{
+ msg = "Bad Response from SDNC Adapter for service-instance " + method
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 3500, msg)
+ }
+ } catch (BpmnError e) {
+ throw e;
+ } catch(Exception ex) {
+ msg = "Exception in postProcessSDNC " + method + " Exception:" + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG"," *** Exit postProcessSDNC " + method + " ***", isDebugEnabled)
+ }
+
+ public void postProcessAAIGET(Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG"," ***** postProcessAAIGET ***** ", isDebugEnabled)
+ String msg = ""
+
+ try {
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
+
+ if(foundInAAI == true){
+ utils.log("DEBUG","Found Service-instance in AAI", isDebugEnabled)
+
+ //Extract GlobalSubscriberId
+ String siRelatedLink = execution.getVariable("GENGS_siResourceLink")
+ if (isBlank(siRelatedLink))
+ {
+ msg = "Could not retrive ServiceInstance data from AAI to delete id:" + serviceInstanceId
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ }
+ else
+ {
+ utils.log("DEBUG","Found Service-instance in AAI. link: " + siRelatedLink, isDebugEnabled)
+ String globalSubscriberId = execution.getVariable("globalSubscriberId")
+ if(isBlank(globalSubscriberId)){
+ int custStart = siRelatedLink.indexOf("customer/")
+ int custEnd = siRelatedLink.indexOf("/service-subscriptions")
+ globalSubscriberId = siRelatedLink.substring(custStart + 9, custEnd)
+ execution.setVariable("globalSubscriberId", globalSubscriberId)
+ }
+
+ //Extract Service Type if not provided on request
+ String serviceType = execution.getVariable("subscriptionServiceType")
+ if(isBlank(serviceType)){
+ int serviceStart = siRelatedLink.indexOf("service-subscription/")
+ int serviceEnd = siRelatedLink.indexOf("/service-instances/")
+ String serviceTypeEncoded = siRelatedLink.substring(serviceStart + 21, serviceEnd)
+ serviceType = UriUtils.decode(serviceTypeEncoded, "UTF-8")
+ execution.setVariable("subscriptionServiceType", serviceType)
+ }
+
+ if (isBlank(globalSubscriberId) || isBlank(serviceType))
+ {
+ msg = "Could not retrive global-customer-id & service-type from AAI to delete id:" + serviceInstanceId
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ }
+ }
+
+ String siData = execution.getVariable("GENGS_service")
+ utils.log("DEBUG", "SI Data", isDebugEnabled)
+ if (isBlank(siData))
+ {
+ msg = "Could not retrive ServiceInstance data from AAI to delete id:" + serviceInstanceId
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
+ }
+ else
+ {
+ utils.log("DEBUG", "SI Data" + siData, isDebugEnabled)
+ //Confirm there are no related service instances (vnf/network or volume)
+ if (utils.nodeExists(siData, "relationship-list")) {
+ utils.log("DEBUG", "SI Data relationship-list exists:", isDebugEnabled)
+ InputSource source = new InputSource(new StringReader(siData));
+ DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();
+ DocumentBuilder docBuilder = docFactory.newDocumentBuilder()
+ Document serviceXml = docBuilder.parse(source)
+
+ NodeList nodeList = serviceXml.getElementsByTagName("relationship")
+ for (int x = 0; x < nodeList.getLength(); x++) {
+ Node node = nodeList.item(x)
+ if (node.getNodeType() == Node.ELEMENT_NODE) {
+ Element eElement = (Element) node
+ def e = eElement.getElementsByTagName("related-to").item(0).getTextContent()
+ if(e.equals("generic-vnf") || e.equals("l3-network")){
+ utils.log("DEBUG", "ServiceInstance still has relationship(s) to generic-vnfs or l3-networks", isDebugEnabled)
+ execution.setVariable("siInUse", true)
+ //there are relationship dependencies to this Service Instance
+ msg = " Stopped deleting Service Instance, it has dependencies. Service instance id: " + serviceInstanceId
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)
+ }else{
+ utils.log("DEBUG", "Relationship NOT related to OpenStack", isDebugEnabled)
+ }
+ }
+ }
+ }
+ }
+ }else{
+ boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
+ if(succInAAI != true){
+ utils.log("DEBUG","Error getting Service-instance from AAI", + serviceInstanceId, isDebugEnabled)
+ WorkflowException workflowException = execution.getVariable("WorkflowException")
+ utils.logAudit("workflowException: " + workflowException)
+ if(workflowException != null){
+ exceptionUtil.buildAndThrowWorkflowException(execution, workflowException.getErrorCode(), workflowException.getErrorMessage())
+ }
+ else
+ {
+ msg = "Failure in postProcessAAIGET GENGS_SuccessIndicator:" + succInAAI
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)
+ }
+ }
+ utils.log("DEBUG","Service-instance NOT found in AAI. Silent Success", isDebugEnabled)
+ }
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception ex) {
+ msg = "Exception in DoDeleteServiceInstance.postProcessAAIGET. " + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG"," *** Exit postProcessAAIGET *** ", isDebugEnabled)
+ }
+
+ public void postProcessAAIDEL(Execution execution) {
+ def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
+ utils.log("DEBUG"," ***** postProcessAAIDEL ***** ", isDebugEnabled)
+ String msg = ""
+ try {
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ boolean succInAAI = execution.getVariable("GENDS_SuccessIndicator")
+ if(succInAAI != true){
+ msg = "Error deleting Service-instance in AAI" + serviceInstanceId
+ utils.log("DEBUG", msg, isDebugEnabled)
+ WorkflowException workflowException = execution.getVariable("WorkflowException")
+ utils.logAudit("workflowException: " + workflowException)
+ if(workflowException != null){
+ exceptionUtil.buildAndThrowWorkflowException(execution, workflowException.getErrorCode(), workflowException.getErrorMessage())
+ }
+ else
+ {
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)
+ }
+ }
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception ex) {
+ msg = "Exception in DoDeleteServiceInstance.postProcessAAIDEL. " + ex.getMessage()
+ utils.log("DEBUG", msg, isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
+ }
+ utils.log("DEBUG"," *** Exit postProcessAAIDEL *** ", isDebugEnabled)
+ }
+}
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-package org.openecomp.mso.bpmn.infrastructure.scripts\r
-\r
-import java.util.UUID;\r
-\r
-import org.json.JSONObject;\r
-import org.json.JSONArray;\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution;\r
-\r
-import static org.apache.commons.lang3.StringUtils.*;\r
-\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils\r
-import org.openecomp.mso.rest.APIResponse\r
-import org.openecomp.mso.rest.RESTClient\r
-import org.openecomp.mso.rest.RESTConfig\r
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils\r
-import org.openecomp.mso.bpmn.core.RollbackData\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-\r
-/**\r
- * This class supports the macro VID Flow\r
- * with the deletion of a generic vnf and related VF modules.\r
- */\r
-class DoDeleteVnfAndModules extends AbstractServiceTaskProcessor {\r
-\r
- String Prefix="DDVAM_"\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
- VidUtils vidUtils = new VidUtils(this) \r
-\r
- /**\r
- * This method gets and validates the incoming\r
- * request.\r
- *\r
- * @param - execution\r
- * \r
- */\r
- public void preProcessRequest(Execution execution) {\r
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix",Prefix)\r
- utils.log("DEBUG", " *** STARTED DoDeleteVnfAndModules PreProcessRequest Process*** ", isDebugEnabled)\r
-\r
- try{\r
- // Get Variables \r
- \r
- String cloudConfiguration = execution.getVariable("cloudConfiguration") \r
- \r
- String requestId = execution.getVariable("requestId")\r
- execution.setVariable("mso-request-id", requestId)\r
- utils.log("DEBUG", "Incoming Request Id is: " + requestId, isDebugEnabled)\r
-\r
- String serviceInstanceId = execution.getVariable("serviceInstanceId") \r
- utils.log("DEBUG", "Incoming Service Instance Id is: " + serviceInstanceId, isDebugEnabled)\r
-\r
- String vnfId = execution.getVariable("vnfId") \r
- utils.log("DEBUG", "Incoming Vnf Id is: " + vnfId, isDebugEnabled) \r
- \r
- String source = "VID"\r
- execution.setVariable("source", source)\r
- utils.log("DEBUG", "Incoming Source is: " + source, isDebugEnabled)\r
- \r
- execution.setVariable("DDVAM_moduleCount", 0)\r
- execution.setVariable("DDVAM_nextModule", 0)\r
- \r
- \r
- }catch(BpmnError b){\r
- utils.log("DEBUG", "Rethrowing MSOWorkflowException", isDebugEnabled)\r
- throw b\r
- }catch(Exception e){\r
- utils.log("DEBUG", " Error Occured in DoCreateVnfAndModules PreProcessRequest method!" + e.getMessage(), isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PreProcessRequest")\r
-\r
- }\r
- utils.log("DEBUG", "*** COMPLETED DoCreateVnfAndModules PreProcessRequest Process ***", isDebugEnabled)\r
- } \r
-\r
- \r
- \r
- public void preProcessAddOnModule(Execution execution){\r
- def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
- logDebug(" ======== STARTED preProcessAddOnModule ======== ", isDebugLogEnabled)\r
- \r
- try { \r
- JSONArray addOnModules = (JSONArray) execution.getVariable("addOnModules")\r
- int addOnIndex = (int) execution.getVariable("addOnModulesDeployed")\r
- \r
- JSONObject addOnModule = addOnModules[addOnIndex]\r
- \r
- def newVfModuleId = UUID.randomUUID().toString()\r
- execution.setVariable("addOnVfModuleId", newVfModuleId)\r
- \r
- execution.setVariable("instancesOfThisModelDeployed", 0)\r
- \r
- JSONObject addOnVfModuleModelInfoObject = jsonUtil.getJsonValueForKey(addOnModule, "modelInfo")\r
- String addOnVfModuleModelInfo = addOnVfModuleModelInfoObject.toString()\r
- execution.setVariable("addOnVfModuleModelInfo", addOnVfModuleModelInfo)\r
- String addOnVfModuleLabel = jsonUtil.getJsonValueForKey(addOnModule, "vfModuleLabel")\r
- execution.setVariable("addOnVfModuleLabel", addOnVfModuleLabel)\r
- String addOnPersonaModelId = jsonUtil.getJsonValueForKey(addOnVfModuleModelInfoObject, "modelInvariantId")\r
- execution.setVariable("addOnPersonaModelId", addOnPersonaModelId)\r
- String addOnInitialCount = jsonUtil.getJsonValueForKey(addOnModule, "initialCount")\r
- execution.setVariable("initialCount", addOnInitialCount)\r
- \r
- \r
- }catch(Exception e){\r
- utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())\r
- }\r
- logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)\r
- }\r
- \r
- /**\r
- * Using the received vnfId and vfModuleId, query AAI to get the corresponding VNF info.\r
- * A 200 response is expected with the VNF info in the response body. Will find out the base module info.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void queryAAIVfModule(Execution execution) {\r
- def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")\r
- def method = getClass().getSimpleName() + '.queryAAIVfModule(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def vnfId = execution.getVariable('DvnfId')\r
- \r
- AaiUtil aaiUriUtil = new AaiUtil(this)\r
- String aai_uri = aaiUriUtil.getNetworkGenericVnfUri(execution)\r
- logDebug('AAI URI is: ' + aai_uri, isDebugLogEnabled)\r
-\r
- String endPoint = execution.getVariable("URN_aai_endpoint") + "${aai_uri}/" + UriUtils.encode(vnfId, "UTF-8") + "?depth=1"\r
- utils.logAudit("AAI endPoint: " + endPoint)\r
-\r
- try {\r
- RESTConfig config = new RESTConfig(endPoint);\r
- def responseData = ''\r
- def aaiRequestId = UUID.randomUUID().toString()\r
- RESTClient client = new RESTClient(config).\r
- addHeader('X-TransactionId', aaiRequestId).\r
- addHeader('X-FromAppId', 'MSO').\r
- addHeader('Content-Type', 'application/xml').\r
- addHeader('Accept','application/xml');\r
- logDebug('sending GET to AAI endpoint \'' + endPoint + '\'', isDebugLogEnabled)\r
- APIResponse response = client.httpGet()\r
- utils.logAudit("createVfModule - invoking httpGet() to AAI")\r
-\r
- responseData = response.getResponseBodyAsString()\r
- if (responseData != null) {\r
- logDebug("Received generic VNF data: " + responseData, isDebugLogEnabled)\r
-\r
- }\r
-\r
- utils.logAudit("createVfModule - queryAAIVfModule Response: " + responseData)\r
- utils.logAudit("createVfModule - queryAAIVfModule ResponseCode: " + response.getStatusCode())\r
-\r
- execution.setVariable('DCVFM_queryAAIVfModuleResponseCode', response.getStatusCode())\r
- execution.setVariable('DCVFM_queryAAIVfModuleResponse', responseData)\r
- logDebug('Response code:' + response.getStatusCode(), isDebugLogEnabled)\r
- logDebug('Response:' + System.lineSeparator() + responseData, isDebugLogEnabled)\r
- //Map<String, String>[] vfModules = new HashMap<String,String>[]\r
- List<Map<String,String>> vfModulesList = new ArrayList<Map<String,String>>();\r
- if (response.getStatusCode() == 200) {\r
- // Parse the VNF record from A&AI to find base module info\r
- logDebug('Parsing the VNF data to find base module info', isDebugLogEnabled)\r
- if (responseData != null) {\r
- def vfModulesText = utils.getNodeXml(responseData, "vf-modules")\r
- def xmlVfModules= new XmlSlurper().parseText(vfModulesText)\r
- def vfModules = xmlVfModules.'**'.findAll {it.name() == "vf-module"}\r
- execution.setVariable("DDVAM_moduleCount", vfModules.size())\r
- int vfModulesSize = 0\r
- for (i in 0..vfModules.size()-1) {\r
- def vfModuleXml = groovy.xml.XmlUtil.serialize(vfModules[i])\r
- \r
- Map<String, String> vfModuleEntry = new HashMap<String, String>()\r
- def vfModuleId = utils.getNodeText1(vfModuleXml, "vf-module-id")\r
- vfModuleEntry.put("vfModuleId", vfModuleName)\r
- def vfModuleName = utils.getNodeText1(vfModuleXml, "vf-module-name")\r
- vfModuleEntry.put("vfModuleName", vfModuleName) \r
- vfModulesList.add(vfModuleEntry) \r
- }\r
- \r
- } \r
- }\r
- execution.setVariable("DDVAM_vfModules", vfModules)\r
- } catch (Exception ex) {\r
- ex.printStackTrace()\r
- logDebug('Exception occurred while executing AAI GET:' + ex.getMessage(),isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'AAI GET Failed:' + ex.getMessage())\r
- }\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in queryAAIVfModule(): ' + e.getMessage())\r
- }\r
- }\r
- \r
- public void prepareNextModuleToDelete(Execution execution){\r
- def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")\r
- execution.setVariable("prefix", Prefix)\r
- logDebug(" ======== STARTED prepareNextModuleToDelete ======== ", isDebugLogEnabled)\r
- \r
- try {\r
- int i = execution.getVariable("DDVAM_nextModule")\r
- def vfModules = execution.getVariable("DDVAM_vfModules")\r
- def vfModule = vfModules[i]\r
- \r
- def vfModuleId = vfModule.get("vfModuleId")\r
- execution.setVariable("DDVAM_vfModuleId", vfModuleId)\r
- \r
- def vfModuleName = vfModule.get("vfModuleName")\r
- execution.setVariable("DDVAM_vfModuleName", vfModuleName)\r
- \r
- \r
- // HARDCODED FOR NOW\r
- def vfModuleModelInfo = ""\r
- execution.setVariable("DDVAM_vfModuleModelInfo", vfModuleModelInfo) \r
- \r
- }catch(Exception e){\r
- utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())\r
- }\r
- logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)\r
- }\r
- \r
- \r
- \r
- \r
-}\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+package org.openecomp.mso.bpmn.infrastructure.scripts
+
+import java.util.UUID;
+
+import org.json.JSONObject;
+import org.json.JSONArray;
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution;
+
+import static org.apache.commons.lang3.StringUtils.*;
+
+import org.openecomp.mso.bpmn.core.json.JsonUtils
+import org.openecomp.mso.rest.APIResponse
+import org.openecomp.mso.rest.RESTClient
+import org.openecomp.mso.rest.RESTConfig
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
+import org.openecomp.mso.bpmn.common.scripts.VidUtils
+import org.openecomp.mso.bpmn.core.RollbackData
+import org.openecomp.mso.bpmn.core.WorkflowException
+
+/**
+ * This class supports the macro VID Flow
+ * with the deletion of a generic vnf and related VF modules.
+ */
+class DoDeleteVnfAndModules extends AbstractServiceTaskProcessor {
+
+ String Prefix="DDVAM_"
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+ JsonUtils jsonUtil = new JsonUtils()
+ VidUtils vidUtils = new VidUtils(this)
+ SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)
+
+ /**
+ * This method gets and validates the incoming
+ * request.
+ *
+ * @param - execution
+ *
+ */
+ public void preProcessRequest(Execution execution) {
+ def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ utils.log("DEBUG", " *** STARTED DoDeleteVnfAndModules PreProcessRequest Process*** ", isDebugEnabled)
+
+ try{
+ // Get Variables
+
+ String cloudConfiguration = execution.getVariable("cloudConfiguration")
+
+ String requestId = execution.getVariable("msoRequestId")
+ execution.setVariable("requestId", requestId)
+ execution.setVariable("mso-request-id", requestId)
+ utils.log("DEBUG", "Incoming Request Id is: " + requestId, isDebugEnabled)
+
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+ utils.log("DEBUG", "Incoming Service Instance Id is: " + serviceInstanceId, isDebugEnabled)
+
+ String vnfId = execution.getVariable("vnfId")
+ utils.log("DEBUG", "Incoming Vnf Id is: " + vnfId, isDebugEnabled)
+
+ String source = "VID"
+ execution.setVariable("DDVAM_source", source)
+ utils.log("DEBUG", "Incoming Source is: " + source, isDebugEnabled)
+
+ String sdncVersion = execution.getVariable("sdncVersion")
+ if (sdncVersion == null) {
+ sdncVersion = "1702"
+ }
+ execution.setVariable("DDVAM_sdncVersion", sdncVersion)
+ utils.log("DEBUG", "Incoming Sdnc Version is: " + sdncVersion, isDebugEnabled)
+
+ String sdncCallbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')
+ if (sdncCallbackUrl == null || sdncCallbackUrl.trim().isEmpty()) {
+ def msg = 'Required variable \'URN_mso_workflow_sdncadapter_callback\' is missing'
+ logError(msg)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2000, msg)
+ }
+ execution.setVariable("sdncCallbackUrl", sdncCallbackUrl)
+ utils.logAudit("SDNC Callback URL: " + sdncCallbackUrl)
+ logDebug("SDNC Callback URL is: " + sdncCallbackUrl, isDebugEnabled)
+
+ if (!sdncVersion.equals("1702")) {
+ //String vnfModelInfo = execution.getVariable("vnfModelInfo")
+ //String serviceModelInfo = execution.getVariable("serviceModelInfo")
+
+ String serviceId = execution.getVariable("productFamilyId")
+ execution.setVariable("DDVAM_serviceId", serviceId)
+ utils.log("DEBUG", "Incoming Service Id is: " + serviceId, isDebugEnabled)
+
+
+ //String modelInvariantId = jsonUtil.getJsonValue(vnfModelInfo, "modelInvariantId")
+ //execution.setVariable("DDVAM_modelInvariantId", modelInvariantId)
+ //utils.log("DEBUG", "Incoming Invariant Id is: " + modelInvariantId, isDebugEnabled)
+
+ //String modelVersionId = jsonUtil.getJsonValue(vnfModelInfo, "modelVersionId")
+ //if (modelVersionId == null) {
+ // modelVersionId = ""
+ //}
+ //execution.setVariable("DDVAM_modelVersionId", modelVersionId)
+ //utils.log("DEBUG", "Incoming Version Id is: " + modelVersionId, isDebugEnabled)
+
+ //String modelVersion = jsonUtil.getJsonValue(vnfModelInfo, "modelVersion")
+ //execution.setVariable("DDVAM_modelVersion", modelVersion)
+ //utils.log("DEBUG", "Incoming Model Version is: " + modelVersion, isDebugEnabled)
+
+ //String modelName = jsonUtil.getJsonValue(vnfModelInfo, "modelName")
+ //execution.setVariable("DDVAM_modelName", modelName)
+ //utils.log("DEBUG", "Incoming Model Name is: " + modelName, isDebugEnabled)
+
+ //String modelCustomizationId = jsonUtil.getJsonValue(vnfModelInfo, "modelCustomizationId")
+ //if (modelCustomizationId == null) {
+ // modelCustomizationId = ""
+ //}
+ //execution.setVariable("DDVAM_modelCustomizationId", modelCustomizationId)
+ //utils.log("DEBUG", "Incoming Model Customization Id is: " + modelCustomizationId, isDebugEnabled)
+
+ String cloudSiteId = execution.getVariable("lcpCloudRegionId")
+ execution.setVariable("DDVAM_cloudSiteId", cloudSiteId)
+ utils.log("DEBUG", "Incoming Cloud Site Id is: " + cloudSiteId, isDebugEnabled)
+
+ String tenantId = execution.getVariable("tenantId")
+ execution.setVariable("DDVAM_tenantId", tenantId)
+ utils.log("DEBUG", "Incoming Tenant Id is: " + tenantId, isDebugEnabled)
+
+ String globalSubscriberId = execution.getVariable("globalSubscriberId")
+ if (globalSubscriberId == null) {
+ globalSubscriberId = ""
+ }
+ execution.setVariable("DDVAM_globalSubscriberId", globalSubscriberId)
+ utils.log("DEBUG", "Incoming Global Subscriber Id is: " + globalSubscriberId, isDebugEnabled)
+ }
+ execution.setVariable("DDVAM_moduleCount", 0)
+ execution.setVariable("DDVAM_nextModule", 0)
+
+
+ }catch(BpmnError b){
+ utils.log("DEBUG", "Rethrowing MSOWorkflowException", isDebugEnabled)
+ throw b
+ }catch(Exception e){
+ utils.log("DEBUG", " Error Occured in DoCreateVnfAndModules PreProcessRequest method!" + e.getMessage(), isDebugEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Internal Error - Occured in DoCreateVnf PreProcessRequest")
+
+ }
+ utils.log("DEBUG", "*** COMPLETED DoCreateVnfAndModules PreProcessRequest Process ***", isDebugEnabled)
+ }
+
+
+
+ public void preProcessAddOnModule(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED preProcessAddOnModule ======== ", isDebugLogEnabled)
+
+ try {
+ JSONArray addOnModules = (JSONArray) execution.getVariable("addOnModules")
+ int addOnIndex = (int) execution.getVariable("addOnModulesDeployed")
+
+ JSONObject addOnModule = addOnModules[addOnIndex]
+
+ def newVfModuleId = UUID.randomUUID().toString()
+ execution.setVariable("addOnVfModuleId", newVfModuleId)
+
+ execution.setVariable("instancesOfThisModelDeployed", 0)
+
+ JSONObject addOnVfModuleModelInfoObject = jsonUtil.getJsonValueForKey(addOnModule, "modelInfo")
+ String addOnVfModuleModelInfo = addOnVfModuleModelInfoObject.toString()
+ execution.setVariable("addOnVfModuleModelInfo", addOnVfModuleModelInfo)
+ String addOnVfModuleLabel = jsonUtil.getJsonValueForKey(addOnModule, "vfModuleLabel")
+ execution.setVariable("addOnVfModuleLabel", addOnVfModuleLabel)
+ String addOnPersonaModelId = jsonUtil.getJsonValueForKey(addOnVfModuleModelInfoObject, "modelInvariantId")
+ execution.setVariable("addOnPersonaModelId", addOnPersonaModelId)
+ String addOnInitialCount = jsonUtil.getJsonValueForKey(addOnModule, "initialCount")
+ execution.setVariable("initialCount", addOnInitialCount)
+
+
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessAddOnModule Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED preProcessSDNCAssignRequest ======== ", isDebugLogEnabled)
+ }
+
+ /**
+ * Using the received vnfId and vfModuleId, query AAI to get the corresponding VNF info.
+ * A 200 response is expected with the VNF info in the response body. Will find out the base module info.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void queryAAIVfModule(Execution execution) {
+ def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")
+ def method = getClass().getSimpleName() + '.queryAAIVfModule(' +
+ 'execution=' + execution.getId() +
+ ')'
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def vnfId = execution.getVariable('vnfId')
+
+ AaiUtil aaiUriUtil = new AaiUtil(this)
+ String aai_uri = aaiUriUtil.getNetworkGenericVnfUri(execution)
+ logDebug('AAI URI is: ' + aai_uri, isDebugLogEnabled)
+
+ String endPoint = execution.getVariable("URN_aai_endpoint") + "${aai_uri}/" + UriUtils.encode(vnfId, "UTF-8") + "?depth=1"
+ utils.logAudit("AAI endPoint: " + endPoint)
+
+ try {
+ RESTConfig config = new RESTConfig(endPoint);
+ def responseData = ''
+ def aaiRequestId = UUID.randomUUID().toString()
+ RESTClient client = new RESTClient(config).
+ addHeader('X-TransactionId', aaiRequestId).
+ addHeader('X-FromAppId', 'MSO').
+ addHeader('Content-Type', 'application/xml').
+ addHeader('Accept','application/xml');
+ logDebug('sending GET to AAI endpoint \'' + endPoint + '\'', isDebugLogEnabled)
+ APIResponse response = client.httpGet()
+ utils.logAudit("createVfModule - invoking httpGet() to AAI")
+
+ responseData = response.getResponseBodyAsString()
+ if (responseData != null) {
+ logDebug("Received generic VNF data: " + responseData, isDebugLogEnabled)
+
+ }
+
+ utils.logAudit("createVfModule - queryAAIVfModule Response: " + responseData)
+ utils.logAudit("createVfModule - queryAAIVfModule ResponseCode: " + response.getStatusCode())
+
+ execution.setVariable('DCVFM_queryAAIVfModuleResponseCode', response.getStatusCode())
+ execution.setVariable('DCVFM_queryAAIVfModuleResponse', responseData)
+ logDebug('Response code:' + response.getStatusCode(), isDebugLogEnabled)
+ logDebug('Response:' + System.lineSeparator() + responseData, isDebugLogEnabled)
+ //Map<String, String>[] vfModules = new HashMap<String,String>[]
+ def vfModulesList = new ArrayList<Map<String,String>>()
+ def vfModules = null
+ def vfModuleBaseEntry = null
+ if (response.getStatusCode() == 200) {
+ // Parse the VNF record from A&AI to find base module info
+ logDebug('Parsing the VNF data to find base module info', isDebugLogEnabled)
+ if (responseData != null) {
+ def vfModulesText = utils.getNodeXml(responseData, "vf-modules")
+ logDebug("vModulesText: " + vfModulesText, isDebugLogEnabled)
+ if (vfModulesText != null && !vfModulesText.trim().isEmpty()) {
+ def xmlVfModules= new XmlSlurper().parseText(vfModulesText)
+ vfModules = xmlVfModules.'**'.findAll {it.name() == "vf-module"}
+ execution.setVariable("DDVAM_moduleCount", vfModules.size())
+ int vfModulesSize = 0
+ for (i in 0..vfModules.size()-1) {
+ def vfModuleXml = groovy.xml.XmlUtil.serialize(vfModules[i])
+
+ Map<String, String> vfModuleEntry = new HashMap<String, String>()
+ def vfModuleId = utils.getNodeText1(vfModuleXml, "vf-module-id")
+ vfModuleEntry.put("vfModuleId", vfModuleId)
+ def vfModuleName = utils.getNodeText1(vfModuleXml, "vf-module-name")
+ vfModuleEntry.put("vfModuleName", vfModuleName)
+
+ def isBaseVfModule = utils.getNodeText(vfModuleXml, "is-base-vf-module")
+ // Save base vf module for last
+ if (isBaseVfModule == "true") {
+ vfModuleBaseEntry = vfModuleEntry
+ }
+ else {
+ vfModulesList.add(vfModuleEntry)
+ }
+ }
+ if (vfModuleBaseEntry != null) {
+ vfModulesList.add(vfModuleBaseEntry)
+ }
+ }
+
+ }
+ }
+ execution.setVariable("DDVAM_vfModules", vfModulesList)
+ } catch (Exception ex) {
+ ex.printStackTrace()
+ logDebug('Exception occurred while executing AAI GET:' + ex.getMessage(),isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'AAI GET Failed:' + ex.getMessage())
+ }
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in queryAAIVfModule(): ' + e.getMessage())
+ }
+ }
+
+ public void prepareNextModuleToDelete(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED prepareNextModuleToDelete ======== ", isDebugLogEnabled)
+
+ try {
+ int i = execution.getVariable("DDVAM_nextModule")
+ def vfModules = execution.getVariable("DDVAM_vfModules")
+ def vfModule = vfModules[i]
+
+ def vfModuleId = vfModule.get("vfModuleId")
+ execution.setVariable("DDVAM_vfModuleId", vfModuleId)
+
+ def vfModuleName = vfModule.get("vfModuleName")
+ execution.setVariable("DDVAM_vfModuleName", vfModuleName)
+
+
+ // HARDCODED FOR NOW
+ def vfModuleModelInfo = ""
+ execution.setVariable("DDVAM_vfModuleModelInfo", vfModuleModelInfo)
+
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occured Processing preProcessAddOnModule. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during prepareNextModuleToDelete Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED prepareNextModuleToDelete ======== ", isDebugLogEnabled)
+ }
+
+ public void preProcessSDNCDeactivateRequest(Execution execution){
+ def isDebugLogEnabled = execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED preProcessSDNCDeactivateRequest ======== ", isDebugLogEnabled)
+ def vnfId = execution.getVariable("vnfId")
+ def serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ try{
+ //Build SDNC Request
+
+ String deactivateSDNCRequest = buildSDNCRequest(execution, serviceInstanceId, "deactivate")
+
+ deactivateSDNCRequest = utils.formatXml(deactivateSDNCRequest)
+ execution.setVariable("DDVAM_deactivateSDNCRequest", deactivateSDNCRequest)
+ logDebug("Outgoing DeactivateSDNCRequest is: \n" + deactivateSDNCRequest, isDebugLogEnabled)
+ utils.logAudit("Outgoing DeactivateSDNCRequest is: \n" + deactivateSDNCRequest)
+
+ }catch(Exception e){
+ utils.log("ERROR", "Exception Occured Processing preProcessSDNCDeactivateRequest. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during preProcessSDNCDeactivateRequest Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED preProcessSDNCDeactivateRequest ======== ", isDebugLogEnabled)
+ }
+
+ public void preProcessSDNCUnassignRequest(Execution execution) {
+ def method = getClass().getSimpleName() + '.preProcessSDNCUnassignRequest(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+ execution.setVariable("prefix", Prefix)
+ logDebug(" ======== STARTED preProcessSDNCUnassignRequest Process ======== ", isDebugLogEnabled)
+ try{
+ String vnfId = execution.getVariable("vnfId")
+ String serviceInstanceId = execution.getVariable("serviceInstanceId")
+
+ String unassignSDNCRequest = buildSDNCRequest(execution, serviceInstanceId, "unassign")
+
+ execution.setVariable("DDVAM_unassignSDNCRequest", unassignSDNCRequest)
+ logDebug("Outgoing UnassignSDNCRequest is: \n" + unassignSDNCRequest, isDebugLogEnabled)
+ utils.logAudit("Outgoing UnassignSDNCRequest is: \n" + unassignSDNCRequest)
+
+ }catch(Exception e){
+ log.debug("Exception Occured Processing preProcessSDNCUnassignRequest. Exception is:\n" + e, isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occured during preProcessSDNCUnassignRequest Method:\n" + e.getMessage())
+ }
+ logDebug("======== COMPLETED preProcessSDNCUnassignRequest Process ======== ", isDebugLogEnabled)
+ }
+
+ public String buildSDNCRequest(Execution execution, String svcInstId, String action){
+
+ String uuid = execution.getVariable('testReqId') // for junits
+ if(uuid==null){
+ uuid = execution.getVariable("mso-request-id") + "-" + System.currentTimeMillis()
+ }
+ def callbackURL = execution.getVariable("sdncCallbackUrl")
+ def requestId = execution.getVariable("msoRequestId")
+ def serviceId = execution.getVariable("DDVAM_serviceId")
+ def tenantId = execution.getVariable("DDVAM_tenantId")
+ def source = execution.getVariable("DDVAM_source")
+ def vnfId = execution.getVariable("vnfId")
+ def serviceInstanceId = execution.getVariable("serviceInstanceId")
+ def cloudSiteId = execution.getVariable("DDVAM_cloudSiteId")
+ def modelCustomizationId = execution.getVariable("DDVAM_modelCustomizationId")
+ //def serviceModelInfo = execution.getVariable("serviceModelInfo")
+ //def vnfModelInfo = execution.getVariable("vnfModelInfo")
+ //String serviceEcompModelInformation = sdncAdapterUtils.modelInfoToEcompModelInformation(serviceModelInfo)
+ //String vnfEcompModelInformation = sdncAdapterUtils.modelInfoToEcompModelInformation(vnfModelInfo)
+ def globalSubscriberId = execution.getVariable("DDVAM_globalSubscriberId")
+ def sdncVersion = execution.getVariable("DDVAM_sdncVersion")
+
+ String sdncRequest =
+ """<sdncadapterworkflow:SDNCAdapterWorkflowRequest xmlns:ns5="http://org.openecomp/mso/request/types/v1"
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
+ <sdncadapter:RequestHeader>
+ <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
+ <sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>
+ <sdncadapter:SvcAction>${action}</sdncadapter:SvcAction>
+ <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>
+ <sdncadapter:CallbackUrl>${callbackURL}</sdncadapter:CallbackUrl>
+ <sdncadapter:MsoAction>generic-resource</sdncadapter:MsoAction>
+ </sdncadapter:RequestHeader>
+ <sdncadapterworkflow:SDNCRequestData>
+ <request-information>
+ <request-id>${requestId}</request-id>
+ <request-action>DeleteVnfInstance</request-action>
+ <source>${source}</source>
+ <notification-url/>
+ <order-number/>
+ <order-version/>
+ </request-information>
+ <service-information>
+ <service-id/>
+ <subscription-service-type/>
+ <service-instance-id>${serviceInstanceId}</service-instance-id>
+ <global-customer-id/>
+ </service-information>
+ <vnf-information>
+ <vnf-id>${vnfId}</vnf-id>
+ <vnf-type/>
+ </vnf-information>
+ <vnf-request-input>
+ <vnf-name/>
+ <tenant>${tenantId}</tenant>
+ <aic-cloud-region>${cloudSiteId}</aic-cloud-region>
+ </vnf-request-input>
+ </sdncadapterworkflow:SDNCRequestData>
+ </sdncadapterworkflow:SDNCAdapterWorkflowRequest>"""
+
+ utils.logAudit("sdncRequest: " + sdncRequest)
+ return sdncRequest
+ }
+
+ public void validateSDNCResponse(Execution execution, String response, String method){
+ def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")
+ execution.setVariable("prefix",Prefix)
+ logDebug(" *** STARTED ValidateSDNCResponse Process*** ", isDebugLogEnabled)
+
+ WorkflowException workflowException = execution.getVariable("WorkflowException")
+ boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")
+
+ utils.logAudit("workflowException: " + workflowException)
+
+ SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)
+ sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)
+
+ utils.logAudit("SDNCResponse: " + response)
+
+ String sdncResponse = response
+ if(execution.getVariable(Prefix + 'sdncResponseSuccess') == true){
+ logDebug("Received a Good Response from SDNC Adapter for " + method + " SDNC Call. Response is: \n" + sdncResponse, isDebugLogEnabled)
+ }else{
+ logDebug("Received a BAD Response from SDNC Adapter for " + method + " SDNC Call.", isDebugLogEnabled)
+ throw new BpmnError("MSOWorkflowException")
+ }
+ logDebug(" *** COMPLETED ValidateSDNCResponse Process*** ", isDebugLogEnabled)
+ }
+
+
+
+
+
+
+
+}
String networkId = utils.getNodeText1(networkRequest, "network-id")
networkId = UriUtils.encode(networkId,"UTF-8")
execution.setVariable(Prefix + "networkId", networkId)
- String messageId = execution.getVariable(Prefix + "messageId")
// Prepare AA&I url
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
String networkRequest = execution.getVariable(Prefix + "networkRequest")
String networkId = utils.getNodeText1(networkRequest, "network-id")
networkId = UriUtils.encode(networkId,"UTF-8")
- String messageId = execution.getVariable(Prefix + "messageId")
// Prepare AA&I url
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
try {
// get variables
- String messageId = execution.getVariable(Prefix + "messageId")
String queryIdAAIResponse = execution.getVariable(Prefix + "requeryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
// reset return code to success
execution.setVariable(Prefix + "aaiQqueryVpnBindingReturnCode", "200")
String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String schemaVersion = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
String aaiStubResponse =
""" <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
<vpn-binding xmlns="${schemaVersion}">
try {
// get variables
- String messageId = execution.getVariable(Prefix + "messageId")
String queryIdAAIResponse = execution.getVariable(Prefix + "requeryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
// reset return code to success
execution.setVariable(Prefix + "aaiQqueryNetworkPolicyReturnCode", "200")
String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String schemaVersion = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
String aaiStubResponse =
""" <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
<network-policy xmlns="${schemaVersion}">
try {
// get variables
- String messageId = execution.getVariable(Prefix + "messageId")
String queryIdAAIResponse = execution.getVariable(Prefix + "requeryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
// reset return code to success
execution.setVariable(Prefix + "aaiQqueryNetworkTableRefReturnCode", "200")
String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String schemaVersion = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
String aaiStubResponse =
""" <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
<route-table-references xmlns="${schemaVersion}">
networkId = UriUtils.encode(networkId,"UTF-8")
String requeryIdAAIResponse = execution.getVariable(Prefix + "requeryIdAAIResponse")
String updateNetworkResponse = execution.getVariable(Prefix + "updateNetworkResponse")
- String messageId = execution.getVariable(Prefix + "messageId")
// Prepare url
String aai_endpoint = execution.getVariable("URN_aai_endpoint")
utils.log("DEBUG", " UPDNETI_updateContrailAAIUrlRequest - " + "\n" + updateContrailAAIUrlRequest, isDebugEnabled)
//Prepare payload (PUT)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
+ String schemaVersion = aaiUriUtil.getNamespaceFromUri(execution, aai_uri)
String payload = networkUtils.ContrailNetworkCreatedUpdate(requeryIdAAIResponse, updateNetworkResponse, schemaVersion)
String payloadXml = utils.formatXml(payload)
utils.logAudit(payloadXml)
// aai all errors
String errorMessage = "Unexpected Response from UpdateContrailAAINetwork - " + returnCode
utils.log("DEBUG", errorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, "2500", errorMessage)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, errorMessage)
}
}
}
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts\r
-\r
-import org.camunda.bpm.engine.delegate.BpmnError\r
-import org.camunda.bpm.engine.runtime.Execution\r
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
-import org.openecomp.mso.bpmn.common.scripts.NetworkUtils\r
-import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils\r
-import org.openecomp.mso.bpmn.common.scripts.VfModule\r
-import org.openecomp.mso.bpmn.common.scripts.VfModuleBase\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils;\r
-import org.openecomp.mso.rest.APIResponse\r
-import org.springframework.web.util.UriUtils\r
-\r
-public class DoUpdateVfModule extends VfModuleBase {\r
-\r
- ExceptionUtil exceptionUtil = new ExceptionUtil()\r
- JsonUtils jsonUtil = new JsonUtils()\r
-\r
- /**\r
- * Initialize the flow's variables.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void initProcessVariables(Execution execution) {\r
- execution.setVariable('prefix', 'DOUPVfMod_')\r
- execution.setVariable('DOUPVfMod_requestInfo', null)\r
- execution.setVariable('DOUPVfMod_serviceInstanceId', null)\r
- execution.setVariable('DOUPVfMod_requestId', null)\r
- execution.setVariable('DOUPVfMod_vnfInputs', null)\r
- execution.setVariable('DOUPVfMod_vnfId', null)\r
- execution.setVariable('DOUPVfMod_vnfName', null)\r
- execution.setVariable('DOUPVfMod_vnfNameFromAAI', null)\r
- execution.setVariable('DOUPVfMod_vfModuleName', null)\r
- execution.setVariable('DOUPVfMod_vfModuleId', null)\r
- execution.setVariable('DOUPVfMod_vnfType', null)\r
- execution.setVariable('DOUPVfMod_asdcServiceModelVersion', null)\r
- execution.setVariable('DOUPVfMod_vfModuleModelName', null)\r
- execution.setVariable('DOUPVfMod_modelCustomizationUuid', null)\r
- execution.setVariable("DOUPVfMod_isBaseVfModule", "false")\r
- execution.setVariable('DOUPVfMod_serviceId', null)\r
- execution.setVariable('DOUPVfMod_aicCloudRegion', null)\r
- execution.setVariable('DOUPVfMod_tenantId', null)\r
- execution.setVariable('DOUPVfMod_volumeGroupId', null)\r
- execution.setVariable('DOUPVfMod_vfModule', null)\r
- execution.setVariable('DOUPVfMod_vnfParams', null)\r
- execution.setVariable("DOUPVfMod_baseVfModuleId", "")\r
- execution.setVariable("DOUPVfMod_baseVfModuleHeatStackId", "")\r
- execution.setVariable('DOUPVfMod_prepareUpdateAAIVfModuleRequest', null)\r
- execution.setVariable('DOUPVfMod_sdncChangeAssignRequest', null)\r
- execution.setVariable('DOUPVfMod_sdncChangeAssignResponse', null)\r
- execution.setVariable('DOUPVfMod_sdncActivateRequest', null)\r
- execution.setVariable('DOUPVfMod_sdncActivateResponse', null)\r
- execution.setVariable('DOUPVfMod_sdncTopologyRequest', null)\r
- execution.setVariable('DOUPVfMod_sdncTopologyResponse', null)\r
- execution.setVariable('DOUPVfMod_vnfAdapterRestRequest', null)\r
- execution.setVariable('DOUPVfMod_updateAAIGenericVnfRequest', null)\r
- execution.setVariable('DOUPVfMod_updateAAIVfModuleRequest', null)\r
- execution.setVariable('DOUPVfMod_skipUpdateGenericVnf', false)\r
- execution.setVariable('DoUpdateVfModuleSuccessIndicator', false)\r
- }\r
-\r
- /**\r
- * Check for missing elements in the received request.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void preProcessRequest(Execution execution) {\r
- def method = getClass().getSimpleName() + '.preProcessRequest(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- initProcessVariables(execution)\r
- def xml = getVariable(execution, 'DoUpdateVfModuleRequest')\r
- utils.logAudit("DoUpdateVfModule request: " + xml)\r
- logDebug('Received request xml:\n' + xml, isDebugLogEnabled)\r
- \r
- if (xml == null || xml.isEmpty()) {\r
- // Building Block-type request\r
-\r
- String cloudConfiguration = execution.getVariable("cloudConfiguration")\r
- String vfModuleModelInfo = execution.getVariable("vfModuleModelInfo")\r
- \r
- def serviceModelInfo = execution.getVariable("serviceModelInfo")\r
- logDebug("serviceModelInfo: " + serviceModelInfo, isDebugLogEnabled)\r
- def vnfModelInfo = execution.getVariable("vnfModelInfo")\r
- \r
-\r
- //tenantId\r
- def tenantId = jsonUtil.getJsonValue(cloudConfiguration, "cloudConfiguration.tenantId")\r
- execution.setVariable("DOUPVfMod_tenantId", tenantId)\r
- \r
- //volumeGroupId\r
- def volumeGroupId = execution.getVariable("volumeGroupId")\r
- execution.setVariable("DOUPVfMod_volumeGroupId", volumeGroupId)\r
- //volumeGroupName\r
- def volumeGroupName = execution.getVariable("volumeGroupName")\r
- execution.setVariable("DOUPVfMod_volumeGroupName", volumeGroupName)\r
- //cloudSiteId\r
- def cloudSiteId = jsonUtil.getJsonValue(cloudConfiguration, "cloudConfiguration.lcpCloudRegionId")\r
- execution.setVariable("DOUPVfMod_cloudSiteId", cloudSiteId)\r
- \r
- logDebug("cloudSiteId: " + cloudSiteId, isDebugLogEnabled)\r
- //vnfType\r
- def vnfType = execution.getVariable("vnfType")\r
- execution.setVariable("DOUPVfMod_vnfType", vnfType)\r
- \r
- logDebug("vnfType: " + vnfType, isDebugLogEnabled)\r
- //vnfName\r
- def vnfName = execution.getVariable("vnfName")\r
- execution.setVariable("DOUPVfMod_vnfName", vnfName)\r
- \r
- logDebug("vnfName: " + vnfName, isDebugLogEnabled)\r
- //vnfId\r
- def vnfId = execution.getVariable("vnfId")\r
- execution.setVariable("DOUPVfMod_vnfId", vnfId)\r
- \r
- logDebug("vnfId: " + vnfId, isDebugLogEnabled)\r
- //vfModuleName\r
- def vfModuleName = execution.getVariable("vfModuleName")\r
- execution.setVariable("DOUPVfMod_vfModuleName", vfModuleName)\r
- \r
- logDebug("vfModuleName: " + vfModuleName, isDebugLogEnabled)\r
- //vfModuleModelName\r
- def vfModuleModelName = jsonUtil.getJsonValue(vfModuleModelInfo, "modelName")\r
- execution.setVariable("DOUPVfMod_vfModuleModelName", vfModuleModelName)\r
- \r
- logDebug("vfModuleModelName: " + vfModuleModelName, isDebugLogEnabled)\r
- //modelCustomizationUuid\r
- def modelCustomizationUuid = jsonUtil.getJsonValue(vfModuleModelInfo, "modelCustomizationId")\r
- execution.setVariable("DOUPVfMod_modelCustomizationUuid", modelCustomizationUuid)\r
- \r
- logDebug("modelCustomizationUuid: " + modelCustomizationUuid, isDebugLogEnabled)\r
- //vfModuleId\r
- def vfModuleId = execution.getVariable("vfModuleId")\r
- execution.setVariable("DOUPVfMod_vfModuleId", vfModuleId)\r
- logDebug("vfModuleId: " + vfModuleId, isDebugLogEnabled)\r
- def requestId = execution.getVariable("requestId")\r
- execution.setVariable("DOUPVfMod_requestId", requestId)\r
- logDebug("requestId: " + requestId, isDebugLogEnabled)\r
- // Set mso-request-id to request-id for VNF Adapter interface\r
- execution.setVariable("mso-request-id", requestId)\r
- //serviceId\r
- def serviceId = execution.getVariable("serviceId")\r
- execution.setVariable("DOUPVfMod_serviceId", serviceId)\r
- logDebug("serviceId: " + serviceId, isDebugLogEnabled)\r
- //serviceInstanceId\r
- def serviceInstanceId = execution.getVariable("serviceInstanceId")\r
- execution.setVariable("DOUPVfMod_serviceInstanceId", serviceInstanceId)\r
- \r
- logDebug("serviceInstanceId: " + serviceInstanceId, isDebugLogEnabled)\r
- //source - HARDCODED\r
- def source = "VID"\r
- execution.setVariable("DOUPVfMod_source", source)\r
- \r
- logDebug("source: " + source, isDebugLogEnabled)\r
- //backoutOnFailure\r
- def disableRollback = execution.getVariable("disableRollback")\r
- def backoutOnFailure = true\r
- if (disableRollback != null && disableRollback.equals("true")) {\r
- backoutOnFailure = false\r
- }\r
- execution.setVariable("DOUPVfMod_backoutOnFailure", backoutOnFailure)\r
- logDebug("backoutOnFailure: " + backoutOnFailure, isDebugLogEnabled)\r
- //isBaseVfModule\r
- def isBaseVfModule = execution.getVariable("isBaseVfModule")\r
- execution.setVariable("DOUPVfMod_isBaseVfModule", isBaseVfModule)\r
- logDebug("isBaseVfModule: " + isBaseVfModule, isDebugLogEnabled)\r
- //asdcServiceModelVersion\r
- def asdcServiceModelVersion = execution.getVariable("asdcServiceModelVersion")\r
- execution.setVariable("DOUPVfMod_asdcServiceModelVersion", asdcServiceModelVersion)\r
- logDebug("asdcServiceModelVersion: " + asdcServiceModelVersion, isDebugLogEnabled)\r
- //personaModelId\r
- execution.setVariable("DOUPVfMod_personaModelId", jsonUtil.getJsonValue(vfModuleModelInfo, "modelInvariantId"))\r
- //personaModelVersion\r
- execution.setVariable("DOUPVfMod_personaModelVersion", jsonUtil.getJsonValue(vfModuleModelInfo, "modelVersion"))\r
- //Get or Generate UUID\r
- String uuid = execution.getVariable("DOUPVfMod_uuid")\r
- if(uuid == null){\r
- uuid = UUID.randomUUID()\r
- logDebug("Generated messageId (UUID) is: " + uuid, isDebugLogEnabled)\r
- }else{\r
- logDebug("Found messageId (UUID) is: " + uuid, isDebugLogEnabled)\r
- }\r
- //isVidRequest\r
- String isVidRequest = execution.getVariable("isVidRequest")\r
- // default to true\r
- if (isVidRequest == null || isVidRequest.isEmpty()) {\r
- execution.setVariable("isVidRequest", "true")\r
- }\r
- //globalSubscriberId\r
- String globalSubscriberId = execution.getVariable("globalSubscriberId")\r
- execution.setVariable("DOUPVfMod_globalSubscriberId", globalSubscriberId)\r
- logDebug("globalSubsrciberId: " + globalSubscriberId, isDebugLogEnabled)\r
- //vnfQueryPath\r
- String vnfQueryPath = execution.getVariable("vnfQueryPath")\r
- execution.setVariable("DOUPVfMod_vnfQueryPath", vnfQueryPath)\r
- logDebug("vnfQueryPath: " + vnfQueryPath, isDebugLogEnabled)\r
-\r
- String vnfParamsChildNodes = execution.getVariable("vfModuleInputParams")\r
- execution.setVariable('DOUPVfMod_vnfParams', vnfParamsChildNodes)\r
- }\r
- else {\r
-\r
- def requestInfo = getRequiredNodeXml(execution, xml, 'request-info')\r
- execution.setVariable('DOUPVfMod_requestInfo', requestInfo)\r
- execution.setVariable('DOUPVfMod_requestId', getRequiredNodeText(execution, requestInfo, 'request-id'))\r
- def serviceInstanceId = execution.getVariable('mso-service-instance-id')\r
- if (serviceInstanceId == null) {\r
- serviceInstanceId = ''\r
- }\r
- execution.setVariable('DOUPVfMod_serviceInstanceId', serviceInstanceId)\r
- \r
- def vnfInputs = getRequiredNodeXml(execution, xml, 'vnf-inputs')\r
- execution.setVariable('DOUPVfMod_vnfInputs', vnfInputs)\r
- execution.setVariable('DOUPVfMod_vnfId', getRequiredNodeText(execution, vnfInputs, 'vnf-id'))\r
- execution.setVariable('DOUPVfMod_vfModuleId', getRequiredNodeText(execution, vnfInputs, 'vf-module-id'))\r
- execution.setVariable('DOUPVfMod_vfModuleName', getNodeTextForce(vnfInputs, 'vf-module-name'))\r
- execution.setVariable('DOUPVfMod_vnfType', getNodeTextForce(vnfInputs, 'vnf-type'))\r
- execution.setVariable('DOUPVfMod_vnfName', getNodeTextForce(vnfInputs, 'vnf-name'))\r
- execution.setVariable('DOUPVfMod_asdcServiceModelVersion', getNodeTextForce(vnfInputs, 'asdc-service-model-version'))\r
- execution.setVariable('DOUPVfMod_vfModuleModelName', getRequiredNodeText(execution, vnfInputs, 'vf-module-model-name'))\r
- execution.setVariable('DOUPVfMod_modelCustomizationUuid', getNodeTextForce(vnfInputs, 'model-customization-id'))\r
- execution.setVariable('DOUPVfMod_serviceId', getRequiredNodeText(execution, vnfInputs, 'service-id'))\r
- execution.setVariable('DOUPVfMod_aicCloudRegion', getRequiredNodeText(execution, vnfInputs, 'aic-cloud-region'))\r
- execution.setVariable('DOUPVfMod_tenantId', getRequiredNodeText(execution, vnfInputs, 'tenant-id'))\r
- //isBaseVfModule\r
- def isBaseVfModule = "false"\r
- if (utils.nodeExists(xml, "is-base-vf-module")) {\r
- isBaseVfModule = utils.getNodeText(xml, "is-base-vf-module")\r
- execution.setVariable("DOUPVfMod_isBaseVfModule", isBaseVfModule)\r
- }\r
- logDebug("isBaseVfModule: " + isBaseVfModule, isDebugLogEnabled)\r
- \r
- NetworkUtils networkUtils = new NetworkUtils()\r
- def backoutOnFailure = networkUtils.isRollbackEnabled(execution, xml)\r
- execution.setVariable("DOUPVfMod_backoutOnFailure", backoutOnFailure)\r
- \r
- def String vgi = getNodeTextForce(vnfInputs, 'volume-group-id')\r
- execution.setVariable('DOUPVfMod_volumeGroupId', vgi)\r
- \r
- execution.setVariable('DOUPVfMod_vnfParams', utils.getNodeXml(xml, 'vnf-params', false))\r
- }\r
-\r
- def sdncCallbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')\r
- if (sdncCallbackUrl == null || sdncCallbackUrl.trim().isEmpty()) {\r
- def msg = 'Required variable \'URN_mso_workflow_sdncadapter_callback\' is missing'\r
- logError(msg)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2000, msg)\r
- }\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in preProcessRequest(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Prepare a Request for invoking the PrepareUpdateAAIVfModule subflow. This will\r
- * set the orchestration-status to 'pending-update'.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void prepPrepareUpdateAAIVfModule(Execution execution) {\r
- def method = getClass().getSimpleName() + '.preparePrepareUpdateAAIVfModule(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def vnfId = execution.getVariable('DOUPVfMod_vnfId')\r
- def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')\r
- def orchestrationStatus = 'pending-update'\r
-\r
- String prepareUpdateAAIVfModuleRequest = """\r
- <PrepareUpdateAAIVfModuleRequest>\r
- <vnf-id>${vnfId}</vnf-id>\r
- <vf-module-id>${vfModuleId}</vf-module-id>\r
- <orchestration-status>${orchestrationStatus}</orchestration-status>\r
- </PrepareUpdateAAIVfModuleRequest>\r
- """\r
- prepareUpdateAAIVfModuleRequest = utils.formatXml(prepareUpdateAAIVfModuleRequest)\r
- execution.setVariable('DOUPVfMod_prepareUpdateAAIVfModuleRequest', prepareUpdateAAIVfModuleRequest)\r
- utils.logAudit("DoUpdateAAIVfModule request: " + prepareUpdateAAIVfModuleRequest)\r
- logDebug('Request for PrepareUpdateAAIVfModule:\n' + prepareUpdateAAIVfModuleRequest, isDebugLogEnabled)\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in preparePrepareUpdateAAIVfModule(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Prepare a Request for invoking the ConfirmVolumeGroupTenant subflow. Currently,\r
- * there is really nothing to do, so we just log that we're passing through.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void prepConfirmVolumeGroupTenant(Execution execution) {\r
- def method = getClass().getSimpleName() + '.prepConfirmVolumeGroupTenant(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- // Nothing to do - just log that we're passing through here\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepConfirmVolumeGroupTenant(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Prepare a Request for invoking the SDNC Adapter subflow to perform\r
- * a VNF topology 'changeassign' operation.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void prepSDNCTopologyChg(Execution execution) {\r
- def method = getClass().getSimpleName() + '.prepSDNCTopologyChg(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def requestId = execution.getVariable('DOUPVfMod_requestId')\r
- def serviceInstanceId = execution.getVariable('DOUPVfMod_serviceInstanceId')\r
- def callbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')\r
- def serviceId = execution.getVariable('DOUPVfMod_serviceId')\r
- def vnfId = execution.getVariable('DOUPVfMod_vnfId')\r
- def vnfType = execution.getVariable('DOUPVfMod_vnfType')\r
- def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')\r
- def vfModuleModelName = execution.getVariable('DOUPVfMod_vfModuleModelName')\r
- def VfModule vfModule = (VfModule) execution.getVariable('DOUPVfMod_vfModule')\r
- def vfModuleName = vfModule.getElementText('vf-module-name')\r
- def tenantId = execution.getVariable('DOUPVfMod_tenantId')\r
- def aicCloudRegion = execution.getVariable('DOUPVfMod_aicCloudRegion')\r
-\r
- // Retrieve vnf name from AAI response\r
- def vnfName = execution.getVariable('DOUPVfMod_vnfNameFromAAI')\r
- execution.setVariable('DOUPVfMod_vnfName', vnfName)\r
-\r
- def vnfParamsXml = execution.getVariable('DOUPVfMod_vnfParams')\r
- def vnfNetworks = transformNetworkParamsToVnfNetworks(vnfParamsXml)\r
-\r
- String sdncTopologyRequest = """\r
- <sdncadapterworkflow:SDNCAdapterWorkflowRequest\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
- <sdncadapter:RequestHeader>\r
- <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>\r
- <sdncadapter:SvcInstanceId>${serviceInstanceId}</sdncadapter:SvcInstanceId>\r
- <sdncadapter:SvcAction>changeassign</sdncadapter:SvcAction>\r
- <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>\r
- <sdncadapter:CallbackUrl>${callbackUrl}</sdncadapter:CallbackUrl>\r
- </sdncadapter:RequestHeader>\r
- <sdncadapterworkflow:SDNCRequestData>\r
- <request-information>\r
- <request-id>${requestId}</request-id>\r
- <request-action>ChangeVNFActivateRequest</request-action>\r
- <source>PORTAL</source>\r
- <notification-url/>\r
- <order-number/>\r
- <order-version/>\r
- </request-information>\r
- <service-information>\r
- <service-type>${serviceId}</service-type>\r
- <service-instance-id>${vnfId}</service-instance-id>\r
- <subscriber-name>dontcare</subscriber-name>\r
- </service-information>\r
- <vnf-request-information>\r
- <vnf-id>${vfModuleId}</vnf-id>\r
- <vnf-type>${vfModuleModelName}</vnf-type>\r
- <vnf-name>${vfModuleName}</vnf-name>\r
- <generic-vnf-id>${vnfId}</generic-vnf-id>\r
- <generic-vnf-name>${vnfName}</generic-vnf-name>\r
- <generic-vnf-type>${vnfType}</generic-vnf-type>\r
- <tenant>${tenantId}</tenant>\r
- <aic-cloud-region>${aicCloudRegion}</aic-cloud-region>\r
- ${vnfNetworks}\r
- </vnf-request-information>\r
- </sdncadapterworkflow:SDNCRequestData>\r
- </sdncadapterworkflow:SDNCAdapterWorkflowRequest>\r
- """\r
- sdncTopologyRequest = utils.formatXml(sdncTopologyRequest)\r
- execution.setVariable('DOUPVfMod_sdncChangeAssignRequest', sdncTopologyRequest)\r
- utils.logAudit("sdncChangeAssignRequest : " + sdncTopologyRequest)\r
- logDebug('Request for SDNCAdapter topology/changeassign:\n' + sdncTopologyRequest, isDebugLogEnabled)\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepSDNCTopologyChg(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Prepare a Request for invoking the SDNC Adapter subflow to perform\r
- * a VNF topology 'query' operation.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void prepSDNCTopologyQuery(Execution execution) {\r
- def method = getClass().getSimpleName() + '.prepSDNCTopologyQuery(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def requestId = execution.getVariable('DOUPVfMod_requestId')\r
- def serviceInstanceId = execution.getVariable('DOUPVfMod_serviceInstanceId')\r
- def callbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')\r
- def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')\r
-\r
- def svcInstId = ""\r
- if (serviceInstanceId == null || serviceInstanceId.isEmpty()) {\r
- svcInstId = vfModuleId\r
- }\r
- else {\r
- svcInstId = serviceInstanceId\r
- }\r
-\r
- //!!!! TEMPORARY WORKAROUND FOR SDNC REPLICATION ISSUE\r
- sleep(5000)\r
-\r
- String sdncTopologyRequest = """\r
- <sdncadapterworkflow:SDNCAdapterWorkflowRequest\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
- <sdncadapter:RequestHeader>\r
- <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>\r
- <sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>\r
- <sdncadapter:SvcAction>query</sdncadapter:SvcAction>\r
- <sdncadapter:SvcOperation>/VNF-API:vnfs/vnf-list/${vfModuleId}</sdncadapter:SvcOperation>\r
- <sdncadapter:CallbackUrl>${callbackUrl}</sdncadapter:CallbackUrl>\r
- <sdncadapter:MsoAction>mobility</sdncadapter:MsoAction>\r
- </sdncadapter:RequestHeader>\r
- </sdncadapterworkflow:SDNCAdapterWorkflowRequest>\r
- """\r
- sdncTopologyRequest = utils.formatXml(sdncTopologyRequest)\r
- execution.setVariable('DOUPVfMod_sdncTopologyRequest', sdncTopologyRequest)\r
- utils.logAudit("sdncTopologyRequest : " + sdncTopologyRequest)\r
- logDebug('Request for SDNCAdapter query:\n' + sdncTopologyRequest, isDebugLogEnabled)\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepSDNCTopologyQuery(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Prepare a Request for invoking the VnfAdapterRest subflow.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void prepVnfAdapterRest(Execution execution) {\r
- def method = getClass().getSimpleName() + '.prepVnfAdapterRest(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def requestId = execution.getVariable('DOUPVfMod_requestId')\r
- def serviceInstanceId = execution.getVariable('DOUPVfMod_serviceInstanceId')\r
- def vnfId = execution.getVariable('DOUPVfMod_vnfId')\r
- def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')\r
- def vfModuleName = execution.getVariable('DOUPVfMod_vfModuleName')\r
- def vnfInputs = execution.getVariable('DOUPVfMod_vnfInputs')\r
- def tenantId = execution.getVariable('DOUPVfMod_tenantId')\r
- def volumeGroupId = execution.getVariable('DOUPVfMod_volumeGroupId')\r
- def VfModule vfModule = (VfModule) execution.getVariable('DOUPVfMod_vfModule')\r
- def heatStackId = vfModule.getElementText('heat-stack-id')\r
- def cloudId = execution.getVariable('DOUPVfMod_aicCloudRegion')\r
- def vnfType = execution.getVariable('DOUPVfMod_vnfType')\r
- def vnfName = execution.getVariable('DOUPVfMod_vnfName')\r
- def vfModuleModelName = execution.getVariable('DOUPVfMod_vfModuleModelName')\r
- def baseVfModuleId = execution.getVariable("DOUPVfMod_baseVfModuleId")\r
- def baseVfModuleStackId = execution.getVariable("DOUPVfMod_baseVfModuleHeatStackId")\r
- def asdcServiceModelVersion = execution.getVariable('DOUPVfMod_asdcServiceModelVersion')\r
- def modelCustomizationUuid = execution.getVariable('DOUPVfMod_modelCustomizationUuid')\r
- def backoutOnFailure = execution.getVariable("DOUPVfMod_backoutOnFailure")\r
-\r
- def vnfParamsXml = execution.getVariable('DOUPVfMod_vnfParams')\r
- def vfModuleParamsEntries = transformParamsToEntries(vnfParamsXml)\r
-\r
- def messageId = execution.getVariable('mso-request-id') + '-' + System.currentTimeMillis()\r
- def notificationUrl = createCallbackURL(execution, "VNFAResponse", messageId)\r
- def useQualifiedHostName = execution.getVariable("URN_mso_use_qualified_host")\r
- if ('true'.equals(useQualifiedHostName)) {\r
- notificationUrl = utils.getQualifiedHostNameForCallback(notificationUrl)\r
- }\r
-\r
- String sdncGetResponse = execution.getVariable('DOUPVfMod_sdncTopologyResponse')\r
-\r
- String vfModuleParams = buildVfModuleParams(vfModuleParamsEntries, sdncGetResponse, vnfId, vnfName,\r
- vfModuleId, vfModuleName, null)\r
-\r
-\r
- String vnfAdapterRestRequest = """\r
- <updateVfModuleRequest>\r
- <cloudSiteId>${cloudId}</cloudSiteId>\r
- <tenantId>${tenantId}</tenantId>\r
- <vnfId>${vnfId}</vnfId>\r
- <vfModuleId>${vfModuleId}</vfModuleId>\r
- <vfModuleStackId>${heatStackId}</vfModuleStackId>\r
- <vnfType>${vnfType}</vnfType>\r
- <vnfVersion>${asdcServiceModelVersion}</vnfVersion>\r
- <modelCustomizationUuid>${modelCustomizationUuid}</modelCustomizationUuid>\r
- <vfModuleType>${vfModuleModelName}</vfModuleType>\r
- <volumeGroupId>${volumeGroupId}</volumeGroupId>\r
- <baseVfModuleId>${baseVfModuleId}</baseVfModuleId>\r
- <baseVfModuleStackId>${baseVfModuleStackId}</baseVfModuleStackId>\r
- <skipAAI>true</skipAAI>\r
- <backout>${backoutOnFailure}</backout>\r
- <failIfExists>false</failIfExists>\r
- <vfModuleParams>\r
- ${vfModuleParams}\r
- </vfModuleParams>\r
- <msoRequest>\r
- <requestId>${requestId}</requestId>\r
- <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>\r
- </msoRequest>\r
- <messageId>${messageId}</messageId>\r
- <notificationUrl>${notificationUrl}</notificationUrl>\r
- </updateVfModuleRequest>\r
- """\r
- vnfAdapterRestRequest = utils.formatXml(vnfAdapterRestRequest)\r
- execution.setVariable('DOUPVfMod_vnfAdapterRestRequest', vnfAdapterRestRequest)\r
- utils.logAudit("vnfAdapterRestRequest : " + vnfAdapterRestRequest)\r
- logDebug('Request for VNFAdapter Rest:\n' + vnfAdapterRestRequest, isDebugLogEnabled)\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepVnfAdapterRest(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Prepare a Request for invoking the UpdateAAIGenericVnf subflow.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void prepUpdateAAIGenericVnf(Execution execution) {\r
- def method = getClass().getSimpleName() + '.prepUpdateAAIGenericVnf(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def vnfId = execution.getVariable('DOUPVfMod_vnfId')\r
- def vnfInputs = execution.getVariable('DOUPVfMod_vnfInputs')\r
-\r
- def personaModelId = utils.getNodeText1(vnfInputs, 'vnf-persona-model-id')\r
- def personaModelVersion = utils.getNodeText1(vnfInputs, 'vnf-persona-model-version')\r
- if ((personaModelId == null) || (personaModelVersion == null)) {\r
- logDebug('Skipping update for Generic VNF ' + vnfId +\r
- ' because either \'vnf-persona-model-id\' or \'vnf-persona-model-version\' is absent', isDebugLogEnabled)\r
- execution.setVariable('DOUPVfMod_skipUpdateGenericVnf', true)\r
- } else {\r
- def personaModelIdElement = '<persona-model-id>' + personaModelId + '</persona-model-id>'\r
- def personaModelVersionElement = '<persona-model-version>' + personaModelVersion + '</persona-model-version>'\r
-\r
- String updateAAIGenericVnfRequest = """\r
- <UpdateAAIGenericVnfRequest>\r
- <vnf-id>${vnfId}</vnf-id>\r
- ${personaModelIdElement}\r
- ${personaModelVersionElement}\r
- </UpdateAAIGenericVnfRequest>\r
- """\r
- updateAAIGenericVnfRequest = utils.formatXml(updateAAIGenericVnfRequest)\r
- execution.setVariable('DOUPVfMod_updateAAIGenericVnfRequest', updateAAIGenericVnfRequest)\r
- utils.logAudit("updateAAIGenericVnfRequest : " + updateAAIGenericVnfRequest)\r
- logDebug('Request for UpdateAAIGenericVnf:\n' + updateAAIGenericVnfRequest, isDebugLogEnabled)\r
- }\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepUpdateAAIGenericVnf(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Prepare a Request for invoking the UpdateAAIVfModule subflow.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void prepUpdateAAIVfModule(Execution execution) {\r
- def method = getClass().getSimpleName() + '.prepUpdateAAIVfModule(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def vnfId = execution.getVariable('DOUPVfMod_vnfId')\r
- def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')\r
- def orchestrationStatus = 'updated'\r
- def vnfInputs = execution.getVariable('DOUPVfMod_vnfInputs')\r
-\r
- def volumeGroupIdElement = ''\r
- def volumeGroupId = execution.getVariable('DOUPVfMod_volumeGroupId')\r
- if (volumeGroupId != null) {\r
- volumeGroupIdElement = '<volume-group-id>' + volumeGroupId + '</volume-group-id>'\r
- }\r
- def personaModelIdElement = ''\r
- def personaModelId = utils.getNodeText1(vnfInputs, 'persona-model-id')\r
- if (personaModelId != null) {\r
- personaModelIdElement = '<persona-model-id>' + personaModelId + '</persona-model-id>'\r
- }\r
- def personaModelVersionElement = ''\r
- def personaModelVersion = utils.getNodeText1(vnfInputs, 'persona-model-version')\r
- if (personaModelVersion != null) {\r
- personaModelVersionElement = '<persona-model-version>' + personaModelVersion + '</persona-model-version>'\r
- }\r
- def contrailServiceInstanceFqdnElement = ''\r
- def contrailServiceInstanceFqdn = utils.getNodeText1(vnfInputs, 'contrail-service-instance-fqdn')\r
- if (contrailServiceInstanceFqdn != null) {\r
- contrailServiceInstanceFqdnElement = '<contrail-service-instance-fqdn>' + contrailServiceInstanceFqdn + '</contrail-service-instance-fqdn>'\r
- }\r
- def personaModelCustomizationIdElement = ''\r
- def modelCustomizationId = execution.getVariable('DOUPVfMod_modelCustomizationUuid')\r
- if (modelCustomizationId != null) {\r
- personaModelCustomizationIdElement = '<persona-model-customization-id>' + modelCustomizationId + '</persona-model-customization-id>'\r
- }\r
-\r
- String updateAAIVfModuleRequest = """\r
- <UpdateAAIVfModuleRequest>\r
- <vnf-id>${vnfId}</vnf-id>\r
- <vf-module-id>${vfModuleId}</vf-module-id>\r
- <orchestration-status>${orchestrationStatus}</orchestration-status>\r
- ${volumeGroupIdElement}\r
- ${personaModelIdElement}\r
- ${personaModelVersionElement}\r
- ${contrailServiceInstanceFqdnElement}\r
- ${personaModelCustomizationIdElement}\r
- </UpdateAAIVfModuleRequest>\r
- """\r
- updateAAIVfModuleRequest = utils.formatXml(updateAAIVfModuleRequest)\r
- execution.setVariable('DOUPVfMod_updateAAIVfModuleRequest', updateAAIVfModuleRequest)\r
- utils.logAudit("updateAAIVfModuleRequest : " + updateAAIVfModuleRequest)\r
- logDebug('Request for UpdateAAIVfModule:\n' + updateAAIVfModuleRequest, isDebugLogEnabled)\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepUpdateAAIVfModule(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Prepare a Request for invoking the SDNC Adapter subflow to perform\r
- * a VNF topology 'activate' operation.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void prepSDNCTopologyAct(Execution execution) {\r
- def method = getClass().getSimpleName() + '.prepSDNCTopologyAct(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def requestId = execution.getVariable('DOUPVfMod_requestId')\r
- def serviceInstanceId = execution.getVariable('DOUPVfMod_serviceInstanceId')\r
- def callbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')\r
- def serviceId = execution.getVariable('DOUPVfMod_serviceId')\r
- def vnfId = execution.getVariable('DOUPVfMod_vnfId')\r
- def vnfName = execution.getVariable('DOUPVfMod_vnfName')\r
- def vnfType = execution.getVariable('DOUPVfMod_vnfType')\r
- def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')\r
- def vfModuleModelName = execution.getVariable('DOUPVfMod_vfModuleModelName')\r
- def VfModule vfModule = (VfModule) execution.getVariable('DOUPVfMod_vfModule')\r
- def vfModuleName = vfModule.getElementText('vf-module-name')\r
- def tenantId = execution.getVariable('DOUPVfMod_tenantId')\r
- def aicCloudRegion = execution.getVariable('DOUPVfMod_aicCloudRegion')\r
-\r
- def vnfParamsXml = execution.getVariable('DOUPVfMod_vnfParams')\r
- def vnfNetworks = transformNetworkParamsToVnfNetworks(vnfParamsXml)\r
-\r
- String sdncTopologyRequest = """\r
- <sdncadapterworkflow:SDNCAdapterWorkflowRequest\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
- <sdncadapter:RequestHeader>\r
- <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>\r
- <sdncadapter:SvcInstanceId>${serviceInstanceId}</sdncadapter:SvcInstanceId>\r
- <sdncadapter:SvcAction>activate</sdncadapter:SvcAction>\r
- <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>\r
- <sdncadapter:CallbackUrl>${callbackUrl}</sdncadapter:CallbackUrl>\r
- </sdncadapter:RequestHeader>\r
- <sdncadapterworkflow:SDNCRequestData>\r
- <request-information>\r
- <request-id>${requestId}</request-id>\r
- <request-action>ChangeVNFActivateRequest</request-action>\r
- <source>PORTAL</source>\r
- <notification-url/>\r
- <order-number/>\r
- <order-version/>\r
- </request-information>\r
- <service-information>\r
- <service-type>${serviceId}</service-type>\r
- <service-instance-id>${vnfId}</service-instance-id>\r
- <subscriber-name>dontcare</subscriber-name>\r
- </service-information>\r
- <vnf-request-information>\r
- <vnf-id>${vfModuleId}</vnf-id>\r
- <vnf-type>${vfModuleModelName}</vnf-type>\r
- <vnf-name>${vfModuleName}</vnf-name>\r
- <generic-vnf-id>${vnfId}</generic-vnf-id>\r
- <generic-vnf-name>${vnfName}</generic-vnf-name>\r
- <generic-vnf-type>${vnfType}</generic-vnf-type>\r
- <tenant>${tenantId}</tenant>\r
- <aic-cloud-region>${aicCloudRegion}</aic-cloud-region>\r
- </vnf-request-information>\r
- </sdncadapterworkflow:SDNCRequestData>\r
- </sdncadapterworkflow:SDNCAdapterWorkflowRequest>\r
- """\r
- sdncTopologyRequest = utils.formatXml(sdncTopologyRequest)\r
- execution.setVariable('DOUPVfMod_sdncActivateRequest', sdncTopologyRequest)\r
- utils.logAudit("sdncActivateRequest : " + sdncTopologyRequest)\r
- logDebug('Request for SDNCAdapter topology/activate:\n' + sdncTopologyRequest, isDebugLogEnabled)\r
-\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepSDNCTopologyAct(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- /**\r
- * Log a WorkflowException that has been created.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void handleWorkflowException(Execution execution) {\r
- def method = getClass().getSimpleName() + '.handleWorkflowException(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def WorkflowException workflowException = (WorkflowException) execution.getVariable('WorkflowException')\r
- logError(method + ' caught WorkflowException: ' + workflowException.getErrorMessage())\r
-\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildWorkflowException(execution, 1002, 'Error in handleWorkflowException(): ' + e.getMessage())\r
- }\r
- }\r
-\r
- public void validateSDNCResponse(Execution execution, String response, String method){\r
- def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")\r
- def prefix = execution.getVariable("prefix")\r
-\r
- logDebug(" *** STARTED ValidateSDNCResponse Process*** ", isDebugLogEnabled)\r
-\r
- WorkflowException workflowException = execution.getVariable("WorkflowException")\r
- boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")\r
-\r
- utils.logAudit("workflowException: " + workflowException)\r
-\r
- SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)\r
- sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)\r
-\r
- utils.logAudit("SDNCResponse: " + response)\r
-\r
- String sdncResponse = response\r
- if(execution.getVariable(prefix + 'sdncResponseSuccess') == true){\r
- logDebug("Received a Good Response from SDNC Adapter for " + method + " SDNC Call. Response is: \n" + sdncResponse, isDebugLogEnabled)\r
- }else{\r
- logDebug("Received a BAD Response from SDNC Adapter for " + method + " SDNC Call.", isDebugLogEnabled)\r
- throw new BpmnError("MSOWorkflowException")\r
- }\r
- logDebug(" *** COMPLETED ValidateSDNCResponse Process*** ", isDebugLogEnabled)\r
- }\r
-\r
- /**\r
- * Using the received vnfId and vfModuleId, query AAI to get the corresponding VNF info.\r
- * A 200 response is expected with the VNF info in the response body. Will find out the base module info.\r
- *\r
- * @param execution The flow's execution instance.\r
- */\r
- public void queryAAIVfModule(Execution execution) {\r
- def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")\r
- def method = getClass().getSimpleName() + '.getVfModule(' +\r
- 'execution=' + execution.getId() +\r
- ')'\r
- logDebug('Entered ' + method, isDebugLogEnabled)\r
-\r
- try {\r
- def vnfId = execution.getVariable('DOUPVfMod_vnfId')\r
- def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')\r
-\r
- AaiUtil aaiUriUtil = new AaiUtil(this)\r
- String aai_uri = aaiUriUtil.getNetworkGenericVnfUri(execution)\r
- logDebug('AAI URI is: ' + aai_uri, isDebugLogEnabled)\r
-\r
- String endPoint = execution.getVariable("URN_aai_endpoint") + "${aai_uri}/" + UriUtils.encode(vnfId, "UTF-8") + "?depth=1"\r
- utils.logAudit("AAI endPoint: " + endPoint)\r
-\r
- try {\r
- def aaiRequestId = UUID.randomUUID().toString()\r
- logDebug('sending GET to AAI endpoint \'' + endPoint + '\'', isDebugLogEnabled)\r
- APIResponse response = aaiUriUtil.executeAAIGetCall(execution, endPoint)\r
- utils.logAudit("createVfModule - invoking httpGet() to AAI")\r
-\r
- def responseData = response.getResponseBodyAsString()\r
- if (responseData != null) {\r
- logDebug("Received generic VNF data: " + responseData, isDebugLogEnabled)\r
-\r
- }\r
-\r
- utils.logAudit("createVfModule - queryAAIVfModule Response: " + responseData)\r
- utils.logAudit("createVfModule - queryAAIVfModule ResponseCode: " + response.getStatusCode())\r
-\r
- execution.setVariable('DOUPVfMod_queryAAIVfModuleResponseCode', response.getStatusCode())\r
- execution.setVariable('DOUPVfMod_queryAAIVfModuleResponse', responseData)\r
- logDebug('Response code:' + response.getStatusCode(), isDebugLogEnabled)\r
- logDebug('Response:' + System.lineSeparator() + responseData, isDebugLogEnabled)\r
- if (response.getStatusCode() == 200) {\r
- // Parse the VNF record from A&AI to find base module info\r
- logDebug('Parsing the VNF data to find base module info', isDebugLogEnabled)\r
- if (responseData != null) {\r
- def vfModulesText = utils.getNodeXml(responseData, "vf-modules")\r
- def xmlVfModules= new XmlSlurper().parseText(vfModulesText)\r
- def vfModules = xmlVfModules.'**'.findAll {it.name() == "vf-module"}\r
- int vfModulesSize = 0\r
- for (i in 0..vfModules.size()-1) {\r
- def vfModuleXml = groovy.xml.XmlUtil.serialize(vfModules[i])\r
- def isBaseVfModule = utils.getNodeText(vfModuleXml, "is-base-vf-module")\r
-\r
- if (isBaseVfModule == "true") {\r
- String baseModuleId = utils.getNodeText1(vfModuleXml, "vf-module-id")\r
- execution.setVariable("DOUPVfMod_baseVfModuleId", baseModuleId)\r
- logDebug('Received baseVfModuleId: ' + baseModuleId, isDebugLogEnabled)\r
- String baseModuleHeatStackId = utils.getNodeText1(vfModuleXml, "heat-stack-id")\r
- execution.setVariable("DOUPVfMod_baseVfModuleHeatStackId", baseModuleHeatStackId)\r
- logDebug('Received baseVfModuleHeatStackId: ' + baseModuleHeatStackId, isDebugLogEnabled)\r
- }\r
- }\r
- }\r
- }\r
- } catch (Exception ex) {\r
- ex.printStackTrace()\r
- logDebug('Exception occurred while executing AAI GET:' + ex.getMessage(),isDebugLogEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'AAI GET Failed:' + ex.getMessage())\r
- }\r
- logDebug('Exited ' + method, isDebugLogEnabled)\r
- } catch (BpmnError e) {\r
- throw e;\r
- } catch (Exception e) {\r
- logError('Caught exception in ' + method, e)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in queryAAIVfModule(): ' + e.getMessage())\r
- }\r
- }\r
-\r
-\r
-}\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts
+
+import org.camunda.bpm.engine.delegate.BpmnError
+import org.camunda.bpm.engine.runtime.Execution
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
+import org.openecomp.mso.bpmn.common.scripts.NetworkUtils
+import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
+import org.openecomp.mso.bpmn.common.scripts.VfModule
+import org.openecomp.mso.bpmn.common.scripts.VfModuleBase
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.json.JsonUtils;
+import org.openecomp.mso.rest.APIResponse
+import org.springframework.web.util.UriUtils
+
+public class DoUpdateVfModule extends VfModuleBase {
+
+ ExceptionUtil exceptionUtil = new ExceptionUtil()
+
+ /**
+ * Initialize the flow's variables.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void initProcessVariables(Execution execution) {
+ execution.setVariable('prefix', 'DOUPVfMod_')
+ execution.setVariable('DOUPVfMod_requestInfo', null)
+ execution.setVariable('DOUPVfMod_serviceInstanceId', null)
+ execution.setVariable('DOUPVfMod_requestId', null)
+ execution.setVariable('DOUPVfMod_vnfInputs', null)
+ execution.setVariable('DOUPVfMod_vnfId', null)
+ execution.setVariable('DOUPVfMod_vnfName', null)
+ execution.setVariable('DOUPVfMod_vnfNameFromAAI', null)
+ execution.setVariable('DOUPVfMod_vfModuleName', null)
+ execution.setVariable('DOUPVfMod_vfModuleId', null)
+ execution.setVariable('DOUPVfMod_vnfType', null)
+ execution.setVariable('DOUPVfMod_asdcServiceModelVersion', null)
+ execution.setVariable('DOUPVfMod_vfModuleModelName', null)
+ execution.setVariable('DOUPVfMod_modelCustomizationUuid', null)
+ execution.setVariable("DOUPVfMod_isBaseVfModule", "false")
+ execution.setVariable('DOUPVfMod_serviceId', null)
+ execution.setVariable('DOUPVfMod_aicCloudRegion', null)
+ execution.setVariable('DOUPVfMod_tenantId', null)
+ execution.setVariable('DOUPVfMod_volumeGroupId', null)
+ execution.setVariable('DOUPVfMod_vfModule', null)
+ execution.setVariable('DOUPVfMod_vnfParams', null)
+ execution.setVariable("DOUPVfMod_baseVfModuleId", "")
+ execution.setVariable("DOUPVfMod_baseVfModuleHeatStackId", "")
+ execution.setVariable('DOUPVfMod_prepareUpdateAAIVfModuleRequest', null)
+ execution.setVariable('DOUPVfMod_sdncChangeAssignRequest', null)
+ execution.setVariable('DOUPVfMod_sdncChangeAssignResponse', null)
+ execution.setVariable('DOUPVfMod_sdncActivateRequest', null)
+ execution.setVariable('DOUPVfMod_sdncActivateResponse', null)
+ execution.setVariable('DOUPVfMod_sdncTopologyRequest', null)
+ execution.setVariable('DOUPVfMod_sdncTopologyResponse', null)
+ execution.setVariable('DOUPVfMod_vnfAdapterRestRequest', null)
+ execution.setVariable('DOUPVfMod_updateAAIGenericVnfRequest', null)
+ execution.setVariable('DOUPVfMod_updateAAIVfModuleRequest', null)
+ execution.setVariable('DOUPVfMod_skipUpdateGenericVnf', false)
+ execution.setVariable('DoUpdateVfModuleSuccessIndicator', false)
+ }
+
+ /**
+ * Check for missing elements in the received request.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void preProcessRequest(Execution execution) {
+ def method = getClass().getSimpleName() + '.preProcessRequest(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ initProcessVariables(execution)
+ def xml = getVariable(execution, 'DoUpdateVfModuleRequest')
+ utils.logAudit("DoUpdateVfModule request: " + xml)
+ logDebug('Received request xml:\n' + xml, isDebugLogEnabled)
+
+ if (xml == null || xml.isEmpty()) {
+ // Building Block-type request
+
+ String cloudConfiguration = execution.getVariable("cloudConfiguration")
+ String vfModuleModelInfo = execution.getVariable("vfModuleModelInfo")
+
+ def serviceModelInfo = execution.getVariable("serviceModelInfo")
+ logDebug("serviceModelInfo: " + serviceModelInfo, isDebugLogEnabled)
+ def vnfModelInfo = execution.getVariable("vnfModelInfo")
+
+
+ //tenantId
+ def tenantId = jsonUtil.getJsonValue(cloudConfiguration, "cloudConfiguration.tenantId")
+ execution.setVariable("DOUPVfMod_tenantId", tenantId)
+
+ //volumeGroupId
+ def volumeGroupId = execution.getVariable("volumeGroupId")
+ execution.setVariable("DOUPVfMod_volumeGroupId", volumeGroupId)
+ //volumeGroupName
+ def volumeGroupName = execution.getVariable("volumeGroupName")
+ execution.setVariable("DOUPVfMod_volumeGroupName", volumeGroupName)
+ //cloudSiteId
+ def cloudSiteId = jsonUtil.getJsonValue(cloudConfiguration, "cloudConfiguration.lcpCloudRegionId")
+ execution.setVariable("DOUPVfMod_cloudSiteId", cloudSiteId)
+
+ logDebug("cloudSiteId: " + cloudSiteId, isDebugLogEnabled)
+ //vnfType
+ def vnfType = execution.getVariable("vnfType")
+ execution.setVariable("DOUPVfMod_vnfType", vnfType)
+
+ logDebug("vnfType: " + vnfType, isDebugLogEnabled)
+ //vnfName
+ def vnfName = execution.getVariable("vnfName")
+ execution.setVariable("DOUPVfMod_vnfName", vnfName)
+
+ logDebug("vnfName: " + vnfName, isDebugLogEnabled)
+ //vnfId
+ def vnfId = execution.getVariable("vnfId")
+ execution.setVariable("DOUPVfMod_vnfId", vnfId)
+
+ logDebug("vnfId: " + vnfId, isDebugLogEnabled)
+ //vfModuleName
+ def vfModuleName = execution.getVariable("vfModuleName")
+ execution.setVariable("DOUPVfMod_vfModuleName", vfModuleName)
+
+ logDebug("vfModuleName: " + vfModuleName, isDebugLogEnabled)
+ //vfModuleModelName
+ def vfModuleModelName = jsonUtil.getJsonValue(vfModuleModelInfo, "modelName")
+ execution.setVariable("DOUPVfMod_vfModuleModelName", vfModuleModelName)
+
+ logDebug("vfModuleModelName: " + vfModuleModelName, isDebugLogEnabled)
+ //modelCustomizationUuid
+ def modelCustomizationUuid = jsonUtil.getJsonValue(vfModuleModelInfo, "modelCustomizationId")
+ execution.setVariable("DOUPVfMod_modelCustomizationUuid", modelCustomizationUuid)
+
+ logDebug("modelCustomizationUuid: " + modelCustomizationUuid, isDebugLogEnabled)
+ //vfModuleId
+ def vfModuleId = execution.getVariable("vfModuleId")
+ execution.setVariable("DOUPVfMod_vfModuleId", vfModuleId)
+ logDebug("vfModuleId: " + vfModuleId, isDebugLogEnabled)
+ def requestId = execution.getVariable("requestId")
+ execution.setVariable("DOUPVfMod_requestId", requestId)
+ logDebug("requestId: " + requestId, isDebugLogEnabled)
+ // Set mso-request-id to request-id for VNF Adapter interface
+ execution.setVariable("mso-request-id", requestId)
+ //serviceId
+ def serviceId = execution.getVariable("serviceId")
+ execution.setVariable("DOUPVfMod_serviceId", serviceId)
+ logDebug("serviceId: " + serviceId, isDebugLogEnabled)
+ //serviceInstanceId
+ def serviceInstanceId = execution.getVariable("serviceInstanceId")
+ execution.setVariable("DOUPVfMod_serviceInstanceId", serviceInstanceId)
+
+ logDebug("serviceInstanceId: " + serviceInstanceId, isDebugLogEnabled)
+ //source - HARDCODED
+ def source = "VID"
+ execution.setVariable("DOUPVfMod_source", source)
+
+ logDebug("source: " + source, isDebugLogEnabled)
+ //backoutOnFailure
+ def disableRollback = execution.getVariable("disableRollback")
+ def backoutOnFailure = true
+ if (disableRollback != null && disableRollback.equals("true")) {
+ backoutOnFailure = false
+ }
+ execution.setVariable("DOUPVfMod_backoutOnFailure", backoutOnFailure)
+ logDebug("backoutOnFailure: " + backoutOnFailure, isDebugLogEnabled)
+ //isBaseVfModule
+ def isBaseVfModule = execution.getVariable("isBaseVfModule")
+ execution.setVariable("DOUPVfMod_isBaseVfModule", isBaseVfModule)
+ logDebug("isBaseVfModule: " + isBaseVfModule, isDebugLogEnabled)
+ //asdcServiceModelVersion
+ def asdcServiceModelVersion = execution.getVariable("asdcServiceModelVersion")
+ execution.setVariable("DOUPVfMod_asdcServiceModelVersion", asdcServiceModelVersion)
+ logDebug("asdcServiceModelVersion: " + asdcServiceModelVersion, isDebugLogEnabled)
+ //personaModelId
+ execution.setVariable("DOUPVfMod_personaModelId", jsonUtil.getJsonValue(vfModuleModelInfo, "modelInvariantId"))
+ //personaModelVersion
+ execution.setVariable("DOUPVfMod_personaModelVersion", jsonUtil.getJsonValue(vfModuleModelInfo, "modelVersion"))
+ //Get or Generate UUID
+ String uuid = execution.getVariable("DOUPVfMod_uuid")
+ if(uuid == null){
+ uuid = UUID.randomUUID()
+ logDebug("Generated messageId (UUID) is: " + uuid, isDebugLogEnabled)
+ }else{
+ logDebug("Found messageId (UUID) is: " + uuid, isDebugLogEnabled)
+ }
+ //isVidRequest
+ String isVidRequest = execution.getVariable("isVidRequest")
+ // default to true
+ if (isVidRequest == null || isVidRequest.isEmpty()) {
+ execution.setVariable("isVidRequest", "true")
+ }
+ //globalSubscriberId
+ String globalSubscriberId = execution.getVariable("globalSubscriberId")
+ execution.setVariable("DOUPVfMod_globalSubscriberId", globalSubscriberId)
+ logDebug("globalSubsrciberId: " + globalSubscriberId, isDebugLogEnabled)
+ //vnfQueryPath
+ String vnfQueryPath = execution.getVariable("vnfQueryPath")
+ execution.setVariable("DOUPVfMod_vnfQueryPath", vnfQueryPath)
+ logDebug("vnfQueryPath: " + vnfQueryPath, isDebugLogEnabled)
+
+ Map<String,String> vfModuleInputParams = execution.getVariable("vfModuleInputParams")
+ if (vfModuleInputParams != null) {
+ execution.setVariable("DOUPVfMod_vnfParamsMap", vfModuleInputParams)
+ }
+ }
+ else {
+
+ def requestInfo = getRequiredNodeXml(execution, xml, 'request-info')
+ execution.setVariable('DOUPVfMod_requestInfo', requestInfo)
+ execution.setVariable('DOUPVfMod_requestId', getRequiredNodeText(execution, requestInfo, 'request-id'))
+ def serviceInstanceId = execution.getVariable('mso-service-instance-id')
+ if (serviceInstanceId == null) {
+ serviceInstanceId = ''
+ }
+ execution.setVariable('DOUPVfMod_serviceInstanceId', serviceInstanceId)
+
+ def vnfInputs = getRequiredNodeXml(execution, xml, 'vnf-inputs')
+ execution.setVariable('DOUPVfMod_vnfInputs', vnfInputs)
+ execution.setVariable('DOUPVfMod_vnfId', getRequiredNodeText(execution, vnfInputs, 'vnf-id'))
+ execution.setVariable('DOUPVfMod_vfModuleId', getRequiredNodeText(execution, vnfInputs, 'vf-module-id'))
+ execution.setVariable('DOUPVfMod_vfModuleName', getNodeTextForce(vnfInputs, 'vf-module-name'))
+ execution.setVariable('DOUPVfMod_vnfType', getNodeTextForce(vnfInputs, 'vnf-type'))
+ execution.setVariable('DOUPVfMod_vnfName', getNodeTextForce(vnfInputs, 'vnf-name'))
+ execution.setVariable('DOUPVfMod_asdcServiceModelVersion', getNodeTextForce(vnfInputs, 'asdc-service-model-version'))
+ execution.setVariable('DOUPVfMod_vfModuleModelName', getRequiredNodeText(execution, vnfInputs, 'vf-module-model-name'))
+ execution.setVariable('DOUPVfMod_modelCustomizationUuid', getNodeTextForce(vnfInputs, 'model-customization-id'))
+ execution.setVariable('DOUPVfMod_serviceId', getRequiredNodeText(execution, vnfInputs, 'service-id'))
+ execution.setVariable('DOUPVfMod_aicCloudRegion', getRequiredNodeText(execution, vnfInputs, 'aic-cloud-region'))
+ execution.setVariable('DOUPVfMod_tenantId', getRequiredNodeText(execution, vnfInputs, 'tenant-id'))
+ //isBaseVfModule
+ def isBaseVfModule = "false"
+ if (utils.nodeExists(xml, "is-base-vf-module")) {
+ isBaseVfModule = utils.getNodeText(xml, "is-base-vf-module")
+ execution.setVariable("DOUPVfMod_isBaseVfModule", isBaseVfModule)
+ }
+ logDebug("isBaseVfModule: " + isBaseVfModule, isDebugLogEnabled)
+
+ NetworkUtils networkUtils = new NetworkUtils()
+ def backoutOnFailure = networkUtils.isRollbackEnabled(execution, xml)
+ execution.setVariable("DOUPVfMod_backoutOnFailure", backoutOnFailure)
+
+ def String vgi = getNodeTextForce(vnfInputs, 'volume-group-id')
+ execution.setVariable('DOUPVfMod_volumeGroupId', vgi)
+
+ execution.setVariable('DOUPVfMod_vnfParams', utils.getNodeXml(xml, 'vnf-params', false))
+ }
+
+ def sdncCallbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')
+ if (sdncCallbackUrl == null || sdncCallbackUrl.trim().isEmpty()) {
+ def msg = 'Required variable \'URN_mso_workflow_sdncadapter_callback\' is missing'
+ logError(msg)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2000, msg)
+ }
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in preProcessRequest(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Prepare a Request for invoking the PrepareUpdateAAIVfModule subflow. This will
+ * set the orchestration-status to 'pending-update'.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepPrepareUpdateAAIVfModule(Execution execution) {
+ def method = getClass().getSimpleName() + '.preparePrepareUpdateAAIVfModule(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def vnfId = execution.getVariable('DOUPVfMod_vnfId')
+ def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')
+ def orchestrationStatus = 'pending-update'
+
+ String prepareUpdateAAIVfModuleRequest = """
+ <PrepareUpdateAAIVfModuleRequest>
+ <vnf-id>${vnfId}</vnf-id>
+ <vf-module-id>${vfModuleId}</vf-module-id>
+ <orchestration-status>${orchestrationStatus}</orchestration-status>
+ </PrepareUpdateAAIVfModuleRequest>
+ """
+ prepareUpdateAAIVfModuleRequest = utils.formatXml(prepareUpdateAAIVfModuleRequest)
+ execution.setVariable('DOUPVfMod_prepareUpdateAAIVfModuleRequest', prepareUpdateAAIVfModuleRequest)
+ utils.logAudit("DoUpdateAAIVfModule request: " + prepareUpdateAAIVfModuleRequest)
+ logDebug('Request for PrepareUpdateAAIVfModule:\n' + prepareUpdateAAIVfModuleRequest, isDebugLogEnabled)
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in preparePrepareUpdateAAIVfModule(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Prepare a Request for invoking the ConfirmVolumeGroupTenant subflow. Currently,
+ * there is really nothing to do, so we just log that we're passing through.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepConfirmVolumeGroupTenant(Execution execution) {
+ def method = getClass().getSimpleName() + '.prepConfirmVolumeGroupTenant(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ // Nothing to do - just log that we're passing through here
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepConfirmVolumeGroupTenant(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Prepare a Request for invoking the SDNC Adapter subflow to perform
+ * a VNF topology 'changeassign' operation.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepSDNCTopologyChg(Execution execution) {
+ def method = getClass().getSimpleName() + '.prepSDNCTopologyChg(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def requestId = execution.getVariable('DOUPVfMod_requestId')
+ def serviceInstanceId = execution.getVariable('DOUPVfMod_serviceInstanceId')
+ def callbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')
+ def serviceId = execution.getVariable('DOUPVfMod_serviceId')
+ def vnfId = execution.getVariable('DOUPVfMod_vnfId')
+ def vnfType = execution.getVariable('DOUPVfMod_vnfType')
+ def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')
+ def vfModuleModelName = execution.getVariable('DOUPVfMod_vfModuleModelName')
+ def VfModule vfModule = (VfModule) execution.getVariable('DOUPVfMod_vfModule')
+ def vfModuleName = vfModule.getElementText('vf-module-name')
+ def tenantId = execution.getVariable('DOUPVfMod_tenantId')
+ def aicCloudRegion = execution.getVariable('DOUPVfMod_aicCloudRegion')
+
+ // Retrieve vnf name from AAI response
+ def vnfName = execution.getVariable('DOUPVfMod_vnfNameFromAAI')
+ execution.setVariable('DOUPVfMod_vnfName', vnfName)
+
+ def vnfParamsXml = execution.getVariable('DOUPVfMod_vnfParams')
+ def vnfNetworks = transformNetworkParamsToVnfNetworks(vnfParamsXml)
+
+ String sdncTopologyRequest = """
+ <sdncadapterworkflow:SDNCAdapterWorkflowRequest
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
+ <sdncadapter:RequestHeader>
+ <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
+ <sdncadapter:SvcInstanceId>${serviceInstanceId}</sdncadapter:SvcInstanceId>
+ <sdncadapter:SvcAction>changeassign</sdncadapter:SvcAction>
+ <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>
+ <sdncadapter:CallbackUrl>${callbackUrl}</sdncadapter:CallbackUrl>
+ </sdncadapter:RequestHeader>
+ <sdncadapterworkflow:SDNCRequestData>
+ <request-information>
+ <request-id>${requestId}</request-id>
+ <request-action>ChangeVNFActivateRequest</request-action>
+ <source>PORTAL</source>
+ <notification-url/>
+ <order-number/>
+ <order-version/>
+ </request-information>
+ <service-information>
+ <service-type>${serviceId}</service-type>
+ <service-instance-id>${vnfId}</service-instance-id>
+ <subscriber-name>dontcare</subscriber-name>
+ </service-information>
+ <vnf-request-information>
+ <vnf-id>${vfModuleId}</vnf-id>
+ <vnf-type>${vfModuleModelName}</vnf-type>
+ <vnf-name>${vfModuleName}</vnf-name>
+ <generic-vnf-id>${vnfId}</generic-vnf-id>
+ <generic-vnf-name>${vnfName}</generic-vnf-name>
+ <generic-vnf-type>${vnfType}</generic-vnf-type>
+ <tenant>${tenantId}</tenant>
+ <aic-cloud-region>${aicCloudRegion}</aic-cloud-region>
+ ${vnfNetworks}
+ </vnf-request-information>
+ </sdncadapterworkflow:SDNCRequestData>
+ </sdncadapterworkflow:SDNCAdapterWorkflowRequest>
+ """
+ sdncTopologyRequest = utils.formatXml(sdncTopologyRequest)
+ execution.setVariable('DOUPVfMod_sdncChangeAssignRequest', sdncTopologyRequest)
+ utils.logAudit("sdncChangeAssignRequest : " + sdncTopologyRequest)
+ logDebug('Request for SDNCAdapter topology/changeassign:\n' + sdncTopologyRequest, isDebugLogEnabled)
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepSDNCTopologyChg(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Prepare a Request for invoking the SDNC Adapter subflow to perform
+ * a VNF topology 'query' operation.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepSDNCTopologyQuery(Execution execution) {
+ def method = getClass().getSimpleName() + '.prepSDNCTopologyQuery(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def requestId = execution.getVariable('DOUPVfMod_requestId')
+ def serviceInstanceId = execution.getVariable('DOUPVfMod_serviceInstanceId')
+ def callbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')
+ def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')
+
+ def svcInstId = ""
+ if (serviceInstanceId == null || serviceInstanceId.isEmpty()) {
+ svcInstId = vfModuleId
+ }
+ else {
+ svcInstId = serviceInstanceId
+ }
+
+ //!!!! TEMPORARY WORKAROUND FOR SDNC REPLICATION ISSUE
+ sleep(5000)
+
+ String sdncTopologyRequest = """
+ <sdncadapterworkflow:SDNCAdapterWorkflowRequest
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
+ <sdncadapter:RequestHeader>
+ <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
+ <sdncadapter:SvcInstanceId>${svcInstId}</sdncadapter:SvcInstanceId>
+ <sdncadapter:SvcAction>query</sdncadapter:SvcAction>
+ <sdncadapter:SvcOperation>/VNF-API:vnfs/vnf-list/${vfModuleId}</sdncadapter:SvcOperation>
+ <sdncadapter:CallbackUrl>${callbackUrl}</sdncadapter:CallbackUrl>
+ <sdncadapter:MsoAction>mobility</sdncadapter:MsoAction>
+ </sdncadapter:RequestHeader>
+ </sdncadapterworkflow:SDNCAdapterWorkflowRequest>
+ """
+ sdncTopologyRequest = utils.formatXml(sdncTopologyRequest)
+ execution.setVariable('DOUPVfMod_sdncTopologyRequest', sdncTopologyRequest)
+ utils.logAudit("sdncTopologyRequest : " + sdncTopologyRequest)
+ logDebug('Request for SDNCAdapter query:\n' + sdncTopologyRequest, isDebugLogEnabled)
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepSDNCTopologyQuery(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Prepare a Request for invoking the VnfAdapterRest subflow.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepVnfAdapterRest(Execution execution) {
+ def method = getClass().getSimpleName() + '.prepVnfAdapterRest(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def requestId = execution.getVariable('DOUPVfMod_requestId')
+ def serviceInstanceId = execution.getVariable('DOUPVfMod_serviceInstanceId')
+ def vnfId = execution.getVariable('DOUPVfMod_vnfId')
+ def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')
+ def vfModuleName = execution.getVariable('DOUPVfMod_vfModuleName')
+ def vnfInputs = execution.getVariable('DOUPVfMod_vnfInputs')
+ def tenantId = execution.getVariable('DOUPVfMod_tenantId')
+ def volumeGroupId = execution.getVariable('DOUPVfMod_volumeGroupId')
+ def VfModule vfModule = (VfModule) execution.getVariable('DOUPVfMod_vfModule')
+ def heatStackId = vfModule.getElementText('heat-stack-id')
+ def cloudId = execution.getVariable('DOUPVfMod_aicCloudRegion')
+ def vnfType = execution.getVariable('DOUPVfMod_vnfType')
+ def vnfName = execution.getVariable('DOUPVfMod_vnfName')
+ def vfModuleModelName = execution.getVariable('DOUPVfMod_vfModuleModelName')
+ def baseVfModuleId = execution.getVariable("DOUPVfMod_baseVfModuleId")
+ def baseVfModuleStackId = execution.getVariable("DOUPVfMod_baseVfModuleHeatStackId")
+ def asdcServiceModelVersion = execution.getVariable('DOUPVfMod_asdcServiceModelVersion')
+ def modelCustomizationUuid = execution.getVariable('DOUPVfMod_modelCustomizationUuid')
+ def backoutOnFailure = execution.getVariable("DOUPVfMod_backoutOnFailure")
+
+ def messageId = execution.getVariable('mso-request-id') + '-' + System.currentTimeMillis()
+ def notificationUrl = createCallbackURL(execution, "VNFAResponse", messageId)
+ def useQualifiedHostName = execution.getVariable("URN_mso_use_qualified_host")
+ if ('true'.equals(useQualifiedHostName)) {
+ notificationUrl = utils.getQualifiedHostNameForCallback(notificationUrl)
+ }
+
+ Map<String, String> vnfParamsMap = execution.getVariable("DOUPVfMod_vnfParamsMap")
+
+ String sdncGetResponse = execution.getVariable('DOUPVfMod_sdncTopologyResponse')
+
+ String vfModuleParams = buildVfModuleParams(vnfParamsMap, sdncGetResponse, vnfId, vnfName,
+ vfModuleId, vfModuleName, null)
+
+
+ String vnfAdapterRestRequest = """
+ <updateVfModuleRequest>
+ <cloudSiteId>${cloudId}</cloudSiteId>
+ <tenantId>${tenantId}</tenantId>
+ <vnfId>${vnfId}</vnfId>
+ <vfModuleId>${vfModuleId}</vfModuleId>
+ <vfModuleStackId>${heatStackId}</vfModuleStackId>
+ <vnfType>${vnfType}</vnfType>
+ <vnfVersion>${asdcServiceModelVersion}</vnfVersion>
+ <modelCustomizationUuid>${modelCustomizationUuid}</modelCustomizationUuid>
+ <vfModuleType>${vfModuleModelName}</vfModuleType>
+ <volumeGroupId>${volumeGroupId}</volumeGroupId>
+ <baseVfModuleId>${baseVfModuleId}</baseVfModuleId>
+ <baseVfModuleStackId>${baseVfModuleStackId}</baseVfModuleStackId>
+ <skipAAI>true</skipAAI>
+ <backout>${backoutOnFailure}</backout>
+ <failIfExists>false</failIfExists>
+ <vfModuleParams>
+ ${vfModuleParams}
+ </vfModuleParams>
+ <msoRequest>
+ <requestId>${requestId}</requestId>
+ <serviceInstanceId>${serviceInstanceId}</serviceInstanceId>
+ </msoRequest>
+ <messageId>${messageId}</messageId>
+ <notificationUrl>${notificationUrl}</notificationUrl>
+ </updateVfModuleRequest>
+ """
+ vnfAdapterRestRequest = utils.formatXml(vnfAdapterRestRequest)
+ execution.setVariable('DOUPVfMod_vnfAdapterRestRequest', vnfAdapterRestRequest)
+ utils.logAudit("vnfAdapterRestRequest : " + vnfAdapterRestRequest)
+ logDebug('Request for VNFAdapter Rest:\n' + vnfAdapterRestRequest, isDebugLogEnabled)
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepVnfAdapterRest(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Prepare a Request for invoking the UpdateAAIGenericVnf subflow.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepUpdateAAIGenericVnf(Execution execution) {
+ def method = getClass().getSimpleName() + '.prepUpdateAAIGenericVnf(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def vnfId = execution.getVariable('DOUPVfMod_vnfId')
+ def vnfInputs = execution.getVariable('DOUPVfMod_vnfInputs')
+
+ def personaModelId = utils.getNodeText1(vnfInputs, 'vnf-persona-model-id')
+ def personaModelVersion = utils.getNodeText1(vnfInputs, 'vnf-persona-model-version')
+ if ((personaModelId == null) || (personaModelVersion == null)) {
+ logDebug('Skipping update for Generic VNF ' + vnfId +
+ ' because either \'vnf-persona-model-id\' or \'vnf-persona-model-version\' is absent', isDebugLogEnabled)
+ execution.setVariable('DOUPVfMod_skipUpdateGenericVnf', true)
+ } else {
+ def personaModelIdElement = '<model-invariant-id>' + personaModelId + '</model-invariant-id>'
+ def personaModelVersionElement = '<model-version-id>' + personaModelVersion + '</model-version-id>'
+
+ String updateAAIGenericVnfRequest = """
+ <UpdateAAIGenericVnfRequest>
+ <vnf-id>${vnfId}</vnf-id>
+ ${personaModelIdElement}
+ ${personaModelVersionElement}
+ </UpdateAAIGenericVnfRequest>
+ """
+ updateAAIGenericVnfRequest = utils.formatXml(updateAAIGenericVnfRequest)
+ execution.setVariable('DOUPVfMod_updateAAIGenericVnfRequest', updateAAIGenericVnfRequest)
+ utils.logAudit("updateAAIGenericVnfRequest : " + updateAAIGenericVnfRequest)
+ logDebug('Request for UpdateAAIGenericVnf:\n' + updateAAIGenericVnfRequest, isDebugLogEnabled)
+ }
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepUpdateAAIGenericVnf(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Prepare a Request for invoking the UpdateAAIVfModule subflow.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepUpdateAAIVfModule(Execution execution) {
+ def method = getClass().getSimpleName() + '.prepUpdateAAIVfModule(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def vnfId = execution.getVariable('DOUPVfMod_vnfId')
+ def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')
+ def orchestrationStatus = 'updated'
+ def vnfInputs = execution.getVariable('DOUPVfMod_vnfInputs')
+
+ def volumeGroupIdElement = ''
+ def volumeGroupId = execution.getVariable('DOUPVfMod_volumeGroupId')
+ if (volumeGroupId != null) {
+ volumeGroupIdElement = '<volume-group-id>' + volumeGroupId + '</volume-group-id>'
+ }
+ def personaModelIdElement = ''
+ def personaModelId = utils.getNodeText1(vnfInputs, 'persona-model-id')
+ if (personaModelId != null) {
+ personaModelIdElement = '<model-invariant-id>' + personaModelId + '</model-invariant-id>'
+ }
+ def personaModelVersionElement = ''
+ def personaModelVersion = utils.getNodeText1(vnfInputs, 'persona-model-version')
+ if (personaModelVersion != null) {
+ personaModelVersionElement = '<model-version-id>' + personaModelVersion + '</model-version-id>'
+ }
+ def contrailServiceInstanceFqdnElement = ''
+ def contrailServiceInstanceFqdn = utils.getNodeText1(vnfInputs, 'contrail-service-instance-fqdn')
+ if (contrailServiceInstanceFqdn != null) {
+ contrailServiceInstanceFqdnElement = '<contrail-service-instance-fqdn>' + contrailServiceInstanceFqdn + '</contrail-service-instance-fqdn>'
+ }
+ def personaModelCustomizationIdElement = ''
+ def modelCustomizationId = execution.getVariable('DOUPVfMod_modelCustomizationUuid')
+ if (modelCustomizationId != null) {
+ personaModelCustomizationIdElement = '<persona-model-customization-id>' + modelCustomizationId + '</persona-model-customization-id>'
+ }
+
+ String updateAAIVfModuleRequest = """
+ <UpdateAAIVfModuleRequest>
+ <vnf-id>${vnfId}</vnf-id>
+ <vf-module-id>${vfModuleId}</vf-module-id>
+ <orchestration-status>${orchestrationStatus}</orchestration-status>
+ ${volumeGroupIdElement}
+ ${personaModelIdElement}
+ ${personaModelVersionElement}
+ ${contrailServiceInstanceFqdnElement}
+ ${personaModelCustomizationIdElement}
+ </UpdateAAIVfModuleRequest>
+ """
+
+ logDebug('Unformatted updateAAIVfModuleRequest: ' + updateAAIVfModuleRequest, isDebugLogEnabled)
+ updateAAIVfModuleRequest = utils.formatXml(updateAAIVfModuleRequest)
+ execution.setVariable('DOUPVfMod_updateAAIVfModuleRequest', updateAAIVfModuleRequest)
+ utils.logAudit("updateAAIVfModuleRequest : " + updateAAIVfModuleRequest)
+ logDebug('Request for UpdateAAIVfModule:\n' + updateAAIVfModuleRequest, isDebugLogEnabled)
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepUpdateAAIVfModule(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Prepare a Request for invoking the SDNC Adapter subflow to perform
+ * a VNF topology 'activate' operation.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void prepSDNCTopologyAct(Execution execution) {
+ def method = getClass().getSimpleName() + '.prepSDNCTopologyAct(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def requestId = execution.getVariable('DOUPVfMod_requestId')
+ def serviceInstanceId = execution.getVariable('DOUPVfMod_serviceInstanceId')
+ def callbackUrl = (String) execution.getVariable('URN_mso_workflow_sdncadapter_callback')
+ def serviceId = execution.getVariable('DOUPVfMod_serviceId')
+ def vnfId = execution.getVariable('DOUPVfMod_vnfId')
+ def vnfName = execution.getVariable('DOUPVfMod_vnfName')
+ def vnfType = execution.getVariable('DOUPVfMod_vnfType')
+ def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')
+ def vfModuleModelName = execution.getVariable('DOUPVfMod_vfModuleModelName')
+ def VfModule vfModule = (VfModule) execution.getVariable('DOUPVfMod_vfModule')
+ def vfModuleName = vfModule.getElementText('vf-module-name')
+ def tenantId = execution.getVariable('DOUPVfMod_tenantId')
+ def aicCloudRegion = execution.getVariable('DOUPVfMod_aicCloudRegion')
+
+ def vnfParamsXml = execution.getVariable('DOUPVfMod_vnfParams')
+ def vnfNetworks = transformNetworkParamsToVnfNetworks(vnfParamsXml)
+
+ String sdncTopologyRequest = """
+ <sdncadapterworkflow:SDNCAdapterWorkflowRequest
+ xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:sdncadapter="http://org.openecomp/workflow/sdnc/adapter/schema/v1">
+ <sdncadapter:RequestHeader>
+ <sdncadapter:RequestId>${requestId}</sdncadapter:RequestId>
+ <sdncadapter:SvcInstanceId>${serviceInstanceId}</sdncadapter:SvcInstanceId>
+ <sdncadapter:SvcAction>activate</sdncadapter:SvcAction>
+ <sdncadapter:SvcOperation>vnf-topology-operation</sdncadapter:SvcOperation>
+ <sdncadapter:CallbackUrl>${callbackUrl}</sdncadapter:CallbackUrl>
+ </sdncadapter:RequestHeader>
+ <sdncadapterworkflow:SDNCRequestData>
+ <request-information>
+ <request-id>${requestId}</request-id>
+ <request-action>ChangeVNFActivateRequest</request-action>
+ <source>PORTAL</source>
+ <notification-url/>
+ <order-number/>
+ <order-version/>
+ </request-information>
+ <service-information>
+ <service-type>${serviceId}</service-type>
+ <service-instance-id>${vnfId}</service-instance-id>
+ <subscriber-name>dontcare</subscriber-name>
+ </service-information>
+ <vnf-request-information>
+ <vnf-id>${vfModuleId}</vnf-id>
+ <vnf-type>${vfModuleModelName}</vnf-type>
+ <vnf-name>${vfModuleName}</vnf-name>
+ <generic-vnf-id>${vnfId}</generic-vnf-id>
+ <generic-vnf-name>${vnfName}</generic-vnf-name>
+ <generic-vnf-type>${vnfType}</generic-vnf-type>
+ <tenant>${tenantId}</tenant>
+ <aic-cloud-region>${aicCloudRegion}</aic-cloud-region>
+ </vnf-request-information>
+ </sdncadapterworkflow:SDNCRequestData>
+ </sdncadapterworkflow:SDNCAdapterWorkflowRequest>
+ """
+ sdncTopologyRequest = utils.formatXml(sdncTopologyRequest)
+ execution.setVariable('DOUPVfMod_sdncActivateRequest', sdncTopologyRequest)
+ utils.logAudit("sdncActivateRequest : " + sdncTopologyRequest)
+ logDebug('Request for SDNCAdapter topology/activate:\n' + sdncTopologyRequest, isDebugLogEnabled)
+
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in prepSDNCTopologyAct(): ' + e.getMessage())
+ }
+ }
+
+ /**
+ * Log a WorkflowException that has been created.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void handleWorkflowException(Execution execution) {
+ def method = getClass().getSimpleName() + '.handleWorkflowException(' +
+ 'execution=' + execution.getId() +
+ ')'
+ def isDebugLogEnabled = execution.getVariable('isDebugLogEnabled')
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def WorkflowException workflowException = (WorkflowException) execution.getVariable('WorkflowException')
+ logError(method + ' caught WorkflowException: ' + workflowException.getErrorMessage())
+
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildWorkflowException(execution, 1002, 'Error in handleWorkflowException(): ' + e.getMessage())
+ }
+ }
+
+ public void validateSDNCResponse(Execution execution, String response, String method){
+ def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")
+ def prefix = execution.getVariable("prefix")
+
+ logDebug(" *** STARTED ValidateSDNCResponse Process*** ", isDebugLogEnabled)
+
+ WorkflowException workflowException = execution.getVariable("WorkflowException")
+ boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")
+
+ utils.logAudit("workflowException: " + workflowException)
+
+ SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)
+ sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)
+
+ utils.logAudit("SDNCResponse: " + response)
+
+ String sdncResponse = response
+ if(execution.getVariable(prefix + 'sdncResponseSuccess') == true){
+ logDebug("Received a Good Response from SDNC Adapter for " + method + " SDNC Call. Response is: \n" + sdncResponse, isDebugLogEnabled)
+ }else{
+ logDebug("Received a BAD Response from SDNC Adapter for " + method + " SDNC Call.", isDebugLogEnabled)
+ throw new BpmnError("MSOWorkflowException")
+ }
+ logDebug(" *** COMPLETED ValidateSDNCResponse Process*** ", isDebugLogEnabled)
+ }
+
+ /**
+ * Using the received vnfId and vfModuleId, query AAI to get the corresponding VNF info.
+ * A 200 response is expected with the VNF info in the response body. Will find out the base module info.
+ *
+ * @param execution The flow's execution instance.
+ */
+ public void queryAAIVfModule(Execution execution) {
+ def isDebugLogEnabled=execution.getVariable("isDebugLogEnabled")
+ def method = getClass().getSimpleName() + '.getVfModule(' +
+ 'execution=' + execution.getId() +
+ ')'
+ logDebug('Entered ' + method, isDebugLogEnabled)
+
+ try {
+ def vnfId = execution.getVariable('DOUPVfMod_vnfId')
+ def vfModuleId = execution.getVariable('DOUPVfMod_vfModuleId')
+
+ AaiUtil aaiUriUtil = new AaiUtil(this)
+ String aai_uri = aaiUriUtil.getNetworkGenericVnfUri(execution)
+ logDebug('AAI URI is: ' + aai_uri, isDebugLogEnabled)
+
+ String endPoint = execution.getVariable("URN_aai_endpoint") + "${aai_uri}/" + UriUtils.encode(vnfId, "UTF-8") + "?depth=1"
+ utils.logAudit("AAI endPoint: " + endPoint)
+
+ try {
+ def aaiRequestId = UUID.randomUUID().toString()
+ logDebug('sending GET to AAI endpoint \'' + endPoint + '\'', isDebugLogEnabled)
+ APIResponse response = aaiUriUtil.executeAAIGetCall(execution, endPoint)
+ utils.logAudit("createVfModule - invoking httpGet() to AAI")
+
+ def responseData = response.getResponseBodyAsString()
+ if (responseData != null) {
+ logDebug("Received generic VNF data: " + responseData, isDebugLogEnabled)
+
+ }
+
+ utils.logAudit("createVfModule - queryAAIVfModule Response: " + responseData)
+ utils.logAudit("createVfModule - queryAAIVfModule ResponseCode: " + response.getStatusCode())
+
+ execution.setVariable('DOUPVfMod_queryAAIVfModuleResponseCode', response.getStatusCode())
+ execution.setVariable('DOUPVfMod_queryAAIVfModuleResponse', responseData)
+ logDebug('Response code:' + response.getStatusCode(), isDebugLogEnabled)
+ logDebug('Response:' + System.lineSeparator() + responseData, isDebugLogEnabled)
+ if (response.getStatusCode() == 200) {
+ // Parse the VNF record from A&AI to find base module info
+ logDebug('Parsing the VNF data to find base module info', isDebugLogEnabled)
+ if (responseData != null) {
+ def vfModulesText = utils.getNodeXml(responseData, "vf-modules")
+ def xmlVfModules= new XmlSlurper().parseText(vfModulesText)
+ def vfModules = xmlVfModules.'**'.findAll {it.name() == "vf-module"}
+ int vfModulesSize = 0
+ for (i in 0..vfModules.size()-1) {
+ def vfModuleXml = groovy.xml.XmlUtil.serialize(vfModules[i])
+ def isBaseVfModule = utils.getNodeText(vfModuleXml, "is-base-vf-module")
+
+ if (isBaseVfModule == "true") {
+ String baseModuleId = utils.getNodeText1(vfModuleXml, "vf-module-id")
+ execution.setVariable("DOUPVfMod_baseVfModuleId", baseModuleId)
+ logDebug('Received baseVfModuleId: ' + baseModuleId, isDebugLogEnabled)
+ String baseModuleHeatStackId = utils.getNodeText1(vfModuleXml, "heat-stack-id")
+ execution.setVariable("DOUPVfMod_baseVfModuleHeatStackId", baseModuleHeatStackId)
+ logDebug('Received baseVfModuleHeatStackId: ' + baseModuleHeatStackId, isDebugLogEnabled)
+ }
+ }
+ }
+ }
+ } catch (Exception ex) {
+ ex.printStackTrace()
+ logDebug('Exception occurred while executing AAI GET:' + ex.getMessage(),isDebugLogEnabled)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'AAI GET Failed:' + ex.getMessage())
+ }
+ logDebug('Exited ' + method, isDebugLogEnabled)
+ } catch (BpmnError e) {
+ throw e;
+ } catch (Exception e) {
+ logError('Caught exception in ' + method, e)
+ exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in queryAAIVfModule(): ' + e.getMessage())
+ }
+ }
+
+
+}
+++ /dev/null
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- * \r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-
-import groovy.xml.XmlUtil
-import groovy.json.*
-
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil;\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor;\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil;\r
-import org.openecomp.mso.bpmn.common.scripts.NetworkUtils;\r
-import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils;\r
-import org.openecomp.mso.bpmn.common.scripts.VidUtils;\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils;\r
-import org.openecomp.mso.rest.APIResponse\r
-
-import java.util.UUID;
-
-import org.camunda.bpm.engine.delegate.BpmnError
-import org.camunda.bpm.engine.runtime.Execution
-import org.apache.commons.lang3.*
-import org.apache.commons.codec.binary.Base64;
-import org.springframework.web.util.UriUtils
-
-/**
- * This groovy class supports the <class>UpdateNetworkInstanceInfra.bpmn</class> process.
- */
-public class UpdateNetworkInstanceInfra extends AbstractServiceTaskProcessor {
- String Prefix="UPDNETI_"
- ExceptionUtil exceptionUtil = new ExceptionUtil()
- JsonUtils jsonUtil = new JsonUtils()
- VidUtils vidUtils = new VidUtils(this)
- NetworkUtils networkUtils = new NetworkUtils()
- SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils()
-
- /**
- * This method is executed during the preProcessRequest task of the <class>UpdateNetworkInstanceInfra.bpmn</class> process.
- * @param execution
- */
- public InitializeProcessVariables(Execution execution){
- /* Initialize all the process variables in this block */
-
- execution.setVariable("UPDNETI_messageId", "")
- execution.setVariable("BasicAuthHeaderValuePO", "")
- execution.setVariable("BasicAuthHeaderValueSDNC", "")
- execution.setVariable("UPDNETI_UpdateNetworkInstanceInfraJsonRequest", "")
- execution.setVariable("UPDNETI_networkRequest", "")
- execution.setVariable("UPDNETI_networkInputs", "")
- execution.setVariable("UPDNETI_networkOutputs", "")
- execution.setVariable("UPDNETI_requestId", "")
- execution.setVariable("UPDNETI_source", "")
- execution.setVariable("UPDNETI_networkId", "")
-
- execution.setVariable("UPDNETI_CompleteMsoProcessRequest", "")
- execution.setVariable("UPDNETI_FalloutHandlerRequest", "")
- execution.setVariable("UPDNETI_isSilentSuccess", false)
- execution.setVariable("UPDNETI_isPONR", false) // Point-of-no-return, means, rollback is not needed
-
- // AAI query Cloud Region
- execution.setVariable("UPDNETI_queryCloudRegionRequest","")
- execution.setVariable("UPDNETI_queryCloudRegionReturnCode","")
- execution.setVariable("UPDNETI_queryCloudRegionResponse","")
- execution.setVariable("UPDNETI_cloudRegionPo","")
- execution.setVariable("UPDNETI_cloudRegionSdnc","")
- execution.setVariable("UPDNETI_isCloudRegionGood", false)
-
- // AAI query Id
- execution.setVariable("UPDNETI_queryIdAAIRequest","")
- execution.setVariable("UPDNETI_queryIdAAIResponse", "")
- execution.setVariable("UPDNETI_aaiIdReturnCode", "")
-
- // AAI query vpn binding
- execution.setVariable("UPDNETI_queryVpnBindingAAIRequest","")
- execution.setVariable("UPDNETI_queryVpnBindingAAIResponse", "")
- execution.setVariable("UPDNETI_aaiQqueryVpnBindingReturnCode", "")
- execution.setVariable("UPDNETI_vpnBindings", null)
- execution.setVariable("UPDNETI_vpnCount", 0)
- execution.setVariable("UPDNETI_routeCollection", "")
-
- // AAI query network policy
- execution.setVariable("UPDNETI_queryNetworkPolicyAAIRequest","")
- execution.setVariable("UPDNETI_queryNetworkPolicyAAIResponse", "")
- execution.setVariable("UPDNETI_aaiQqueryNetworkPolicyReturnCode", "")
- execution.setVariable("UPDNETI_networkPolicyUriList", null)
- execution.setVariable("UPDNETI_networkPolicyCount", 0)
- execution.setVariable("UPDNETI_networkCollection", "")
-
- // AAI query route table reference
- execution.setVariable("UPDNETI_queryNetworkTableRefAAIRequest","")
- execution.setVariable("UPDNETI_queryNetworkTableRefAAIResponse", "")
- execution.setVariable("UPDNETI_aaiQqueryNetworkTableRefReturnCode", "")
- execution.setVariable("UPDNETI_networkTableRefUriList", null)
- execution.setVariable("UPDNETI_networkTableRefCount", 0)
- execution.setVariable("UPDNETI_tableRefCollection", "")
-
- // AAI requery Id
- execution.setVariable("UPDNETI_requeryIdAAIRequest","")
- execution.setVariable("UPDNETI_requeryIdAAIResponse", "")
- execution.setVariable("UPDNETI_aaiRequeryIdReturnCode", "")
-
- // AAI update contrail
- execution.setVariable("UPDNETI_updateContrailAAIUrlRequest","")
- execution.setVariable("UPDNETI_updateContrailAAIPayloadRequest","")
- execution.setVariable("UPDNETI_updateContrailAAIResponse", "")
- execution.setVariable("UPDNETI_aaiUpdateContrailReturnCode", "")
-
- execution.setVariable("UPDNETI_updateNetworkRequest", "")
- execution.setVariable("UPDNETI_updateNetworkResponse", "")
- execution.setVariable("UPDNETI_rollbackNetworkRequest", "")
- execution.setVariable("UPDNETI_rollbackNetworkResponse", "")
- execution.setVariable("UPDNETI_networkReturnCode", "")
- execution.setVariable("UPDNETI_rollbackNetworkReturnCode", "")
- execution.setVariable("UPDNETI_isNetworkRollbackNeeded", false)
-
- execution.setVariable("UPDNETI_changeAssignSDNCRequest", "")
- execution.setVariable("UPDNETI_changeAssignSDNCResponse", "")
- execution.setVariable("UPDNETI_rollbackSDNCRequest", "")
- execution.setVariable("UPDNETI_rollbackSDNCResponse", "")
- execution.setVariable("UPDNETI_sdncReturnCode", "")
- execution.setVariable("UPDNETI_rollbackSDNCReturnCode", "")
- execution.setVariable("UPDNETI_isSdncRollbackNeeded", false)
- execution.setVariable("UPDNETI_sdncResponseSuccess", false)
-
- execution.setVariable("UPDNETI_updateDBRequest", "")
- execution.setVariable("UPDNETI_updateDBResponse", "")
- execution.setVariable("UPDNETI_dbReturnCode", "")
-
- execution.setVariable("UPDNETI_isVnfBindingPresent", false)
- execution.setVariable("UPDNETI_Success", false)
- execution.setVariable("UPDNETI_serviceInstanceId", "")
- execution.setVariable("GENGS_type", "service-instance") // Setting for Generic Sub Flow use
-
- }
-
- // **************************************************
- // Pre or Prepare Request Section
- // **************************************************
- /**
- * This method is executed during the preProcessRequest task of the <class>UpdateNetworkInstanceInfra.bpmn</class> process.
- * @param execution
- */
- public void preProcessRequest (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix",Prefix)
-
- utils.log("DEBUG", " ***** Inside preProcessRequest UpdateNetworkInstanceInfra Request ***** ", isDebugEnabled)
-
- // initialize flow variables
- InitializeProcessVariables(execution)
-
- // get Incoming request & validate json format
- String updateNetworkJsonIncoming = execution.getVariable("bpmnRequest")
- utils.logAudit(updateNetworkJsonIncoming)
- try {
- def prettyJson = JsonOutput.prettyPrint(updateNetworkJsonIncoming.toString())
- utils.log("DEBUG", " Incoming message formatted . . . : " + '\n' + prettyJson, isDebugEnabled)
-
- } catch (Exception ex) {
- String dataErrorMessage = " Invalid json format Request - " + ex.getMessage()
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
- }
-
- // PO Authorization Info / headers Authorization=
- String basicAuthValuePO = execution.getVariable("URN_mso_adapters_po_auth")
- utils.log("DEBUG", " Obtained BasicAuth userid password for PO/SDNC adapter: " + basicAuthValuePO, isDebugEnabled)
- try {
- def encodedString = utils.getBasicAuth(basicAuthValuePO, execution.getVariable("URN_mso_msoKey"))
- execution.setVariable("BasicAuthHeaderValuePO",encodedString)
- execution.setVariable("BasicAuthHeaderValueSDNC", encodedString)
-
- } catch (IOException ex) {
- String dataErrorMessage = " Unable to encode PO/SDNC user/password string - " + ex.getMessage()
- utils.log("DEBUG", dataErrorMessage, , isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
- }
-
- try {
- // Catalog DB headers Authorization\r
- String basicAuthValueDB = execution.getVariable("URN_mso_adapters_db_auth")\r
- utils.log("DEBUG", " Obtained BasicAuth userid password for Catalog DB adapter: " + basicAuthValueDB, isDebugEnabled)\r
- \r
- def encodedString = utils.getBasicAuth(basicAuthValueDB, execution.getVariable("URN_mso_msoKey"))\r
- execution.setVariable("BasicAuthHeaderValueDB",encodedString)\r
- } catch (IOException ex) {\r
- String dataErrorMessage = " Unable to encode Catalog DB user/password string - " + ex.getMessage()\r
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)\r
- }\r
- \r
- try {\r
-
- execution.setVariable("UPDNETI_UpdateNetworkInstanceInfraJsonRequest", updateNetworkJsonIncoming)
-
- // recreate the xml network-request
- String networkRequest = vidUtils.createXmlNetworkRequestInfra(execution, updateNetworkJsonIncoming)
- execution.setVariable("UPDNETI_networkRequest", networkRequest)
- utils.log("DEBUG", " network-request - " + '\n' + networkRequest, isDebugEnabled)
-
- String networkInputs = utils.getNodeXml(networkRequest, "network-inputs", false).replace("tag0:","").replace(":tag0","")
- execution.setVariable("UPDNETI_networkInputs", networkInputs)
- utils.log("DEBUG", " networkInputs - " + '\n' + networkInputs, isDebugEnabled)
-
- String netId = utils.getNodeText1(networkRequest, "network-id")
- String netName = utils.getNodeText1(networkRequest, "network-name")
- String networkOutputs =
- """<network-outputs>
- <network-id>${netId}</network-id>
- <network-name>${netName}</network-name>
- </network-outputs>"""
- execution.setVariable("UPDNETI_networkOutputs", networkOutputs)
- utils.log("DEBUG", " networkOutputs - " + '\n' + networkOutputs, isDebugEnabled)
-
- String requestId = execution.getVariable("mso-request-id")\r
- if (requestId == null || requestId == "") {
- requestId = execution.getVariable("requestId")
- }
- execution.setVariable("UPDNETI_requestId", requestId)
- execution.setVariable("UPDNETI_source", utils.getNodeText1(networkRequest, "source"))
-
- // prepare messageId
- String messageId = execution.getVariable("UPDNETI_messageId") // for testing
- if (messageId == null || messageId == "") {
- messageId = UUID.randomUUID()
- utils.log("DEBUG", " UPDNETI_messageId, random generated: " + messageId, isDebugEnabled)
- } else {
- utils.log("DEBUG", " UPDNETI_messageId, pre-assigned: " + messageId, isDebugEnabled)
- }
- execution.setVariable("UPDNETI_messageId", messageId)
-
- // validate 'backout-on-failure' to override 'URN_mso_rollback'
- boolean rollbackEnabled = networkUtils.isRollbackEnabled(execution, networkRequest)
- execution.setVariable("UPDNETI_rollbackEnabled", rollbackEnabled)
-
- String networkId = ""
- if (utils.nodeExists(networkRequest, "network-id")) {
- networkId = utils.getNodeText1(networkRequest, "network-id")
- if (networkId == 'null' || networkId == "") {
- sendSyncError(execution)
- // missing value of networkId
- String dataErrorMessage = "Variable 'network-id' value/element is missing."
- utils.log("DEBUG", " Invalid Request - " + dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- }
- }
-
- String lcpCloudRegion = ""
- if (utils.nodeExists(networkRequest, "aic-cloud-region")) {
- lcpCloudRegion = utils.getNodeText1(networkRequest, "aic-cloud-region")
- if ((lcpCloudRegion == 'null') || (lcpCloudRegion == "")) {
- sendSyncError(execution)
- String dataErrorMessage = "requestDetails has missing 'aic-cloud-region' value/element."
- utils.log("DEBUG", " Invalid Request - " + dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
- }
- }
-
- String serviceInstanceId = ""
- if (utils.nodeExists(networkRequest, "service-instance-id")) {
- serviceInstanceId = utils.getNodeText1(networkRequest, "service-instance-id")
- if ((serviceInstanceId == 'null') || (lcpCloudRegion == "")) {
- sendSyncError(execution)
- String dataErrorMessage = "Variable 'serviceInstanceId' value/element is missing."
- utils.log("DEBUG", " Invalid Request - " + dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
- }
- }
-
- execution.setVariable("UPDNETI_serviceInstanceId", serviceInstanceId)
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex){
- sendSyncError(execution)
- // caught exception
- String exceptionMessage = "Exception Encountered in UpdateNetworkInstanceInfra, PreProcessRequest() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
- }
-
- public void sendSyncResponse (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix",Prefix)
-
- utils.log("DEBUG", " ***** Inside sendSyncResponse of UpdateNetworkInstanceInfra ***** ", isDebugEnabled)
-
- try {
- String serviceInstanceId = execution.getVariable("UPDNETI_serviceInstanceId")
- String requestId = execution.getVariable("mso-request-id")\r
-
- // RESTResponse (for API Handler (APIH) Reply Task)
- String updateNetworkRestRequest = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim()
-
- utils.log("DEBUG", " sendSyncResponse to APIH - " + "\n" + updateNetworkRestRequest, isDebugEnabled)
- sendWorkflowResponse(execution, 202, updateNetworkRestRequest)
-
- } catch (Exception ex) {
- String exceptionMessage = "Bpmn error encountered in UpdateNetworkInstanceInfra flow. sendSyncResponse() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
- }
-
- }
-
- public void callRESTQueryAAICloudRegion (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside callRESTQueryAAICloudRegion of UpdateNetworkInstanceInfra ***** " , isDebugEnabled)
-
- try {
- String networkInputs = execution.getVariable("UPDNETI_networkInputs")
- String cloudRegion = utils.getNodeText1(networkInputs, "aic-cloud-region")
- cloudRegion = UriUtils.encode(cloudRegion,"UTF-8")
-
- // Prepare AA&I url
- String aai_endpoint = execution.getVariable("URN_aai_endpoint")
- AaiUtil aaiUtil = new AaiUtil(this)
- String aai_uri = aaiUtil.getCloudInfrastructureCloudRegionUri(execution)
- String queryCloudRegionRequest = "${aai_endpoint}${aai_uri}/" + cloudRegion
- utils.logAudit(queryCloudRegionRequest)
- execution.setVariable("UPDNETI_queryCloudRegionRequest", queryCloudRegionRequest)
- utils.log("DEBUG", " UPDNETI_queryCloudRegionRequest - " + "\n" + queryCloudRegionRequest, isDebugEnabled)
-
- String cloudRegionPo = aaiUtil.getAAICloudReqion(execution, queryCloudRegionRequest, "PO", cloudRegion)
- String cloudRegionSdnc = aaiUtil.getAAICloudReqion(execution, queryCloudRegionRequest, "SDNC", cloudRegion)
-
- if ((cloudRegionPo != "ERROR") && (cloudRegionSdnc != "ERROR")) {
- execution.setVariable("UPDNETI_cloudRegionPo", cloudRegionPo)
- execution.setVariable("UPDNETI_cloudRegionSdnc", cloudRegionSdnc)
- execution.setVariable("UPDNETI_isCloudRegionGood", true)
-
- } else {
- String dataErrorMessage = "QueryAAICloudRegion Unsuccessful. Return Code: " + execution.getVariable("UPDNETI_queryCloudRegionReturnCode")
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- }
-
- utils.log("DEBUG", " is Cloud Region Good: " + execution.getVariable("UPDNETI_isCloudRegionGood"), isDebugEnabled)
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- // try error
- String exceptionMessage = "Bpmn error encountered in UpdateNetworkInstanceInfra flow - callRESTQueryAAICloudRegion() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void callRESTQueryAAINetworkId(Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside callRESTQueryAAINetworkId of UpdateNetworkInstanceInfra ***** " , isDebugEnabled)
-
- try {
- // get variables
- String networkRequest = execution.getVariable("UPDNETI_networkRequest")
- String networkId = utils.getNodeText1(networkRequest, "network-id")
- networkId = UriUtils.encode(networkId,"UTF-8")
- execution.setVariable("UPDNETI_networkId", networkId)
- String messageId = execution.getVariable("UPDNETI_messageId")
-
- // Prepare AA&I url
- String aai_endpoint = execution.getVariable("URN_aai_endpoint")
- AaiUtil aaiUriUtil = new AaiUtil(this)
- String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String queryIdAAIRequest = "${aai_endpoint}${aai_uri}/" + networkId
- utils.logAudit(queryIdAAIRequest)
- execution.setVariable("UPDNETI_queryIdAAIRequest", queryIdAAIRequest)
- utils.log("DEBUG", " UPDNETI_queryIdAAIRequest - " + "\n" + queryIdAAIRequest, isDebugEnabled)
-
- APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryIdAAIRequest)
- String returnCode = response.getStatusCode()
- execution.setVariable("UPDNETI_aaiIdReturnCode", returnCode)
-
- utils.log("DEBUG", " ***** AAI Response Code : " + returnCode, isDebugEnabled)
-
- String aaiResponseAsString = response.getResponseBodyAsString()
-
- if (returnCode=='200') {
- utils.logAudit(aaiResponseAsString)
- execution.setVariable("UPDNETI_queryIdAAIResponse", aaiResponseAsString)
- utils.log("DEBUG", " QueryAAINetworkId Success REST Response - " + "\n" + aaiResponseAsString, isDebugEnabled)
-
- } else {
- if (returnCode=='404') {
- String dataErrorMessage = "Response Error from QueryAAINetworkId is 404 (Not Found)."
- utils.log("DEBUG", " AAI Query Failed. " + dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- } else {
- if (aaiResponseAsString.contains("RESTFault")) {
- WorkflowException exceptionObject = exceptionUtil.MapAAIExceptionToWorkflowException(aaiResponseAsString, execution)
- execution.setVariable("WorkflowException", exceptionObject)
- throw new BpmnError("MSOWorkflowException")
-
- } else {
- // aai all errors
- String dataErrorMessage = "Unexpected Response from QueryAAINetworkId - " + returnCode
- utils.log("DEBUG", "Unexpected Response from QueryAAINetworkId - " + dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- }
- }
- }
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- String exceptionMessage = "Bpmn error encountered in UpdateNetworkInstanceInfra flow. callRESTQueryAAINetworkId() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void callRESTReQueryAAINetworkId(Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside callRESTReQueryAAINetworkId of UpdateNetworkInstanceInfra ***** " , isDebugEnabled)
-
- try {
- // get variables
- String networkId = utils.getNodeText1(execution.getVariable("UPDNETI_changeAssignSDNCResponse"), "network-id")
- networkId = UriUtils.encode(networkId,"UTF-8")
- String messageId = execution.getVariable("UPDNETI_messageId")
-
- // Prepare AA&I url
- String aai_endpoint = execution.getVariable("URN_aai_endpoint")
- AaiUtil aaiUriUtil = new AaiUtil(this)
- String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String requeryIdAAIRequest = "${aai_endpoint}${aai_uri}/" + networkId
- utils.logAudit(requeryIdAAIRequest)
- execution.setVariable("UPDNETI_requeryIdAAIRequest", requeryIdAAIRequest)
- utils.log("DEBUG", " UPDNETI_requeryIdAAIRequest - " + "\n" + requeryIdAAIRequest, isDebugEnabled)
-
- APIResponse response = aaiUriUtil.executeAAIGetCall(execution, requeryIdAAIRequest)
- String returnCode = response.getStatusCode()
- execution.setVariable("UPDNETI_aaiRequeryIdReturnCode", returnCode)
- utils.log("DEBUG", " ***** AAI ReQuery Response Code : " + returnCode, isDebugEnabled)
-
- String aaiResponseAsString = response.getResponseBodyAsString()
-
- if (returnCode=='200') {
- utils.logAudit(aaiResponseAsString)
- execution.setVariable("UPDNETI_requeryIdAAIResponse", aaiResponseAsString)
- utils.log("DEBUG", " ReQueryAAINetworkId Success REST Response - " + "\n" + aaiResponseAsString, isDebugEnabled)
-
- String netId = utils.getNodeText1(aaiResponseAsString, "network-id")
- String netName = utils.getNodeText1(aaiResponseAsString, "network-name")
- String networkOutputs =
- """<network-outputs>
- <network-id>${netId}</network-id>
- <network-name>${netName}</network-name>
- </network-outputs>"""
- execution.setVariable("UPDNETI_networkOutputs", networkOutputs)
- utils.log("DEBUG", " networkOutputs - " + '\n' + networkOutputs, isDebugEnabled)
-
- } else {
- if (returnCode=='404') {
- String dataErrorMessage = "Response Error from ReQueryAAINetworkId is 404 (Not Found)."
- utils.log("DEBUG", " AAI ReQuery Failed. - " + dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- } else {
- if (aaiResponseAsString.contains("RESTFault")) {
- WorkflowException exceptionObject = exceptionUtil.MapAAIExceptionToWorkflowException(aaiResponseAsString, execution)
- execution.setVariable("WorkflowException", exceptionObject)
- throw new BpmnError("MSOWorkflowException")
-
- } else {
- // aai all errors
- String dataErrorMessage = "Unexpected Response from ReQueryAAINetworkId - " + returnCode
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- }
- }
- }
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- String exceptionMessage = "Bpmn error encountered in UpdateNetworkInstanceInfra flow. callRESTReQueryAAINetworkId() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void callRESTQueryAAINetworkVpnBinding(Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside callRESTQueryAAINetworkVpnBinding of UpdateNetworkInstanceInfra ***** " , isDebugEnabled)
-
- try {
-
- // get variables
- String messageId = execution.getVariable("UPDNETI_messageId")
- String queryIdAAIResponse = execution.getVariable("UPDNETI_requeryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
- String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
- utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
-
- // Check if Vnf Binding is present, then build a List of vnfBinding
- List vpnBindingUri = networkUtils.getVnfBindingObject(relationship)
- int vpnCount = vpnBindingUri.size()
- execution.setVariable("UPDNETI_vpnCount", vpnCount)
- utils.log("DEBUG", " UPDNETI_vpnCount - " + vpnCount, isDebugEnabled)
-
- String aai_endpoint = execution.getVariable("URN_aai_endpoint")
- AaiUtil aaiUriUtil = new AaiUtil(this)
-
- if (vpnCount > 0) {
- execution.setVariable("UPDNETI_vpnBindings", vpnBindingUri)
- utils.log("DEBUG", " vpnBindingUri List - " + vpnBindingUri, isDebugEnabled)
-
- String routeTargets = ""
- // AII loop call using list vpnBindings
- for (i in 0..vpnBindingUri.size()-1) {
-
- int counting = i+1
-
- // prepare url using vpnBinding
- String queryVpnBindingAAIRequest = ""
- String aai_uri = aaiUriUtil.getNetworkVpnBindingUri(execution)
-
- // Note: By default, the vpnBinding url is found in 'related-link' of the response,
- // so, the default in URN mappings for this is set to "" (ie, space), unless forced to use the URN mapping.
- if (aai_uri == null || aai_uri == "") {
- // using value of 'related-link' from response
- if (vpnBindingUri[i].charAt(vpnBindingUri[i].length()-1) == '/') {
- queryVpnBindingAAIRequest = "${aai_endpoint}" + vpnBindingUri[i].substring(0, vpnBindingUri[i].length()-1)
- } else {
- queryVpnBindingAAIRequest = "${aai_endpoint}" + vpnBindingUri[i]
- }
-
- } else {
- // using uri value in URN mapping
- String vpnBindingId = vpnBindingUri[i].substring(vpnBindingUri[i].indexOf("/vpn-binding/")+13, vpnBindingUri[i].length())
- if (vpnBindingId.charAt(vpnBindingId.length()-1) == '/') {
- vpnBindingId = vpnBindingId.substring(0, vpnBindingId.length()-1)
- }
- queryVpnBindingAAIRequest = "${aai_endpoint}${aai_uri}/" + vpnBindingId
- }
-
- utils.logAudit(queryVpnBindingAAIRequest)
- execution.setVariable("UPDNETI_queryVpnBindingAAIRequest", queryVpnBindingAAIRequest)
- utils.log("DEBUG", " UPDNETI_queryVpnBindingAAIRequest, , vpnBinding #" + counting + " : " + "\n" + queryVpnBindingAAIRequest, isDebugEnabled)
-
- APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryVpnBindingAAIRequest)
- String returnCode = response.getStatusCode()
- execution.setVariable("UPDNETI_aaiQqueryVpnBindingReturnCode", returnCode)
- utils.log("DEBUG", " ***** AAI query vpn binding Response Code, vpnBinding #" + counting + " : " + returnCode, isDebugEnabled)
-
- String aaiResponseAsString = response.getResponseBodyAsString()
-
- if (returnCode=='200') {
- utils.logAudit(aaiResponseAsString)
- execution.setVariable("UPDNETI_queryVpnBindingAAIResponse", aaiResponseAsString)
- utils.log("DEBUG", " AAI Query Vpn Binding Success REST Response, , vpnBinding #" + counting + " : " + "\n" + aaiResponseAsString, isDebugEnabled)
-
- String routeTarget = ""
- if (utils.nodeExists(aaiResponseAsString, "global-route-target")) {
- routeTarget = utils.getNodeText1(aaiResponseAsString, "global-route-target")
- routeTargets += "<routeTargets>" + routeTarget + "</routeTargets>" + '\n'
- }
-
- } else {
- if (returnCode=='404') {
- String dataErrorMessage = "Response Error from AAINetworkVpnBinding is 404 (Not Found)."
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- } else {
- if (aaiResponseAsString.contains("RESTFault")) {
- WorkflowException exceptionObject = exceptionUtil.MapAAIExceptionToWorkflowException(aaiResponseAsString, execution)
- execution.setVariable("WorkflowException", exceptionObject)
- throw new BpmnError("MSOWorkflowException")
-
- } else {
- // aai all errors
- String dataErrorMessage = " Unexpected Response from AAINetworkVpnBinding - " + returnCode
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- }
- }
- }
-
- } // end loop
-
- execution.setVariable("UPDNETI_routeCollection", routeTargets)
- utils.log("DEBUG", " UPDNETI_routeCollection - " + '\n' + routeTargets, isDebugEnabled)
-
- } else {
- // reset return code to success
- execution.setVariable("UPDNETI_aaiQqueryVpnBindingReturnCode", "200")
- String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
- String aaiStubResponse =
- """ <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
- <vpn-binding xmlns="${schemaVersion}">
- <global-route-target/>
- </vpn-binding>
- </rest:payload>"""
- String aaiStubResponseAsXml = utils.formatXml(aaiStubResponse)
- execution.setVariable("UPDNETI_queryVpnBindingAAIResponse", aaiStubResponseAsXml)
- execution.setVariable("UPDNETI_routeCollection", "<routeTargets/>")
- utils.log("DEBUG", " No vpnBinding, using this stub as response - " + '\n' + aaiStubResponseAsXml, isDebugEnabled)
-
- }
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- String exceptionMessage = "Bpmn error encountered in UpdateNetworkInstanceInfra flow. callRESTQueryAAINetworkVpnBinding() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void callRESTQueryAAINetworkPolicy(Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside callRESTQueryAAINetworkPolicy of UpdateNetworkInstanceInfra ***** " , isDebugEnabled)
-
- try {
- // get variables
- String messageId = execution.getVariable("UPDNETI_messageId")
- String queryIdAAIResponse = execution.getVariable("UPDNETI_requeryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
- String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
- utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
-
- // Check if Network Policy is present, then build a List of network policy
- List networkPolicyUriList = networkUtils.getNetworkPolicyObject(relationship)
- int networkPolicyCount = networkPolicyUriList.size()
- execution.setVariable("UPDNETI_networkPolicyCount", networkPolicyCount)
- utils.log("DEBUG", " UPDNETI_networkPolicyCount - " + networkPolicyCount, isDebugEnabled)
-
- String aai_endpoint = execution.getVariable("URN_aai_endpoint")
- AaiUtil aaiUriUtil = new AaiUtil(this)
-
- if (networkPolicyCount > 0) {
- execution.setVariable("UPDNETI_networkPolicyUriList", networkPolicyUriList)
- utils.log("DEBUG", " networkPolicyUri List - " + networkPolicyUriList, isDebugEnabled)
-
- String networkPolicies = ""
- // AII loop call using list vpnBindings
- for (i in 0..networkPolicyUriList.size()-1) {
-
- int counting = i+1
-
- // prepare url using vpnBinding
- String queryNetworkPolicyAAIRequest = ""
-
- String aai_uri = aaiUriUtil.getNetworkPolicyUri(execution)
-
- // Note: By default, the network policy url is found in 'related-link' of the response,
- // so, the default in URN mappings for this is set to "" (ie, space), unless forced to use the URN mapping.
- if (aai_uri == null || aai_uri == "") {
- // using value of 'related-link' from response
- if (networkPolicyUriList[i].charAt(networkPolicyUriList[i].length()-1) == '/') {
- queryNetworkPolicyAAIRequest = "${aai_endpoint}" + networkPolicyUriList[i].substring(0, networkPolicyUriList[i].length()-1)
- } else {
- queryNetworkPolicyAAIRequest = "${aai_endpoint}" + networkPolicyUriList[i]
- }
- } else {
- // using uri value in URN mapping
- String networkPolicyId = networkPolicyUriList[i].substring(networkPolicyUriList[i].indexOf("/network-policy/")+16, networkPolicyUriList[i].length())
- println " networkPolicyId - " + networkPolicyId
- if (networkPolicyId.charAt(networkPolicyId.length()-1) == '/') {
- networkPolicyId = networkPolicyId.substring(0, networkPolicyId.length()-1)
- }
- queryNetworkPolicyAAIRequest = "${aai_endpoint}${aai_uri}/" + networkPolicyId
-
- }
-
-
- utils.logAudit(queryNetworkPolicyAAIRequest)
- execution.setVariable("UPDNETI_queryNetworkPolicyAAIRequest", queryNetworkPolicyAAIRequest)
- utils.log("DEBUG", " UPDNETI_queryNetworkPolicyAAIRequest, , NetworkPolicy #" + counting + " : " + "\n" + queryNetworkPolicyAAIRequest, isDebugEnabled)
-
- APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryNetworkPolicyAAIRequest)
- String returnCode = response.getStatusCode()
- execution.setVariable("UPDNETI_aaiQqueryNetworkPolicyReturnCode", returnCode)
- utils.log("DEBUG", " ***** AAI query network policy Response Code, NetworkPolicy #" + counting + " : " + returnCode, isDebugEnabled)
-
- String aaiResponseAsString = response.getResponseBodyAsString()
-
- if (returnCode=='200') {
- utils.logAudit(aaiResponseAsString)
- execution.setVariable("UPDNETI_queryNetworkPolicyAAIResponse", aaiResponseAsString)
- utils.log("DEBUG", " QueryAAINetworkPolicy Success REST Response, , NetworkPolicy #" + counting + " : " + "\n" + aaiResponseAsString, isDebugEnabled)
-
- String networkPolicy = ""
- if (utils.nodeExists(aaiResponseAsString, "network-policy-fqdn")) {
- networkPolicy = utils.getNodeText1(aaiResponseAsString, "network-policy-fqdn")
- networkPolicies += "<policyFqdns>" + networkPolicy + "</policyFqdns>" + '\n'
- }
-
- } else {
- if (returnCode=='404') {
- String dataErrorMessage = "Response Error from QueryAAINetworkPolicy is 404 (Not Found)."
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- } else {
- if (aaiResponseAsString.contains("RESTFault")) {
- WorkflowException exceptionObject = exceptionUtil.MapAAIExceptionToWorkflowException(aaiResponseAsString, execution)
- execution.setVariable("WorkflowException", exceptionObject)
- throw new BpmnError("MSOWorkflowException")
-
- } else {
- // aai all errors
- String dataErrorMessage = "Unexpected Response from QueryAAINetworkPolicy - " + returnCode
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- }
- }
- }
-
- } // end loop
-
- execution.setVariable("UPDNETI_networkCollection", networkPolicies)
- utils.log("DEBUG", " UPDNETI_networkCollection - " + '\n' + networkPolicies, isDebugEnabled)
-
- } else {
- // reset return code to success
- execution.setVariable("UPDNETI_aaiQqueryNetworkPolicyReturnCode", "200")
- String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
- String aaiStubResponse =
- """ <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
- <network-policy xmlns="${schemaVersion}">
- <network-policy-fqdn/>
- </network-policy>
- </rest:payload>"""
- String aaiStubResponseAsXml = utils.formatXml(aaiStubResponse)
- execution.setVariable("UPDNETI_queryNetworkPolicyAAIResponse", aaiStubResponseAsXml)
- execution.setVariable("UPDNETI_networkCollection", "<policyFqdns/>")
- utils.log("DEBUG", " No net policies, using this stub as response - " + '\n' + aaiStubResponseAsXml, isDebugEnabled)
-
- }
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- String exceptionMessage = "Bpmn error encountered in UpdateNetworkInstanceInfra flow. callRESTQueryAAINetworkPolicy() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void callRESTQueryAAINetworkTableRef(Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside callRESTQueryAAINetworkTableRef of UpdateNetworkInstanceInfra ***** " , isDebugEnabled)
-
- try {
- // get variables
- String messageId = execution.getVariable("UPDNETI_messageId")
- String queryIdAAIResponse = execution.getVariable("UPDNETI_requeryIdAAIResponse").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
- String relationship = networkUtils.getFirstNodeXml(queryIdAAIResponse, "relationship-list").trim().replace("tag0:","").replace(":tag0","")
- utils.log("DEBUG", " relationship - " + relationship, isDebugEnabled)
-
- // Check if Network TableREf is present, then build a List of network policy
- List networkTableRefUriList = networkUtils.getNetworkTableRefObject(relationship)
- int networkTableRefCount = networkTableRefUriList.size()
- execution.setVariable("UPDNETI_networkTableRefCount", networkTableRefCount)
- utils.log("DEBUG", " UPDNETI_networkTableRefCount - " + networkTableRefCount, isDebugEnabled)
-
- String aai_endpoint = execution.getVariable("URN_aai_endpoint")
- AaiUtil aaiUriUtil = new AaiUtil(this)
-
- if (networkTableRefCount > 0) {
- execution.setVariable("UPDNETI_networkTableRefUriList", networkTableRefUriList)
- utils.log("DEBUG", " networkTableRefUri List - " + networkTableRefUriList, isDebugEnabled)
-
- // AII loop call using list vpnBindings
- String networkTableRefs = ""
- for (i in 0..networkTableRefUriList.size()-1) {
-
- int counting = i+1
-
- // prepare url using tableRef
- String queryNetworkTableRefAAIRequest = ""
-
- String aai_uri = aaiUriUtil.getNetworkTableReferencesUri(execution)
-
- // Note: By default, the network policy url is found in 'related-link' of the response,
- // so, the default in URN mappings for this is set to "" (ie, space), unless forced to use the URN mapping.
- if (aai_uri == null || aai_uri == "") {
- // using value of 'related-link' from response
- if (networkTableRefUriList[i].charAt(networkTableRefUriList[i].length()-1) == '/') {
- queryNetworkTableRefAAIRequest = "${aai_endpoint}" + networkTableRefUriList[i].substring(0, networkTableRefUriList[i].length()-1)
- } else {
- queryNetworkTableRefAAIRequest = "${aai_endpoint}" + networkTableRefUriList[i]
- }
- } else {
- // using uri value in URN mapping
- String networkTableRefId = networkTableRefUriList[i].substring(networkTableRefUriList[i].indexOf("/route-table-reference/")+23, networkTableRefUriList[i].length())
-
- if (networkTableRefId.charAt(networkTableRefId.length()-1) == '/') {
- networkTableRefId = networkTableRefId.substring(0, networkTableRefId.length()-1)
- }
- queryNetworkTableRefAAIRequest = "${aai_endpoint}${aai_uri}/" + networkTableRefId
-
- }
-
-
- utils.logAudit(queryNetworkTableRefAAIRequest)
- execution.setVariable("UPDNETI_queryNetworkTableRefAAIRequest", queryNetworkTableRefAAIRequest)
- utils.log("DEBUG", " UPDNETI_queryNetworkTableRefAAIRequest, , NetworkTableRef #" + counting + " : " + "\n" + queryNetworkTableRefAAIRequest, isDebugEnabled)
-
- APIResponse response = aaiUriUtil.executeAAIGetCall(execution, queryNetworkTableRefAAIRequest)
- String returnCode = response.getStatusCode()
- execution.setVariable("UPDNETI_aaiQqueryNetworkTableRefReturnCode", returnCode)
- utils.log("DEBUG", " ***** AAI query network Table Reference Response Code, NetworkTableRef #" + counting + " : " + returnCode, isDebugEnabled)
-
- String aaiResponseAsString = response.getResponseBodyAsString()
-
- if (returnCode=='200') {
- utils.logAudit(aaiResponseAsString)
- execution.setVariable("UPDNETI_queryNetworkTableRefAAIResponse", aaiResponseAsString)
- utils.log("DEBUG", " QueryAAINetworkTableRef Success REST Response, , NetworkTableRef #" + counting + " : " + "\n" + aaiResponseAsString, isDebugEnabled)
-
- String networkTableRef = ""
- if (utils.nodeExists(aaiResponseAsString, "route-table-reference-fqdn")) {
- networkTableRef = utils.getNodeText1(aaiResponseAsString, "route-table-reference-fqdn")
- networkTableRefs += "<routeTableFqdns>" + networkTableRef + "</routeTableFqdns>" + '\n'
- }
-
- } else {
- if (returnCode=='404') {
- String dataErrorMessage = "Response Error from QueryAAINetworkTableRef is 404 (Not Found)."
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- } else {
- if (aaiResponseAsString.contains("RESTFault")) {
- WorkflowException exceptionObject = exceptionUtil.MapAAIExceptionToWorkflowException(aaiResponseAsString, execution)
- execution.setVariable("WorkflowException", exceptionObject)
- throw new BpmnError("MSOWorkflowException")
-
- } else {
- // aai all errors
- String dataErrorMessage = "Unexpected Response from QueryAAINetworkTableRef - " + returnCode
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- }
- }
- }
-
- } // end loop
-
- execution.setVariable("UPDNETI_tableRefCollection", networkTableRefs)
- utils.log("DEBUG", " UPDNETI_tableRefCollection - " + '\n' + networkTableRefs, isDebugEnabled)
-
- } else {
- // reset return code to success
- execution.setVariable("UPDNETI_aaiQqueryNetworkTableRefReturnCode", "200")
- String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
- String aaiStubResponse =
- """ <rest:payload contentType="text/xml" xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd">
- <route-table-references xmlns="${schemaVersion}">
- <route-table-reference-fqdn/>
- </route-table-references>
- </rest:payload>"""
- String aaiStubResponseAsXml = utils.formatXml(aaiStubResponse)
- execution.setVariable("UPDNETI_queryNetworkTableRefAAIResponse", aaiStubResponseAsXml)
- execution.setVariable("UPDNETI_tableRefCollection", "<routeTableFqdns/>")
- utils.log("DEBUG", " No net table references, using this stub as response - " + '\n' + aaiStubResponseAsXml, isDebugEnabled)
-
- }
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- String exceptionMessage = "Bpmn error encountered in UpdateNetworkInstanceInfra flow. callRESTQueryAAINetworkTableRef() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void callRESTUpdateContrailAAINetwork(Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside callRESTUpdateContrailAAINetwork of UpdateNetworkInstanceInfra ***** " , isDebugEnabled)
-
- try {
- // get variables
- String networkId = utils.getNodeText1(execution.getVariable("UPDNETI_changeAssignSDNCResponse"), "network-id")
- networkId = UriUtils.encode(networkId,"UTF-8")
- String requeryIdAAIResponse = execution.getVariable("UPDNETI_requeryIdAAIResponse")
- String updateNetworkResponse = execution.getVariable("UPDNETI_updateNetworkResponse")
- String messageId = execution.getVariable("UPDNETI_messageId")
-
- // Prepare url
- String aai_endpoint = execution.getVariable("URN_aai_endpoint")
- AaiUtil aaiUriUtil = new AaiUtil(this)
- String aai_uri = aaiUriUtil.getNetworkL3NetworkUri(execution)
- String updateContrailAAIUrlRequest = "${aai_endpoint}${aai_uri}/" + networkId
-
- utils.logAudit(updateContrailAAIUrlRequest)
- execution.setVariable("UPDNETI_updateContrailAAIUrlRequest", updateContrailAAIUrlRequest)
- utils.log("DEBUG", " UPDNETI_updateContrailAAIUrlRequest - " + "\n" + updateContrailAAIUrlRequest, isDebugEnabled)
-
- //Prepare payload (PUT)
- String schemaVersion = aaiUriUtil.getNamespaceFromUri(aai_uri)
- String payload = networkUtils.ContrailNetworkCreatedUpdate(requeryIdAAIResponse, updateNetworkResponse, schemaVersion)
- String payloadXml = utils.formatXml(payload)
- utils.logAudit(payloadXml)
- execution.setVariable("UPDNETI_updateContrailAAIPayloadRequest", payloadXml)
- utils.log("DEBUG", " 'payload' to Update Contrail - " + "\n" + payloadXml, isDebugEnabled)
-
- APIResponse response = aaiUriUtil.executeAAIPutCall(execution, updateContrailAAIUrlRequest, payload)
- String returnCode = response.getStatusCode()
- execution.setVariable("UPDNETI_aaiUpdateContrailReturnCode", returnCode)
-
- utils.log("DEBUG", " ***** AAI Update Contrail Response Code : " + returnCode, isDebugEnabled)
-
- String aaiUpdateContrailResponseAsString = response.getResponseBodyAsString()
-
- if (returnCode=='200') {
- utils.logAudit(aaiUpdateContrailResponseAsString)
- execution.setVariable("UPDNETI_updateContrailAAIResponse", aaiUpdateContrailResponseAsString)
- utils.log("DEBUG", " AAI Update Contrail Success REST Response - " + "\n" + aaiUpdateContrailResponseAsString, isDebugEnabled)
- // Point-of-no-return is set to false, rollback not needed.
- execution.setVariable("UPDNETI_isPONR", true)
-
- } else {
- if (returnCode=='404') {
- String dataErrorMessage = " Response Error from UpdateContrailAAINetwork is 404 (Not Found)."
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- } else {
- if (aaiUpdateContrailResponseAsString.contains("RESTFault")) {
- WorkflowException exceptionObject = exceptionUtil.MapAAIExceptionToWorkflowException(aaiUpdateContrailResponseAsString, execution)
- execution.setVariable("WorkflowException", exceptionObject)
- throw new BpmnError("MSOWorkflowException")
-
- } else {
- // aai all errors
- String errorMessage = "Unexpected Response from UpdateContrailAAINetwork - " + returnCode
- utils.log("DEBUG", errorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, "2500", errorMessage)
- }
- }
- }
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- String exceptionMessage = "Bpmn error encountered in UpdateNetworkInstanceInfra flow. callRESTUpdateContrailAAINetwork() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void prepareUpdateNetworkRequest (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside prepareUpdateNetworkRequest of UpdateNetworkInstanceInfra ***** ", isDebugEnabled)
-
- try {
-
- // get variables
- String requestId = execution.getVariable("UPDNETI_requestId")
- String messageId = execution.getVariable("UPDNETI_messageId")
- String source = execution.getVariable("UPDNETI_source")
-
- String requestInput = execution.getVariable("UPDNETI_networkRequest")
- String queryIdResponse = execution.getVariable("UPDNETI_requeryIdAAIResponse")
- String cloudRegionId = execution.getVariable("UPDNETI_cloudRegionPo")
- String backoutOnFailure = execution.getVariable("UPDNETI_rollbackEnabled")
-
- // Prepare Network request
- String routeCollection = execution.getVariable("UPDNETI_routeCollection")
- String policyCollection = execution.getVariable("UPDNETI_networkCollection")
- String tableCollection = execution.getVariable("UPDNETI_tableRefCollection")
- String updateNetworkRequest = networkUtils.UpdateNetworkRequestV2(execution, requestId, messageId, requestInput, queryIdResponse, routeCollection, policyCollection, tableCollection, cloudRegionId, backoutOnFailure, source )
- // Format Response
- String buildUpdateNetworkRequestAsString = utils.formatXml(updateNetworkRequest)
- buildUpdateNetworkRequestAsString = buildUpdateNetworkRequestAsString.replace(":w1aac13n0", "").replace("w1aac13n0:", "")
- utils.logAudit(buildUpdateNetworkRequestAsString)
-
- execution.setVariable("UPDNETI_updateNetworkRequest", buildUpdateNetworkRequestAsString)
- utils.log("DEBUG", " UPDNETI_updateNetworkRequest - " + "\n" + buildUpdateNetworkRequestAsString, isDebugEnabled)
-
- } catch (Exception ex) {
- String exceptionMessage = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. prepareUpdateNetworkRequest() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void prepareSDNCRequest (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside prepareSDNCRequest of UpdateNetworkInstanceInfra ***** ", isDebugEnabled)
-
- try {
- // get variables
- String sdncCallback = execution.getVariable("URN_mso_workflow_sdncadapter_callback")
- String updateNetworkInput = execution.getVariable("UPDNETI_networkRequest")
- String cloudRegionId = execution.getVariable("UPDNETI_cloudRegionSdnc")
-
- String networkId = ""
- if (utils.nodeExists(updateNetworkInput, "network-id")) {
- networkId = utils.getNodeText1(updateNetworkInput, "network-id")
- }
- if (networkId == null) {networkId = ""}
-
- String serviceInstanceId = utils.getNodeText1(updateNetworkInput, "service-instance-id")
-
- // 1. prepare assign topology via SDNC Adapter SUBFLOW call
- String sndcTopologyCreateRequest = sdncAdapterUtils.sdncTopologyRequestV2(execution, updateNetworkInput, serviceInstanceId, sdncCallback, "changeassign", "NetworkActivateRequest", cloudRegionId, networkId, null, null)
-
- String sndcTopologyUpdateRequesAsString = utils.formatXml(sndcTopologyCreateRequest)
- utils.logAudit(sndcTopologyUpdateRequesAsString)
- execution.setVariable("UPDNETI_changeAssignSDNCRequest", sndcTopologyUpdateRequesAsString)
- utils.log("DEBUG", " UPDNETI_changeAssignSDNCRequest - " + "\n" + sndcTopologyUpdateRequesAsString, isDebugEnabled)
-
-
- } catch (Exception ex) {
- String exceptionMessage = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. prepareSDNCRequest() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void prepareDBRequest (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- try {
- // Catalog DB headers Authorization\r
- String basicAuthValueDB = execution.getVariable("URN_mso_adapters_db_auth")\r
- utils.log("DEBUG", " Obtained BasicAuth userid password for Catalog DB adapter: " + basicAuthValueDB, isDebugEnabled)\r
- \r
- def encodedString = utils.getBasicAuth(basicAuthValueDB, execution.getVariable("URN_mso_msoKey"))\r
- execution.setVariable("BasicAuthHeaderValueDB",encodedString)\r
- } catch (IOException ex) {\r
- String dataErrorMessage = " Unable to encode Catalog DB user/password string - " + ex.getMessage()\r
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)\r
- }\r
- \r
- try {\r
- utils.log("DEBUG", " ***** Inside prepareDBRequest of UpdateNetworkInstanceInfra ***** ", isDebugEnabled)
-
- String networkOutputs = execution.getVariable("UPDNETI_networkOutputs")
- String networkName = ""
- try {
- networkName = utils.getNodeText1(networkOutputs, "network-name")
- if (networkName == null) {networkName = ""}
- } catch (Exception ex) {
- networkName = ""
- utils.log("DEBUG", " No 'network-name' found in '<network-outputs>' ! ", isDebugEnabled)
- }
- String networkId = ""
- try {
- networkId = utils.getNodeText1(networkOutputs, "network-id")
- if (networkId == null) {networkId = ""}
- } catch (Exception) {
- networkId = ""
- utils.log("DEBUG", " No 'network-id' found in '<network-outputs>' ! ", isDebugEnabled)
- }
- String requestId = execution.getVariable("UPDNETI_requestId")
-
- String statusMessage = "Network successfully updated."
-
- String dbRequest =
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
- <soapenv:Header/>
- <soapenv:Body>
- <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <requestId>${requestId}</requestId>
- <lastModifiedBy>BPMN</lastModifiedBy>
- <statusMessage>${statusMessage}</statusMessage>
- <responseBody></responseBody>
- <requestStatus>COMPLETED</requestStatus>
- <progress>100</progress>
- <vnfOutputs><network-id>${networkId}</network-id><network-name>${networkName}</network-names></vnfOutputs>
- <networkId>${networkId}</networkId>
- </ns:updateInfraRequest>
- </soapenv:Body>
- </soapenv:Envelope>"""
-
- String buildDeleteDBRequestAsString = utils.formatXml(dbRequest)
- execution.setVariable("UPDNETI_updateDBRequest", buildDeleteDBRequestAsString)
- utils.log("DEBUG", " DB Adapter Request - " + "\n" + buildDeleteDBRequestAsString, isDebugEnabled)
- utils.logAudit(buildDeleteDBRequestAsString)
-
- } catch (Exception ex) {
- String exceptionMessage = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. prepareDBRequest() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void prepareDBRequestError (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- try {
- // Catalog DB headers Authorization\r
- String basicAuthValueDB = execution.getVariable("URN_mso_adapters_db_auth")\r
- utils.log("DEBUG", " Obtained BasicAuth userid password for Catalog DB adapter: " + basicAuthValueDB, isDebugEnabled)\r
- \r
- def encodedString = utils.getBasicAuth(basicAuthValueDB, execution.getVariable("URN_mso_msoKey"))\r
- execution.setVariable("BasicAuthHeaderValueDB",encodedString)\r
- } catch (IOException ex) {\r
- String dataErrorMessage = " Unable to encode Catalog DB user/password string - " + ex.getMessage()\r
- utils.log("DEBUG", dataErrorMessage, isDebugEnabled)\r
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)\r
- }\r
- \r
- try {\r
- utils.log("DEBUG", " ***** Inside prepareDBRequestError of UpdateNetworkInstanceInfra ***** ", isDebugEnabled)
-
- String statusMessage = ""
- WorkflowException wfe = null
- if (execution.getVariable("WorkflowException") instanceof WorkflowException) {
- wfe = execution.getVariable("WorkflowException")
- statusMessage = wfe.getErrorMessage()
- } else {
- String workflowException = execution.getVariable("WorkflowException")
- try {
- statusMessage = utils.getNodeText1(workflowException, "ErrorMessage")
- } catch (Exception ex) {
- statusMessage = "Encountered Error during DB Update. " + ex.getMessage()
- }
- }
- String networkOutputs = execution.getVariable("UPDNETI_networkOutputs")
- String requestId = execution.getVariable("UPDNETI_requestId")
- String networkId = ""
- try {
- networkId = utils.getNodeText1(networkOutputs, "network-id")
- if (networkId == null) {networkId = ""}
- } catch (Exception) {
- networkId = ""
- utils.log("DEBUG", " No 'network-id' found in '<network-outputs>' ! ", isDebugEnabled)
- }
- String networkName = ""
- try {
- networkName = utils.getNodeText1(networkOutputs, "network-name")
- if (networkName == null) {networkName = ""}
- } catch (Exception ex) {
- networkName = ""
- utils.log("DEBUG", " No 'network-name' found in '<network-outputs>' ! ", isDebugEnabled)
- }
- String dbRequest =
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
- <soapenv:Header/>
- <soapenv:Body>
- <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <requestId>${requestId}</requestId>
- <lastModifiedBy>BPMN</lastModifiedBy>
- <statusMessage>${statusMessage}</statusMessage>
- <responseBody></responseBody>
- <requestStatus>FAILED</requestStatus>
- <vnfOutputs><network-id>${networkId}</network-id><network-name>${networkName}</network-names></vnfOutputs>
- </ns:updateInfraRequest>
- </soapenv:Body>
- </soapenv:Envelope>"""
-
- execution.setVariable("UPDNETI_updateDBRequest", dbRequest)
- utils.log("DEBUG", " DB Adapter Request - " + "\n" + dbRequest, isDebugEnabled)
- utils.logAudit(dbRequest)
-
- } catch (Exception ex) {
- String exceptionMessage = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. prepareDBRequestError() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
-
- // **************************************************
- // Post or Validate Response Section
- // **************************************************
-
- public void validateUpdateNetworkResponse (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside validateUpdateNetworkResponse of UpdateNetworkInstanceInfra *****", isDebugEnabled)
-
- try {
- String returnCode = execution.getVariable("UPDNETI_networkReturnCode")
- String networkResponse = execution.getVariable("UPDNETI_updateNetworkResponse")
- if (networkResponse==null) {
- networkResponse="" // reset
- }
-
- utils.log("DEBUG", " Network Adapter update responseCode: " + returnCode, isDebugEnabled)
-
- String errorMessage = ""
- if (returnCode == "200") {
- execution.setVariable("UPDNETI_isNetworkRollbackNeeded", true)
- utils.logAudit(networkResponse)
- execution.setVariable("UPDNETI_updateNetworkResponse", networkResponse)
- utils.log("DEBUG", " Network Adapter update Success Response - " + "\n" + networkResponse, isDebugEnabled)
-
- // prepare rollback data
- String rollbackData = utils.getNodeXml(networkResponse, "rollback", false).replace("tag0:","").replace(":tag0","")
- String rollbackNetwork =
- """<NetworkAdapter:rollbackNetwork xmlns:NetworkAdapter="http://org.openecomp.mso/network">\r
- ${rollbackData}
- </NetworkAdapter:rollbackNetwork>"""
- String rollbackNetworkXml = utils.formatXml(rollbackNetwork)
- execution.setVariable("UPDNETI_rollbackNetworkRequest", rollbackNetworkXml)
- utils.log("DEBUG", " Network Adapter rollback data - " + "\n" + rollbackNetworkXml, isDebugEnabled)
-
- } else { // network error
- if (returnCode.toInteger() > 399 && returnCode.toInteger() < 600) { //4xx, 5xx
- if (networkResponse.contains("updateNetworkError")) {
- networkResponse = networkResponse.replace('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>', '')
- errorMessage = utils.getNodeText1(networkResponse, "message")
- errorMessage = "Received error from Network Adapter: " + errorMessage
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, errorMessage)
-
- } else { // CatchAll exception
- if (returnCode == "500") {
- errorMessage = "JBWEB000065: HTTP Status 500."
- } else {
- errorMessage = "Return code is " + returnCode
- }
- errorMessage = "Received error from Network Adapter: " + errorMessage
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, errorMessage)
-
- }
-
- } else { // CatchAll exception
- String dataErrorMessage = "Received error from Network Adapter. Return code is: " + returnCode
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, dataErrorMessage)
-
- }
-
- }
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- String exceptionMessage = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. validateUpdateNetworkResponse() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
-
- }
-
- public void validateSDNCResponse (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside validateSDNCResponse of UpdateNetworkInstanceInfra ***** ", isDebugEnabled)
-
- String response = execution.getVariable("UPDNETI_changeAssignSDNCResponse")
- WorkflowException workflowException = null
- try {
- workflowException = execution.getVariable("UPDNETI_WorkflowException")
- //execution.setVariable("WorkflowException", workflowException)
- } catch (Exception ex) {
- utils.log("DEBUG", " Sdnc 'WorkflowException' object is empty or null. ", isDebugEnabled)
- }
-
- boolean successIndicator = execution.getVariable("SDNCA_SuccessIndicator")
-
- SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)
- sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator)
- // reset variable
- String changeAssignSDNCResponseDecodeXml = sdncAdapterUtils.decodeXML(execution.getVariable("UPDNETI_changeAssignSDNCResponse"))
- changeAssignSDNCResponseDecodeXml = changeAssignSDNCResponseDecodeXml.replace("&", "&").replace('<?xml version="1.0" encoding="UTF-8"?>', "")
- execution.setVariable("UPDNETI_changeAssignSDNCResponse", changeAssignSDNCResponseDecodeXml)
-
- if (execution.getVariable("UPDNETI_sdncResponseSuccess") == true) { // from sdnc util, prefix+'sdncResponseSuccess'
- execution.setVariable("UPDNETI_isSdncRollbackNeeded", true)
- utils.log("DEBUG", "Successfully Validated SDNC Response", isDebugEnabled)
-
- } else {
- utils.log("DEBUG", "Did NOT Successfully Validated SDNC Response", isDebugEnabled)
- throw new BpmnError("MSOWorkflowException")
- }
-
- }
-
-
- public void postProcessResponse (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside postProcessResponse of UpdateNetworkInstanceInfra ***** ", isDebugEnabled)
-
- try {
- // Display DB response: UPDNETI_updateDBResponse / UPDNETI_dbReturnCode
- String dbReturnCode = execution.getVariable("UPDNETI_dbReturnCode")
- utils.log("DEBUG", " ***** DB Update Response Code : " + dbReturnCode, isDebugEnabled)
- String updateDBResponse = execution.getVariable("UPDNETI_updateDBResponse")
- utils.log("DEBUG", " ***** DB Update Response String: " + '\n' + updateDBResponse, isDebugEnabled)
- utils.logAudit(updateDBResponse)
-
- String source = execution.getVariable("UPDNETI_source")
- String requestId = execution.getVariable("UPDNETI_requestId")
-
- String msoCompletionRequest =
- """<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>
- <action>UPDATE</action>
- <source>${source}</source>
- </request-info>
- <aetgt:mso-bpel-name>BPMN Network action: UPDATE</aetgt:mso-bpel-name>
- </aetgt:MsoCompletionRequest>"""
-
- // Format Response
- String xmlMsoCompletionRequest = utils.formatXml(msoCompletionRequest)
-
- if (dbReturnCode == "200") {
- utils.logAudit(updateDBResponse)
- utils.logAudit(xmlMsoCompletionRequest)
- execution.setVariable("UPDNETI_Success", true)
- execution.setVariable("UPDNETI_CompleteMsoProcessRequest", xmlMsoCompletionRequest)
- utils.log("DEBUG", " Overall SUCCESS Response going to CompleteMsoProcess - " + "\n" + xmlMsoCompletionRequest, isDebugEnabled)
-
- } else {
- String errorMessage = " DB Update failed, code: " + dbReturnCode
- utils.log("DEBUG", errorMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 2500, errorMessage)
-
- }
-
-
- } catch (BpmnError e) {
- throw e;
-
- } catch (Exception ex) {
- String exceptionMessage = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. postProcessResponse() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
-
- }
-
- public void prepareSDNCRollbackRequest (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Inside prepareSDNCRollbackRequest of UpdateNetworkInstanceInfra ***** ", isDebugEnabled)
-
- try {
- // for some reason the WorkflowException object is null after the sdnc rollback call task, need to save WorkflowException.
- execution.setVariable("UPDNETI_WorkflowException", execution.getVariable("WorkflowException"))
- // get variables
- String sdncCallback = execution.getVariable("URN_mso_workflow_sdncadapter_callback")
- String updateNetworkInput = execution.getVariable("UPDNETI_networkRequest")
- String cloudRegionId = execution.getVariable("UPDNETI_cloudRegionSdnc")
- String changeAssignSDNCResponse = execution.getVariable("UPDNETI_changeAssignSDNCResponse")
- String networkId = utils.getNodeText1(changeAssignSDNCResponse, "network-id")
-
- String serviceInstanceId = utils.getNodeText1(updateNetworkInput, "service-instance-id")
-
- // 2. prepare rollback topology via SDNC Adapter SUBFLOW call
- String sndcTopologyRollbackRequest = sdncAdapterUtils.sdncTopologyRequestV2(execution, updateNetworkInput, serviceInstanceId, sdncCallback, "rollback", "NetworkActivateRequest", cloudRegionId, networkId, null, null)
- String sndcTopologyRollbackRequestAsString = utils.formatXml(sndcTopologyRollbackRequest)
- execution.setVariable("UPDNETI_rollbackSDNCRequest", sndcTopologyRollbackRequestAsString)
- utils.log("DEBUG", " Preparing request for SDNC Topology assign's rollback/compensation . . . - " + "\n" + sndcTopologyRollbackRequestAsString, isDebugEnabled)
-
-
- } catch (Exception ex) {
- String exceptionMessage = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. prepareSDNCRollbackRequest() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
- }
-
- public void validateRollbackResponses (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- try {
- // Note: Updates do not support rollback. To restore a previous state, another Update would be needed to revert to the original settings.
- // This would need to be managed by the client.
- String rollbackNetworkErrorMessages = ""
- Boolean isNetworkRollbackNeeded = execution.getVariable("UPDNETI_isNetworkRollbackNeeded")
- if (isNetworkRollbackNeeded == true) {
- rollbackNetworkErrorMessages = " + PO Network rollback is not supported for Update. Submit another Update to restore/rollback."
- }
-
- // validate SDNC rollback response
- String rollbackSdncErrorMessages = ""
- Boolean isSdncRollbackNeeded = execution.getVariable("UPDNETI_isSdncRollbackNeeded")
- if (isSdncRollbackNeeded == true) {
- String rollbackSDNCReturnCode = execution.getVariable("UPDNETI_rollbackSDNCReturnCode")
- String rollbackSDNCReturnInnerCode = ""
- String rollbackSDNCResponse = execution.getVariable("UPDNETI_rollbackSDNCResponse")
- SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this)
- rollbackSDNCResponse = sdncAdapterUtils.decodeXML(rollbackSDNCResponse)
- rollbackSDNCResponse = rollbackSDNCResponse.replace("&", "&").replace('$', '').replace('<?xml version="1.0" encoding="UTF-8"?>', "")
-
- if (rollbackSDNCReturnCode == "200") {
- if (utils.nodeExists(rollbackSDNCResponse, "response-code")) {
- rollbackSDNCReturnInnerCode = utils.getNodeText1(rollbackSDNCResponse, "response-code")
- if (rollbackSDNCReturnInnerCode == "200" || rollbackSDNCReturnInnerCode == "" || rollbackSDNCReturnInnerCode == "0") {
- rollbackSdncErrorMessages = " + SNDC rollback completed."
- } else {
- rollbackSdncErrorMessages = " + SDNC rollback failed. "
- }
- } else {
- rollbackSdncErrorMessages = " + SNDC rollback completed."
- }
- } else {
- rollbackSdncErrorMessages = " + SDNC rollback failed. "
- }
-
- utils.log("DEBUG", " SDNC rollback Code - " + rollbackSDNCReturnCode, isDebugEnabled)
- utils.log("DEBUG", " SDNC rollback Response - " + rollbackSDNCResponse, isDebugEnabled)
-
- }
-
- //WorkflowException wfe = execution.getVariable("WorkflowException")
- //String statusMessage = wfe.getErrorMessage()
- //int errorCode = wfe.getErrorCode()
-
- String statusMessage = ""
- int errorCode = 0
- WorkflowException wfe = execution.getVariable("WorkflowException")
- if (wfe instanceof WorkflowException) {
- statusMessage = wfe.getErrorMessage()
- errorCode = wfe.getErrorCode()
- } else {
- if (execution.getVariable("UPDNETI_WorkflowException") instanceof WorkflowException) {
- // get saved WorkflowException
- WorkflowException swfe = execution.getVariable("UPDNETI_WorkflowException")
- statusMessage = swfe.getErrorMessage()
- errorCode = swfe.getErrorCode()
- } else {
- statusMessage = "Encountered Error, please see previous tasks/activities/steps for error messages."
- errorCode = 7000
- }
- }
-
- // recreate WorkflowException to include the rollback Message
- statusMessage = statusMessage + rollbackNetworkErrorMessages + rollbackSdncErrorMessages
- exceptionUtil.buildWorkflowException(execution, errorCode, statusMessage)
-
- } catch (Exception ex) {
- execution.setVariable("WorkflowException", null)
- String exceptionMessage = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. validateRollbackResponses() - " + ex.getMessage()
- utils.log("DEBUG", exceptionMessage, isDebugEnabled)
- exceptionUtil.buildWorkflowException(execution, 7000, exceptionMessage)
-
- }
-
-
-
- }
-
- // *******************************
- // Build Error Section
- // *******************************
-
- // Prepare for FalloutHandler
- public void buildErrorResponse (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- utils.log("DEBUG", " ***** Prepare for FalloutHandler. FAILURE - prepare request for sub-process FalloutHandler. *****", isDebugEnabled)
-
- String dbReturnCode = execution.getVariable("UPDNETI_dbReturnCode")
- utils.log("DEBUG", " ***** DB Update Response Code : " + dbReturnCode, isDebugEnabled)
- String updateDBResponse = execution.getVariable("UPDNETI_updateDBResponse")
- utils.log("DEBUG", " ***** DB Update Response String: " + '\n' + updateDBResponse, isDebugEnabled)
- utils.logAudit(updateDBResponse)
-
- String falloutHandlerRequest = ""
- String requestId = execution.getVariable("UPDNETI_requestId")
- String source = execution.getVariable("UPDNETI_source")
- try {
- execution.setVariable("UPDNETI_Success", false)
- WorkflowException wfe = execution.getVariable("WorkflowException")
- String errorCode = String.valueOf(wfe.getErrorCode())
- String errorMessage = wfe.getErrorMessage()
- falloutHandlerRequest =
- """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>
- <action>UPDATE</action>
- <source>${source}</source>
- </request-info>
- <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorMessage}</aetgt:ErrorMessage>
- <aetgt:ErrorCode>${errorCode}</aetgt:ErrorCode>
- </aetgt:WorkflowException>
- </aetgt:FalloutHandlerRequest>"""
-
- utils.logAudit(falloutHandlerRequest)
- execution.setVariable("UPDNETI_FalloutHandlerRequest", falloutHandlerRequest)
- utils.log("DEBUG", " Overall Error Response going to FalloutHandler: " + "\n" + falloutHandlerRequest, isDebugEnabled)
-
- } catch (Exception ex) {
- String errorException = " Bpmn error encountered in UpdateNetworkInstanceInfra flow. FalloutHandlerRequest, buildErrorResponse() - " + ex.getMessage()
- utils.log("DEBUG", errorException, isDebugEnabled)
- falloutHandlerRequest =
- """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>${requestId}</request-id>
- <action>UPDATE</action>
- <source>${source}</source>
- </request-info>
- <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>${errorException}</aetgt:ErrorMessage>
- <aetgt:ErrorCode>7000</aetgt:ErrorCode>
- </aetgt:WorkflowException>
- </aetgt:FalloutHandlerRequest>"""
-
- execution.setVariable("UPDNETI_FalloutHandlerRequest", falloutHandlerRequest)
- utils.log("DEBUG", " Overall Error Response going to FalloutHandler: " + "\n" + falloutHandlerRequest, isDebugEnabled)
-
- }
-
- }
-
-
- public void sendSyncError (Execution execution) {
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix", Prefix)
-
- try {
-
- String requestId = execution.getVariable("mso-request-id")\r
-
- // REST Error (for API Handler (APIH) Reply Task)
- String syncError = """{"requestReferences":{"instanceId":"","requestId":"${requestId}"}}""".trim()
-
- sendWorkflowResponse(execution, 500, syncError)
-
- } catch (Exception ex) {
- utils.log("DEBUG", " Bpmn error encountered in UpdateNetworkInstanceInfra flow. sendSyncError() - " + ex.getMessage(), isDebugEnabled)
- }
-
- }
-
-
- public void processJavaException(Execution execution){
- def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
- execution.setVariable("prefix",Prefix)
- try{
- utils.log("DEBUG", "Caught a Java Exception", isDebugEnabled)
- utils.log("DEBUG", "Started processJavaException Method", isDebugEnabled)
- utils.log("DEBUG", "Variables List: " + execution.getVariables(), isDebugEnabled)
- execution.setVariable("UnexpectedError", "Caught a Java Lang Exception") // Adding this line temporarily until this flows error handling gets updated
- exceptionUtil.buildWorkflowException(execution, 500, "Caught a Java Lang Exception")
-
- }catch(Exception e){
- utils.log("DEBUG", "Caught Exception during processJavaException Method: " + e, isDebugEnabled)
- execution.setVariable("UnexpectedError", "Exception in processJavaException method") // Adding this line temporarily until this flows error handling gets updated
- exceptionUtil.buildWorkflowException(execution, 500, "Exception in processJavaException method")
- }
- utils.log("DEBUG", "Completed processJavaException Method", isDebugEnabled)
- }
-
-}
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts
import groovy.util.Node
import groovy.util.XmlParser;
import org.camunda.bpm.engine.delegate.BpmnError
import org.camunda.bpm.engine.runtime.Execution
import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils;\r
-import org.openecomp.mso.rest.APIResponse\r
-import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor\r
-import org.openecomp.mso.bpmn.core.RollbackData\r
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.json.JsonUtils;
+import org.openecomp.mso.rest.APIResponse
+import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
+import org.openecomp.mso.bpmn.core.RollbackData
public class UpdateVfModule extends AbstractServiceTaskProcessor {
String updateInfraRequest = """
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
- xmlns:req="http://org.openecomp.mso/requestsdb">\r
+ xmlns:req="http://org.openecomp.mso/requestsdb">
<soapenv:Header/>
<soapenv:Body>
<req:updateInfraRequest>
def requestInfo = getVariable(execution, 'UPDVfMod_requestInfo')
String content = """
- <sdncadapterworkflow:MsoCompletionRequest xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:reqtype="http://org.openecomp/mso/request/types/v1">\r
+ <sdncadapterworkflow:MsoCompletionRequest xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:reqtype="http://org.openecomp/mso/request/types/v1">
${requestInfo}
<sdncadapterworkflow:mso-bpel-name>MSO_ACTIVATE_BPEL</sdncadapterworkflow:mso-bpel-name>
</sdncadapterworkflow:MsoCompletionRequest>
}
String content = """
- <sdncadapterworkflow:FalloutHandlerRequest xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:reqtype="http://org.openecomp/mso/request/types/v1"\r
- xmlns:msoservtypes="http://org.openecomp/mso/request/types/v1"\r
- xmlns:structuredtypes="http://org.openecomp/mso/structured/types/v1">\r
+ <sdncadapterworkflow:FalloutHandlerRequest xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:reqtype="http://org.openecomp/mso/request/types/v1"
+ xmlns:msoservtypes="http://org.openecomp/mso/request/types/v1"
+ xmlns:structuredtypes="http://org.openecomp/mso/structured/types/v1">
${requestInformation}
<sdncadapterworkflow:WorkflowException>
<sdncadapterworkflow:ErrorMessage>${encErrorResponseMsg}</sdncadapterworkflow:ErrorMessage>
-/*-\r
- * ============LICENSE_START=======================================================\r
- * OPENECOMP - MSO\r
- * ================================================================================\r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
- * ================================================================================\r
- * Licensed under the Apache License, Version 2.0 (the "License");\r
- * you may not use this file except in compliance with the License.\r
- * You may obtain a copy of the License at\r
- *\r
- * http://www.apache.org/licenses/LICENSE-2.0\r
- *\r
- * Unless required by applicable law or agreed to in writing, software\r
- * distributed under the License is distributed on an "AS IS" BASIS,\r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
- * See the License for the specific language governing permissions and\r
- * limitations under the License.\r
- * ============LICENSE_END=========================================================\r
- */\r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts\r
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.bpmn.infrastructure.scripts
import java.util.concurrent.ExecutionException;
import org.camunda.bpm.engine.runtime.Execution
import org.apache.commons.lang3.*
import org.springframework.web.util.UriUtils
-import org.openecomp.mso.bpmn.common.scripts.AaiUtil\r
-import org.openecomp.mso.bpmn.common.scripts.VfModuleBase\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-import org.openecomp.mso.bpmn.core.json.JsonUtils;\r
-import org.openecomp.mso.rest.APIResponse\r
-import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil\r
+import org.openecomp.mso.bpmn.common.scripts.AaiUtil
+import org.openecomp.mso.bpmn.common.scripts.VfModuleBase
+import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.json.JsonUtils;
+import org.openecomp.mso.rest.APIResponse
+import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
class UpdateVfModuleVolume extends VfModuleBase {
def volumeInputs = execution.getVariable('UPDVfModVol_volumeInputs')
String synchResponse = """
- <volume-request xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
+ <volume-request xmlns="http://org.openecomp/mso/infra/vnf-request/v1">
<request-info>
<request-id>${requestId}</request-id>
<action>UPDATE_VF_MODULE_VOL</action>
def requestId = execution.getVariable('UPDVfModVol_requestId')
def serviceId = execution.getVariable('UPDVfModVol_serviceId')
- def messageId = execution.getVariable('mso-request-id') + '-' + System.currentTimeMillis()\r
+ def messageId = execution.getVariable('mso-request-id') + '-' + System.currentTimeMillis()
def notificationUrl = createCallbackURL(execution, "VNFAResponse", messageId)
def useQualifiedHostName = execution.getVariable("URN_mso_use_qualified_host")
if ('true'.equals(useQualifiedHostName)) {
String updateInfraRequest = """
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
- xmlns:req="http://org.openecomp.mso/requestsdb">\r
+ xmlns:req="http://org.openecomp.mso/requestsdb">
<soapenv:Header/>
<soapenv:Body>
<req:updateInfraRequest>
def requestInfo = execution.getVariable('UPDVfModVol_requestInfo')
String content = """
- <sdncadapterworkflow:MsoCompletionRequest xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:reqtype="http://org.openecomp/mso/request/types/v1">\r
+ <sdncadapterworkflow:MsoCompletionRequest xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:reqtype="http://org.openecomp/mso/request/types/v1">
${requestInfo}
<sdncadapterworkflow:mso-bpel-name>MSO_ACTIVATE_BPEL</sdncadapterworkflow:mso-bpel-name>
</sdncadapterworkflow:MsoCompletionRequest>
}
String content = """
- <sdncadapterworkflow:FalloutHandlerRequest xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:reqtype="http://org.openecomp/mso/request/types/v1"\r
- xmlns:msoservtypes="http://org.openecomp/mso/request/types/v1"\r
- xmlns:structuredtypes="http://org.openecomp/mso/structured/types/v1">\r
+ <sdncadapterworkflow:FalloutHandlerRequest xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"
+ xmlns:reqtype="http://org.openecomp/mso/request/types/v1"
+ xmlns:msoservtypes="http://org.openecomp/mso/request/types/v1"
+ xmlns:structuredtypes="http://org.openecomp/mso/structured/types/v1">
${requestInfo}
<sdncadapterworkflow:WorkflowException>
<sdncadapterworkflow:ErrorMessage>${encErrorResponseMsg}</sdncadapterworkflow:ErrorMessage>
<?xml version="1.0" encoding="UTF-8"?>
<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
- <bpmn2:process id="CreateServiceInstance" name="CreateServiceInstance" isExecutable="true">
+ <bpmn2:process id="CreateGenericALaCarteServiceInstance" name="CreateGenericALaCarteServiceInstance" isExecutable="true">
<bpmn2:startEvent id="createSI_startEvent" name="Create SI Start Flow">
<bpmn2:outgoing>SequenceFlow_0lp2z7l</bpmn2:outgoing>
</bpmn2:startEvent>
<bpmn2:scriptTask id="ScriptTask_1" name="Handle Unexpected Error" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_10</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_14</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.utils.*
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.common.scripts.*
ExceptionUtil ex = new ExceptionUtil()
ex.processJavaException(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:incoming>SequenceFlow_0lp2z7l</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0ktadna</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi= new CreateServiceInstance()
+def csi= new CreateGenericALaCarteServiceInstance()
csi.preProcessRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_0lp2z7l" sourceRef="createSI_startEvent" targetRef="ScriptTask_0pvcr6j" />
<bpmn2:incoming>SequenceFlow_1o4wwba</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0xxvjxq</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi = new CreateServiceInstance()
+def csi = new CreateGenericALaCarteServiceInstance()
csi.prepareCompletionRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:callActivity id="CallActivity_0sevgre" name="Call CompleteMsoProcess" calledElement="CompleteMsoProcess">
<bpmn2:incoming>SequenceFlow_14eadeb</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1reso2f</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi = new CreateServiceInstance()
+def csi = new CreateGenericALaCarteServiceInstance()
csi.prepareFalloutRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:callActivity id="CallActivity_1ksm1dz" name="Call FalloutHandler" calledElement="FalloutHandler">
<bpmn2:incoming>SequenceFlow_0n4umjf</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_14eadeb</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi = new CreateServiceInstance()
+def csi = new CreateGenericALaCarteServiceInstance()
csi.sendSyncError(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_14eadeb" sourceRef="ScriptTask_0o4smqp" targetRef="ScriptTask_1hql91g" />
<bpmn2:incoming>SequenceFlow_0ktadna</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0eto8sn</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi = new CreateServiceInstance()
+def csi = new CreateGenericALaCarteServiceInstance()
csi.sendSyncResponse(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_0ktadna" sourceRef="ScriptTask_0pvcr6j" targetRef="Task_1nko5zz" />
<bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
<bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="CreateServiceInstance">
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="CreateGenericALaCarteServiceInstance">
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createSI_startEvent">
<dc:Bounds x="-6" y="79" width="36" height="36" />
<bpmndi:BPMNLabel>
-<?xml version="1.0" encoding="UTF-8"?>\r
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">\r
- <bpmn2:process id="CreateGenericMacroServiceNetworkVnf" name="CreateGenericMacroServiceNetworkVnf" isExecutable="true">\r
- <bpmn2:scriptTask id="sendSyncAckResponse_ScriptTask" name="Send Sync Ack Response" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+ <bpmn2:process id="CreateGenericMacroServiceNetworkVnf" name="CreateGenericMacroServiceNetworkVnf" isExecutable="true">
+ <bpmn2:scriptTask id="sendSyncAckResponse_ScriptTask" name="Send Sync Ack Response" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.sendSyncResponse(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="sendSyncAckResponse_ScriptTask" targetRef="IntermediateThrowEvent_2" />\r
- <bpmn2:startEvent id="createVIPR_startEvent" name="Start Flow">\r
- <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>\r
- </bpmn2:startEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="createVIPR_startEvent" targetRef="preProcessRequest_ScriptTask" />\r
- <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.sendSyncResponse(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="sendSyncAckResponse_ScriptTask" targetRef="IntermediateThrowEvent_2" />
+ <bpmn2:startEvent id="createVIPR_startEvent" name="Start Flow">
+ <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
+ </bpmn2:startEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="createVIPR_startEvent" targetRef="preProcessRequest_ScriptTask" />
+ <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.preProcessRequest(execution)\r
-]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="sendSyncAckResponse_ScriptTask" />\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_3" name="vIPR-ATM">\r
+def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.preProcessRequest(execution)
+]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="sendSyncAckResponse_ScriptTask" />
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_3" name="vIPR-ATM">
<bpmn2:outgoing>SequenceFlow_10o22u2</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_37" name="vIPR-ATM" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:scriptTask id="postProcessAndCompletionRequest_ScriptTask" name="Post Process & Completion Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0afe2pg</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_29</bpmn2:outgoing>\r
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_37" name="vIPR-ATM" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:scriptTask id="postProcessAndCompletionRequest_ScriptTask" name="Post Process & Completion Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0afe2pg</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_29</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.postProcessResponse(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_29" name="" sourceRef="postProcessAndCompletionRequest_ScriptTask" targetRef="callCompleteMsoProcess_CallActivity" />\r
- <bpmn2:callActivity id="callCompleteMsoProcess_CallActivity" name="Call CompleteMsoProcess" calledElement="CompleteMsoProcess">\r
- <bpmn2:extensionElements>\r
- <camunda:in variables="all" />\r
- <camunda:out variables="all" />\r
- <camunda:in source="CREVAS_CompleteMsoProcessRequest" target="CompleteMsoProcessRequest" />\r
- <camunda:in source="mso-request-id" target="requestId" />\r
- <camunda:in source="serviceInstanceId" target="serviceInstanceId" />\r
- <camunda:out source="CMSO_ResponseCode" target="CMSO_ResponseCode" />\r
- <camunda:out source="CompleteMsoProcessResponse" target="CompleteMsoProcessResponse" />\r
- <camunda:out source="CMSO_ErrorResponse" target="CMSO_ErrorResponse" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_29</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="callCompleteMsoProcess_CallActivity" targetRef="ScriptTask_2" />\r
- <bpmn2:scriptTask id="ScriptTask_2" name="Set Success Indicator" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>\r
- <bpmn2:script><![CDATA[// The following variable is checked by the unit test\r
-execution.setVariable("CreateGenericMacroServiceNetworkVnfSuccessIndicator", true)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="ScriptTask_2" targetRef="CreateVIPR_EndEvent" />\r
- <bpmn2:endEvent id="CreateVIPR_EndEvent" name="End">\r
- <bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>\r
- <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_13" />\r
- </bpmn2:endEvent>\r
- <bpmn2:subProcess id="UnexpectedError_SubProcess_1" name="Sub-process for UnexpectedErrors" triggeredByEvent="true">\r
- <bpmn2:startEvent id="StartEvent_1">\r
- <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>\r
- <bpmn2:errorEventDefinition id="_ErrorEventDefinition_92" errorRef="Error_1" />\r
- </bpmn2:startEvent>\r
- <bpmn2:endEvent id="EndEvent_1">\r
- <bpmn2:incoming>SequenceFlow_5</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="StartEvent_1" targetRef="ScriptTask_1" />\r
- <bpmn2:scriptTask id="ScriptTask_1" name="Log / Print Unexpected Error" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_5</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.postProcessResponse(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_29" name="" sourceRef="postProcessAndCompletionRequest_ScriptTask" targetRef="callCompleteMsoProcess_CallActivity" />
+ <bpmn2:callActivity id="callCompleteMsoProcess_CallActivity" name="Call CompleteMsoProcess" calledElement="CompleteMsoProcess">
+ <bpmn2:extensionElements>
+ <camunda:in variables="all" />
+ <camunda:out variables="all" />
+ <camunda:in source="CGMSNV_CompleteMsoProcessRequest" target="CompleteMsoProcessRequest" />
+ <camunda:in source="mso-request-id" target="requestId" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:out source="CMSO_ResponseCode" target="CMSO_ResponseCode" />
+ <camunda:out source="CompleteMsoProcessResponse" target="CompleteMsoProcessResponse" />
+ <camunda:out source="CMSO_ErrorResponse" target="CMSO_ErrorResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_29</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="callCompleteMsoProcess_CallActivity" targetRef="ScriptTask_2" />
+ <bpmn2:scriptTask id="ScriptTask_2" name="Set Success Indicator" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[// The following variable is checked by the unit test
+execution.setVariable("CreateGenericMacroServiceNetworkVnfSuccessIndicator", true)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="ScriptTask_2" targetRef="CreateVIPR_EndEvent" />
+ <bpmn2:endEvent id="CreateVIPR_EndEvent" name="End">
+ <bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
+ <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_13" />
+ </bpmn2:endEvent>
+ <bpmn2:subProcess id="UnexpectedError_SubProcess_1" name="Sub-process for UnexpectedErrors" triggeredByEvent="true">
+ <bpmn2:startEvent id="StartEvent_1">
+ <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
+ <bpmn2:errorEventDefinition id="_ErrorEventDefinition_92" errorRef="Error_1" />
+ </bpmn2:startEvent>
+ <bpmn2:endEvent id="EndEvent_1">
+ <bpmn2:incoming>SequenceFlow_5</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="StartEvent_1" targetRef="ScriptTask_1" />
+ <bpmn2:scriptTask id="ScriptTask_1" name="Log / Print Unexpected Error" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_5</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateServiceInstanceInfra = new CreateServiceInstanceInfra()\r
-CreateServiceInstanceInfra.processJavaException(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="ScriptTask_1" targetRef="EndEvent_1" />\r
- </bpmn2:subProcess>\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_4" name="FinishProcess">\r
- <bpmn2:outgoing>SequenceFlow_12ilko1</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_39" name="FinishProcess" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:callActivity id="doCreateNetworkInstance_CallActivity" name="DoCreate Network Instance" calledElement="DoCreateNetworkInstance">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:in source="networkModelInfo" target="networkModelInfo" />\r
- <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />\r
- <camunda:in source="tenantId" target="tenantId" />\r
- <camunda:in source="productFamilyId" target="productFamilyId" />\r
- <camunda:in source="disableRollback" target="disableRollback" />\r
- <camunda:in source="serviceInstanceId" target="serviceInstanceId" />\r
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />\r
- <camunda:in source="networkInputParams" target="networkInputParams" />\r
- <camunda:in source="failIfExists" target="failIfExists" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="rollbackData" target="DCRENI_rollbackData" />\r
- <camunda:out source="rolledBack" target="DCRENI_rolledBack" />\r
- <camunda:out source="networkId" target="networkId" />\r
- <camunda:out source="networkName" target="networkName" />\r
- <camunda:out source="networkOutputParams" target="networkOutputParams" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- <camunda:in source="subscriptionServiceType" target="subscriptionServiceType" />\r
- <camunda:in source="globalSubscriberId" target="globalSubscriberId" />\r
- <camunda:in source="serviceModelInfo" target="serviceModelInfo" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1bwbn7r</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_12ag2bk</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:scriptTask id="ScriptTask_PrepareNetworkCreate" name="Prepare for Network Create" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0cmebdc</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0dfkfh1</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1bwbn7r</bpmn2:outgoing>\r
+def CreateServiceInstanceInfra = new CreateServiceInstanceInfra()
+CreateServiceInstanceInfra.processJavaException(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="ScriptTask_1" targetRef="EndEvent_1" />
+ </bpmn2:subProcess>
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_4" name="FinishProcess">
+ <bpmn2:outgoing>SequenceFlow_12ilko1</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_39" name="FinishProcess" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:callActivity id="doCreateNetworkInstance_CallActivity" name="DoCreate Network Instance" calledElement="DoCreateNetworkInstance">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="networkModelInfo" target="networkModelInfo" />
+ <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="tenantId" target="tenantId" />
+ <camunda:in source="productFamilyId" target="productFamilyId" />
+ <camunda:in source="disableRollback" target="disableRollback" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="networkInputParams" target="networkInputParams" />
+ <camunda:in source="failIfExists" target="failIfExists" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="rollbackData" target="DCRENI_rollbackData" />
+ <camunda:out source="rolledBack" target="DCRENI_rolledBack" />
+ <camunda:out source="networkId" target="networkId" />
+ <camunda:out source="networkName" target="networkName" />
+ <camunda:out source="networkOutputParams" target="networkOutputParams" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ <camunda:in source="subscriptionServiceType" target="subscriptionServiceType" />
+ <camunda:in source="globalSubscriberId" target="globalSubscriberId" />
+ <camunda:in source="serviceModelInfo" target="serviceModelInfo" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1bwbn7r</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_12ag2bk</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_PrepareNetworkCreate" name="Prepare for Network Create" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0cmebdc</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0dfkfh1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1bwbn7r</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.prepareNetworkCreate(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:callActivity id="doCreateServiceInstance_CallActivity" name="DoCreate ServiceInstance " calledElement="DoCreateServiceInstance">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:in source="globalSubscriberId" target="globalSubscriberId" />\r
- <camunda:in sourceExpression="vIPR-ATM" target="subscriptionServiceType" />\r
- <camunda:in source="serviceInstanceId" target="serviceInstanceId" />\r
- <camunda:out source="rollbackData" target="DCRESI_rollbackData" />\r
- <camunda:in source="serviceInstanceName" target="serviceInstanceName" />\r
- <camunda:in source="serviceModelInfo" target="serviceModelInfo" />\r
- <camunda:in source="failIfExists" target="failIfExists" />\r
- <camunda:in source="disableRollback" target="disableRollback" />\r
- <camunda:in source="serviceInputParams" target="serviceInputParams" />\r
- <camunda:out source="rolledBack" target="DCRESI_rolledBack" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="serviceInstanceName" target="serviceInstanceName" />\r
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />\r
- <camunda:in source="subscriptionServiceType" target="subscriptionServiceType" />\r
- <camunda:in source="productFamilyId" target="productFamilyId" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_0j6sjye</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1ky2sv9</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:callActivity id="doCreateVNFandModules_CallActivity" name="DoCreate VNF and Modules " calledElement="DoCreateVnfAndModules">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:in source="disableRollback" target="disableRollback" />\r
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />\r
- <camunda:in source="serviceInstanceId" target="serviceInstanceId" />\r
- <camunda:in source="productFamilyId" target="productFamilyId" />\r
- <camunda:in source="vnfModelInfo" target="vnfModelInfo" />\r
- <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />\r
- <camunda:in source="tenantId" target="tenantId" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- <camunda:out source="rollbackData" target="DCVM_rollbackData" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="vnfId" target="vnfId" />\r
- <camunda:out source="vnfName" target="vnfName" />\r
- <camunda:out source="vnfOutputParams" target="vnfOutputParams" />\r
- <camunda:out source="rolledBack" target="rolledBack" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1h77psn</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0qi5uxg</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:scriptTask id="ScriptTask_3" name="Prepare to Create VNF" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0bvecvm</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1h77psn</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.prepareNetworkCreate(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:callActivity id="doCreateServiceInstance_CallActivity" name="DoCreate ServiceInstance " calledElement="DoCreateServiceInstance">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="globalSubscriberId" target="globalSubscriberId" />
+ <camunda:in sourceExpression="vIPR-ATM" target="subscriptionServiceType" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:out source="rollbackData" target="DCRESI_rollbackData" />
+ <camunda:in source="serviceInstanceName" target="serviceInstanceName" />
+ <camunda:in source="serviceModelInfo" target="serviceModelInfo" />
+ <camunda:in source="failIfExists" target="failIfExists" />
+ <camunda:in source="disableRollback" target="disableRollback" />
+ <camunda:in source="serviceInputParams" target="serviceInputParams" />
+ <camunda:out source="rolledBack" target="DCRESI_rolledBack" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="serviceInstanceName" target="serviceInstanceName" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="subscriptionServiceType" target="subscriptionServiceType" />
+ <camunda:in source="productFamilyId" target="productFamilyId" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0j6sjye</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1ky2sv9</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:callActivity id="doCreateVNFandModules_CallActivity" name="DoCreate VNF and Modules " calledElement="DoCreateVnfAndModules">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="disableRollback" target="disableRollback" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:in source="productFamilyId" target="productFamilyId" />
+ <camunda:in source="vnfModelInfo" target="vnfModelInfo" />
+ <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="tenantId" target="tenantId" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ <camunda:out source="rollbackData" target="DCVM_rollbackData" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="vnfId" target="vnfId" />
+ <camunda:out source="vnfName" target="vnfName" />
+ <camunda:out source="vnfOutputParams" target="vnfOutputParams" />
+ <camunda:out source="rolledBack" target="rolledBack" />
+ <camunda:in source="serviceModelInfo" target="serviceModelInfo" />
+ <camunda:in source="globalSubscriberId" target="globalSubscriberId" />
+ <camunda:in source="serviceDecomposition" target="serviceDecomposition" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1h77psn</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0qi5uxg</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_3" name="Prepare to Create VNF" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0bvecvm</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1h77psn</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.prepareVnfAndModulesCreate(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_4" name="GoToFinishProcess">\r
- <bpmn2:incoming>SequenceFlow_0xowenu</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_41" name="FinishProcess" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_2" name="GoTovIPR-ATM">\r
- <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_38" name="vIPR-ATM" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:subProcess id="SubProcess_0s6hpty" name="Subprocess For Exception / FalloutHandler " triggeredByEvent="true">\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1vwgs6p" name="Is Rollback On?" default="SequenceFlow_0dhf2js">\r
- <bpmn2:incoming>SequenceFlow_0zq7i3q</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0zpbskl</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0dhf2js</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:startEvent id="StartEvent_1bwmffk" name="Fault Start">\r
- <bpmn2:outgoing>SequenceFlow_0zq7i3q</bpmn2:outgoing>\r
- <bpmn2:errorEventDefinition />\r
- </bpmn2:startEvent>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_0ydrtdx" name="isPONR?" default="SequenceFlow_02o4yqx">\r
- <bpmn2:incoming>SequenceFlow_0zpbskl</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1sx5llu</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_02o4yqx</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_00rt5qa" name="is VNF Ok?" default="SequenceFlow_05lo85t">\r
- <bpmn2:incoming>SequenceFlow_0sdb3on</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_05lo85t</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0xtr1g5</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1kvn1pz" name="Network Rollback present?" default="SequenceFlow_19mxskt">\r
- <bpmn2:incoming>SequenceFlow_05lo85t</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_09xerwk</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_19mxskt</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0tmepzk</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:callActivity id="CallActivity_0jw5tqa" name="Call FalloutHandlerV1" calledElement="FalloutHandler">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="CREVAS_falloutRequest" target="FalloutHandlerRequest" />\r
- <camunda:in source="msoRequestId" target="mso-request-id" />\r
- <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />\r
- <camunda:out source="FH_ResponseCode" target="FH_ResponseCode" />\r
- <camunda:out source="FalloutHandlerResponse" target="FalloutHandlerResponse" />\r
- <camunda:out source="FH_ErrorResponse" target="FH_ErrorResponse" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_0807ukc</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_19yywk8</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:endEvent id="EndEvent_04xute7">\r
- <bpmn2:incoming>SequenceFlow_19yywk8</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:inclusiveGateway id="InclusiveGateway_1pqjttt">\r
- <bpmn2:incoming>SequenceFlow_19mxskt</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1brxd2r</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_08s0ew2</bpmn2:outgoing>\r
- </bpmn2:inclusiveGateway>\r
- <bpmn2:scriptTask id="ScriptTask_0yk02h3" name="Prepare FalloutHandler" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0jg47xm</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0807ukc</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.prepareVnfAndModulesCreate(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_4" name="GoToFinishProcess">
+ <bpmn2:incoming>SequenceFlow_0xowenu</bpmn2:incoming>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_41" name="FinishProcess" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_2" name="GoTovIPR-ATM">
+ <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_38" name="vIPR-ATM" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:subProcess id="SubProcess_0s6hpty" name="Subprocess For Exception / FalloutHandler " triggeredByEvent="true">
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1vwgs6p" name="Is Rollback On?" default="SequenceFlow_0dhf2js">
+ <bpmn2:incoming>SequenceFlow_0zq7i3q</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0zpbskl</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0dhf2js</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:startEvent id="StartEvent_1bwmffk" name="Fault Start">
+ <bpmn2:outgoing>SequenceFlow_0zq7i3q</bpmn2:outgoing>
+ <bpmn2:errorEventDefinition />
+ </bpmn2:startEvent>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0ydrtdx" name="isPONR?" default="SequenceFlow_02o4yqx">
+ <bpmn2:incoming>SequenceFlow_0zpbskl</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1sx5llu</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_02o4yqx</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_00rt5qa" name="is VNF Ok?" default="SequenceFlow_05lo85t">
+ <bpmn2:incoming>SequenceFlow_0sdb3on</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_05lo85t</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0xtr1g5</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1kvn1pz" name="Network Rollback present?" default="SequenceFlow_19mxskt">
+ <bpmn2:incoming>SequenceFlow_05lo85t</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_09xerwk</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_19mxskt</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0tmepzk</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:callActivity id="CallActivity_0jw5tqa" name="Call FalloutHandlerV1" calledElement="FalloutHandler">
+ <bpmn2:extensionElements>
+ <camunda:in source="CGMSNV_falloutRequest" target="FalloutHandlerRequest" />
+ <camunda:in source="msoRequestId" target="mso-request-id" />
+ <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />
+ <camunda:out source="FH_ResponseCode" target="FH_ResponseCode" />
+ <camunda:out source="FalloutHandlerResponse" target="FalloutHandlerResponse" />
+ <camunda:out source="FH_ErrorResponse" target="FH_ErrorResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0807ukc</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_19yywk8</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:endEvent id="EndEvent_04xute7">
+ <bpmn2:incoming>SequenceFlow_19yywk8</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:inclusiveGateway id="InclusiveGateway_1pqjttt">
+ <bpmn2:incoming>SequenceFlow_19mxskt</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1brxd2r</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_08s0ew2</bpmn2:outgoing>
+ </bpmn2:inclusiveGateway>
+ <bpmn2:scriptTask id="ScriptTask_0yk02h3" name="Prepare FalloutHandler" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0jg47xm</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0807ukc</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.prepareFalloutRequest(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0zpbskl" name="Yes" sourceRef="ExclusiveGateway_1vwgs6p" targetRef="ExclusiveGateway_0ydrtdx">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("disableRollback") != true}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0dhf2js" name="No" sourceRef="ExclusiveGateway_1vwgs6p" targetRef="InclusiveGateway_0foywso" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1sx5llu" name="Yes" sourceRef="ExclusiveGateway_0ydrtdx" targetRef="InclusiveGateway_0foywso">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("PONR") == true}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_02o4yqx" name="No" sourceRef="ExclusiveGateway_0ydrtdx" targetRef="ScriptTask_17doerz" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_05lo85t" name="No" sourceRef="ExclusiveGateway_00rt5qa" targetRef="ExclusiveGateway_1kvn1pz" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0xtr1g5" name="Yes" sourceRef="ExclusiveGateway_00rt5qa" targetRef="DoRollbackVNFandModules_CallActivity">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DCVM_rollbackData") != null }]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_19mxskt" name="No" sourceRef="ExclusiveGateway_1kvn1pz" targetRef="InclusiveGateway_1pqjttt" />\r
- <bpmn2:callActivity id="DoRollbackVNFandModules_CallActivity" name="DoRollback VNF and Modules " calledElement="DoCreateVnfAndModules">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:in source="DCVAM_rollbackData" target="rollbackData" />\r
- <camunda:out source="rollbackSuccessful" target="DCVAM_rollbackSuccessful" />\r
- <camunda:out source="rollbackError" target="DCVAM_rollbackError" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_0xtr1g5</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_09xerwk</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:sequenceFlow id="SequenceFlow_09xerwk" sourceRef="DoRollbackVNFandModules_CallActivity" targetRef="ExclusiveGateway_1kvn1pz" />\r
- <bpmn2:callActivity id="DoRollbackNetwork_CallActivity" name="DoRollback Network" calledElement="DoCreateNetworkInstanceRollback">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:in source="DCRENI_rollbackData" target="rollbackData" />\r
- <camunda:out source="rollbackSuccessful" target="DCRENI_rollbackSuccessful" />\r
- <camunda:out source="rollbackError" target="DCRENI_rollbackError" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_0136s37</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1fqmrda</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1dmsx0d</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_09o09bu" name="Network rolled back OK?" default="SequenceFlow_0g7scsg">\r
- <bpmn2:incoming>SequenceFlow_1ieiew4</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1os9x7w</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0g7scsg</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:callActivity id="DoRollbackService_CallActivity" name="DoRollback Service " calledElement="DoCreateServiceInstanceRollback">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="DCRESI_rollbackData" target="rollbackData" />\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:out source="rollbackSuccessful" target="DCRESI_rollbackSuccessful" />\r
- <camunda:out source="rollbackError" target="DCRESI_rollbackError" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1os9x7w</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1f1hd3l</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:inclusiveGateway id="InclusiveGateway_0foywso">\r
- <bpmn2:incoming>SequenceFlow_1sx5llu</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0dhf2js</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1rabks0</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0jg47xm</bpmn2:outgoing>\r
- </bpmn2:inclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1os9x7w" name="Yes" sourceRef="ExclusiveGateway_09o09bu" targetRef="DoRollbackService_CallActivity">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("DCRENI_rollbackSuccessful") == null || execution.getVariable("DCRENI_rollbackSuccessful") == true }]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1f1hd3l" sourceRef="DoRollbackService_CallActivity" targetRef="InclusiveGateway_0m9f5ka" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0g7scsg" name="No" sourceRef="ExclusiveGateway_09o09bu" targetRef="InclusiveGateway_0m9f5ka" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0jg47xm" sourceRef="InclusiveGateway_0foywso" targetRef="ScriptTask_0yk02h3" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0807ukc" sourceRef="ScriptTask_0yk02h3" targetRef="CallActivity_0jw5tqa" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_19yywk8" sourceRef="CallActivity_0jw5tqa" targetRef="EndEvent_04xute7" />\r
- <bpmn2:scriptTask id="ScriptTask_184teky" name="Validate Network Rollback" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1dmsx0d</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1otyild</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.prepareFalloutRequest(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_0zpbskl" name="Yes" sourceRef="ExclusiveGateway_1vwgs6p" targetRef="ExclusiveGateway_0ydrtdx">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("disableRollback") != true}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0dhf2js" name="No" sourceRef="ExclusiveGateway_1vwgs6p" targetRef="InclusiveGateway_0foywso" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1sx5llu" name="Yes" sourceRef="ExclusiveGateway_0ydrtdx" targetRef="InclusiveGateway_0foywso">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("PONR") == true}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_02o4yqx" name="No" sourceRef="ExclusiveGateway_0ydrtdx" targetRef="ScriptTask_17doerz" />
+ <bpmn2:sequenceFlow id="SequenceFlow_05lo85t" name="No" sourceRef="ExclusiveGateway_00rt5qa" targetRef="ExclusiveGateway_1kvn1pz" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0xtr1g5" name="Yes" sourceRef="ExclusiveGateway_00rt5qa" targetRef="DoRollbackVNFandModules_CallActivity">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DCVM_rollbackData") != null }]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_19mxskt" name="No" sourceRef="ExclusiveGateway_1kvn1pz" targetRef="InclusiveGateway_1pqjttt" />
+ <bpmn2:callActivity id="DoRollbackVNFandModules_CallActivity" name="DoRollback VNF and Modules " calledElement="DoCreateVnfAndModulesRollback">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="DCVAM_rollbackData" target="rollbackData" />
+ <camunda:out source="rollbackSuccessful" target="DCVAM_rollbackSuccessful" />
+ <camunda:out source="rollbackError" target="DCVAM_rollbackError" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0xtr1g5</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_09xerwk</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_09xerwk" sourceRef="DoRollbackVNFandModules_CallActivity" targetRef="ExclusiveGateway_1kvn1pz" />
+ <bpmn2:callActivity id="DoRollbackNetwork_CallActivity" name="DoRollback Network" calledElement="DoCreateNetworkInstanceRollback">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="DCRENI_rollbackData" target="rollbackData" />
+ <camunda:out source="rollbackSuccessful" target="DCRENI_rollbackSuccessful" />
+ <camunda:out source="rollbackError" target="DCRENI_rollbackError" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0136s37</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1fqmrda</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1dmsx0d</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_09o09bu" name="Network rolled back OK?" default="SequenceFlow_0g7scsg">
+ <bpmn2:incoming>SequenceFlow_1ieiew4</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1os9x7w</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0g7scsg</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:callActivity id="DoRollbackService_CallActivity" name="DoRollback Service " calledElement="DoCreateServiceInstanceRollback">
+ <bpmn2:extensionElements>
+ <camunda:in source="DCRESI_rollbackData" target="rollbackData" />
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:out source="rollbackSuccessful" target="DCRESI_rollbackSuccessful" />
+ <camunda:out source="rollbackError" target="DCRESI_rollbackError" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1os9x7w</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1f1hd3l</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:inclusiveGateway id="InclusiveGateway_0foywso">
+ <bpmn2:incoming>SequenceFlow_1sx5llu</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0dhf2js</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1rabks0</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0jg47xm</bpmn2:outgoing>
+ </bpmn2:inclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_1os9x7w" name="Yes" sourceRef="ExclusiveGateway_09o09bu" targetRef="DoRollbackService_CallActivity">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("DCRENI_rollbackSuccessful") == null || execution.getVariable("DCRENI_rollbackSuccessful") == true }]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_1f1hd3l" sourceRef="DoRollbackService_CallActivity" targetRef="InclusiveGateway_0m9f5ka" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0g7scsg" name="No" sourceRef="ExclusiveGateway_09o09bu" targetRef="InclusiveGateway_0m9f5ka" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0jg47xm" sourceRef="InclusiveGateway_0foywso" targetRef="ScriptTask_0yk02h3" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0807ukc" sourceRef="ScriptTask_0yk02h3" targetRef="CallActivity_0jw5tqa" />
+ <bpmn2:sequenceFlow id="SequenceFlow_19yywk8" sourceRef="CallActivity_0jw5tqa" targetRef="EndEvent_04xute7" />
+ <bpmn2:scriptTask id="ScriptTask_184teky" name="Validate Network Rollback" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1dmsx0d</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1otyild</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.validateNetworkRollback(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1c386z9" name="Rollback Additional Networks?" default="SequenceFlow_12u8ufr">\r
- <bpmn2:incoming>SequenceFlow_1otyild</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0136s37</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_12u8ufr</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1dmsx0d" sourceRef="DoRollbackNetwork_CallActivity" targetRef="ScriptTask_184teky" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1otyild" sourceRef="ScriptTask_184teky" targetRef="ExclusiveGateway_1c386z9" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0136s37" name="Yes" sourceRef="ExclusiveGateway_1c386z9" targetRef="DoRollbackNetwork_CallActivity">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CREVAS_NetworksCreatedCount") > 0 }]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_12u8ufr" name="No" sourceRef="ExclusiveGateway_1c386z9" targetRef="ExclusiveGateway_05indeh" />\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1bts0nw" name="VNF rolled back OK?" default="SequenceFlow_1brxd2r">\r
- <bpmn2:incoming>SequenceFlow_0tmepzk</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1fqmrda</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1brxd2r</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0tmepzk" name="Yes" sourceRef="ExclusiveGateway_1kvn1pz" targetRef="ExclusiveGateway_1bts0nw">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("DCRENI_rollbackData") != null }]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1fqmrda" name="Yes" sourceRef="ExclusiveGateway_1bts0nw" targetRef="DoRollbackNetwork_CallActivity">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("DCVAM_rollbackSuccessful") == null || execution.getVariable("DCVAM_rollbackSuccessful") == true }]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1brxd2r" name="No" sourceRef="ExclusiveGateway_1bts0nw" targetRef="InclusiveGateway_1pqjttt" />\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_05indeh" name="Service Rollback present?" default="SequenceFlow_0sezboq">\r
- <bpmn2:incoming>SequenceFlow_12u8ufr</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_08s0ew2</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1ieiew4</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0sezboq</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_08s0ew2" sourceRef="InclusiveGateway_1pqjttt" targetRef="ExclusiveGateway_05indeh" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1ieiew4" name="Yes" sourceRef="ExclusiveGateway_05indeh" targetRef="ExclusiveGateway_09o09bu">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("DCRESI_rollbackData") != null }]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0sezboq" name="No" sourceRef="ExclusiveGateway_05indeh" targetRef="InclusiveGateway_0m9f5ka" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0zq7i3q" name="" sourceRef="StartEvent_1bwmffk" targetRef="ExclusiveGateway_1vwgs6p" />\r
- <bpmn2:inclusiveGateway id="InclusiveGateway_0m9f5ka">\r
- <bpmn2:incoming>SequenceFlow_1f1hd3l</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0g7scsg</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0sezboq</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0f4u373</bpmn2:outgoing>\r
- </bpmn2:inclusiveGateway>\r
- <bpmn2:scriptTask id="ScriptTask_17doerz" name="Pre Process Rollback" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_02o4yqx</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0sdb3on</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.validateNetworkRollback(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1c386z9" name="Rollback Additional Networks?" default="SequenceFlow_12u8ufr">
+ <bpmn2:incoming>SequenceFlow_1otyild</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0136s37</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_12u8ufr</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_1dmsx0d" sourceRef="DoRollbackNetwork_CallActivity" targetRef="ScriptTask_184teky" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1otyild" sourceRef="ScriptTask_184teky" targetRef="ExclusiveGateway_1c386z9" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0136s37" name="Yes" sourceRef="ExclusiveGateway_1c386z9" targetRef="DoRollbackNetwork_CallActivity">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CGMSNV_NetworksCreatedCount") > 0 }]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_12u8ufr" name="No" sourceRef="ExclusiveGateway_1c386z9" targetRef="ExclusiveGateway_05indeh" />
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1bts0nw" name="VNF rolled back OK?" default="SequenceFlow_1brxd2r">
+ <bpmn2:incoming>SequenceFlow_0tmepzk</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1fqmrda</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1brxd2r</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_0tmepzk" name="Yes" sourceRef="ExclusiveGateway_1kvn1pz" targetRef="ExclusiveGateway_1bts0nw">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("DCRENI_rollbackData") != null }]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_1fqmrda" name="Yes" sourceRef="ExclusiveGateway_1bts0nw" targetRef="DoRollbackNetwork_CallActivity">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("DCVAM_rollbackSuccessful") == null || execution.getVariable("DCVAM_rollbackSuccessful") == true }]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_1brxd2r" name="No" sourceRef="ExclusiveGateway_1bts0nw" targetRef="InclusiveGateway_1pqjttt" />
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_05indeh" name="Service Rollback present?" default="SequenceFlow_0sezboq">
+ <bpmn2:incoming>SequenceFlow_12u8ufr</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_08s0ew2</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1ieiew4</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0sezboq</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_08s0ew2" sourceRef="InclusiveGateway_1pqjttt" targetRef="ExclusiveGateway_05indeh" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1ieiew4" name="Yes" sourceRef="ExclusiveGateway_05indeh" targetRef="ExclusiveGateway_09o09bu">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("DCRESI_rollbackData") != null }]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0sezboq" name="No" sourceRef="ExclusiveGateway_05indeh" targetRef="InclusiveGateway_0m9f5ka" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0zq7i3q" name="" sourceRef="StartEvent_1bwmffk" targetRef="ExclusiveGateway_1vwgs6p" />
+ <bpmn2:inclusiveGateway id="InclusiveGateway_0m9f5ka">
+ <bpmn2:incoming>SequenceFlow_1f1hd3l</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0g7scsg</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0sezboq</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0f4u373</bpmn2:outgoing>
+ </bpmn2:inclusiveGateway>
+ <bpmn2:scriptTask id="ScriptTask_17doerz" name="Pre Process Rollback" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_02o4yqx</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0sdb3on</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.preProcessRollback(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:scriptTask id="ScriptTask_0wyub4x" name="Post Process Rollback" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0f4u373</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1rabks0</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.preProcessRollback(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:scriptTask id="ScriptTask_0wyub4x" name="Post Process Rollback" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0f4u373</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1rabks0</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.postProcessRollback(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0sdb3on" sourceRef="ScriptTask_17doerz" targetRef="ExclusiveGateway_00rt5qa" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0f4u373" sourceRef="InclusiveGateway_0m9f5ka" targetRef="ScriptTask_0wyub4x" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1rabks0" sourceRef="ScriptTask_0wyub4x" targetRef="InclusiveGateway_0foywso" />\r
- </bpmn2:subProcess>\r
- <bpmn2:scriptTask id="callDbCatalog_scriptTask" name="Get Models Info for Service (DB Catalog) " scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1vwssu7</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_19etqmx</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.postProcessRollback(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_0sdb3on" sourceRef="ScriptTask_17doerz" targetRef="ExclusiveGateway_00rt5qa" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0f4u373" sourceRef="InclusiveGateway_0m9f5ka" targetRef="ScriptTask_0wyub4x" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1rabks0" sourceRef="ScriptTask_0wyub4x" targetRef="InclusiveGateway_0foywso" />
+ </bpmn2:subProcess>
+ <bpmn2:scriptTask id="callDbCatalog_scriptTask" name="Get Models Info for Service " scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1vwssu7</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_19etqmx</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.callDBCatalog(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:scriptTask id="prepareCreateService_scriptTask" name="Prepare Create Service " scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_10o22u2</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0j6sjye</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.getDataFromDecomposition(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:scriptTask id="prepareCreateService_scriptTask" name="Prepare Create Service " scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0hvcwa1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0j6sjye</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.prepareCreateServiceInstance(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_10o22u2" sourceRef="IntermediateCatchEvent_3" targetRef="prepareCreateService_scriptTask" />\r
- <bpmn2:scriptTask id="setPONR_ScriptTask" name="set PONR">\r
- <bpmn2:incoming>SequenceFlow_12ilko1</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0afe2pg</bpmn2:outgoing>\r
- <bpmn2:script><![CDATA[#{execution.setVariable("PONR", true)}]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_12ilko1" sourceRef="IntermediateCatchEvent_4" targetRef="setPONR_ScriptTask" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0afe2pg" sourceRef="setPONR_ScriptTask" targetRef="postProcessAndCompletionRequest_ScriptTask" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1bwbn7r" sourceRef="ScriptTask_PrepareNetworkCreate" targetRef="doCreateNetworkInstance_CallActivity" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1n7r495" name="No" sourceRef="ExclusiveGateway_0fe690i" targetRef="ExclusiveGateway_1os8cm5" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1h77psn" sourceRef="ScriptTask_3" targetRef="doCreateVNFandModules_CallActivity" />\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_1nh09nr" name="StartNetworks">\r
- <bpmn2:outgoing>SequenceFlow_1vwssu7</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition name="StartNetworks" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0prlju0" name="GoTo StartNetworks">\r
- <bpmn2:incoming>SequenceFlow_13uceka</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition name="StartNetworks" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_0b9wd4f" name="Create Network(s)?" default="SequenceFlow_1f26zbk">\r
- <bpmn2:incoming>SequenceFlow_19etqmx</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0cmebdc</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1f26zbk</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_0fe690i" name="Create Additional Networks?" default="SequenceFlow_1n7r495">\r
- <bpmn2:incoming>SequenceFlow_04vlq8r</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1n7r495</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0dfkfh1</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0dfkfh1" name="Yes" sourceRef="ExclusiveGateway_0fe690i" targetRef="ScriptTask_PrepareNetworkCreate">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CREVAS_NetworksCreatedCount") < execution.getVariable("CREVAS_NetworksCount")}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0cmebdc" name="Yes" sourceRef="ExclusiveGateway_0b9wd4f" targetRef="ScriptTask_PrepareNetworkCreate">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CREVAS_NetworksCount") > 0}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1os8cm5">\r
- <bpmn2:incoming>SequenceFlow_1n7r495</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1f26zbk</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1j7n6qx</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1f26zbk" name="No" sourceRef="ExclusiveGateway_0b9wd4f" targetRef="ExclusiveGateway_1os8cm5" />\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0nreq15" name="GoTo StartVnfs">\r
- <bpmn2:incoming>SequenceFlow_1j7n6qx</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition name="StartVnfs" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1vwssu7" sourceRef="IntermediateCatchEvent_1nh09nr" targetRef="callDbCatalog_scriptTask" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_19etqmx" sourceRef="callDbCatalog_scriptTask" targetRef="ExclusiveGateway_0b9wd4f" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1j7n6qx" sourceRef="ExclusiveGateway_1os8cm5" targetRef="IntermediateThrowEvent_0nreq15" />\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_0rlqdvq" name="StartVnfs">\r
- <bpmn2:outgoing>SequenceFlow_10tbv62</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition name="StartVnfs" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1nlocis" name="Create VNF?" default="SequenceFlow_0w7328u">\r
- <bpmn2:incoming>SequenceFlow_10tbv62</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0bvecvm</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0w7328u</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_04q1qud">\r
- <bpmn2:incoming>SequenceFlow_0qi5uxg</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0w7328u</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0xowenu</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_10tbv62" sourceRef="IntermediateCatchEvent_0rlqdvq" targetRef="ExclusiveGateway_1nlocis" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0bvecvm" name="Yes" sourceRef="ExclusiveGateway_1nlocis" targetRef="ScriptTask_3">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CREVAS_VNFsCount") >0}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0qi5uxg" name="in 1702 scope only one VNF will be created - if needed" sourceRef="doCreateVNFandModules_CallActivity" targetRef="ExclusiveGateway_04q1qud">\r
- <bpmn2:documentation>in 1702 scope only one VNF will be created</bpmn2:documentation>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0w7328u" name="No" sourceRef="ExclusiveGateway_1nlocis" targetRef="ExclusiveGateway_04q1qud" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0xowenu" sourceRef="ExclusiveGateway_04q1qud" targetRef="IntermediateThrowEvent_4" />\r
- <bpmn2:scriptTask id="ScriptTask_04o8gb3" name="Validate Network Create" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_12ag2bk</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_04vlq8r</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.prepareCreateServiceInstance(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:scriptTask id="setPONR_ScriptTask" name="set PONR">
+ <bpmn2:incoming>SequenceFlow_12ilko1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0afe2pg</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[#{execution.setVariable("PONR", true)}]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_12ilko1" sourceRef="IntermediateCatchEvent_4" targetRef="setPONR_ScriptTask" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0afe2pg" sourceRef="setPONR_ScriptTask" targetRef="postProcessAndCompletionRequest_ScriptTask" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1bwbn7r" sourceRef="ScriptTask_PrepareNetworkCreate" targetRef="doCreateNetworkInstance_CallActivity" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1n7r495" name="No" sourceRef="ExclusiveGateway_0fe690i" targetRef="ExclusiveGateway_1os8cm5" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1h77psn" sourceRef="ScriptTask_3" targetRef="doCreateVNFandModules_CallActivity" />
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_1nh09nr" name="StartNetworks">
+ <bpmn2:outgoing>SequenceFlow_1vwssu7</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition name="StartNetworks" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0prlju0" name="GoTo StartNetworks">
+ <bpmn2:incoming>SequenceFlow_13uceka</bpmn2:incoming>
+ <bpmn2:linkEventDefinition name="StartNetworks" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0b9wd4f" name="Create Network(s)?" default="SequenceFlow_1f26zbk">
+ <bpmn2:incoming>SequenceFlow_19etqmx</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0cmebdc</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1f26zbk</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0fe690i" name="Create Additional Networks?" default="SequenceFlow_1n7r495">
+ <bpmn2:incoming>SequenceFlow_04vlq8r</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1n7r495</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0dfkfh1</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_0dfkfh1" name="Yes" sourceRef="ExclusiveGateway_0fe690i" targetRef="ScriptTask_PrepareNetworkCreate">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CGMSNV_NetworksCreatedCount") < execution.getVariable("CGMSNV_NetworksCount")}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0cmebdc" name="Yes" sourceRef="ExclusiveGateway_0b9wd4f" targetRef="ScriptTask_PrepareNetworkCreate">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CGMSNV_NetworksCount") > 0}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1os8cm5">
+ <bpmn2:incoming>SequenceFlow_1n7r495</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1f26zbk</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1j7n6qx</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_1f26zbk" name="No" sourceRef="ExclusiveGateway_0b9wd4f" targetRef="ExclusiveGateway_1os8cm5" />
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0nreq15" name="GoTo StartVnfs">
+ <bpmn2:incoming>SequenceFlow_1j7n6qx</bpmn2:incoming>
+ <bpmn2:linkEventDefinition name="StartVnfs" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_1vwssu7" sourceRef="IntermediateCatchEvent_1nh09nr" targetRef="callDbCatalog_scriptTask" />
+ <bpmn2:sequenceFlow id="SequenceFlow_19etqmx" sourceRef="callDbCatalog_scriptTask" targetRef="ExclusiveGateway_0b9wd4f" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1j7n6qx" sourceRef="ExclusiveGateway_1os8cm5" targetRef="IntermediateThrowEvent_0nreq15" />
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_0rlqdvq" name="StartVnfs">
+ <bpmn2:outgoing>SequenceFlow_10tbv62</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition name="StartVnfs" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1nlocis" name="Create VNF?" default="SequenceFlow_0w7328u">
+ <bpmn2:incoming>SequenceFlow_10tbv62</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0bvecvm</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0w7328u</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_04q1qud">
+ <bpmn2:incoming>SequenceFlow_0qi5uxg</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0w7328u</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0xowenu</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_10tbv62" sourceRef="IntermediateCatchEvent_0rlqdvq" targetRef="ExclusiveGateway_1nlocis" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0bvecvm" name="Yes" sourceRef="ExclusiveGateway_1nlocis" targetRef="ScriptTask_3">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CGMSNV_VNFsCount") >0}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0qi5uxg" name="in 1702 scope only one VNF will be created - if needed" sourceRef="doCreateVNFandModules_CallActivity" targetRef="ExclusiveGateway_04q1qud">
+ <bpmn2:documentation>in 1702 scope only one VNF will be created</bpmn2:documentation>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0w7328u" name="No" sourceRef="ExclusiveGateway_1nlocis" targetRef="ExclusiveGateway_04q1qud" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0xowenu" sourceRef="ExclusiveGateway_04q1qud" targetRef="IntermediateThrowEvent_4" />
+ <bpmn2:scriptTask id="ScriptTask_04o8gb3" name="Validate Network Create" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_12ag2bk</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_04vlq8r</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.validateNetworkCreate(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_12ag2bk" sourceRef="doCreateNetworkInstance_CallActivity" targetRef="ScriptTask_04o8gb3" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_04vlq8r" sourceRef="ScriptTask_04o8gb3" targetRef="ExclusiveGateway_0fe690i" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0j6sjye" sourceRef="prepareCreateService_scriptTask" targetRef="doCreateServiceInstance_CallActivity" />\r
- <bpmn2:serviceTask id="updateInfraRequest" name="Update DB status to SUCCESS">\r
- <bpmn2:extensionElements>\r
- <camunda:connector>\r
- <camunda:inputOutput>\r
- <camunda:inputParameter name="url">${URN_mso_adapters_db_endpoint}</camunda:inputParameter>\r
- <camunda:inputParameter name="payload"><![CDATA[${execution.getVariable("CREVAS_setUpdateDbInstancePayload")}]]></camunda:inputParameter>\r
- <camunda:inputParameter name="headers">\r
- <camunda:map>\r
- <camunda:entry key="content-type">application/soap+xml</camunda:entry>\r
- </camunda:map>\r
- </camunda:inputParameter>\r
- <camunda:inputParameter name="method">POST</camunda:inputParameter>\r
- </camunda:inputOutput>\r
- <camunda:connectorId>soap-http-connector</camunda:connectorId>\r
- </camunda:connector>\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_0vj46ej</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_13uceka</bpmn2:outgoing>\r
- </bpmn2:serviceTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_13uceka" sourceRef="updateInfraRequest" targetRef="IntermediateThrowEvent_0prlju0" />\r
- <bpmn2:scriptTask id="ScriptTask_1qd3uwb" name="PostProcess Create Service " scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1ky2sv9</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0vj46ej</bpmn2:outgoing>\r
+def CreateGenericMacroServiceNetworkVnf= new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.validateNetworkCreate(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_12ag2bk" sourceRef="doCreateNetworkInstance_CallActivity" targetRef="ScriptTask_04o8gb3" />
+ <bpmn2:sequenceFlow id="SequenceFlow_04vlq8r" sourceRef="ScriptTask_04o8gb3" targetRef="ExclusiveGateway_0fe690i" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0j6sjye" sourceRef="prepareCreateService_scriptTask" targetRef="doCreateServiceInstance_CallActivity" />
+ <bpmn2:serviceTask id="updateInfraRequest" name="Update DB status to SUCCESS">
+ <bpmn2:extensionElements>
+ <camunda:connector>
+ <camunda:inputOutput>
+ <camunda:inputParameter name="url">${URN_mso_adapters_db_endpoint}</camunda:inputParameter>
+ <camunda:inputParameter name="payload"><![CDATA[${execution.getVariable("CGMSNV_setUpdateDbInstancePayload")}]]></camunda:inputParameter>
+ <camunda:inputParameter name="headers">
+ <camunda:map>
+ <camunda:entry key="content-type">application/soap+xml</camunda:entry>
+ </camunda:map>
+ </camunda:inputParameter>
+ <camunda:inputParameter name="method">POST</camunda:inputParameter>
+ </camunda:inputOutput>
+ <camunda:connectorId>soap-http-connector</camunda:connectorId>
+ </camunda:connector>
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0vj46ej</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_13uceka</bpmn2:outgoing>
+ </bpmn2:serviceTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_13uceka" sourceRef="updateInfraRequest" targetRef="IntermediateThrowEvent_0prlju0" />
+ <bpmn2:scriptTask id="ScriptTask_1qd3uwb" name="PostProcess Create Service " scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1ky2sv9</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0vj46ej</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()\r
-CreateGenericMacroServiceNetworkVnf.postProcessServiceInstanceCreate(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1ky2sv9" sourceRef="doCreateServiceInstance_CallActivity" targetRef="ScriptTask_1qd3uwb" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0vj46ej" sourceRef="ScriptTask_1qd3uwb" targetRef="updateInfraRequest" />\r
- </bpmn2:process>\r
- <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />\r
- <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />\r
- <bpmndi:BPMNDiagram id="BPMNDiagram_1">\r
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="CreateGenericMacroServiceNetworkVnf">\r
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createVIPR_startEvent">\r
- <dc:Bounds x="96" y="90" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="82" y="131" width="65" height="22" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">\r
- <dc:Bounds x="285" y="68" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">\r
- <di:waypoint xsi:type="dc:Point" x="132" y="108" />\r
- <di:waypoint xsi:type="dc:Point" x="285" y="108" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="171" y="108" width="6" height="6" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_4" bpmnElement="callCompleteMsoProcess_CallActivity">\r
- <dc:Bounds x="787" y="1115" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_80" bpmnElement="postProcessAndCompletionRequest_ScriptTask">\r
- <dc:Bounds x="514" y="1115" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_61" targetElement="_BPMNShape_ScriptTask_127">\r
- <di:waypoint xsi:type="dc:Point" x="385" y="108" />\r
- <di:waypoint xsi:type="dc:Point" x="476" y="108" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="271" y="69" width="6" height="6" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_127" bpmnElement="sendSyncAckResponse_ScriptTask">\r
- <dc:Bounds x="476" y="68" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_42" bpmnElement="SequenceFlow_29" sourceElement="_BPMNShape_ScriptTask_80" targetElement="_BPMNShape_CallActivity_4">\r
- <di:waypoint xsi:type="dc:Point" x="614" y="1155" />\r
- <di:waypoint xsi:type="dc:Point" x="787" y="1155" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="701" y="1140" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="CreateVIPR_EndEvent">\r
- <dc:Bounds x="1286" y="1135" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1294" y="1176" width="20" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_CallActivity_4" targetElement="_BPMNShape_ScriptTask_337">\r
- <di:waypoint xsi:type="dc:Point" x="887" y="1155" />\r
- <di:waypoint xsi:type="dc:Point" x="1095" y="1154" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="991" y="1140" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_SubProcess_27" bpmnElement="UnexpectedError_SubProcess_1" isExpanded="true">\r
- <dc:Bounds x="1281" y="1385" width="409" height="232" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_70" bpmnElement="StartEvent_1">\r
- <dc:Bounds x="1349" y="1490" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1367" y="1531" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_269" bpmnElement="ScriptTask_1">\r
- <dc:Bounds x="1424" y="1468" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_219" bpmnElement="EndEvent_1">\r
- <dc:Bounds x="1577" y="1490" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1595" y="1531" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_StartEvent_70" targetElement="_BPMNShape_ScriptTask_269">\r
- <di:waypoint xsi:type="dc:Point" x="1385" y="1508" />\r
- <di:waypoint xsi:type="dc:Point" x="1424" y="1508" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1413" y="1508" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_5" sourceElement="_BPMNShape_ScriptTask_269" targetElement="_BPMNShape_EndEvent_219">\r
- <di:waypoint xsi:type="dc:Point" x="1524" y="1508" />\r
- <di:waypoint xsi:type="dc:Point" x="1557" y="1508" />\r
- <di:waypoint xsi:type="dc:Point" x="1557" y="1508" />\r
- <di:waypoint xsi:type="dc:Point" x="1577" y="1508" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1572" y="1508" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_75" bpmnElement="doCreateServiceInstance_CallActivity">\r
- <dc:Bounds x="476" y="223" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_127">\r
- <di:waypoint xsi:type="dc:Point" x="576" y="108" />\r
- <di:waypoint xsi:type="dc:Point" x="728" y="108" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="652" y="93" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_337" bpmnElement="ScriptTask_2">\r
- <dc:Bounds x="1095" y="1114" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_ScriptTask_337" targetElement="_BPMNShape_EndEvent_177">\r
- <di:waypoint xsi:type="dc:Point" x="1195" y="1153" />\r
- <di:waypoint xsi:type="dc:Point" x="1286" y="1153" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1241" y="1138" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_76" bpmnElement="doCreateNetworkInstance_CallActivity">\r
- <dc:Bounds x="542" y="491" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_35" bpmnElement="IntermediateCatchEvent_3">\r
- <dc:Bounds x="96" y="245" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="88" y="281" width="51" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_36" bpmnElement="IntermediateCatchEvent_4">\r
- <dc:Bounds x="84" y="1137" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="66" y="1173" width="71" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_51" bpmnElement="IntermediateThrowEvent_4">\r
- <dc:Bounds x="1033" y="854" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1008" y="895" width="85" height="26" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_341" bpmnElement="ScriptTask_PrepareNetworkCreate">\r
- <dc:Bounds x="400" y="488" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_342" bpmnElement="ScriptTask_3">\r
- <dc:Bounds x="456" y="765" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_81" bpmnElement="doCreateVNFandModules_CallActivity">\r
- <dc:Bounds x="623" y="765" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_49" bpmnElement="IntermediateThrowEvent_2">\r
- <dc:Bounds x="728" y="90" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="707" y="131" width="77" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="SubProcess_0s6hpty_di" bpmnElement="SubProcess_0s6hpty" isExpanded="true">\r
- <dc:Bounds x="-75" y="1333" width="1324" height="837" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1vwgs6p_di" bpmnElement="ExclusiveGateway_1vwgs6p" isMarkerVisible="true">\r
- <dc:Bounds x="79" y="2042" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="66" y="2102" width="80" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="StartEvent_1bwmffk_di" bpmnElement="StartEvent_1bwmffk">\r
- <dc:Bounds x="-34" y="2050" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="-40" y="2091" width="50" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_0ydrtdx_di" bpmnElement="ExclusiveGateway_0ydrtdx" isMarkerVisible="true">\r
- <dc:Bounds x="79" y="1935" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="13" y="1950" width="47" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_00rt5qa_di" bpmnElement="ExclusiveGateway_00rt5qa" isMarkerVisible="true">\r
- <dc:Bounds x="79" y="1625" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="5" y="1640" width="57" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1kvn1pz_di" bpmnElement="ExclusiveGateway_1kvn1pz" isMarkerVisible="true">\r
- <dc:Bounds x="206" y="1505" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="188" y="1471" width="89" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="CallActivity_0jw5tqa_di" bpmnElement="CallActivity_0jw5tqa">\r
- <dc:Bounds x="1052" y="2016" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="EndEvent_04xute7_di" bpmnElement="EndEvent_04xute7">\r
- <dc:Bounds x="1189" y="2038" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1207" y="2079" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="InclusiveGateway_1pqjttt_di" bpmnElement="InclusiveGateway_1pqjttt">\r
- <dc:Bounds x="303" y="1625" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="328" y="1680" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_0yk02h3_di" bpmnElement="ScriptTask_0yk02h3">\r
- <dc:Bounds x="920" y="2016" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0zpbskl_di" bpmnElement="SequenceFlow_0zpbskl">\r
- <di:waypoint xsi:type="dc:Point" x="104" y="2042" />\r
- <di:waypoint xsi:type="dc:Point" x="104" y="1985" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="110" y="2023.785849077779" width="19" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0dhf2js_di" bpmnElement="SequenceFlow_0dhf2js">\r
- <di:waypoint xsi:type="dc:Point" x="129" y="2067" />\r
- <di:waypoint xsi:type="dc:Point" x="763" y="2067" />\r
- <di:waypoint xsi:type="dc:Point" x="763" y="1985" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="169" y="2072" width="14" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1sx5llu_di" bpmnElement="SequenceFlow_1sx5llu">\r
- <di:waypoint xsi:type="dc:Point" x="129" y="1960" />\r
- <di:waypoint xsi:type="dc:Point" x="434" y="1960" />\r
- <di:waypoint xsi:type="dc:Point" x="434" y="1960" />\r
- <di:waypoint xsi:type="dc:Point" x="738" y="1960" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="448" y="1964" width="19" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_02o4yqx_di" bpmnElement="SequenceFlow_02o4yqx">\r
- <di:waypoint xsi:type="dc:Point" x="104" y="1935" />\r
- <di:waypoint xsi:type="dc:Point" x="104" y="1851" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="115" y="1888.0011779924323" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_05lo85t_di" bpmnElement="SequenceFlow_05lo85t">\r
- <di:waypoint xsi:type="dc:Point" x="129" y="1650" />\r
- <di:waypoint xsi:type="dc:Point" x="231" y="1650" />\r
- <di:waypoint xsi:type="dc:Point" x="231" y="1555" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="133" y="1654" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0xtr1g5_di" bpmnElement="SequenceFlow_0xtr1g5">\r
- <di:waypoint xsi:type="dc:Point" x="104" y="1625" />\r
- <di:waypoint xsi:type="dc:Point" x="104" y="1570" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="113" y="1565" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_19mxskt_di" bpmnElement="SequenceFlow_19mxskt">\r
- <di:waypoint xsi:type="dc:Point" x="242" y="1544" />\r
- <di:waypoint xsi:type="dc:Point" x="317" y="1636" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="281" y="1572" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_0r7telk_di" bpmnElement="callDbCatalog_scriptTask">\r
- <dc:Bounds x="184" y="533" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_1gacz45_di" bpmnElement="prepareCreateService_scriptTask">\r
- <dc:Bounds x="285" y="223" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_10o22u2_di" bpmnElement="SequenceFlow_10o22u2">\r
- <di:waypoint xsi:type="dc:Point" x="132" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="285" y="262" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="209" y="247.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_11b4gmn_di" bpmnElement="setPONR_ScriptTask">\r
- <dc:Bounds x="228" y="1115" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_12ilko1_di" bpmnElement="SequenceFlow_12ilko1">\r
- <di:waypoint xsi:type="dc:Point" x="120" y="1155" />\r
- <di:waypoint xsi:type="dc:Point" x="228" y="1155" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="174" y="1130" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0afe2pg_di" bpmnElement="SequenceFlow_0afe2pg">\r
- <di:waypoint xsi:type="dc:Point" x="328" y="1155" />\r
- <di:waypoint xsi:type="dc:Point" x="471" y="1155" />\r
- <di:waypoint xsi:type="dc:Point" x="514" y="1155" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="400" y="1140" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="CallActivity_1cvt373_di" bpmnElement="DoRollbackVNFandModules_CallActivity">\r
- <dc:Bounds x="54" y="1490" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_09xerwk_di" bpmnElement="SequenceFlow_09xerwk">\r
- <di:waypoint xsi:type="dc:Point" x="154" y="1530" />\r
- <di:waypoint xsi:type="dc:Point" x="206" y="1530" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="180" y="1515" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="CallActivity_0zl1ald_di" bpmnElement="DoRollbackNetwork_CallActivity">\r
- <dc:Bounds x="404" y="1490" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_09o09bu_di" bpmnElement="ExclusiveGateway_09o09bu" isMarkerVisible="true">\r
- <dc:Bounds x="608" y="1625" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="596" y="1596" width="73" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="CallActivity_0oh7wzu_di" bpmnElement="DoRollbackService_CallActivity">\r
- <dc:Bounds x="713" y="1610" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="InclusiveGateway_0foywso_di" bpmnElement="InclusiveGateway_0foywso">\r
- <dc:Bounds x="738" y="1935" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="763" y="1990" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1os9x7w_di" bpmnElement="SequenceFlow_1os9x7w">\r
- <di:waypoint xsi:type="dc:Point" x="658" y="1650" />\r
- <di:waypoint xsi:type="dc:Point" x="713" y="1650" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="678" y="1635" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1f1hd3l_di" bpmnElement="SequenceFlow_1f1hd3l">\r
- <di:waypoint xsi:type="dc:Point" x="763" y="1690" />\r
- <di:waypoint xsi:type="dc:Point" x="763" y="1743" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="778" y="1716.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0g7scsg_di" bpmnElement="SequenceFlow_0g7scsg">\r
- <di:waypoint xsi:type="dc:Point" x="633" y="1675" />\r
- <di:waypoint xsi:type="dc:Point" x="633" y="1768" />\r
- <di:waypoint xsi:type="dc:Point" x="738" y="1768" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="641" y="1710.0295234297107" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0jg47xm_di" bpmnElement="SequenceFlow_0jg47xm">\r
- <di:waypoint xsi:type="dc:Point" x="788" y="1960" />\r
- <di:waypoint xsi:type="dc:Point" x="970" y="1960" />\r
- <di:waypoint xsi:type="dc:Point" x="970" y="2016" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="879" y="1945" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0807ukc_di" bpmnElement="SequenceFlow_0807ukc">\r
- <di:waypoint xsi:type="dc:Point" x="1020" y="2056" />\r
- <di:waypoint xsi:type="dc:Point" x="1052" y="2056" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1036" y="2041" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_19yywk8_di" bpmnElement="SequenceFlow_19yywk8">\r
- <di:waypoint xsi:type="dc:Point" x="1152" y="2056" />\r
- <di:waypoint xsi:type="dc:Point" x="1189" y="2056" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1171" y="2041" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1bwbn7r_di" bpmnElement="SequenceFlow_1bwbn7r">\r
- <di:waypoint xsi:type="dc:Point" x="500" y="530" />\r
- <di:waypoint xsi:type="dc:Point" x="542" y="529" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="521" y="514.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1n7r495_di" bpmnElement="SequenceFlow_1n7r495">\r
- <di:waypoint xsi:type="dc:Point" x="882" y="528" />\r
- <di:waypoint xsi:type="dc:Point" x="923" y="528" />\r
- <di:waypoint xsi:type="dc:Point" x="923" y="561" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="896" y="513" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1h77psn_di" bpmnElement="SequenceFlow_1h77psn">\r
- <di:waypoint xsi:type="dc:Point" x="556" y="806" />\r
- <di:waypoint xsi:type="dc:Point" x="586" y="806" />\r
- <di:waypoint xsi:type="dc:Point" x="586" y="804" />\r
- <di:waypoint xsi:type="dc:Point" x="623" y="804" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="601" y="805" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="IntermediateCatchEvent_1nh09nr_di" bpmnElement="IntermediateCatchEvent_1nh09nr">\r
- <dc:Bounds x="83" y="555" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="66" y="591" width="70" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="IntermediateThrowEvent_0prlju0_di" bpmnElement="IntermediateThrowEvent_0prlju0">\r
- <dc:Bounds x="905" y="245" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="888" y="286" width="70" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_0b9wd4f_di" bpmnElement="ExclusiveGateway_0b9wd4f" isMarkerVisible="true">\r
- <dc:Bounds x="332" y="548" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="393" y="580" width="61" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_0fe690i_di" bpmnElement="ExclusiveGateway_0fe690i" isMarkerVisible="true">\r
- <dc:Bounds x="828" y="503" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="796" y="561" width="82" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0dfkfh1_di" bpmnElement="SequenceFlow_0dfkfh1">\r
- <di:waypoint xsi:type="dc:Point" x="853" y="503" />\r
- <di:waypoint xsi:type="dc:Point" x="853" y="426" />\r
- <di:waypoint xsi:type="dc:Point" x="450" y="426" />\r
- <di:waypoint xsi:type="dc:Point" x="450" y="486" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="644" y="411" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0cmebdc_di" bpmnElement="SequenceFlow_0cmebdc">\r
- <di:waypoint xsi:type="dc:Point" x="357" y="548" />\r
- <di:waypoint xsi:type="dc:Point" x="357" y="528" />\r
- <di:waypoint xsi:type="dc:Point" x="400" y="528" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="363" y="538" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1os8cm5_di" bpmnElement="ExclusiveGateway_1os8cm5" isMarkerVisible="true">\r
- <dc:Bounds x="898" y="561" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="923" y="616" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1f26zbk_di" bpmnElement="SequenceFlow_1f26zbk">\r
- <di:waypoint xsi:type="dc:Point" x="357" y="598" />\r
- <di:waypoint xsi:type="dc:Point" x="357" y="665" />\r
- <di:waypoint xsi:type="dc:Point" x="923" y="665" />\r
- <di:waypoint xsi:type="dc:Point" x="923" y="611" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="633" y="650" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="IntermediateThrowEvent_0nreq15_di" bpmnElement="IntermediateThrowEvent_0nreq15">\r
- <dc:Bounds x="1033" y="568" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1013" y="609" width="75" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1vwssu7_di" bpmnElement="SequenceFlow_1vwssu7">\r
- <di:waypoint xsi:type="dc:Point" x="119" y="573" />\r
- <di:waypoint xsi:type="dc:Point" x="184" y="573" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="152" y="548" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_19etqmx_di" bpmnElement="SequenceFlow_19etqmx">\r
- <di:waypoint xsi:type="dc:Point" x="284" y="573" />\r
- <di:waypoint xsi:type="dc:Point" x="332" y="573" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="308" y="548" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1j7n6qx_di" bpmnElement="SequenceFlow_1j7n6qx">\r
- <di:waypoint xsi:type="dc:Point" x="948" y="586" />\r
- <di:waypoint xsi:type="dc:Point" x="1033" y="586" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="991" y="561" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="IntermediateCatchEvent_0rlqdvq_di" bpmnElement="IntermediateCatchEvent_0rlqdvq">\r
- <dc:Bounds x="83" y="870" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="77" y="906" width="45" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1nlocis_di" bpmnElement="ExclusiveGateway_1nlocis" isMarkerVisible="true">\r
- <dc:Bounds x="332" y="863" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="396" y="882" width="62" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_04q1qud_di" bpmnElement="ExclusiveGateway_04q1qud" isMarkerVisible="true">\r
- <dc:Bounds x="898" y="847" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="923" y="902" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_10tbv62_di" bpmnElement="SequenceFlow_10tbv62">\r
- <di:waypoint xsi:type="dc:Point" x="119" y="888" />\r
- <di:waypoint xsi:type="dc:Point" x="332" y="888" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="226" y="863" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0bvecvm_di" bpmnElement="SequenceFlow_0bvecvm">\r
- <di:waypoint xsi:type="dc:Point" x="357" y="863" />\r
- <di:waypoint xsi:type="dc:Point" x="357" y="805" />\r
- <di:waypoint xsi:type="dc:Point" x="456" y="805" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="368" y="838" width="19" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0qi5uxg_di" bpmnElement="SequenceFlow_0qi5uxg">\r
- <di:waypoint xsi:type="dc:Point" x="723" y="805" />\r
- <di:waypoint xsi:type="dc:Point" x="923" y="805" />\r
- <di:waypoint xsi:type="dc:Point" x="923" y="847" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="808" y="752" width="89" height="50" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0w7328u_di" bpmnElement="SequenceFlow_0w7328u">\r
- <di:waypoint xsi:type="dc:Point" x="357" y="914" />\r
- <di:waypoint xsi:type="dc:Point" x="357" y="937" />\r
- <di:waypoint xsi:type="dc:Point" x="923" y="937" />\r
- <di:waypoint xsi:type="dc:Point" x="923" y="898" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="603" y="913" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0xowenu_di" bpmnElement="SequenceFlow_0xowenu">\r
- <di:waypoint xsi:type="dc:Point" x="948" y="872" />\r
- <di:waypoint xsi:type="dc:Point" x="1033" y="872" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="991" y="847" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_04o8gb3_di" bpmnElement="ScriptTask_04o8gb3">\r
- <dc:Bounds x="686" y="491" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_12ag2bk_di" bpmnElement="SequenceFlow_12ag2bk">\r
- <di:waypoint xsi:type="dc:Point" x="642" y="531" />\r
- <di:waypoint xsi:type="dc:Point" x="686" y="531" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="664" y="506" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_04vlq8r_di" bpmnElement="SequenceFlow_04vlq8r">\r
- <di:waypoint xsi:type="dc:Point" x="786" y="531" />\r
- <di:waypoint xsi:type="dc:Point" x="807" y="531" />\r
- <di:waypoint xsi:type="dc:Point" x="807" y="528" />\r
- <di:waypoint xsi:type="dc:Point" x="828" y="528" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="822" y="519.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0j6sjye_di" bpmnElement="SequenceFlow_0j6sjye">\r
- <di:waypoint xsi:type="dc:Point" x="385" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="476" y="263" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="431" y="248" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_184teky_di" bpmnElement="ScriptTask_184teky">\r
- <dc:Bounds x="546" y="1490" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1c386z9_di" bpmnElement="ExclusiveGateway_1c386z9" isMarkerVisible="true">\r
- <dc:Bounds x="685" y="1505" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="758" y="1512" width="53" height="36" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1dmsx0d_di" bpmnElement="SequenceFlow_1dmsx0d">\r
- <di:waypoint xsi:type="dc:Point" x="504" y="1530" />\r
- <di:waypoint xsi:type="dc:Point" x="546" y="1530" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="525" y="1515" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1otyild_di" bpmnElement="SequenceFlow_1otyild">\r
- <di:waypoint xsi:type="dc:Point" x="646" y="1530" />\r
- <di:waypoint xsi:type="dc:Point" x="685" y="1530" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="666" y="1515" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0136s37_di" bpmnElement="SequenceFlow_0136s37">\r
- <di:waypoint xsi:type="dc:Point" x="710" y="1505" />\r
- <di:waypoint xsi:type="dc:Point" x="710" y="1414" />\r
- <di:waypoint xsi:type="dc:Point" x="454" y="1414" />\r
- <di:waypoint xsi:type="dc:Point" x="454" y="1490" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="574" y="1399" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_12u8ufr_di" bpmnElement="SequenceFlow_12u8ufr">\r
- <di:waypoint xsi:type="dc:Point" x="710" y="1555" />\r
- <di:waypoint xsi:type="dc:Point" x="710" y="1586" />\r
- <di:waypoint xsi:type="dc:Point" x="530" y="1586" />\r
- <di:waypoint xsi:type="dc:Point" x="530" y="1625" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="615" y="1571" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1bts0nw_di" bpmnElement="ExclusiveGateway_1bts0nw" isMarkerVisible="true">\r
- <dc:Bounds x="303" y="1505" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="289" y="1471" width="81" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0tmepzk_di" bpmnElement="SequenceFlow_0tmepzk">\r
- <di:waypoint xsi:type="dc:Point" x="256" y="1530" />\r
- <di:waypoint xsi:type="dc:Point" x="303" y="1530" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="271" y="1505" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1fqmrda_di" bpmnElement="SequenceFlow_1fqmrda">\r
- <di:waypoint xsi:type="dc:Point" x="353" y="1530" />\r
- <di:waypoint xsi:type="dc:Point" x="404" y="1530" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="370" y="1505" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1brxd2r_di" bpmnElement="SequenceFlow_1brxd2r">\r
- <di:waypoint xsi:type="dc:Point" x="328" y="1555" />\r
- <di:waypoint xsi:type="dc:Point" x="328" y="1625" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="336" y="1580" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_05indeh_di" bpmnElement="ExclusiveGateway_05indeh" isMarkerVisible="true">\r
- <dc:Bounds x="505" y="1625" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="430" y="1593" width="85" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_08s0ew2_di" bpmnElement="SequenceFlow_08s0ew2">\r
- <di:waypoint xsi:type="dc:Point" x="353" y="1650" />\r
- <di:waypoint xsi:type="dc:Point" x="505" y="1650" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="429" y="1625" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1ieiew4_di" bpmnElement="SequenceFlow_1ieiew4">\r
- <di:waypoint xsi:type="dc:Point" x="555" y="1650" />\r
- <di:waypoint xsi:type="dc:Point" x="608" y="1650" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="573" y="1625" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0sezboq_di" bpmnElement="SequenceFlow_0sezboq">\r
- <di:waypoint xsi:type="dc:Point" x="530" y="1675" />\r
- <di:waypoint xsi:type="dc:Point" x="530" y="1768" />\r
- <di:waypoint xsi:type="dc:Point" x="738" y="1768" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="538" y="1710.0295234297107" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ServiceTask_16yhzej_di" bpmnElement="updateInfraRequest">\r
- <dc:Bounds x="764" y="223" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_13uceka_di" bpmnElement="SequenceFlow_13uceka">\r
- <di:waypoint xsi:type="dc:Point" x="864" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="905" y="263" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="885" y="248" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_1qd3uwb_di" bpmnElement="ScriptTask_1qd3uwb">\r
- <dc:Bounds x="618" y="226" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1ky2sv9_di" bpmnElement="SequenceFlow_1ky2sv9">\r
- <di:waypoint xsi:type="dc:Point" x="576" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="597" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="597" y="266" />\r
- <di:waypoint xsi:type="dc:Point" x="618" y="266" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="612" y="254.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0vj46ej_di" bpmnElement="SequenceFlow_0vj46ej">\r
- <di:waypoint xsi:type="dc:Point" x="718" y="266" />\r
- <di:waypoint xsi:type="dc:Point" x="741" y="266" />\r
- <di:waypoint xsi:type="dc:Point" x="741" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="764" y="263" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="756" y="254.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_17doerz_di" bpmnElement="ScriptTask_17doerz">\r
- <dc:Bounds x="54" y="1771" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0zq7i3q_di" bpmnElement="SequenceFlow_0zq7i3q">\r
- <di:waypoint xsi:type="dc:Point" x="2" y="2068" />\r
- <di:waypoint xsi:type="dc:Point" x="49" y="2068" />\r
- <di:waypoint xsi:type="dc:Point" x="49" y="2067" />\r
- <di:waypoint xsi:type="dc:Point" x="79" y="2067" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="18" y="2069" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="InclusiveGateway_0m9f5ka_di" bpmnElement="InclusiveGateway_0m9f5ka">\r
- <dc:Bounds x="738" y="1743" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="763" y="1798" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_0wyub4x_di" bpmnElement="ScriptTask_0wyub4x">\r
- <dc:Bounds x="713" y="1827" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0sdb3on_di" bpmnElement="SequenceFlow_0sdb3on">\r
- <di:waypoint xsi:type="dc:Point" x="104" y="1771" />\r
- <di:waypoint xsi:type="dc:Point" x="104" y="1675" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="119" y="1713" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0f4u373_di" bpmnElement="SequenceFlow_0f4u373">\r
- <di:waypoint xsi:type="dc:Point" x="763" y="1793" />\r
- <di:waypoint xsi:type="dc:Point" x="763" y="1827" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="778" y="1800" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1rabks0_di" bpmnElement="SequenceFlow_1rabks0">\r
- <di:waypoint xsi:type="dc:Point" x="763" y="1907" />\r
- <di:waypoint xsi:type="dc:Point" x="763" y="1935" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="778" y="1911" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- </bpmndi:BPMNPlane>\r
- </bpmndi:BPMNDiagram>\r
-</bpmn2:definitions>\r
+def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.postProcessServiceInstanceCreate(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_1ky2sv9" sourceRef="doCreateServiceInstance_CallActivity" targetRef="ScriptTask_1qd3uwb" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0vj46ej" sourceRef="ScriptTask_1qd3uwb" targetRef="updateInfraRequest" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0hvcwa1" sourceRef="DecomposeService" targetRef="prepareCreateService_scriptTask" />
+ <bpmn2:callActivity id="DecomposeService" name="DecomposeService" calledElement="DecomposeService">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:in source="serviceModelInfo" target="serviceModelInfo" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:out source="serviceDecomposition" target="serviceDecomposition" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_00h6hmd</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0hvcwa1</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_0cdtchu" name="Prepare Decompose Service " scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1eu60rt</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_00h6hmd</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+def CreateGenericMacroServiceNetworkVnf = new CreateGenericMacroServiceNetworkVnf()
+CreateGenericMacroServiceNetworkVnf.prepareDecomposeService(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_1eu60rt" sourceRef="IntermediateCatchEvent_3" targetRef="ScriptTask_0cdtchu" />
+ <bpmn2:sequenceFlow id="SequenceFlow_00h6hmd" sourceRef="ScriptTask_0cdtchu" targetRef="DecomposeService" />
+ </bpmn2:process>
+ <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
+ <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
+ <bpmndi:BPMNDiagram id="BPMNDiagram_1">
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="CreateGenericMacroServiceNetworkVnf">
+ <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createVIPR_startEvent">
+ <dc:Bounds x="96" y="90" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="82" y="131" width="65" height="22" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">
+ <dc:Bounds x="285" y="68" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">
+ <di:waypoint xsi:type="dc:Point" x="132" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="285" y="108" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="171" y="108" width="6" height="6" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_4" bpmnElement="callCompleteMsoProcess_CallActivity">
+ <dc:Bounds x="787" y="1115" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_80" bpmnElement="postProcessAndCompletionRequest_ScriptTask">
+ <dc:Bounds x="514" y="1115" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_61" targetElement="_BPMNShape_ScriptTask_127">
+ <di:waypoint xsi:type="dc:Point" x="385" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="476" y="108" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="271" y="69" width="6" height="6" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_127" bpmnElement="sendSyncAckResponse_ScriptTask">
+ <dc:Bounds x="476" y="68" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_42" bpmnElement="SequenceFlow_29" sourceElement="_BPMNShape_ScriptTask_80" targetElement="_BPMNShape_CallActivity_4">
+ <di:waypoint xsi:type="dc:Point" x="614" y="1155" />
+ <di:waypoint xsi:type="dc:Point" x="787" y="1155" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="701" y="1140" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="CreateVIPR_EndEvent">
+ <dc:Bounds x="1286" y="1135" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1294" y="1176" width="20" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_CallActivity_4" targetElement="_BPMNShape_ScriptTask_337">
+ <di:waypoint xsi:type="dc:Point" x="887" y="1155" />
+ <di:waypoint xsi:type="dc:Point" x="1095" y="1154" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="991" y="1140" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_SubProcess_27" bpmnElement="UnexpectedError_SubProcess_1" isExpanded="true">
+ <dc:Bounds x="1281" y="1385" width="409" height="232" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_StartEvent_70" bpmnElement="StartEvent_1">
+ <dc:Bounds x="1349" y="1490" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1367" y="1531" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_269" bpmnElement="ScriptTask_1">
+ <dc:Bounds x="1424" y="1468" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_EndEvent_219" bpmnElement="EndEvent_1">
+ <dc:Bounds x="1577" y="1490" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1595" y="1531" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_StartEvent_70" targetElement="_BPMNShape_ScriptTask_269">
+ <di:waypoint xsi:type="dc:Point" x="1385" y="1508" />
+ <di:waypoint xsi:type="dc:Point" x="1424" y="1508" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1413" y="1508" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_5" sourceElement="_BPMNShape_ScriptTask_269" targetElement="_BPMNShape_EndEvent_219">
+ <di:waypoint xsi:type="dc:Point" x="1524" y="1508" />
+ <di:waypoint xsi:type="dc:Point" x="1557" y="1508" />
+ <di:waypoint xsi:type="dc:Point" x="1557" y="1508" />
+ <di:waypoint xsi:type="dc:Point" x="1577" y="1508" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1572" y="1508" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_75" bpmnElement="doCreateServiceInstance_CallActivity">
+ <dc:Bounds x="610" y="223" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_127">
+ <di:waypoint xsi:type="dc:Point" x="576" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="728" y="108" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="652" y="93" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_337" bpmnElement="ScriptTask_2">
+ <dc:Bounds x="1095" y="1114" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_ScriptTask_337" targetElement="_BPMNShape_EndEvent_177">
+ <di:waypoint xsi:type="dc:Point" x="1195" y="1153" />
+ <di:waypoint xsi:type="dc:Point" x="1286" y="1153" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1241" y="1138" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_76" bpmnElement="doCreateNetworkInstance_CallActivity">
+ <dc:Bounds x="542" y="491" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_35" bpmnElement="IntermediateCatchEvent_3">
+ <dc:Bounds x="96" y="245" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="88" y="281" width="51" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_36" bpmnElement="IntermediateCatchEvent_4">
+ <dc:Bounds x="84" y="1137" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="66" y="1173" width="71" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_51" bpmnElement="IntermediateThrowEvent_4">
+ <dc:Bounds x="1033" y="854" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1008" y="895" width="85" height="26" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_341" bpmnElement="ScriptTask_PrepareNetworkCreate">
+ <dc:Bounds x="400" y="488" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_342" bpmnElement="ScriptTask_3">
+ <dc:Bounds x="456" y="765" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_81" bpmnElement="doCreateVNFandModules_CallActivity">
+ <dc:Bounds x="623" y="765" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_49" bpmnElement="IntermediateThrowEvent_2">
+ <dc:Bounds x="728" y="90" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="707" y="131" width="77" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="SubProcess_0s6hpty_di" bpmnElement="SubProcess_0s6hpty" isExpanded="true">
+ <dc:Bounds x="-75" y="1333" width="1324" height="837" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1vwgs6p_di" bpmnElement="ExclusiveGateway_1vwgs6p" isMarkerVisible="true">
+ <dc:Bounds x="79" y="2042" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="66" y="2102" width="80" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="StartEvent_1bwmffk_di" bpmnElement="StartEvent_1bwmffk">
+ <dc:Bounds x="-34" y="2050" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="-40" y="2091" width="50" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0ydrtdx_di" bpmnElement="ExclusiveGateway_0ydrtdx" isMarkerVisible="true">
+ <dc:Bounds x="79" y="1935" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="13" y="1950" width="47" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_00rt5qa_di" bpmnElement="ExclusiveGateway_00rt5qa" isMarkerVisible="true">
+ <dc:Bounds x="79" y="1625" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="5" y="1640" width="57" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1kvn1pz_di" bpmnElement="ExclusiveGateway_1kvn1pz" isMarkerVisible="true">
+ <dc:Bounds x="206" y="1505" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="188" y="1471" width="89" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0jw5tqa_di" bpmnElement="CallActivity_0jw5tqa">
+ <dc:Bounds x="1052" y="2016" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="EndEvent_04xute7_di" bpmnElement="EndEvent_04xute7">
+ <dc:Bounds x="1189" y="2038" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1207" y="2079" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="InclusiveGateway_1pqjttt_di" bpmnElement="InclusiveGateway_1pqjttt">
+ <dc:Bounds x="303" y="1625" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="328" y="1680" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_0yk02h3_di" bpmnElement="ScriptTask_0yk02h3">
+ <dc:Bounds x="920" y="2016" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0zpbskl_di" bpmnElement="SequenceFlow_0zpbskl">
+ <di:waypoint xsi:type="dc:Point" x="104" y="2042" />
+ <di:waypoint xsi:type="dc:Point" x="104" y="1985" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="110" y="2023.785849077779" width="19" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0dhf2js_di" bpmnElement="SequenceFlow_0dhf2js">
+ <di:waypoint xsi:type="dc:Point" x="129" y="2067" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="2067" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="1985" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="169" y="2072" width="14" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1sx5llu_di" bpmnElement="SequenceFlow_1sx5llu">
+ <di:waypoint xsi:type="dc:Point" x="129" y="1960" />
+ <di:waypoint xsi:type="dc:Point" x="434" y="1960" />
+ <di:waypoint xsi:type="dc:Point" x="434" y="1960" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="1960" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="448" y="1964" width="19" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_02o4yqx_di" bpmnElement="SequenceFlow_02o4yqx">
+ <di:waypoint xsi:type="dc:Point" x="104" y="1935" />
+ <di:waypoint xsi:type="dc:Point" x="104" y="1851" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="115" y="1888.0011779924323" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_05lo85t_di" bpmnElement="SequenceFlow_05lo85t">
+ <di:waypoint xsi:type="dc:Point" x="129" y="1650" />
+ <di:waypoint xsi:type="dc:Point" x="231" y="1650" />
+ <di:waypoint xsi:type="dc:Point" x="231" y="1555" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="133" y="1654" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0xtr1g5_di" bpmnElement="SequenceFlow_0xtr1g5">
+ <di:waypoint xsi:type="dc:Point" x="104" y="1625" />
+ <di:waypoint xsi:type="dc:Point" x="104" y="1570" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="113" y="1565" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_19mxskt_di" bpmnElement="SequenceFlow_19mxskt">
+ <di:waypoint xsi:type="dc:Point" x="242" y="1544" />
+ <di:waypoint xsi:type="dc:Point" x="317" y="1636" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="281" y="1572" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_0r7telk_di" bpmnElement="callDbCatalog_scriptTask">
+ <dc:Bounds x="184" y="533" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1gacz45_di" bpmnElement="prepareCreateService_scriptTask">
+ <dc:Bounds x="456" y="223" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_11b4gmn_di" bpmnElement="setPONR_ScriptTask">
+ <dc:Bounds x="228" y="1115" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_12ilko1_di" bpmnElement="SequenceFlow_12ilko1">
+ <di:waypoint xsi:type="dc:Point" x="120" y="1155" />
+ <di:waypoint xsi:type="dc:Point" x="228" y="1155" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="174" y="1130" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0afe2pg_di" bpmnElement="SequenceFlow_0afe2pg">
+ <di:waypoint xsi:type="dc:Point" x="328" y="1155" />
+ <di:waypoint xsi:type="dc:Point" x="471" y="1155" />
+ <di:waypoint xsi:type="dc:Point" x="514" y="1155" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="400" y="1140" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_1cvt373_di" bpmnElement="DoRollbackVNFandModules_CallActivity">
+ <dc:Bounds x="54" y="1490" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_09xerwk_di" bpmnElement="SequenceFlow_09xerwk">
+ <di:waypoint xsi:type="dc:Point" x="154" y="1530" />
+ <di:waypoint xsi:type="dc:Point" x="206" y="1530" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="180" y="1515" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0zl1ald_di" bpmnElement="DoRollbackNetwork_CallActivity">
+ <dc:Bounds x="404" y="1490" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_09o09bu_di" bpmnElement="ExclusiveGateway_09o09bu" isMarkerVisible="true">
+ <dc:Bounds x="608" y="1625" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="596" y="1596" width="73" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0oh7wzu_di" bpmnElement="DoRollbackService_CallActivity">
+ <dc:Bounds x="713" y="1610" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="InclusiveGateway_0foywso_di" bpmnElement="InclusiveGateway_0foywso">
+ <dc:Bounds x="738" y="1935" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="763" y="1990" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1os9x7w_di" bpmnElement="SequenceFlow_1os9x7w">
+ <di:waypoint xsi:type="dc:Point" x="658" y="1650" />
+ <di:waypoint xsi:type="dc:Point" x="713" y="1650" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="678" y="1635" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1f1hd3l_di" bpmnElement="SequenceFlow_1f1hd3l">
+ <di:waypoint xsi:type="dc:Point" x="763" y="1690" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="1743" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="778" y="1716.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0g7scsg_di" bpmnElement="SequenceFlow_0g7scsg">
+ <di:waypoint xsi:type="dc:Point" x="633" y="1675" />
+ <di:waypoint xsi:type="dc:Point" x="633" y="1768" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="1768" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="641" y="1710.0295234297107" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0jg47xm_di" bpmnElement="SequenceFlow_0jg47xm">
+ <di:waypoint xsi:type="dc:Point" x="788" y="1960" />
+ <di:waypoint xsi:type="dc:Point" x="970" y="1960" />
+ <di:waypoint xsi:type="dc:Point" x="970" y="2016" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="879" y="1945" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0807ukc_di" bpmnElement="SequenceFlow_0807ukc">
+ <di:waypoint xsi:type="dc:Point" x="1020" y="2056" />
+ <di:waypoint xsi:type="dc:Point" x="1052" y="2056" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1036" y="2041" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_19yywk8_di" bpmnElement="SequenceFlow_19yywk8">
+ <di:waypoint xsi:type="dc:Point" x="1152" y="2056" />
+ <di:waypoint xsi:type="dc:Point" x="1189" y="2056" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1171" y="2041" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1bwbn7r_di" bpmnElement="SequenceFlow_1bwbn7r">
+ <di:waypoint xsi:type="dc:Point" x="500" y="530" />
+ <di:waypoint xsi:type="dc:Point" x="542" y="529" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="521" y="514.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1n7r495_di" bpmnElement="SequenceFlow_1n7r495">
+ <di:waypoint xsi:type="dc:Point" x="882" y="528" />
+ <di:waypoint xsi:type="dc:Point" x="923" y="528" />
+ <di:waypoint xsi:type="dc:Point" x="923" y="561" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="896" y="513" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1h77psn_di" bpmnElement="SequenceFlow_1h77psn">
+ <di:waypoint xsi:type="dc:Point" x="556" y="806" />
+ <di:waypoint xsi:type="dc:Point" x="586" y="806" />
+ <di:waypoint xsi:type="dc:Point" x="586" y="804" />
+ <di:waypoint xsi:type="dc:Point" x="623" y="804" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="601" y="805" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="IntermediateCatchEvent_1nh09nr_di" bpmnElement="IntermediateCatchEvent_1nh09nr">
+ <dc:Bounds x="83" y="555" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="66" y="591" width="70" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="IntermediateThrowEvent_0prlju0_di" bpmnElement="IntermediateThrowEvent_0prlju0">
+ <dc:Bounds x="1065" y="245" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1048" y="286" width="70" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0b9wd4f_di" bpmnElement="ExclusiveGateway_0b9wd4f" isMarkerVisible="true">
+ <dc:Bounds x="332" y="548" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="393" y="580" width="61" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0fe690i_di" bpmnElement="ExclusiveGateway_0fe690i" isMarkerVisible="true">
+ <dc:Bounds x="828" y="503" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="796" y="561" width="82" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0dfkfh1_di" bpmnElement="SequenceFlow_0dfkfh1">
+ <di:waypoint xsi:type="dc:Point" x="853" y="503" />
+ <di:waypoint xsi:type="dc:Point" x="853" y="426" />
+ <di:waypoint xsi:type="dc:Point" x="450" y="426" />
+ <di:waypoint xsi:type="dc:Point" x="450" y="486" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="644" y="411" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0cmebdc_di" bpmnElement="SequenceFlow_0cmebdc">
+ <di:waypoint xsi:type="dc:Point" x="357" y="548" />
+ <di:waypoint xsi:type="dc:Point" x="357" y="528" />
+ <di:waypoint xsi:type="dc:Point" x="400" y="528" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="363" y="538" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1os8cm5_di" bpmnElement="ExclusiveGateway_1os8cm5" isMarkerVisible="true">
+ <dc:Bounds x="898" y="561" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="923" y="616" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1f26zbk_di" bpmnElement="SequenceFlow_1f26zbk">
+ <di:waypoint xsi:type="dc:Point" x="357" y="598" />
+ <di:waypoint xsi:type="dc:Point" x="357" y="665" />
+ <di:waypoint xsi:type="dc:Point" x="923" y="665" />
+ <di:waypoint xsi:type="dc:Point" x="923" y="611" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="633" y="650" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="IntermediateThrowEvent_0nreq15_di" bpmnElement="IntermediateThrowEvent_0nreq15">
+ <dc:Bounds x="1033" y="568" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1013" y="609" width="75" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1vwssu7_di" bpmnElement="SequenceFlow_1vwssu7">
+ <di:waypoint xsi:type="dc:Point" x="119" y="573" />
+ <di:waypoint xsi:type="dc:Point" x="184" y="573" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="152" y="548" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_19etqmx_di" bpmnElement="SequenceFlow_19etqmx">
+ <di:waypoint xsi:type="dc:Point" x="284" y="573" />
+ <di:waypoint xsi:type="dc:Point" x="332" y="573" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="308" y="548" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1j7n6qx_di" bpmnElement="SequenceFlow_1j7n6qx">
+ <di:waypoint xsi:type="dc:Point" x="948" y="586" />
+ <di:waypoint xsi:type="dc:Point" x="1033" y="586" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="991" y="561" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="IntermediateCatchEvent_0rlqdvq_di" bpmnElement="IntermediateCatchEvent_0rlqdvq">
+ <dc:Bounds x="83" y="870" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="77" y="906" width="45" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1nlocis_di" bpmnElement="ExclusiveGateway_1nlocis" isMarkerVisible="true">
+ <dc:Bounds x="332" y="863" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="396" y="882" width="62" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_04q1qud_di" bpmnElement="ExclusiveGateway_04q1qud" isMarkerVisible="true">
+ <dc:Bounds x="898" y="847" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="923" y="902" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_10tbv62_di" bpmnElement="SequenceFlow_10tbv62">
+ <di:waypoint xsi:type="dc:Point" x="119" y="888" />
+ <di:waypoint xsi:type="dc:Point" x="332" y="888" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="226" y="863" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0bvecvm_di" bpmnElement="SequenceFlow_0bvecvm">
+ <di:waypoint xsi:type="dc:Point" x="357" y="863" />
+ <di:waypoint xsi:type="dc:Point" x="357" y="805" />
+ <di:waypoint xsi:type="dc:Point" x="456" y="805" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="368" y="838" width="19" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0qi5uxg_di" bpmnElement="SequenceFlow_0qi5uxg">
+ <di:waypoint xsi:type="dc:Point" x="723" y="805" />
+ <di:waypoint xsi:type="dc:Point" x="923" y="805" />
+ <di:waypoint xsi:type="dc:Point" x="923" y="847" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="808" y="752" width="89" height="50" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0w7328u_di" bpmnElement="SequenceFlow_0w7328u">
+ <di:waypoint xsi:type="dc:Point" x="357" y="914" />
+ <di:waypoint xsi:type="dc:Point" x="357" y="937" />
+ <di:waypoint xsi:type="dc:Point" x="923" y="937" />
+ <di:waypoint xsi:type="dc:Point" x="923" y="898" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="603" y="913" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0xowenu_di" bpmnElement="SequenceFlow_0xowenu">
+ <di:waypoint xsi:type="dc:Point" x="948" y="872" />
+ <di:waypoint xsi:type="dc:Point" x="1033" y="872" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="991" y="847" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_04o8gb3_di" bpmnElement="ScriptTask_04o8gb3">
+ <dc:Bounds x="686" y="491" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_12ag2bk_di" bpmnElement="SequenceFlow_12ag2bk">
+ <di:waypoint xsi:type="dc:Point" x="642" y="531" />
+ <di:waypoint xsi:type="dc:Point" x="686" y="531" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="664" y="506" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_04vlq8r_di" bpmnElement="SequenceFlow_04vlq8r">
+ <di:waypoint xsi:type="dc:Point" x="786" y="531" />
+ <di:waypoint xsi:type="dc:Point" x="807" y="531" />
+ <di:waypoint xsi:type="dc:Point" x="807" y="528" />
+ <di:waypoint xsi:type="dc:Point" x="828" y="528" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="822" y="519.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0j6sjye_di" bpmnElement="SequenceFlow_0j6sjye">
+ <di:waypoint xsi:type="dc:Point" x="556" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="610" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="583" y="248" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_184teky_di" bpmnElement="ScriptTask_184teky">
+ <dc:Bounds x="546" y="1490" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1c386z9_di" bpmnElement="ExclusiveGateway_1c386z9" isMarkerVisible="true">
+ <dc:Bounds x="685" y="1505" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="758" y="1512" width="53" height="36" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1dmsx0d_di" bpmnElement="SequenceFlow_1dmsx0d">
+ <di:waypoint xsi:type="dc:Point" x="504" y="1530" />
+ <di:waypoint xsi:type="dc:Point" x="546" y="1530" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="525" y="1515" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1otyild_di" bpmnElement="SequenceFlow_1otyild">
+ <di:waypoint xsi:type="dc:Point" x="646" y="1530" />
+ <di:waypoint xsi:type="dc:Point" x="685" y="1530" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="666" y="1515" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0136s37_di" bpmnElement="SequenceFlow_0136s37">
+ <di:waypoint xsi:type="dc:Point" x="710" y="1505" />
+ <di:waypoint xsi:type="dc:Point" x="710" y="1414" />
+ <di:waypoint xsi:type="dc:Point" x="454" y="1414" />
+ <di:waypoint xsi:type="dc:Point" x="454" y="1490" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="574" y="1399" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_12u8ufr_di" bpmnElement="SequenceFlow_12u8ufr">
+ <di:waypoint xsi:type="dc:Point" x="710" y="1555" />
+ <di:waypoint xsi:type="dc:Point" x="710" y="1586" />
+ <di:waypoint xsi:type="dc:Point" x="530" y="1586" />
+ <di:waypoint xsi:type="dc:Point" x="530" y="1625" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="615" y="1571" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1bts0nw_di" bpmnElement="ExclusiveGateway_1bts0nw" isMarkerVisible="true">
+ <dc:Bounds x="303" y="1505" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="289" y="1471" width="81" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0tmepzk_di" bpmnElement="SequenceFlow_0tmepzk">
+ <di:waypoint xsi:type="dc:Point" x="256" y="1530" />
+ <di:waypoint xsi:type="dc:Point" x="303" y="1530" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="271" y="1505" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1fqmrda_di" bpmnElement="SequenceFlow_1fqmrda">
+ <di:waypoint xsi:type="dc:Point" x="353" y="1530" />
+ <di:waypoint xsi:type="dc:Point" x="404" y="1530" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="370" y="1505" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1brxd2r_di" bpmnElement="SequenceFlow_1brxd2r">
+ <di:waypoint xsi:type="dc:Point" x="328" y="1555" />
+ <di:waypoint xsi:type="dc:Point" x="328" y="1625" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="336" y="1580" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_05indeh_di" bpmnElement="ExclusiveGateway_05indeh" isMarkerVisible="true">
+ <dc:Bounds x="505" y="1625" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="430" y="1593" width="85" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_08s0ew2_di" bpmnElement="SequenceFlow_08s0ew2">
+ <di:waypoint xsi:type="dc:Point" x="353" y="1650" />
+ <di:waypoint xsi:type="dc:Point" x="505" y="1650" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="429" y="1625" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1ieiew4_di" bpmnElement="SequenceFlow_1ieiew4">
+ <di:waypoint xsi:type="dc:Point" x="555" y="1650" />
+ <di:waypoint xsi:type="dc:Point" x="608" y="1650" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="573" y="1625" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0sezboq_di" bpmnElement="SequenceFlow_0sezboq">
+ <di:waypoint xsi:type="dc:Point" x="530" y="1675" />
+ <di:waypoint xsi:type="dc:Point" x="530" y="1768" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="1768" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="538" y="1710.0295234297107" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ServiceTask_16yhzej_di" bpmnElement="updateInfraRequest">
+ <dc:Bounds x="921" y="223" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_13uceka_di" bpmnElement="SequenceFlow_13uceka">
+ <di:waypoint xsi:type="dc:Point" x="1021" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="1065" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1043" y="248" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1qd3uwb_di" bpmnElement="ScriptTask_1qd3uwb">
+ <dc:Bounds x="772" y="223" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1ky2sv9_di" bpmnElement="SequenceFlow_1ky2sv9">
+ <di:waypoint xsi:type="dc:Point" x="710" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="772" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="741" y="248" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0vj46ej_di" bpmnElement="SequenceFlow_0vj46ej">
+ <di:waypoint xsi:type="dc:Point" x="872" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="921" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="897" y="248" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_17doerz_di" bpmnElement="ScriptTask_17doerz">
+ <dc:Bounds x="54" y="1771" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0zq7i3q_di" bpmnElement="SequenceFlow_0zq7i3q">
+ <di:waypoint xsi:type="dc:Point" x="2" y="2068" />
+ <di:waypoint xsi:type="dc:Point" x="49" y="2068" />
+ <di:waypoint xsi:type="dc:Point" x="49" y="2067" />
+ <di:waypoint xsi:type="dc:Point" x="79" y="2067" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="18" y="2069" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="InclusiveGateway_0m9f5ka_di" bpmnElement="InclusiveGateway_0m9f5ka">
+ <dc:Bounds x="738" y="1743" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="763" y="1798" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_0wyub4x_di" bpmnElement="ScriptTask_0wyub4x">
+ <dc:Bounds x="713" y="1827" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0sdb3on_di" bpmnElement="SequenceFlow_0sdb3on">
+ <di:waypoint xsi:type="dc:Point" x="104" y="1771" />
+ <di:waypoint xsi:type="dc:Point" x="104" y="1675" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="119" y="1713" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0f4u373_di" bpmnElement="SequenceFlow_0f4u373">
+ <di:waypoint xsi:type="dc:Point" x="763" y="1793" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="1827" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="778" y="1800" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1rabks0_di" bpmnElement="SequenceFlow_1rabks0">
+ <di:waypoint xsi:type="dc:Point" x="763" y="1907" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="1935" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="778" y="1911" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0hvcwa1_di" bpmnElement="SequenceFlow_0hvcwa1">
+ <di:waypoint xsi:type="dc:Point" x="407" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="456" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="432" y="248" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0w2alah_di" bpmnElement="DecomposeService">
+ <dc:Bounds x="307" y="223" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_0cdtchu_di" bpmnElement="ScriptTask_0cdtchu">
+ <dc:Bounds x="171" y="223" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1eu60rt_di" bpmnElement="SequenceFlow_1eu60rt">
+ <di:waypoint xsi:type="dc:Point" x="132" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="171" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="152" y="238" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_00h6hmd_di" bpmnElement="SequenceFlow_00h6hmd">
+ <di:waypoint xsi:type="dc:Point" x="271" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="307" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="289" y="238" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ </bpmndi:BPMNPlane>
+ </bpmndi:BPMNDiagram>
+</bpmn2:definitions>
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd" id="_pNTO8MRhEeWv36YLr7PC3Q" exporter="camunda modeler" exporterVersion="2.7.0" targetNamespace="http://camunda.org/schema/1.0/bpmn">
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_pNTO8MRhEeWv36YLr7PC3Q" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:process id="CreateVfModuleInfra" name="CreateVfModuleInfra" isExecutable="true">
<bpmn2:startEvent id="StartEvent_1" name="Start">
<bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
</bpmn2:startEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="StartEvent_1" targetRef="PreProcessRequest"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="StartEvent_1" targetRef="PreProcessRequest" />
<bpmn2:callActivity id="DoCreateVfModuleSubprocess" name="Do Create Vf Module" calledElement="DoCreateVfModule">
<bpmn2:extensionElements>
- <camunda:in source="DoCreateVfModuleRequest" target="DoCreateVfModuleRequest"/>
- <camunda:in source="mso-request-id" target="mso-request-id"/>
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled"/>
- <camunda:in source="isVidRequest" target="isVidRequest"/>
- <camunda:in source="newVfModuleId" target="newVfModuleId"/>
- <camunda:out source="DCVFM_vnfId" target="CVFMI_vnfId"/>
- <camunda:out source="DCVFM_vfModuleId" target="CVFMI_vfModuleId"/>
- <camunda:out source="RollbackData" target="RollbackData"/>
- <camunda:out source="WorkflowException" target="WorkflowException"/>
- <camunda:out source="WorkflowResponse" target="CVFMI_WorkflowResponse"/>
+ <camunda:in source="CVFMI_requestId" target="msoRequestId" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="isVidRequest" target="isVidRequest" />
+ <camunda:in source="CVFMI_disableRollback" target="disableRollback" />
+ <camunda:out source="DCVFM_vnfId" target="CVFMI_vnfId" />
+ <camunda:out source="DCVFM_vfModuleId" target="CVFMI_vfModuleId" />
+ <camunda:out source="RollbackData" target="RollbackData" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="WorkflowResponse" target="CVFMI_WorkflowResponse" />
+ <camunda:out source="DCVFM_vfModuleName" target="CVFMI_vfModuleName" />
+ <camunda:in source="CVFMI_vnfType" target="vnfType" />
+ <camunda:in source="CVFMI_vnfName" target="vnfName" />
+ <camunda:in source="CVFMI_vnfId" target="vnfId" />
+ <camunda:in source="CVFMI_vfModuleName" target="vfModuleName" />
+ <camunda:in source="CVFMI_vfModuleType" target="vfModuleType" />
+ <camunda:in source="CVFMI_volumeGroupId" target="volumeGroupId" />
+ <camunda:in source="CVFMI_volumeGroupName" target="volumeGroupName" />
+ <camunda:in source="CVFMI_isBaseVfModule" target="isBaseVfModule" />
+ <camunda:in source="CVFMI_asdcServiceModelVersion" target="asdcServiceModelVersion" />
+ <camunda:in source="CVFMI_serviceInstanceId" target="serviceInstanceId" />
+ <camunda:in source="CVFMI_serviceModelInfo" target="serviceModelInfo" />
+ <camunda:in source="CVFMI_vnfModelInfo" target="vnfModelInfo" />
+ <camunda:in source="CVFMI_globalSubscriberId" target="globalSubscriberId" />
+ <camunda:in source="CVFMI_sdncVersion" target="sdncVersion" />
+ <camunda:in source="CVFMI_lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="CVFMI_tenantId" target="tenantId" />
+ <camunda:in source="CVFMI_vfModuleId" target="vfModuleId" />
+ <camunda:in source="CVFMI_vfModuleModelInfo" target="vfModuleModelInfo" />
+ <camunda:in source="CVFMI_usePreload" target="usePreload" />
+ <camunda:in source="CVFMI_vfModuleInputParams" target="vfModuleInputParams" />
</bpmn2:extensionElements>
<bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
def createVfModule = new CreateVfModuleInfra()
createVfModule.sendResponse(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="SendResponse" targetRef="DoCreateVfModuleSubprocess"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="SendResponse" targetRef="DoCreateVfModuleSubprocess" />
<bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_1" name="To FinishLine">
<bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_34" name="FinishLine"/>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_34" name="FinishLine" />
</bpmn2:intermediateThrowEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="DoCreateVfModuleSubprocess" targetRef="IntermediateThrowEvent_1"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="DoCreateVfModuleSubprocess" targetRef="IntermediateThrowEvent_1" />
<bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_1" name="FinishLine">
<bpmn2:outgoing>SequenceFlow_5</bpmn2:outgoing>
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_35" name="FinishLine"/>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_35" name="FinishLine" />
</bpmn2:intermediateCatchEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="IntermediateCatchEvent_1" targetRef="PrepareUpdateInfraRequest"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="IntermediateCatchEvent_1" targetRef="PrepareUpdateInfraRequest" />
<bpmn2:scriptTask id="PrepareUpdateInfraRequest" name="Prepare Update Infra Request" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_5</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>
<bpmn2:serviceTask id="ServiceTask_1" name="Update Infra Request">
<bpmn2:extensionElements>
<camunda:connector>
- <camunda:connectorId>http-connector</camunda:connectorId>
<camunda:inputOutput>
<camunda:inputParameter name="url">${URN_mso_adapters_db_endpoint}</camunda:inputParameter>
<camunda:inputParameter name="headers">
<camunda:outputParameter name="CVFMI_dbResponseCode">${statusCode}</camunda:outputParameter>
<camunda:outputParameter name="CVFMI_dbResponse">${response}</camunda:outputParameter>
</camunda:inputOutput>
+ <camunda:connectorId>http-connector</camunda:connectorId>
</camunda:connector>
</bpmn2:extensionElements>
<bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>
</bpmn2:serviceTask>
- <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="PrepareUpdateInfraRequest" targetRef="ServiceTask_1"/>
- <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="ServiceTask_1" targetRef="UpdateInfraRequestResponseCheck"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="PrepareUpdateInfraRequest" targetRef="ServiceTask_1" />
+ <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="ServiceTask_1" targetRef="UpdateInfraRequestResponseCheck" />
<bpmn2:scriptTask id="PrepareMSOCompletionHandler" name="Prepare MSO Completion Handler" scriptFormat="groovy">
<bpmn2:incoming>updateInfraRequestResponseGood</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_12</bpmn2:outgoing>
def createVfModule = new CreateVfModuleInfra()
createVfModule.postProcessResponse(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_12" name="" sourceRef="PrepareMSOCompletionHandler" targetRef="MSOCompletionHandler"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_12" name="" sourceRef="PrepareMSOCompletionHandler" targetRef="MSOCompletionHandler" />
<bpmn2:callActivity id="MSOCompletionHandler" name="MSO Completion Handler" calledElement="CompleteMsoProcess">
<bpmn2:extensionElements>
- <camunda:in source="CVFMI_msoCompletionRequest" target="CompleteMsoProcessRequest"/>
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled"/>
- <camunda:in source="mso-service-instance-id" target="mso-service-instance-id"/>
- <camunda:in source="mso-request-id" target="mso-request-id"/>
- <camunda:out source="CompleteMsoProcessResponse" target="CompleteMsoProcessResponse"/>
- <camunda:out source="CMSO_ErrorResponse" target="CMSO_ErrorResponse"/>
+ <camunda:in source="CVFMI_msoCompletionRequest" target="CompleteMsoProcessRequest" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="mso-service-instance-id" target="mso-service-instance-id" />
+ <camunda:in source="mso-request-id" target="mso-request-id" />
+ <camunda:out source="CompleteMsoProcessResponse" target="CompleteMsoProcessResponse" />
+ <camunda:out source="CMSO_ErrorResponse" target="CMSO_ErrorResponse" />
</bpmn2:extensionElements>
<bpmn2:incoming>SequenceFlow_12</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_14</bpmn2:outgoing>
<bpmn2:outgoing>updateInfraRequestResponseBad</bpmn2:outgoing>
<bpmn2:outgoing>updateInfraRequestResponseGood</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="updateInfraRequestResponseBad" name="no" sourceRef="UpdateInfraRequestResponseCheck" targetRef="EndEvent_2"/>
+ <bpmn2:sequenceFlow id="updateInfraRequestResponseBad" name="no" sourceRef="UpdateInfraRequestResponseCheck" targetRef="EndEvent_2" />
<bpmn2:sequenceFlow id="updateInfraRequestResponseGood" name="yes" sourceRef="UpdateInfraRequestResponseCheck" targetRef="PrepareMSOCompletionHandler">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CVFMI_dbResponseCode" ) == '200'}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
<bpmn2:endEvent id="EndEvent_2">
<bpmn2:incoming>updateInfraRequestResponseBad</bpmn2:incoming>
- <bpmn2:errorEventDefinition id="_ErrorEventDefinition_2" errorRef="Error_1"/>
+ <bpmn2:errorEventDefinition id="_ErrorEventDefinition_2" errorRef="Error_1" />
</bpmn2:endEvent>
<bpmn2:subProcess id="ErrorHandler" name="Error Handler" triggeredByEvent="true">
<bpmn2:scriptTask id="ValidateRollbackResponse" name="Validate Rollback Response" scriptFormat="groovy">
def createVfModule = new CreateVfModuleInfra()
createVfModule.validateRollbackResponse(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_21" name="" sourceRef="ValidateRollbackResponse" targetRef="InclusiveGateway_1"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_21" name="" sourceRef="ValidateRollbackResponse" targetRef="InclusiveGateway_1" />
<bpmn2:callActivity id="ScriptTask_1" name="Do CreateVfModule Rollback" calledElement="DoCreateVfModuleRollback">
<bpmn2:extensionElements>
- <camunda:in source="RollbackData" target="RollbackData"/>
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled"/>
- <camunda:in source="isVidRequest" target="isVidRequest"/>
- <camunda:out source="MSOWorkflowException" target="RollbackWorkflowException"/>
+ <camunda:in source="RollbackData" target="RollbackData" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="isVidRequest" target="isVidRequest" />
+ <camunda:out source="MSOWorkflowException" target="RollbackWorkflowException" />
</bpmn2:extensionElements>
<bpmn2:incoming>SequenceFlow_19</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_17</bpmn2:outgoing>
</bpmn2:callActivity>
- <bpmn2:sequenceFlow id="SequenceFlow_17" name="" sourceRef="ScriptTask_1" targetRef="ValidateRollbackResponse"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_17" name="" sourceRef="ScriptTask_1" targetRef="ValidateRollbackResponse" />
<bpmn2:startEvent id="StartEvent_2" name="Catch All Errors">
<bpmn2:outgoing>SequenceFlow_13</bpmn2:outgoing>
- <bpmn2:errorEventDefinition id="ErrorEventDefinition_1"/>
+ <bpmn2:errorEventDefinition id="ErrorEventDefinition_1" />
</bpmn2:startEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_13" name="" sourceRef="StartEvent_2" targetRef="ExclusiveGateway_1"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_13" name="" sourceRef="StartEvent_2" targetRef="ExclusiveGateway_1" />
<bpmn2:callActivity id="FalloutHandler" name="Fallout Handler" calledElement="FalloutHandler">
<bpmn2:extensionElements>
- <camunda:in source="CVFMI_FalloutHandlerRequest" target="FalloutHandlerRequest"/>
- <camunda:in source="mso-request-id" target="mso-request-id"/>
- <camunda:in source="mso-service-instance-id" target="mso-service-instance-id"/>
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled"/>
+ <camunda:in source="CVFMI_FalloutHandlerRequest" target="FalloutHandlerRequest" />
+ <camunda:in source="mso-request-id" target="mso-request-id" />
+ <camunda:in source="mso-service-instance-id" target="mso-service-instance-id" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
</bpmn2:extensionElements>
<bpmn2:incoming>SequenceFlow_10</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_11</bpmn2:outgoing>
</bpmn2:callActivity>
- <bpmn2:sequenceFlow id="SequenceFlow_11" name="" sourceRef="FalloutHandler" targetRef="EndEvent_3"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_11" name="" sourceRef="FalloutHandler" targetRef="EndEvent_3" />
<bpmn2:endEvent id="EndEvent_3">
<bpmn2:incoming>SequenceFlow_11</bpmn2:incoming>
- <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_11"/>
+ <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_11" />
</bpmn2:endEvent>
<bpmn2:scriptTask id="PrepareFalloutHandler" name="Prepare Fallout Handler" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_22</bpmn2:incoming>
def cvfm = new CreateVfModuleInfra()
cvfm.falloutHandlerPrep(execution, 'CVFMI_FalloutHandlerRequest')]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_10" name="" sourceRef="PrepareFalloutHandler" targetRef="FalloutHandler"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_10" name="" sourceRef="PrepareFalloutHandler" targetRef="FalloutHandler" />
<bpmn2:inclusiveGateway id="InclusiveGateway_1">
<bpmn2:incoming>SequenceFlow_21</bpmn2:incoming>
<bpmn2:incoming>isRollbackOnNoSequenceFlow</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_22</bpmn2:outgoing>
</bpmn2:inclusiveGateway>
- <bpmn2:sequenceFlow id="SequenceFlow_22" name="" sourceRef="InclusiveGateway_1" targetRef="PrepareFalloutHandler"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_22" name="" sourceRef="InclusiveGateway_1" targetRef="PrepareFalloutHandler" />
<bpmn2:exclusiveGateway id="ExclusiveGateway_1" name="Is Rollback On? " default="isRollbackOnNoSequenceFlow">
<bpmn2:incoming>SequenceFlow_13</bpmn2:incoming>
<bpmn2:outgoing>isRollbackOnNoSequenceFlow</bpmn2:outgoing>
<bpmn2:outgoing>IsRollbackOnYesSequenceFlow</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="isRollbackOnNoSequenceFlow" name="no" sourceRef="ExclusiveGateway_1" targetRef="InclusiveGateway_1"/>
+ <bpmn2:sequenceFlow id="isRollbackOnNoSequenceFlow" name="no" sourceRef="ExclusiveGateway_1" targetRef="InclusiveGateway_1" />
<bpmn2:scriptTask id="LogAndSaveOriginalException" name="Log and Save Original Exception" scriptFormat="groovy">
<bpmn2:incoming>IsRollbackOnYesSequenceFlow</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_19</bpmn2:outgoing>
<bpmn2:sequenceFlow id="IsRollbackOnYesSequenceFlow" name="yes" sourceRef="ExclusiveGateway_1" targetRef="LogAndSaveOriginalException">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("CVFMI_rollbackEnabled") == true}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="SequenceFlow_19" name="" sourceRef="LogAndSaveOriginalException" targetRef="ScriptTask_1"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_19" name="" sourceRef="LogAndSaveOriginalException" targetRef="ScriptTask_1" />
</bpmn2:subProcess>
<bpmn2:scriptTask id="SetSuccessIndicator" name="Set Success Indicator" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_14</bpmn2:incoming>
</bpmn2:scriptTask>
<bpmn2:endEvent id="EndEvent_1">
<bpmn2:incoming>SequenceFlow_16</bpmn2:incoming>
- <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_10"/>
+ <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_10" />
</bpmn2:endEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_14" name="" sourceRef="MSOCompletionHandler" targetRef="SetSuccessIndicator"/>
- <bpmn2:sequenceFlow id="SequenceFlow_16" name="" sourceRef="SetSuccessIndicator" targetRef="EndEvent_1"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_14" name="" sourceRef="MSOCompletionHandler" targetRef="SetSuccessIndicator" />
+ <bpmn2:sequenceFlow id="SequenceFlow_16" name="" sourceRef="SetSuccessIndicator" targetRef="EndEvent_1" />
<bpmn2:boundaryEvent id="BoundaryEvent_1" name="" attachedToRef="ErrorHandler">
<bpmn2:outgoing>SequenceFlow_15</bpmn2:outgoing>
- <bpmn2:errorEventDefinition id="_ErrorEventDefinition_3"/>
+ <bpmn2:errorEventDefinition id="_ErrorEventDefinition_3" />
</bpmn2:boundaryEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_15" name="" sourceRef="BoundaryEvent_1" targetRef="EndEvent_4"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_15" name="" sourceRef="BoundaryEvent_1" targetRef="EndEvent_4" />
<bpmn2:endEvent id="EndEvent_4">
<bpmn2:incoming>SequenceFlow_15</bpmn2:incoming>
- <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_12"/>
+ <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_12" />
</bpmn2:endEvent>
<bpmn2:scriptTask id="PreProcessRequest" name="Pre-Process Request" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
def createVfModule = new CreateVfModuleInfra()
createVfModule.preProcessRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="PreProcessRequest" targetRef="SendResponse"/>
+ <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="PreProcessRequest" targetRef="SendResponse" />
</bpmn2:process>
- <bpmn2:error id="Error_1" errorCode="MSOWorkflowException" name="MSOWorkflowException"/>
- <bpmn2:error id="Error_2" errorCode="RESTFault" name="REST Fault"/>
+ <bpmn2:error id="Error_1" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
+ <bpmn2:error id="Error_2" name="REST Fault" errorCode="RESTFault" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="CreateVfModuleInfra">
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_50" bpmnElement="StartEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="41.0" y="231.0"/>
+ <dc:Bounds x="41" y="231" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_50" targetElement="_BPMNShape_ScriptTask_124">
- <di:waypoint xsi:type="dc:Point" x="77.0" y="249.0"/>
- <di:waypoint xsi:type="dc:Point" x="226.0" y="249.0"/>
+ <di:waypoint xsi:type="dc:Point" x="77" y="249" />
+ <di:waypoint xsi:type="dc:Point" x="226" y="249" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="99.0" y="249.0"/>
+ <dc:Bounds x="99" y="249" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_124" bpmnElement="PreProcessRequest">
- <dc:Bounds height="80.0" width="100.0" x="226.0" y="209.0"/>
+ <dc:Bounds x="226" y="209" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ServiceTask_86" bpmnElement="SendResponse">
- <dc:Bounds height="80.0" width="100.0" x="432.0" y="209.0"/>
+ <dc:Bounds x="432" y="209" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_124" targetElement="_BPMNShape_ServiceTask_86">
- <di:waypoint xsi:type="dc:Point" x="326.0" y="249.0"/>
- <di:waypoint xsi:type="dc:Point" x="432.0" y="249.0"/>
+ <di:waypoint xsi:type="dc:Point" x="326" y="249" />
+ <di:waypoint xsi:type="dc:Point" x="432" y="249" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="348.0" y="249.0"/>
+ <dc:Bounds x="348" y="249" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_178" bpmnElement="DoCreateVfModuleSubprocess">
- <dc:Bounds height="80.0" width="145.0" x="612.0" y="209.0"/>
+ <dc:Bounds x="612" y="209" width="145" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_7" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ServiceTask_86" targetElement="_BPMNShape_ScriptTask_178">
- <di:waypoint xsi:type="dc:Point" x="532.0" y="249.0"/>
- <di:waypoint xsi:type="dc:Point" x="612.0" y="249.0"/>
+ <di:waypoint xsi:type="dc:Point" x="532" y="249" />
+ <di:waypoint xsi:type="dc:Point" x="612" y="249" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_47" bpmnElement="IntermediateThrowEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="823.0" y="231.0"/>
+ <dc:Bounds x="823" y="231" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="841.0" y="272.0"/>
+ <dc:Bounds x="841" y="272" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_4" sourceElement="_BPMNShape_ScriptTask_178" targetElement="_BPMNShape_IntermediateThrowEvent_47">
- <di:waypoint xsi:type="dc:Point" x="756.0" y="249.0"/>
- <di:waypoint xsi:type="dc:Point" x="823.0" y="249.0"/>
+ <di:waypoint xsi:type="dc:Point" x="756" y="249" />
+ <di:waypoint xsi:type="dc:Point" x="823" y="249" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_32" bpmnElement="IntermediateCatchEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="39.0" y="349.0"/>
+ <dc:Bounds x="39" y="349" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="65.0" x="25.0" y="390.0"/>
+ <dc:Bounds x="25" y="390" width="65" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_219" bpmnElement="PrepareUpdateInfraRequest">
- <dc:Bounds height="80.0" width="100.0" x="127.0" y="327.0"/>
+ <dc:Bounds x="127" y="327" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ServiceTask_103" bpmnElement="ServiceTask_1">
- <dc:Bounds height="80.0" width="100.0" x="277.0" y="327.0"/>
+ <dc:Bounds x="277" y="327" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_179" bpmnElement="UpdateInfraRequestResponseCheck" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="443.0" y="341.0"/>
+ <dc:Bounds x="443" y="341" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="68.0" x="435.0" y="308.0"/>
+ <dc:Bounds x="435" y="308" width="68" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_220" bpmnElement="PrepareMSOCompletionHandler">
- <dc:Bounds height="80.0" width="100.0" x="552.0" y="327.0"/>
+ <dc:Bounds x="552" y="327" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_221" bpmnElement="MSOCompletionHandler">
- <dc:Bounds height="80.0" width="100.0" x="708.0" y="327.0"/>
+ <dc:Bounds x="708" y="327" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="EndEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="1020.0" y="349.0"/>
+ <dc:Bounds x="1020" y="349" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="1038.0" y="390.0"/>
+ <dc:Bounds x="1038" y="390" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_178" bpmnElement="EndEvent_2">
- <dc:Bounds height="36.0" width="36.0" x="452.0" y="469.0"/>
+ <dc:Bounds x="452" y="469" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="470.0" y="510.0"/>
+ <dc:Bounds x="470" y="510" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_5" sourceElement="_BPMNShape_IntermediateCatchEvent_32" targetElement="_BPMNShape_ScriptTask_219">
- <di:waypoint xsi:type="dc:Point" x="75.0" y="367.0"/>
- <di:waypoint xsi:type="dc:Point" x="127.0" y="367.0"/>
+ <di:waypoint xsi:type="dc:Point" x="75" y="367" />
+ <di:waypoint xsi:type="dc:Point" x="127" y="367" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="105.0" y="367.0"/>
+ <dc:Bounds x="105" y="367" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_6" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_ScriptTask_219" targetElement="_BPMNShape_ServiceTask_103">
- <di:waypoint xsi:type="dc:Point" x="227.0" y="367.0"/>
- <di:waypoint xsi:type="dc:Point" x="277.0" y="367.0"/>
+ <di:waypoint xsi:type="dc:Point" x="227" y="367" />
+ <di:waypoint xsi:type="dc:Point" x="277" y="367" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_ServiceTask_103" targetElement="_BPMNShape_ExclusiveGateway_179">
- <di:waypoint xsi:type="dc:Point" x="377.0" y="367.0"/>
- <di:waypoint xsi:type="dc:Point" x="410.0" y="367.0"/>
- <di:waypoint xsi:type="dc:Point" x="410.0" y="366.0"/>
- <di:waypoint xsi:type="dc:Point" x="443.0" y="366.0"/>
+ <di:waypoint xsi:type="dc:Point" x="377" y="367" />
+ <di:waypoint xsi:type="dc:Point" x="410" y="367" />
+ <di:waypoint xsi:type="dc:Point" x="410" y="366" />
+ <di:waypoint xsi:type="dc:Point" x="443" y="366" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="407.0" y="366.0"/>
+ <dc:Bounds x="407" y="366" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_9" bpmnElement="updateInfraRequestResponseBad" sourceElement="_BPMNShape_ExclusiveGateway_179" targetElement="_BPMNShape_EndEvent_178">
- <di:waypoint xsi:type="dc:Point" x="468.0" y="391.0"/>
- <di:waypoint xsi:type="dc:Point" x="469.0" y="421.0"/>
- <di:waypoint xsi:type="dc:Point" x="470.0" y="421.0"/>
- <di:waypoint xsi:type="dc:Point" x="470.0" y="469.0"/>
+ <di:waypoint xsi:type="dc:Point" x="468" y="391" />
+ <di:waypoint xsi:type="dc:Point" x="469" y="421" />
+ <di:waypoint xsi:type="dc:Point" x="470" y="421" />
+ <di:waypoint xsi:type="dc:Point" x="470" y="469" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="20.0" x="459.0" y="419.0"/>
+ <dc:Bounds x="459" y="419" width="20" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_11" bpmnElement="updateInfraRequestResponseGood" sourceElement="_BPMNShape_ExclusiveGateway_179" targetElement="_BPMNShape_ScriptTask_220">
- <di:waypoint xsi:type="dc:Point" x="493.0" y="366.0"/>
- <di:waypoint xsi:type="dc:Point" x="523.0" y="366.0"/>
- <di:waypoint xsi:type="dc:Point" x="523.0" y="367.0"/>
- <di:waypoint xsi:type="dc:Point" x="552.0" y="367.0"/>
+ <di:waypoint xsi:type="dc:Point" x="493" y="366" />
+ <di:waypoint xsi:type="dc:Point" x="523" y="366" />
+ <di:waypoint xsi:type="dc:Point" x="523" y="367" />
+ <di:waypoint xsi:type="dc:Point" x="552" y="367" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="27.0" x="510.0" y="367.0"/>
+ <dc:Bounds x="510" y="367" width="27" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_12" sourceElement="_BPMNShape_ScriptTask_220" targetElement="_BPMNShape_ScriptTask_221">
- <di:waypoint xsi:type="dc:Point" x="652.0" y="367.0"/>
- <di:waypoint xsi:type="dc:Point" x="708.0" y="367.0"/>
+ <di:waypoint xsi:type="dc:Point" x="652" y="367" />
+ <di:waypoint xsi:type="dc:Point" x="708" y="367" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="678.0" y="367.0"/>
+ <dc:Bounds x="678" y="367" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_SubProcess_20" bpmnElement="ErrorHandler" isExpanded="true">
- <dc:Bounds height="385.0" width="925.0" x="48.0" y="540.0"/>
+ <dc:Bounds x="48" y="540" width="925" height="385" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_54" bpmnElement="StartEvent_2">
- <dc:Bounds height="36.0" width="36.0" x="72.0" y="844.0"/>
+ <dc:Bounds x="72" y="844" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="98.0" x="60.0" y="886.0"/>
+ <dc:Bounds x="60" y="886" width="98" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_222" bpmnElement="PrepareFalloutHandler">
- <dc:Bounds height="80.0" width="100.0" x="564.0" y="672.0"/>
+ <dc:Bounds x="564" y="672" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_223" bpmnElement="FalloutHandler">
- <dc:Bounds height="80.0" width="100.0" x="708.0" y="672.0"/>
+ <dc:Bounds x="708" y="672" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_179" bpmnElement="EndEvent_3">
- <dc:Bounds height="36.0" width="36.0" x="864.0" y="694.0"/>
+ <dc:Bounds x="864" y="694" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="882.0" y="735.0"/>
+ <dc:Bounds x="882" y="735" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_BoundaryEvent_44" bpmnElement="BoundaryEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="955.0" y="690.0"/>
+ <dc:Bounds x="955" y="690" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="970.0" y="731.0"/>
+ <dc:Bounds x="970" y="731" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_180" bpmnElement="EndEvent_4">
- <dc:Bounds height="36.0" width="36.0" x="1049.0" y="690.0"/>
+ <dc:Bounds x="1049" y="690" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="1067.0" y="731.0"/>
+ <dc:Bounds x="1067" y="731" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_14" bpmnElement="SequenceFlow_10" sourceElement="_BPMNShape_ScriptTask_222" targetElement="_BPMNShape_ScriptTask_223">
- <di:waypoint xsi:type="dc:Point" x="664.0" y="712.0"/>
- <di:waypoint xsi:type="dc:Point" x="708.0" y="712.0"/>
+ <di:waypoint xsi:type="dc:Point" x="664" y="712" />
+ <di:waypoint xsi:type="dc:Point" x="708" y="712" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="689.0" y="712.0"/>
+ <dc:Bounds x="689" y="712" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_15" bpmnElement="SequenceFlow_11" sourceElement="_BPMNShape_ScriptTask_223" targetElement="_BPMNShape_EndEvent_179">
- <di:waypoint xsi:type="dc:Point" x="808.0" y="712.0"/>
- <di:waypoint xsi:type="dc:Point" x="864.0" y="712.0"/>
+ <di:waypoint xsi:type="dc:Point" x="808" y="712" />
+ <di:waypoint xsi:type="dc:Point" x="864" y="712" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="836.0" y="712.0"/>
+ <dc:Bounds x="836" y="712" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_17" bpmnElement="SequenceFlow_15" sourceElement="_BPMNShape_BoundaryEvent_44" targetElement="_BPMNShape_EndEvent_180">
- <di:waypoint xsi:type="dc:Point" x="991.0" y="708.0"/>
- <di:waypoint xsi:type="dc:Point" x="1049.0" y="708.0"/>
+ <di:waypoint xsi:type="dc:Point" x="991" y="708" />
+ <di:waypoint xsi:type="dc:Point" x="1049" y="708" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1015.0" y="708.0"/>
+ <dc:Bounds x="1015" y="708" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_241" bpmnElement="SetSuccessIndicator">
- <dc:Bounds height="79.0" width="103.0" x="858.0" y="328.0"/>
+ <dc:Bounds x="858" y="328" width="103" height="79" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_16" bpmnElement="SequenceFlow_14" sourceElement="_BPMNShape_ScriptTask_221" targetElement="_BPMNShape_ScriptTask_241">
- <di:waypoint xsi:type="dc:Point" x="808.0" y="367.0"/>
- <di:waypoint xsi:type="dc:Point" x="858.0" y="367.0"/>
+ <di:waypoint xsi:type="dc:Point" x="808" y="367" />
+ <di:waypoint xsi:type="dc:Point" x="858" y="367" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_18" bpmnElement="SequenceFlow_16" sourceElement="_BPMNShape_ScriptTask_241" targetElement="_BPMNShape_EndEvent_177">
- <di:waypoint xsi:type="dc:Point" x="960.0" y="367.0"/>
- <di:waypoint xsi:type="dc:Point" x="1020.0" y="367.0"/>
+ <di:waypoint xsi:type="dc:Point" x="960" y="367" />
+ <di:waypoint xsi:type="dc:Point" x="1020" y="367" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_223" bpmnElement="ExclusiveGateway_1" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="205.0" y="836.0"/>
+ <dc:Bounds x="205" y="836" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="102.0" x="193.0" y="901.0"/>
+ <dc:Bounds x="193" y="901" width="102" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_266" bpmnElement="ValidateRollbackResponse">
- <dc:Bounds height="79.0" width="103.0" x="312.0" y="554.0"/>
+ <dc:Bounds x="312" y="554" width="103" height="79" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_InclusiveGateway_25" bpmnElement="InclusiveGateway_1">
- <dc:Bounds height="50.0" width="50.0" x="459.0" y="686.0"/>
+ <dc:Bounds x="459" y="686" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="484.0" y="741.0"/>
+ <dc:Bounds x="484" y="741" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_13" bpmnElement="SequenceFlow_13" sourceElement="_BPMNShape_StartEvent_54" targetElement="_BPMNShape_ExclusiveGateway_223">
- <di:waypoint xsi:type="dc:Point" x="108.0" y="862.0"/>
- <di:waypoint xsi:type="dc:Point" x="156.0" y="862.0"/>
- <di:waypoint xsi:type="dc:Point" x="156.0" y="861.0"/>
- <di:waypoint xsi:type="dc:Point" x="205.0" y="861.0"/>
+ <di:waypoint xsi:type="dc:Point" x="108" y="862" />
+ <di:waypoint xsi:type="dc:Point" x="156" y="862" />
+ <di:waypoint xsi:type="dc:Point" x="156" y="861" />
+ <di:waypoint xsi:type="dc:Point" x="205" y="861" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="153.0" y="862.0"/>
+ <dc:Bounds x="153" y="862" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_20" bpmnElement="isRollbackOnNoSequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_223" targetElement="_BPMNShape_InclusiveGateway_25">
- <di:waypoint xsi:type="dc:Point" x="255.0" y="861.0"/>
- <di:waypoint xsi:type="dc:Point" x="354.0" y="861.0"/>
- <di:waypoint xsi:type="dc:Point" x="354.0" y="711.0"/>
- <di:waypoint xsi:type="dc:Point" x="459.0" y="711.0"/>
+ <di:waypoint xsi:type="dc:Point" x="255" y="861" />
+ <di:waypoint xsi:type="dc:Point" x="354" y="861" />
+ <di:waypoint xsi:type="dc:Point" x="354" y="711" />
+ <di:waypoint xsi:type="dc:Point" x="459" y="711" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="20.0" x="324.0" y="866.0"/>
+ <dc:Bounds x="324" y="866" width="20" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_23" bpmnElement="SequenceFlow_21" sourceElement="_BPMNShape_ScriptTask_266" targetElement="_BPMNShape_InclusiveGateway_25">
- <di:waypoint xsi:type="dc:Point" x="414.0" y="593.0"/>
- <di:waypoint xsi:type="dc:Point" x="484.0" y="593.0"/>
- <di:waypoint xsi:type="dc:Point" x="484.0" y="686.0"/>
+ <di:waypoint xsi:type="dc:Point" x="414" y="593" />
+ <di:waypoint xsi:type="dc:Point" x="484" y="593" />
+ <di:waypoint xsi:type="dc:Point" x="484" y="686" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="462.0" y="593.0"/>
+ <dc:Bounds x="462" y="593" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_24" bpmnElement="SequenceFlow_22" sourceElement="_BPMNShape_InclusiveGateway_25" targetElement="_BPMNShape_ScriptTask_222">
- <di:waypoint xsi:type="dc:Point" x="509.0" y="711.0"/>
- <di:waypoint xsi:type="dc:Point" x="527.0" y="711.0"/>
- <di:waypoint xsi:type="dc:Point" x="527.0" y="712.0"/>
- <di:waypoint xsi:type="dc:Point" x="564.0" y="712.0"/>
+ <di:waypoint xsi:type="dc:Point" x="509" y="711" />
+ <di:waypoint xsi:type="dc:Point" x="527" y="711" />
+ <di:waypoint xsi:type="dc:Point" x="527" y="712" />
+ <di:waypoint xsi:type="dc:Point" x="564" y="712" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="533.0" y="712.0"/>
+ <dc:Bounds x="533" y="712" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_267" bpmnElement="ScriptTask_1">
- <dc:Bounds height="79.0" width="103.0" x="179.0" y="554.0"/>
+ <dc:Bounds x="179" y="554" width="103" height="79" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_22" bpmnElement="SequenceFlow_17" sourceElement="_BPMNShape_ScriptTask_267" targetElement="_BPMNShape_ScriptTask_266">
- <di:waypoint xsi:type="dc:Point" x="281.0" y="593.0"/>
- <di:waypoint xsi:type="dc:Point" x="312.0" y="593.0"/>
+ <di:waypoint xsi:type="dc:Point" x="281" y="593" />
+ <di:waypoint xsi:type="dc:Point" x="312" y="593" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="294.0" y="593.0"/>
+ <dc:Bounds x="294" y="593" width="6" height="6" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_283" bpmnElement="LogAndSaveOriginalException">
- <dc:Bounds height="79.0" width="103.0" x="179.0" y="693.0"/>
+ <dc:Bounds x="179" y="693" width="103" height="79" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_21" bpmnElement="IsRollbackOnYesSequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_223" targetElement="_BPMNShape_ScriptTask_283">
- <di:waypoint xsi:type="dc:Point" x="230.0" y="836.0"/>
- <di:waypoint xsi:type="dc:Point" x="230.0" y="771.0"/>
+ <di:waypoint xsi:type="dc:Point" x="230" y="836" />
+ <di:waypoint xsi:type="dc:Point" x="230" y="771" />
<bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="27.0" x="240.0" y="804.0"/>
+ <dc:Bounds x="240" y="804" width="27" height="22" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_25" bpmnElement="SequenceFlow_19" sourceElement="_BPMNShape_ScriptTask_283" targetElement="_BPMNShape_ScriptTask_267">
- <di:waypoint xsi:type="dc:Point" x="230.0" y="693.0"/>
- <di:waypoint xsi:type="dc:Point" x="230.0" y="632.0"/>
+ <di:waypoint xsi:type="dc:Point" x="230" y="693" />
+ <di:waypoint xsi:type="dc:Point" x="230" y="632" />
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
-</bpmn2:definitions>
\ No newline at end of file
+</bpmn2:definitions>
<bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="sendResponse" targetRef="CreateVNF" />
<bpmn2:callActivity id="CreateVNF" name="Create VNF" calledElement="DoCreateVnf">
<bpmn2:extensionElements>
- <camunda:in source="CREVI_requestId" target="requestId" />
+ <camunda:in source="CREVI_requestId" target="msoRequestId" />
<camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
<camunda:in source="CREVI_serviceInstanceId" target="serviceInstanceId" />
<camunda:in source="CREVI_suppressRollback" target="disableRollback" />
<camunda:in source="CREVI_vnfType" target="vnfType" />
<camunda:in source="CREVI_vnfName" target="vnfName" />
<camunda:in source="CREVI_vnfId" target="vnfId" />
- <camunda:in source="CREVI_cloudConfiguration" target="cloudConfiguration" />
<camunda:in source="CREVI_serviceId" target="productFamilyId" />
<camunda:in source="CREVI_vnfInputParameters" target="vnfInputParameters" />
<camunda:out source="vnfId" target="CREVI_vnfId" />
<camunda:out source="vnfOutputParameters" target="CREVI_vnfOutputParameters" />
<camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:in source="CREVI_lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="CREVI_tenantId" target="tenandId" />
</bpmn2:extensionElements>
<bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0lso26t</bpmn2:outgoing>
<?xml version="1.0" encoding="UTF-8"?>
<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
- <bpmn2:process id="DelServiceInstance" name="DelServiceInstance" isExecutable="true">
+ <bpmn2:process id="DeleteGenericALaCarteServiceInstance" name="DeleteGenericALaCarteServiceInstance" isExecutable="true">
<bpmn2:startEvent id="deleteSI_startEvent" name="Delete SI Start Flow">
<bpmn2:outgoing>SequenceFlow_0lp2z7l</bpmn2:outgoing>
</bpmn2:startEvent>
<bpmn2:scriptTask id="ScriptTask_1" name="Handle Unexpected Error" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_10</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_14</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.utils.*
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.common.scripts.*
ExceptionUtil ex = new ExceptionUtil()
ex.processJavaException(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:scriptTask id="ScriptTask_0pvcr6j" name="Pre Process Incoming Request" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_0lp2z7l</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0ktadna</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi= new DelServiceInstance()
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
+def csi= new DeleteGenericALaCarteServiceInstance()
csi.preProcessRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_0lp2z7l" sourceRef="deleteSI_startEvent" targetRef="ScriptTask_0pvcr6j" />
<bpmn2:scriptTask id="ScriptTask_0cihgpv" name="Prepare Completion Request" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_1qjygj5</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0xxvjxq</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi = new DelServiceInstance()
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
+def csi = new DeleteGenericALaCarteServiceInstance()
csi.prepareCompletionRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:callActivity id="CallActivity_0sevgre" name="Call CompleteMsoProcess" calledElement="CompleteMsoProcess">
<bpmn2:scriptTask id="ScriptTask_1hql91g" name="Prepare Fallout Request" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_14eadeb</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1reso2f</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi = new DelServiceInstance()
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
+def csi = new DeleteGenericALaCarteServiceInstance()
csi.prepareFalloutRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:callActivity id="CallActivity_1ksm1dz" name="Call FalloutHandler" calledElement="FalloutHandler">
<bpmn2:scriptTask id="ScriptTask_0o4smqp" name="Send Error Response">
<bpmn2:incoming>SequenceFlow_0n4umjf</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_14eadeb</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi = new DelServiceInstance()
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
+def csi = new DeleteGenericALaCarteServiceInstance()
csi.sendSyncError(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_14eadeb" sourceRef="ScriptTask_0o4smqp" targetRef="ScriptTask_1hql91g" />
<bpmn2:scriptTask id="Task_1nko5zz" name="Send Sync Ack Response" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_0ktadna</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0eto8sn</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def csi = new DelServiceInstance()
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
+def csi = new DeleteGenericALaCarteServiceInstance()
csi.sendSyncResponse(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_0ktadna" sourceRef="ScriptTask_0pvcr6j" targetRef="Task_1nko5zz" />
<bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
<bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DelServiceInstance">
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DeleteGenericALaCarteServiceInstance">
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="deleteSI_startEvent">
<dc:Bounds x="117" y="79" width="36" height="36" />
<bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
-</bpmn2:definitions>
+</bpmn2:definitions>
\ No newline at end of file
-<?xml version="1.0" encoding="UTF-8"?>\r
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">\r
- <bpmn2:process id="DeleteGenericMacroServiceNetworkVnf" name="DeleteGenericMacroServiceNetworkVnf" isExecutable="true">\r
- <bpmn2:scriptTask id="sendSyncAckResponse_ScriptTask" name="Send Sync Ack Response" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+ <bpmn2:process id="DeleteGenericMacroServiceNetworkVnf" name="DeleteGenericMacroServiceNetworkVnf" isExecutable="true">
+ <bpmn2:scriptTask id="sendSyncAckResponse_ScriptTask" name="Send Sync Ack Response" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.sendSyncResponse(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="sendSyncAckResponse_ScriptTask" targetRef="IntermediateThrowEvent_2" />\r
- <bpmn2:startEvent id="createVIPR_startEvent" name="Start Flow">\r
- <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>\r
- </bpmn2:startEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="createVIPR_startEvent" targetRef="preProcessRequest_ScriptTask" />\r
- <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>\r
+def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.sendSyncResponse(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="sendSyncAckResponse_ScriptTask" targetRef="IntermediateThrowEvent_2" />
+ <bpmn2:startEvent id="createVIPR_startEvent" name="Start Flow">
+ <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
+ </bpmn2:startEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="createVIPR_startEvent" targetRef="preProcessRequest_ScriptTask" />
+ <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.preProcessRequest(execution)\r
-]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="sendSyncAckResponse_ScriptTask" />\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_3" name="vIPR-ATM">\r
- <bpmn2:outgoing>SequenceFlow_10o22u2</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_37" name="vIPR-ATM" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:scriptTask id="postProcessAndCompletionRequest_ScriptTask" name="Post Process & Completion Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_12ilko1</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_29</bpmn2:outgoing>\r
+def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.preProcessRequest(execution)
+]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="sendSyncAckResponse_ScriptTask" />
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_3" name="vIPR-ATM">
+ <bpmn2:outgoing>SequenceFlow_10o22u2</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_37" name="vIPR-ATM" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:scriptTask id="postProcessAndCompletionRequest_ScriptTask" name="Post Process & Completion Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_12ilko1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_29</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.postProcessResponse(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_29" name="" sourceRef="postProcessAndCompletionRequest_ScriptTask" targetRef="callCompleteMsoProcess_CallActivity" />\r
- <bpmn2:callActivity id="callCompleteMsoProcess_CallActivity" name="Call CompleteMsoProcess" calledElement="CompleteMsoProcess">\r
- <bpmn2:extensionElements>\r
- <camunda:in variables="all" />\r
- <camunda:out variables="all" />\r
- <camunda:in source="DELVAS_CompleteMsoProcessRequest" target="CompleteMsoProcessRequest" />\r
- <camunda:in source="requestId" target="requestId" />\r
- <camunda:in source="serviceInstanceId" target="serviceInstanceId" />\r
- <camunda:out source="CMSO_ResponseCode" target="CMSO_ResponseCode" />\r
- <camunda:out source="CompleteMsoProcessResponse" target="CompleteMsoProcessResponse" />\r
- <camunda:out source="CMSO_ErrorResponse" target="CMSO_ErrorResponse" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_29</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="callCompleteMsoProcess_CallActivity" targetRef="ScriptTask_2" />\r
- <bpmn2:scriptTask id="ScriptTask_2" name="Set Success Indicator" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>\r
- <bpmn2:script><![CDATA[// The following variable is checked by the unit test\r
-execution.setVariable("DeleteGenericMacroServiceNetworkVnfSuccessIndicator", true)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="ScriptTask_2" targetRef="DeleteVIPR_EndEvent" />\r
- <bpmn2:endEvent id="DeleteVIPR_EndEvent" name="End">\r
- <bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>\r
- <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_13" />\r
- </bpmn2:endEvent>\r
- <bpmn2:subProcess id="UnexpectedError_SubProcess_1" name="Sub-process for UnexpectedErrors" triggeredByEvent="true">\r
- <bpmn2:startEvent id="StartEvent_1">\r
- <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>\r
- <bpmn2:errorEventDefinition id="_ErrorEventDefinition_92" errorRef="Error_1" />\r
- </bpmn2:startEvent>\r
- <bpmn2:endEvent id="EndEvent_1">\r
- <bpmn2:incoming>SequenceFlow_5</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="StartEvent_1" targetRef="ScriptTask_1" />\r
- <bpmn2:scriptTask id="ScriptTask_1" name="Log / Print Unexpected Error" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_5</bpmn2:outgoing>\r
+def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.postProcessResponse(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_29" name="" sourceRef="postProcessAndCompletionRequest_ScriptTask" targetRef="callCompleteMsoProcess_CallActivity" />
+ <bpmn2:callActivity id="callCompleteMsoProcess_CallActivity" name="Call CompleteMsoProcess" calledElement="CompleteMsoProcess">
+ <bpmn2:extensionElements>
+ <camunda:in variables="all" />
+ <camunda:out variables="all" />
+ <camunda:in source="DELVAS_CompleteMsoProcessRequest" target="CompleteMsoProcessRequest" />
+ <camunda:in source="requestId" target="requestId" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:out source="CMSO_ResponseCode" target="CMSO_ResponseCode" />
+ <camunda:out source="CompleteMsoProcessResponse" target="CompleteMsoProcessResponse" />
+ <camunda:out source="CMSO_ErrorResponse" target="CMSO_ErrorResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_29</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="callCompleteMsoProcess_CallActivity" targetRef="ScriptTask_2" />
+ <bpmn2:scriptTask id="ScriptTask_2" name="Set Success Indicator" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[// The following variable is checked by the unit test
+execution.setVariable("DeleteGenericMacroServiceNetworkVnfSuccessIndicator", true)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="ScriptTask_2" targetRef="DeleteVIPR_EndEvent" />
+ <bpmn2:endEvent id="DeleteVIPR_EndEvent" name="End">
+ <bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
+ <bpmn2:terminateEventDefinition id="_TerminateEventDefinition_13" />
+ </bpmn2:endEvent>
+ <bpmn2:subProcess id="UnexpectedError_SubProcess_1" name="Sub-process for UnexpectedErrors" triggeredByEvent="true">
+ <bpmn2:startEvent id="StartEvent_1">
+ <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
+ <bpmn2:errorEventDefinition id="_ErrorEventDefinition_92" errorRef="Error_1" />
+ </bpmn2:startEvent>
+ <bpmn2:endEvent id="EndEvent_1">
+ <bpmn2:incoming>SequenceFlow_5</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="StartEvent_1" targetRef="ScriptTask_1" />
+ <bpmn2:scriptTask id="ScriptTask_1" name="Log / Print Unexpected Error" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_5</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteServiceInstanceInfra = new DeleteServiceInstanceInfra()\r
-DeleteServiceInstanceInfra.processJavaException(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="ScriptTask_1" targetRef="EndEvent_1" />\r
- </bpmn2:subProcess>\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_4" name="FinishProcess">\r
- <bpmn2:outgoing>SequenceFlow_12ilko1</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_39" name="FinishProcess" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:callActivity id="doDeleteNetworkInstance_CallActivity" name="DoDelete Network Instance" calledElement="DoDeleteNetworkInstance">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />\r
- <camunda:in source="tenantId" target="tenantId" />\r
- <camunda:in source="disableRollback" target="disableRollback" />\r
- <camunda:in source="serviceInstanceId" target="serviceInstanceId" />\r
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />\r
- <camunda:in source="failIfExists" target="failIfExists" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="rollbackData" target="DELNWKI_rollbackData" />\r
- <camunda:out source="rolledBack" target="DELNWKI_rolledBack" />\r
- <camunda:out source="wasDeleted" target="wasDeleted" />\r
- <camunda:in source="networkId" target="networkId" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1bwbn7r</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_12ag2bk</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:scriptTask id="ScriptTask_PrepareNetworkDelete" name="Prepare for Network Delete" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0cmebdc</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0dfkfh1</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1bwbn7r</bpmn2:outgoing>\r
+def DeleteServiceInstanceInfra = new DeleteServiceInstanceInfra()
+DeleteServiceInstanceInfra.processJavaException(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="ScriptTask_1" targetRef="EndEvent_1" />
+ </bpmn2:subProcess>
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_4" name="FinishProcess">
+ <bpmn2:outgoing>SequenceFlow_12ilko1</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_39" name="FinishProcess" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:callActivity id="doDeleteNetworkInstance_CallActivity" name="DoDelete Network Instance" calledElement="DoDeleteNetworkInstance">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="tenantId" target="tenantId" />
+ <camunda:in source="disableRollback" target="disableRollback" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="failIfExists" target="failIfExists" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="rollbackData" target="DELNWKI_rollbackData" />
+ <camunda:out source="rolledBack" target="DELNWKI_rolledBack" />
+ <camunda:out source="wasDeleted" target="wasDeleted" />
+ <camunda:in source="networkId" target="networkId" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1bwbn7r</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_12ag2bk</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_PrepareNetworkDelete" name="Prepare for Network Delete" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0cmebdc</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0dfkfh1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1bwbn7r</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf= new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.prepareNetworkDelete(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:callActivity id="doDeleteServiceInstance_CallActivity" name="DoDelete ServiceInstance " calledElement="DoDeleteServiceInstance">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:in source="serviceInstanceId" target="serviceInstanceId" />\r
- <camunda:out source="rollbackData" target="DCRESI_rollbackData" />\r
- <camunda:in source="failExists" target="failExists" />\r
- <camunda:in source="disableRollback" target="disableRollback" />\r
- <camunda:out source="rolledBack" target="DCRESI_rolledBack" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_10o22u2</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_04ao07f</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:callActivity id="doDeleteVNFandModules_CallActivity" name="DoDelete VNF and Modules " calledElement="DoDeleteVnfAndModules">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="msoRequestId" />\r
- <camunda:in source="disableRollback" target="disableRollback" />\r
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />\r
- <camunda:in source="serviceInstanceId" target="serviceInstanceId" />\r
- <camunda:in source="vnftId" target="vnftId" />\r
- <camunda:in source="sdncVersion" target="sdncVersion" />\r
- <camunda:out source="rollbackData" target="rollbackData" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="rolledBack" target="rolledBack" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1h77psn</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1dmn40p</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:scriptTask id="ScriptTask_3" name="Prepare to Delete VNF" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0bvecvm</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0mr8jgt</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1h77psn</bpmn2:outgoing>\r
+def DeleteGenericMacroServiceNetworkVnf= new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.prepareNetworkDelete(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:callActivity id="doDeleteServiceInstance_CallActivity" name="DoDelete ServiceInstance " calledElement="DoDeleteServiceInstance">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:out source="rollbackData" target="DCRESI_rollbackData" />
+ <camunda:in source="failExists" target="failExists" />
+ <camunda:in source="disableRollback" target="disableRollback" />
+ <camunda:out source="rolledBack" target="DCRESI_rolledBack" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_10o22u2</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_04ao07f</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:callActivity id="doDeleteVNFandModules_CallActivity" name="DoDelete VNF and Modules " calledElement="DoDeleteVnfAndModules">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="disableRollback" target="disableRollback" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:in source="vnfId" target="vnfId" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ <camunda:out source="rollbackData" target="rollbackData" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="rolledBack" target="rolledBack" />
+ <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="tenantId" target="tenantId" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1h77psn</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1dmn40p</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_3" name="Prepare to Delete VNF" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0bvecvm</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0mr8jgt</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1h77psn</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf= new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.prepareVnfAndModulesDelete(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_4" name="GoToStartNetworks">\r
- <bpmn2:incoming>SequenceFlow_0xowenu</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_41" name="StartNetworks" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_2" name="GoQueryServiceInstance">\r
- <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition id="_LinkEventDefinition_38" name="QueryServiceInstance" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:subProcess id="SubProcess_0s6hpty" name="Subprocess For Exception / FalloutHandler " triggeredByEvent="true">\r
- <bpmn2:startEvent id="StartEvent_1bwmffk" name="Fault Start">\r
- <bpmn2:outgoing>SequenceFlow_06llof4</bpmn2:outgoing>\r
- <bpmn2:errorEventDefinition />\r
- </bpmn2:startEvent>\r
- <bpmn2:callActivity id="CallActivity_0jw5tqa" name="Call FalloutHandlerV1" calledElement="FalloutHandler">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="DELVAS_falloutRequest" target="FalloutHandlerRequest" />\r
- <camunda:in source="msoRequestId" target="mso-request-id" />\r
- <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />\r
- <camunda:out source="FH_ResponseCode" target="FH_ResponseCode" />\r
- <camunda:out source="FalloutHandlerResponse" target="FalloutHandlerResponse" />\r
- <camunda:out source="FH_ErrorResponse" target="FH_ErrorResponse" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_0807ukc</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_19yywk8</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:endEvent id="EndEvent_04xute7">\r
- <bpmn2:incoming>SequenceFlow_19yywk8</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:scriptTask id="ScriptTask_0yk02h3" name="Prepare FalloutHandler" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_06llof4</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0807ukc</bpmn2:outgoing>\r
+def DeleteGenericMacroServiceNetworkVnf= new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.prepareVnfAndModulesDelete(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_4" name="GoToStartNetworks">
+ <bpmn2:incoming>SequenceFlow_0xowenu</bpmn2:incoming>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_41" name="StartNetworks" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_2" name="GoQueryServiceInstance">
+ <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
+ <bpmn2:linkEventDefinition id="_LinkEventDefinition_38" name="QueryServiceInstance" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:subProcess id="SubProcess_0s6hpty" name="Subprocess For Exception / FalloutHandler " triggeredByEvent="true">
+ <bpmn2:startEvent id="StartEvent_1bwmffk" name="Fault Start">
+ <bpmn2:outgoing>SequenceFlow_06llof4</bpmn2:outgoing>
+ <bpmn2:errorEventDefinition />
+ </bpmn2:startEvent>
+ <bpmn2:callActivity id="CallActivity_0jw5tqa" name="Call FalloutHandlerV1" calledElement="FalloutHandler">
+ <bpmn2:extensionElements>
+ <camunda:in source="DELVAS_falloutRequest" target="FalloutHandlerRequest" />
+ <camunda:in source="msoRequestId" target="mso-request-id" />
+ <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />
+ <camunda:out source="FH_ResponseCode" target="FH_ResponseCode" />
+ <camunda:out source="FalloutHandlerResponse" target="FalloutHandlerResponse" />
+ <camunda:out source="FH_ErrorResponse" target="FH_ErrorResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0807ukc</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_19yywk8</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:endEvent id="EndEvent_04xute7">
+ <bpmn2:incoming>SequenceFlow_19yywk8</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:scriptTask id="ScriptTask_0yk02h3" name="Prepare FalloutHandler" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_06llof4</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0807ukc</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.prepareFalloutRequest(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0807ukc" sourceRef="ScriptTask_0yk02h3" targetRef="CallActivity_0jw5tqa" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_19yywk8" sourceRef="CallActivity_0jw5tqa" targetRef="EndEvent_04xute7" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_06llof4" sourceRef="StartEvent_1bwmffk" targetRef="ScriptTask_0yk02h3" />\r
- </bpmn2:subProcess>\r
- <bpmn2:sequenceFlow id="SequenceFlow_10o22u2" sourceRef="IntermediateCatchEvent_3" targetRef="doDeleteServiceInstance_CallActivity" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_12ilko1" sourceRef="IntermediateCatchEvent_4" targetRef="postProcessAndCompletionRequest_ScriptTask" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1bwbn7r" sourceRef="ScriptTask_PrepareNetworkDelete" targetRef="doDeleteNetworkInstance_CallActivity" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1n7r495" name="No" sourceRef="ExclusiveGateway_0fe690i" targetRef="ExclusiveGateway_1os8cm5" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1h77psn" sourceRef="ScriptTask_3" targetRef="doDeleteVNFandModules_CallActivity" />\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_1nh09nr" name="StartNetworks">\r
- <bpmn2:outgoing>SequenceFlow_1vwssu7</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition name="StartNetworks" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0prlju0" name="GoTo FinishProcess">\r
- <bpmn2:incoming>SequenceFlow_04ao07f</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition name="FinishProcess" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_0b9wd4f" name="Delete Network(s)?" default="SequenceFlow_1f26zbk">\r
- <bpmn2:incoming>SequenceFlow_1vwssu7</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0cmebdc</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1f26zbk</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_0fe690i" name="Delete Additional Networks?" default="SequenceFlow_1n7r495">\r
- <bpmn2:incoming>SequenceFlow_04vlq8r</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1n7r495</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0dfkfh1</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0dfkfh1" name="Yes" sourceRef="ExclusiveGateway_0fe690i" targetRef="ScriptTask_PrepareNetworkDelete">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DELVAS_networksDeletedCount") < execution.getVariable("DELVAS_networksCount")}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0cmebdc" name="Yes" sourceRef="ExclusiveGateway_0b9wd4f" targetRef="ScriptTask_PrepareNetworkDelete">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DELVAS_networksCount") > 0}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1os8cm5">\r
- <bpmn2:incoming>SequenceFlow_1n7r495</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1f26zbk</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1j7n6qx</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1f26zbk" name="No" sourceRef="ExclusiveGateway_0b9wd4f" targetRef="ExclusiveGateway_1os8cm5" />\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0nreq15" name="GoTo vIPR-ATM">\r
- <bpmn2:incoming>SequenceFlow_1j7n6qx</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition name="vIPR-ATM" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1vwssu7" sourceRef="IntermediateCatchEvent_1nh09nr" targetRef="ExclusiveGateway_0b9wd4f" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1j7n6qx" sourceRef="ExclusiveGateway_1os8cm5" targetRef="IntermediateThrowEvent_0nreq15" />\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_0rlqdvq" name="StartVnfs">\r
- <bpmn2:outgoing>SequenceFlow_10tbv62</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition name="StartVnfs" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1nlocis" name="Delete VNF?" default="SequenceFlow_0w7328u">\r
- <bpmn2:incoming>SequenceFlow_10tbv62</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0bvecvm</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_0w7328u</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_04q1qud">\r
- <bpmn2:incoming>SequenceFlow_0w7328u</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1wc8h5g</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0xowenu</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_10tbv62" sourceRef="IntermediateCatchEvent_0rlqdvq" targetRef="ExclusiveGateway_1nlocis" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0bvecvm" name="Yes" sourceRef="ExclusiveGateway_1nlocis" targetRef="ScriptTask_3">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DELVAS_vnfsCount") > 0}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0w7328u" name="No" sourceRef="ExclusiveGateway_1nlocis" targetRef="ExclusiveGateway_04q1qud" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0xowenu" sourceRef="ExclusiveGateway_04q1qud" targetRef="IntermediateThrowEvent_4" />\r
- <bpmn2:scriptTask id="ScriptTask_04o8gb3" name="Validate Network Delete" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_12ag2bk</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_04vlq8r</bpmn2:outgoing>\r
+def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.prepareFalloutRequest(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_0807ukc" sourceRef="ScriptTask_0yk02h3" targetRef="CallActivity_0jw5tqa" />
+ <bpmn2:sequenceFlow id="SequenceFlow_19yywk8" sourceRef="CallActivity_0jw5tqa" targetRef="EndEvent_04xute7" />
+ <bpmn2:sequenceFlow id="SequenceFlow_06llof4" sourceRef="StartEvent_1bwmffk" targetRef="ScriptTask_0yk02h3" />
+ </bpmn2:subProcess>
+ <bpmn2:sequenceFlow id="SequenceFlow_10o22u2" sourceRef="IntermediateCatchEvent_3" targetRef="doDeleteServiceInstance_CallActivity" />
+ <bpmn2:sequenceFlow id="SequenceFlow_12ilko1" sourceRef="IntermediateCatchEvent_4" targetRef="postProcessAndCompletionRequest_ScriptTask" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1bwbn7r" sourceRef="ScriptTask_PrepareNetworkDelete" targetRef="doDeleteNetworkInstance_CallActivity" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1n7r495" name="No" sourceRef="ExclusiveGateway_0fe690i" targetRef="ExclusiveGateway_1os8cm5" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1h77psn" sourceRef="ScriptTask_3" targetRef="doDeleteVNFandModules_CallActivity" />
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_1nh09nr" name="StartNetworks">
+ <bpmn2:outgoing>SequenceFlow_1vwssu7</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition name="StartNetworks" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0prlju0" name="GoTo FinishProcess">
+ <bpmn2:incoming>SequenceFlow_04ao07f</bpmn2:incoming>
+ <bpmn2:linkEventDefinition name="FinishProcess" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0b9wd4f" name="Delete Network(s)?" default="SequenceFlow_1f26zbk">
+ <bpmn2:incoming>SequenceFlow_1vwssu7</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0cmebdc</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1f26zbk</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0fe690i" name="Delete Additional Networks?" default="SequenceFlow_1n7r495">
+ <bpmn2:incoming>SequenceFlow_04vlq8r</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1n7r495</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0dfkfh1</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_0dfkfh1" name="Yes" sourceRef="ExclusiveGateway_0fe690i" targetRef="ScriptTask_PrepareNetworkDelete">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DELVAS_networksDeletedCount") < execution.getVariable("DELVAS_networksCount")}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0cmebdc" name="Yes" sourceRef="ExclusiveGateway_0b9wd4f" targetRef="ScriptTask_PrepareNetworkDelete">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DELVAS_networksCount") > 0}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1os8cm5">
+ <bpmn2:incoming>SequenceFlow_1n7r495</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1f26zbk</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1j7n6qx</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_1f26zbk" name="No" sourceRef="ExclusiveGateway_0b9wd4f" targetRef="ExclusiveGateway_1os8cm5" />
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0nreq15" name="GoTo vIPR-ATM">
+ <bpmn2:incoming>SequenceFlow_1j7n6qx</bpmn2:incoming>
+ <bpmn2:linkEventDefinition name="vIPR-ATM" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_1vwssu7" sourceRef="IntermediateCatchEvent_1nh09nr" targetRef="ExclusiveGateway_0b9wd4f" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1j7n6qx" sourceRef="ExclusiveGateway_1os8cm5" targetRef="IntermediateThrowEvent_0nreq15" />
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_0rlqdvq" name="StartVnfs">
+ <bpmn2:outgoing>SequenceFlow_10tbv62</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition name="StartVnfs" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1nlocis" name="Delete VNF?" default="SequenceFlow_0w7328u">
+ <bpmn2:incoming>SequenceFlow_10tbv62</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0bvecvm</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0w7328u</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_04q1qud">
+ <bpmn2:incoming>SequenceFlow_0w7328u</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1wc8h5g</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0xowenu</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_10tbv62" sourceRef="IntermediateCatchEvent_0rlqdvq" targetRef="ExclusiveGateway_1nlocis" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0bvecvm" name="Yes" sourceRef="ExclusiveGateway_1nlocis" targetRef="ScriptTask_3">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DELVAS_vnfsCount") > 0}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0w7328u" name="No" sourceRef="ExclusiveGateway_1nlocis" targetRef="ExclusiveGateway_04q1qud" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0xowenu" sourceRef="ExclusiveGateway_04q1qud" targetRef="IntermediateThrowEvent_4" />
+ <bpmn2:scriptTask id="ScriptTask_04o8gb3" name="Validate Network Delete" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_12ag2bk</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_04vlq8r</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf= new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.validateNetworkDelete(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_12ag2bk" sourceRef="doDeleteNetworkInstance_CallActivity" targetRef="ScriptTask_04o8gb3" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_04vlq8r" sourceRef="ScriptTask_04o8gb3" targetRef="ExclusiveGateway_0fe690i" />\r
- <bpmn2:callActivity id="callGetServiceInstance" name="Get Service Instance" calledElement="GenericGetService">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="serviceInstanceId" target="GENGS_serviceInstanceId" />\r
- <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />\r
- <camunda:in source="GENGS_type" target="GENGS_type" />\r
- <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />\r
- <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />\r
- <camunda:out source="GENGS_service" target="GENGS_service" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="GENGS_siResourceLink" target="GENGS_siResourceLink" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_0jek18q</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1ttswdr</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:scriptTask id="ScriptTask_05m3m2e" name="Process Response & ready data for subflows" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1ttswdr</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_18103ca</bpmn2:outgoing>\r
+def DeleteGenericMacroServiceNetworkVnf= new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.validateNetworkDelete(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_12ag2bk" sourceRef="doDeleteNetworkInstance_CallActivity" targetRef="ScriptTask_04o8gb3" />
+ <bpmn2:sequenceFlow id="SequenceFlow_04vlq8r" sourceRef="ScriptTask_04o8gb3" targetRef="ExclusiveGateway_0fe690i" />
+ <bpmn2:callActivity id="callGetServiceInstance" name="Get Service Instance" calledElement="GenericGetService">
+ <bpmn2:extensionElements>
+ <camunda:in source="serviceInstanceId" target="GENGS_serviceInstanceId" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="GENGS_type" target="GENGS_type" />
+ <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />
+ <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />
+ <camunda:out source="GENGS_service" target="GENGS_service" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="GENGS_siResourceLink" target="GENGS_siResourceLink" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0jek18q</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1ttswdr</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_05m3m2e" name="Process Response & ready data for subflows" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1ttswdr</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_18103ca</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.prepareServiceInstanceDelete(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_112zjtp" name="QueryServiceInstance">\r
- <bpmn2:outgoing>SequenceFlow_0jek18q</bpmn2:outgoing>\r
- <bpmn2:linkEventDefinition name="QueryServiceInstance" />\r
- </bpmn2:intermediateCatchEvent>\r
- <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_162gs5w" name="GoToStartVnfs">\r
- <bpmn2:incoming>SequenceFlow_18103ca</bpmn2:incoming>\r
- <bpmn2:linkEventDefinition name="StartVnfs" />\r
- </bpmn2:intermediateThrowEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0jek18q" sourceRef="IntermediateCatchEvent_112zjtp" targetRef="callGetServiceInstance" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_18103ca" sourceRef="ScriptTask_05m3m2e" targetRef="IntermediateThrowEvent_162gs5w" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_04ao07f" sourceRef="doDeleteServiceInstance_CallActivity" targetRef="IntermediateThrowEvent_0prlju0" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1ttswdr" sourceRef="callGetServiceInstance" targetRef="ScriptTask_05m3m2e" />\r
- <bpmn2:scriptTask id="ScriptTask_1ildy3f" name="Validate VNF delete" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1dmn40p</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0g2cw86</bpmn2:outgoing>\r
+def DeleteGenericMacroServiceNetworkVnf = new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.prepareServiceInstanceDelete(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_112zjtp" name="QueryServiceInstance">
+ <bpmn2:outgoing>SequenceFlow_0jek18q</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition name="QueryServiceInstance" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_162gs5w" name="GoToStartVnfs">
+ <bpmn2:incoming>SequenceFlow_18103ca</bpmn2:incoming>
+ <bpmn2:linkEventDefinition name="StartVnfs" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_0jek18q" sourceRef="IntermediateCatchEvent_112zjtp" targetRef="callGetServiceInstance" />
+ <bpmn2:sequenceFlow id="SequenceFlow_18103ca" sourceRef="ScriptTask_05m3m2e" targetRef="IntermediateThrowEvent_162gs5w" />
+ <bpmn2:sequenceFlow id="SequenceFlow_04ao07f" sourceRef="doDeleteServiceInstance_CallActivity" targetRef="IntermediateThrowEvent_0prlju0" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1ttswdr" sourceRef="callGetServiceInstance" targetRef="ScriptTask_05m3m2e" />
+ <bpmn2:scriptTask id="ScriptTask_1ildy3f" name="Validate VNF delete" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1dmn40p</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0g2cw86</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def DeleteGenericMacroServiceNetworkVnf= new DeleteGenericMacroServiceNetworkVnf()\r
-DeleteGenericMacroServiceNetworkVnf.validateVnfDelete(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1uds6yu" name="Delete Additional VNFs?" default="SequenceFlow_1wc8h5g">\r
- <bpmn2:incoming>SequenceFlow_0g2cw86</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0mr8jgt</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1wc8h5g</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1dmn40p" sourceRef="doDeleteVNFandModules_CallActivity" targetRef="ScriptTask_1ildy3f" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0g2cw86" sourceRef="ScriptTask_1ildy3f" targetRef="ExclusiveGateway_1uds6yu" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0mr8jgt" name="Yes" sourceRef="ExclusiveGateway_1uds6yu" targetRef="ScriptTask_3">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DELVAS_vnfsDeletedCountt") < execution.getVariable("DELVAS_vnfsCount")}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1wc8h5g" name="No" sourceRef="ExclusiveGateway_1uds6yu" targetRef="ExclusiveGateway_04q1qud" />\r
- </bpmn2:process>\r
- <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />\r
- <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />\r
- <bpmndi:BPMNDiagram id="BPMNDiagram_1">\r
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DeleteGenericMacroServiceNetworkVnf">\r
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createVIPR_startEvent">\r
- <dc:Bounds x="96" y="90" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="82" y="131" width="65" height="22" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">\r
- <dc:Bounds x="285" y="68" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">\r
- <di:waypoint xsi:type="dc:Point" x="132" y="108" />\r
- <di:waypoint xsi:type="dc:Point" x="285" y="108" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="171" y="108" width="6" height="6" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_4" bpmnElement="callCompleteMsoProcess_CallActivity">\r
- <dc:Bounds x="476" y="1192" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_80" bpmnElement="postProcessAndCompletionRequest_ScriptTask">\r
- <dc:Bounds x="285" y="1193" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_61" targetElement="_BPMNShape_ScriptTask_127">\r
- <di:waypoint xsi:type="dc:Point" x="385" y="108" />\r
- <di:waypoint xsi:type="dc:Point" x="476" y="108" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="271" y="69" width="6" height="6" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_127" bpmnElement="sendSyncAckResponse_ScriptTask">\r
- <dc:Bounds x="476" y="68" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_42" bpmnElement="SequenceFlow_29" sourceElement="_BPMNShape_ScriptTask_80" targetElement="_BPMNShape_CallActivity_4">\r
- <di:waypoint xsi:type="dc:Point" x="385" y="1233" />\r
- <di:waypoint xsi:type="dc:Point" x="476" y="1232" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="431" y="1217.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="DeleteVIPR_EndEvent">\r
- <dc:Bounds x="1046" y="1213" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1054" y="1254" width="19" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_CallActivity_4" targetElement="_BPMNShape_ScriptTask_337">\r
- <di:waypoint xsi:type="dc:Point" x="576" y="1233" />\r
- <di:waypoint xsi:type="dc:Point" x="636" y="1233" />\r
- <di:waypoint xsi:type="dc:Point" x="636" y="1230" />\r
- <di:waypoint xsi:type="dc:Point" x="803" y="1230" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="651" y="1231.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_SubProcess_27" bpmnElement="UnexpectedError_SubProcess_1" isExpanded="true">\r
- <dc:Bounds x="686" y="1374" width="405" height="205" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_70" bpmnElement="StartEvent_1">\r
- <dc:Bounds x="754" y="1479" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="772" y="1520" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_269" bpmnElement="ScriptTask_1">\r
- <dc:Bounds x="829" y="1457" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_219" bpmnElement="EndEvent_1">\r
- <dc:Bounds x="982" y="1479" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1000" y="1520" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_StartEvent_70" targetElement="_BPMNShape_ScriptTask_269">\r
- <di:waypoint xsi:type="dc:Point" x="790" y="1497" />\r
- <di:waypoint xsi:type="dc:Point" x="829" y="1497" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="818" y="1497" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_5" sourceElement="_BPMNShape_ScriptTask_269" targetElement="_BPMNShape_EndEvent_219">\r
- <di:waypoint xsi:type="dc:Point" x="929" y="1497" />\r
- <di:waypoint xsi:type="dc:Point" x="962" y="1497" />\r
- <di:waypoint xsi:type="dc:Point" x="962" y="1497" />\r
- <di:waypoint xsi:type="dc:Point" x="982" y="1497" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="977" y="1497" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_75" bpmnElement="doDeleteServiceInstance_CallActivity">\r
- <dc:Bounds x="285" y="1009" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_127">\r
- <di:waypoint xsi:type="dc:Point" x="576" y="108" />\r
- <di:waypoint xsi:type="dc:Point" x="728" y="108" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="652" y="93" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_337" bpmnElement="ScriptTask_2">\r
- <dc:Bounds x="803" y="1191" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_ScriptTask_337" targetElement="_BPMNShape_EndEvent_177">\r
- <di:waypoint xsi:type="dc:Point" x="903" y="1230" />\r
- <di:waypoint xsi:type="dc:Point" x="1046" y="1231" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="975" y="1215.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_76" bpmnElement="doDeleteNetworkInstance_CallActivity">\r
- <dc:Bounds x="555" y="722" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_35" bpmnElement="IntermediateCatchEvent_3">\r
- <dc:Bounds x="100" y="1031" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="92" y="1067" width="51" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_36" bpmnElement="IntermediateCatchEvent_4">\r
- <dc:Bounds x="100" y="1216" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="82" y="1252" width="71" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_51" bpmnElement="IntermediateThrowEvent_4">\r
- <dc:Bounds x="1036" y="524" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1011" y="565" width="85" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_341" bpmnElement="ScriptTask_PrepareNetworkDelete">\r
- <dc:Bounds x="413" y="719" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_342" bpmnElement="ScriptTask_3">\r
- <dc:Bounds x="413" y="435" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_81" bpmnElement="doDeleteVNFandModules_CallActivity">\r
- <dc:Bounds x="555" y="435" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_49" bpmnElement="IntermediateThrowEvent_2">\r
- <dc:Bounds x="728" y="90" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="703" y="131" width="86" height="26" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="SubProcess_0s6hpty_di" bpmnElement="SubProcess_0s6hpty" isExpanded="true">\r
- <dc:Bounds x="52" y="1375" width="598" height="203" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="StartEvent_1bwmffk_di" bpmnElement="StartEvent_1bwmffk">\r
- <dc:Bounds x="123" y="1448" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="117" y="1489" width="50" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="CallActivity_0jw5tqa_di" bpmnElement="CallActivity_0jw5tqa">\r
- <dc:Bounds x="384" y="1426" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="EndEvent_04xute7_di" bpmnElement="EndEvent_04xute7">\r
- <dc:Bounds x="539" y="1448" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="557" y="1489" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_0yk02h3_di" bpmnElement="ScriptTask_0yk02h3">\r
- <dc:Bounds x="237" y="1426" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_10o22u2_di" bpmnElement="SequenceFlow_10o22u2">\r
- <di:waypoint xsi:type="dc:Point" x="136" y="1049" />\r
- <di:waypoint xsi:type="dc:Point" x="285" y="1049" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="211" y="1034" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_12ilko1_di" bpmnElement="SequenceFlow_12ilko1">\r
- <di:waypoint xsi:type="dc:Point" x="136" y="1234" />\r
- <di:waypoint xsi:type="dc:Point" x="285" y="1233" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="211" y="1218.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0807ukc_di" bpmnElement="SequenceFlow_0807ukc">\r
- <di:waypoint xsi:type="dc:Point" x="337" y="1466" />\r
- <di:waypoint xsi:type="dc:Point" x="384" y="1466" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="361" y="1451" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_19yywk8_di" bpmnElement="SequenceFlow_19yywk8">\r
- <di:waypoint xsi:type="dc:Point" x="484" y="1466" />\r
- <di:waypoint xsi:type="dc:Point" x="539" y="1466" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="512" y="1451" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1bwbn7r_di" bpmnElement="SequenceFlow_1bwbn7r">\r
- <di:waypoint xsi:type="dc:Point" x="513" y="761" />\r
- <di:waypoint xsi:type="dc:Point" x="555" y="760" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="534" y="746" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1n7r495_di" bpmnElement="SequenceFlow_1n7r495">\r
- <di:waypoint xsi:type="dc:Point" x="891" y="762" />\r
- <di:waypoint xsi:type="dc:Point" x="936" y="762" />\r
- <di:waypoint xsi:type="dc:Point" x="936" y="792" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="908" y="747" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1h77psn_di" bpmnElement="SequenceFlow_1h77psn">\r
- <di:waypoint xsi:type="dc:Point" x="513" y="475" />\r
- <di:waypoint xsi:type="dc:Point" x="555" y="475" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="534" y="460" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="IntermediateCatchEvent_1nh09nr_di" bpmnElement="IntermediateCatchEvent_1nh09nr">\r
- <dc:Bounds x="96" y="786" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="80" y="822" width="68" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="IntermediateThrowEvent_0prlju0_di" bpmnElement="IntermediateThrowEvent_0prlju0">\r
- <dc:Bounds x="508" y="1031" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="491" y="1072" width="70" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_0b9wd4f_di" bpmnElement="ExclusiveGateway_0b9wd4f" isMarkerVisible="true">\r
- <dc:Bounds x="345" y="779" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="408" y="811" width="57" height="26" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_0fe690i_di" bpmnElement="ExclusiveGateway_0fe690i" isMarkerVisible="true">\r
- <dc:Bounds x="841" y="737" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="809" y="795" width="82" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0dfkfh1_di" bpmnElement="SequenceFlow_0dfkfh1">\r
- <di:waypoint xsi:type="dc:Point" x="866" y="737" />\r
- <di:waypoint xsi:type="dc:Point" x="866" y="657" />\r
- <di:waypoint xsi:type="dc:Point" x="463" y="657" />\r
- <di:waypoint xsi:type="dc:Point" x="463" y="717" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="657" y="642" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0cmebdc_di" bpmnElement="SequenceFlow_0cmebdc">\r
- <di:waypoint xsi:type="dc:Point" x="370" y="779" />\r
- <di:waypoint xsi:type="dc:Point" x="370" y="759" />\r
- <di:waypoint xsi:type="dc:Point" x="413" y="759" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="375" y="769" width="19" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1os8cm5_di" bpmnElement="ExclusiveGateway_1os8cm5" isMarkerVisible="true">\r
- <dc:Bounds x="911" y="792" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="936" y="847" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1f26zbk_di" bpmnElement="SequenceFlow_1f26zbk">\r
- <di:waypoint xsi:type="dc:Point" x="370" y="829" />\r
- <di:waypoint xsi:type="dc:Point" x="370" y="896" />\r
- <di:waypoint xsi:type="dc:Point" x="936" y="896" />\r
- <di:waypoint xsi:type="dc:Point" x="936" y="842" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="646" y="881" width="14" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="IntermediateThrowEvent_0nreq15_di" bpmnElement="IntermediateThrowEvent_0nreq15">\r
- <dc:Bounds x="1046" y="799" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1024" y="840" width="80" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1vwssu7_di" bpmnElement="SequenceFlow_1vwssu7">\r
- <di:waypoint xsi:type="dc:Point" x="132" y="804" />\r
- <di:waypoint xsi:type="dc:Point" x="345" y="804" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="239" y="789" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1j7n6qx_di" bpmnElement="SequenceFlow_1j7n6qx">\r
- <di:waypoint xsi:type="dc:Point" x="961" y="817" />\r
- <di:waypoint xsi:type="dc:Point" x="1046" y="817" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1004" y="792" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="IntermediateCatchEvent_0rlqdvq_di" bpmnElement="IntermediateCatchEvent_0rlqdvq">\r
- <dc:Bounds x="86" y="540" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="80" y="576" width="45" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1nlocis_di" bpmnElement="ExclusiveGateway_1nlocis" isMarkerVisible="true">\r
- <dc:Bounds x="335" y="533" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="395" y="565" width="62" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_04q1qud_di" bpmnElement="ExclusiveGateway_04q1qud" isMarkerVisible="true">\r
- <dc:Bounds x="901" y="517" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="926" y="572" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_10tbv62_di" bpmnElement="SequenceFlow_10tbv62">\r
- <di:waypoint xsi:type="dc:Point" x="122" y="558" />\r
- <di:waypoint xsi:type="dc:Point" x="335" y="558" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="229" y="533" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0bvecvm_di" bpmnElement="SequenceFlow_0bvecvm">\r
- <di:waypoint xsi:type="dc:Point" x="360" y="533" />\r
- <di:waypoint xsi:type="dc:Point" x="360" y="475" />\r
- <di:waypoint xsi:type="dc:Point" x="413" y="475" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="366" y="494" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0w7328u_di" bpmnElement="SequenceFlow_0w7328u">\r
- <di:waypoint xsi:type="dc:Point" x="360" y="584" />\r
- <di:waypoint xsi:type="dc:Point" x="360" y="607" />\r
- <di:waypoint xsi:type="dc:Point" x="926" y="607" />\r
- <di:waypoint xsi:type="dc:Point" x="926" y="568" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="606" y="583" width="14" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0xowenu_di" bpmnElement="SequenceFlow_0xowenu">\r
- <di:waypoint xsi:type="dc:Point" x="951" y="542" />\r
- <di:waypoint xsi:type="dc:Point" x="1036" y="542" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="994" y="517" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_04o8gb3_di" bpmnElement="ScriptTask_04o8gb3">\r
- <dc:Bounds x="699" y="722" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_12ag2bk_di" bpmnElement="SequenceFlow_12ag2bk">\r
- <di:waypoint xsi:type="dc:Point" x="655" y="762" />\r
- <di:waypoint xsi:type="dc:Point" x="699" y="762" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="677" y="737" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_04vlq8r_di" bpmnElement="SequenceFlow_04vlq8r">\r
- <di:waypoint xsi:type="dc:Point" x="799" y="762" />\r
- <di:waypoint xsi:type="dc:Point" x="820" y="762" />\r
- <di:waypoint xsi:type="dc:Point" x="820" y="762" />\r
- <di:waypoint xsi:type="dc:Point" x="841" y="762" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="835" y="762" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="CallActivity_0nmoax4_di" bpmnElement="callGetServiceInstance">\r
- <dc:Bounds x="285" y="223" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_05m3m2e_di" bpmnElement="ScriptTask_05m3m2e">\r
- <dc:Bounds x="476" y="223" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="IntermediateCatchEvent_112zjtp_di" bpmnElement="IntermediateCatchEvent_112zjtp">\r
- <dc:Bounds x="96" y="245" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="72" y="281" width="82" height="25" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="IntermediateThrowEvent_162gs5w_di" bpmnElement="IntermediateThrowEvent_162gs5w">\r
- <dc:Bounds x="732" y="245" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="713" y="286" width="72" height="13" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0jek18q_di" bpmnElement="SequenceFlow_0jek18q">\r
- <di:waypoint xsi:type="dc:Point" x="132" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="285" y="263" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="209" y="248" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_18103ca_di" bpmnElement="SequenceFlow_18103ca">\r
- <di:waypoint xsi:type="dc:Point" x="576" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="732" y="263" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="654" y="248" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_04ao07f_di" bpmnElement="SequenceFlow_04ao07f">\r
- <di:waypoint xsi:type="dc:Point" x="385" y="1049" />\r
- <di:waypoint xsi:type="dc:Point" x="508" y="1049" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="447" y="1034" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1ttswdr_di" bpmnElement="SequenceFlow_1ttswdr">\r
- <di:waypoint xsi:type="dc:Point" x="385" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="422" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="422" y="263" />\r
- <di:waypoint xsi:type="dc:Point" x="476" y="263" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="437" y="263" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_1ildy3f_di" bpmnElement="ScriptTask_1ildy3f">\r
- <dc:Bounds x="687" y="435" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1uds6yu_di" bpmnElement="ExclusiveGateway_1uds6yu" isMarkerVisible="true">\r
- <dc:Bounds x="828" y="450" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="797" y="508" width="80" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1dmn40p_di" bpmnElement="SequenceFlow_1dmn40p">\r
- <di:waypoint xsi:type="dc:Point" x="655" y="475" />\r
- <di:waypoint xsi:type="dc:Point" x="687" y="475" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="671" y="450" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0g2cw86_di" bpmnElement="SequenceFlow_0g2cw86">\r
- <di:waypoint xsi:type="dc:Point" x="787" y="475" />\r
- <di:waypoint xsi:type="dc:Point" x="828" y="475" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="808" y="460" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0mr8jgt_di" bpmnElement="SequenceFlow_0mr8jgt">\r
- <di:waypoint xsi:type="dc:Point" x="853" y="453" />\r
- <di:waypoint xsi:type="dc:Point" x="853" y="364" />\r
- <di:waypoint xsi:type="dc:Point" x="463" y="364" />\r
- <di:waypoint xsi:type="dc:Point" x="463" y="435" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="649" y="349" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1wc8h5g_di" bpmnElement="SequenceFlow_1wc8h5g">\r
- <di:waypoint xsi:type="dc:Point" x="878" y="475" />\r
- <di:waypoint xsi:type="dc:Point" x="926" y="475" />\r
- <di:waypoint xsi:type="dc:Point" x="926" y="517" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="895" y="460" width="14" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_06llof4_di" bpmnElement="SequenceFlow_06llof4">\r
- <di:waypoint xsi:type="dc:Point" x="159" y="1466" />\r
- <di:waypoint xsi:type="dc:Point" x="237" y="1466" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="198" y="1441" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- </bpmndi:BPMNPlane>\r
- </bpmndi:BPMNDiagram>\r
-</bpmn2:definitions>\r
+def DeleteGenericMacroServiceNetworkVnf= new DeleteGenericMacroServiceNetworkVnf()
+DeleteGenericMacroServiceNetworkVnf.validateVnfDelete(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1uds6yu" name="Delete Additional VNFs?" default="SequenceFlow_1wc8h5g">
+ <bpmn2:incoming>SequenceFlow_0g2cw86</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0mr8jgt</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1wc8h5g</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_1dmn40p" sourceRef="doDeleteVNFandModules_CallActivity" targetRef="ScriptTask_1ildy3f" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0g2cw86" sourceRef="ScriptTask_1ildy3f" targetRef="ExclusiveGateway_1uds6yu" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0mr8jgt" name="Yes" sourceRef="ExclusiveGateway_1uds6yu" targetRef="ScriptTask_3">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DELVAS_vnfsDeletedCountt") < execution.getVariable("DELVAS_vnfsCount")}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_1wc8h5g" name="No" sourceRef="ExclusiveGateway_1uds6yu" targetRef="ExclusiveGateway_04q1qud" />
+ </bpmn2:process>
+ <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
+ <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
+ <bpmndi:BPMNDiagram id="BPMNDiagram_1">
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DeleteGenericMacroServiceNetworkVnf">
+ <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createVIPR_startEvent">
+ <dc:Bounds x="96" y="90" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="82" y="131" width="65" height="22" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">
+ <dc:Bounds x="285" y="68" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">
+ <di:waypoint xsi:type="dc:Point" x="132" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="285" y="108" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="171" y="108" width="6" height="6" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_4" bpmnElement="callCompleteMsoProcess_CallActivity">
+ <dc:Bounds x="476" y="1192" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_80" bpmnElement="postProcessAndCompletionRequest_ScriptTask">
+ <dc:Bounds x="285" y="1193" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_61" targetElement="_BPMNShape_ScriptTask_127">
+ <di:waypoint xsi:type="dc:Point" x="385" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="476" y="108" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="271" y="69" width="6" height="6" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_127" bpmnElement="sendSyncAckResponse_ScriptTask">
+ <dc:Bounds x="476" y="68" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_42" bpmnElement="SequenceFlow_29" sourceElement="_BPMNShape_ScriptTask_80" targetElement="_BPMNShape_CallActivity_4">
+ <di:waypoint xsi:type="dc:Point" x="385" y="1233" />
+ <di:waypoint xsi:type="dc:Point" x="476" y="1232" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="431" y="1217.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="DeleteVIPR_EndEvent">
+ <dc:Bounds x="1046" y="1213" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1054" y="1254" width="19" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_CallActivity_4" targetElement="_BPMNShape_ScriptTask_337">
+ <di:waypoint xsi:type="dc:Point" x="576" y="1233" />
+ <di:waypoint xsi:type="dc:Point" x="636" y="1233" />
+ <di:waypoint xsi:type="dc:Point" x="636" y="1230" />
+ <di:waypoint xsi:type="dc:Point" x="803" y="1230" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="651" y="1231.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_SubProcess_27" bpmnElement="UnexpectedError_SubProcess_1" isExpanded="true">
+ <dc:Bounds x="686" y="1374" width="405" height="205" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_StartEvent_70" bpmnElement="StartEvent_1">
+ <dc:Bounds x="754" y="1479" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="772" y="1520" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_269" bpmnElement="ScriptTask_1">
+ <dc:Bounds x="829" y="1457" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_EndEvent_219" bpmnElement="EndEvent_1">
+ <dc:Bounds x="982" y="1479" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1000" y="1520" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_StartEvent_70" targetElement="_BPMNShape_ScriptTask_269">
+ <di:waypoint xsi:type="dc:Point" x="790" y="1497" />
+ <di:waypoint xsi:type="dc:Point" x="829" y="1497" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="818" y="1497" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_5" sourceElement="_BPMNShape_ScriptTask_269" targetElement="_BPMNShape_EndEvent_219">
+ <di:waypoint xsi:type="dc:Point" x="929" y="1497" />
+ <di:waypoint xsi:type="dc:Point" x="962" y="1497" />
+ <di:waypoint xsi:type="dc:Point" x="962" y="1497" />
+ <di:waypoint xsi:type="dc:Point" x="982" y="1497" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="977" y="1497" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_75" bpmnElement="doDeleteServiceInstance_CallActivity">
+ <dc:Bounds x="285" y="1009" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_127">
+ <di:waypoint xsi:type="dc:Point" x="576" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="728" y="108" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="652" y="93" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_337" bpmnElement="ScriptTask_2">
+ <dc:Bounds x="803" y="1191" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_ScriptTask_337" targetElement="_BPMNShape_EndEvent_177">
+ <di:waypoint xsi:type="dc:Point" x="903" y="1230" />
+ <di:waypoint xsi:type="dc:Point" x="1046" y="1231" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="975" y="1215.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_76" bpmnElement="doDeleteNetworkInstance_CallActivity">
+ <dc:Bounds x="555" y="722" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_35" bpmnElement="IntermediateCatchEvent_3">
+ <dc:Bounds x="100" y="1031" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="92" y="1067" width="51" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_36" bpmnElement="IntermediateCatchEvent_4">
+ <dc:Bounds x="100" y="1216" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="82" y="1252" width="71" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_51" bpmnElement="IntermediateThrowEvent_4">
+ <dc:Bounds x="1036" y="524" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1011" y="565" width="85" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_341" bpmnElement="ScriptTask_PrepareNetworkDelete">
+ <dc:Bounds x="413" y="719" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_342" bpmnElement="ScriptTask_3">
+ <dc:Bounds x="413" y="435" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_81" bpmnElement="doDeleteVNFandModules_CallActivity">
+ <dc:Bounds x="555" y="435" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_49" bpmnElement="IntermediateThrowEvent_2">
+ <dc:Bounds x="728" y="90" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="703" y="131" width="86" height="26" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="SubProcess_0s6hpty_di" bpmnElement="SubProcess_0s6hpty" isExpanded="true">
+ <dc:Bounds x="52" y="1375" width="598" height="203" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="StartEvent_1bwmffk_di" bpmnElement="StartEvent_1bwmffk">
+ <dc:Bounds x="123" y="1448" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="117" y="1489" width="50" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0jw5tqa_di" bpmnElement="CallActivity_0jw5tqa">
+ <dc:Bounds x="384" y="1426" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="EndEvent_04xute7_di" bpmnElement="EndEvent_04xute7">
+ <dc:Bounds x="539" y="1448" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="557" y="1489" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_0yk02h3_di" bpmnElement="ScriptTask_0yk02h3">
+ <dc:Bounds x="237" y="1426" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_10o22u2_di" bpmnElement="SequenceFlow_10o22u2">
+ <di:waypoint xsi:type="dc:Point" x="136" y="1049" />
+ <di:waypoint xsi:type="dc:Point" x="285" y="1049" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="211" y="1034" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_12ilko1_di" bpmnElement="SequenceFlow_12ilko1">
+ <di:waypoint xsi:type="dc:Point" x="136" y="1234" />
+ <di:waypoint xsi:type="dc:Point" x="285" y="1233" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="211" y="1218.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0807ukc_di" bpmnElement="SequenceFlow_0807ukc">
+ <di:waypoint xsi:type="dc:Point" x="337" y="1466" />
+ <di:waypoint xsi:type="dc:Point" x="384" y="1466" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="361" y="1451" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_19yywk8_di" bpmnElement="SequenceFlow_19yywk8">
+ <di:waypoint xsi:type="dc:Point" x="484" y="1466" />
+ <di:waypoint xsi:type="dc:Point" x="539" y="1466" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="512" y="1451" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1bwbn7r_di" bpmnElement="SequenceFlow_1bwbn7r">
+ <di:waypoint xsi:type="dc:Point" x="513" y="761" />
+ <di:waypoint xsi:type="dc:Point" x="555" y="760" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="534" y="746" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1n7r495_di" bpmnElement="SequenceFlow_1n7r495">
+ <di:waypoint xsi:type="dc:Point" x="891" y="762" />
+ <di:waypoint xsi:type="dc:Point" x="936" y="762" />
+ <di:waypoint xsi:type="dc:Point" x="936" y="792" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="908" y="747" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1h77psn_di" bpmnElement="SequenceFlow_1h77psn">
+ <di:waypoint xsi:type="dc:Point" x="513" y="475" />
+ <di:waypoint xsi:type="dc:Point" x="555" y="475" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="534" y="460" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="IntermediateCatchEvent_1nh09nr_di" bpmnElement="IntermediateCatchEvent_1nh09nr">
+ <dc:Bounds x="96" y="786" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="80" y="822" width="68" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="IntermediateThrowEvent_0prlju0_di" bpmnElement="IntermediateThrowEvent_0prlju0">
+ <dc:Bounds x="508" y="1031" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="491" y="1072" width="70" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0b9wd4f_di" bpmnElement="ExclusiveGateway_0b9wd4f" isMarkerVisible="true">
+ <dc:Bounds x="345" y="779" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="408" y="811" width="57" height="26" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0fe690i_di" bpmnElement="ExclusiveGateway_0fe690i" isMarkerVisible="true">
+ <dc:Bounds x="841" y="737" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="809" y="795" width="82" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0dfkfh1_di" bpmnElement="SequenceFlow_0dfkfh1">
+ <di:waypoint xsi:type="dc:Point" x="866" y="737" />
+ <di:waypoint xsi:type="dc:Point" x="866" y="657" />
+ <di:waypoint xsi:type="dc:Point" x="463" y="657" />
+ <di:waypoint xsi:type="dc:Point" x="463" y="717" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="657" y="642" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0cmebdc_di" bpmnElement="SequenceFlow_0cmebdc">
+ <di:waypoint xsi:type="dc:Point" x="370" y="779" />
+ <di:waypoint xsi:type="dc:Point" x="370" y="759" />
+ <di:waypoint xsi:type="dc:Point" x="413" y="759" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="375" y="769" width="19" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1os8cm5_di" bpmnElement="ExclusiveGateway_1os8cm5" isMarkerVisible="true">
+ <dc:Bounds x="911" y="792" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="936" y="847" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1f26zbk_di" bpmnElement="SequenceFlow_1f26zbk">
+ <di:waypoint xsi:type="dc:Point" x="370" y="829" />
+ <di:waypoint xsi:type="dc:Point" x="370" y="896" />
+ <di:waypoint xsi:type="dc:Point" x="936" y="896" />
+ <di:waypoint xsi:type="dc:Point" x="936" y="842" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="646" y="881" width="14" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="IntermediateThrowEvent_0nreq15_di" bpmnElement="IntermediateThrowEvent_0nreq15">
+ <dc:Bounds x="1046" y="799" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1024" y="840" width="80" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1vwssu7_di" bpmnElement="SequenceFlow_1vwssu7">
+ <di:waypoint xsi:type="dc:Point" x="132" y="804" />
+ <di:waypoint xsi:type="dc:Point" x="345" y="804" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="239" y="789" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1j7n6qx_di" bpmnElement="SequenceFlow_1j7n6qx">
+ <di:waypoint xsi:type="dc:Point" x="961" y="817" />
+ <di:waypoint xsi:type="dc:Point" x="1046" y="817" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1004" y="792" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="IntermediateCatchEvent_0rlqdvq_di" bpmnElement="IntermediateCatchEvent_0rlqdvq">
+ <dc:Bounds x="86" y="540" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="80" y="576" width="45" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1nlocis_di" bpmnElement="ExclusiveGateway_1nlocis" isMarkerVisible="true">
+ <dc:Bounds x="335" y="533" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="395" y="565" width="62" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_04q1qud_di" bpmnElement="ExclusiveGateway_04q1qud" isMarkerVisible="true">
+ <dc:Bounds x="901" y="517" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="926" y="572" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_10tbv62_di" bpmnElement="SequenceFlow_10tbv62">
+ <di:waypoint xsi:type="dc:Point" x="122" y="558" />
+ <di:waypoint xsi:type="dc:Point" x="335" y="558" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="229" y="533" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0bvecvm_di" bpmnElement="SequenceFlow_0bvecvm">
+ <di:waypoint xsi:type="dc:Point" x="360" y="533" />
+ <di:waypoint xsi:type="dc:Point" x="360" y="475" />
+ <di:waypoint xsi:type="dc:Point" x="413" y="475" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="366" y="494" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0w7328u_di" bpmnElement="SequenceFlow_0w7328u">
+ <di:waypoint xsi:type="dc:Point" x="360" y="584" />
+ <di:waypoint xsi:type="dc:Point" x="360" y="607" />
+ <di:waypoint xsi:type="dc:Point" x="926" y="607" />
+ <di:waypoint xsi:type="dc:Point" x="926" y="568" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="606" y="583" width="14" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0xowenu_di" bpmnElement="SequenceFlow_0xowenu">
+ <di:waypoint xsi:type="dc:Point" x="951" y="542" />
+ <di:waypoint xsi:type="dc:Point" x="1036" y="542" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="994" y="517" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_04o8gb3_di" bpmnElement="ScriptTask_04o8gb3">
+ <dc:Bounds x="699" y="722" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_12ag2bk_di" bpmnElement="SequenceFlow_12ag2bk">
+ <di:waypoint xsi:type="dc:Point" x="655" y="762" />
+ <di:waypoint xsi:type="dc:Point" x="699" y="762" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="677" y="737" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_04vlq8r_di" bpmnElement="SequenceFlow_04vlq8r">
+ <di:waypoint xsi:type="dc:Point" x="799" y="762" />
+ <di:waypoint xsi:type="dc:Point" x="820" y="762" />
+ <di:waypoint xsi:type="dc:Point" x="820" y="762" />
+ <di:waypoint xsi:type="dc:Point" x="841" y="762" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="835" y="762" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0nmoax4_di" bpmnElement="callGetServiceInstance">
+ <dc:Bounds x="285" y="223" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_05m3m2e_di" bpmnElement="ScriptTask_05m3m2e">
+ <dc:Bounds x="476" y="223" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="IntermediateCatchEvent_112zjtp_di" bpmnElement="IntermediateCatchEvent_112zjtp">
+ <dc:Bounds x="96" y="245" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="72" y="281" width="82" height="25" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="IntermediateThrowEvent_162gs5w_di" bpmnElement="IntermediateThrowEvent_162gs5w">
+ <dc:Bounds x="732" y="245" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="713" y="286" width="72" height="13" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0jek18q_di" bpmnElement="SequenceFlow_0jek18q">
+ <di:waypoint xsi:type="dc:Point" x="132" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="285" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="209" y="248" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_18103ca_di" bpmnElement="SequenceFlow_18103ca">
+ <di:waypoint xsi:type="dc:Point" x="576" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="732" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="654" y="248" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_04ao07f_di" bpmnElement="SequenceFlow_04ao07f">
+ <di:waypoint xsi:type="dc:Point" x="385" y="1049" />
+ <di:waypoint xsi:type="dc:Point" x="508" y="1049" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="447" y="1034" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1ttswdr_di" bpmnElement="SequenceFlow_1ttswdr">
+ <di:waypoint xsi:type="dc:Point" x="385" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="422" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="422" y="263" />
+ <di:waypoint xsi:type="dc:Point" x="476" y="263" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="437" y="263" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1ildy3f_di" bpmnElement="ScriptTask_1ildy3f">
+ <dc:Bounds x="687" y="435" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1uds6yu_di" bpmnElement="ExclusiveGateway_1uds6yu" isMarkerVisible="true">
+ <dc:Bounds x="828" y="450" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="797" y="508" width="80" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1dmn40p_di" bpmnElement="SequenceFlow_1dmn40p">
+ <di:waypoint xsi:type="dc:Point" x="655" y="475" />
+ <di:waypoint xsi:type="dc:Point" x="687" y="475" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="671" y="450" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0g2cw86_di" bpmnElement="SequenceFlow_0g2cw86">
+ <di:waypoint xsi:type="dc:Point" x="787" y="475" />
+ <di:waypoint xsi:type="dc:Point" x="828" y="475" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="808" y="460" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0mr8jgt_di" bpmnElement="SequenceFlow_0mr8jgt">
+ <di:waypoint xsi:type="dc:Point" x="853" y="453" />
+ <di:waypoint xsi:type="dc:Point" x="853" y="364" />
+ <di:waypoint xsi:type="dc:Point" x="463" y="364" />
+ <di:waypoint xsi:type="dc:Point" x="463" y="435" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="649" y="349" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1wc8h5g_di" bpmnElement="SequenceFlow_1wc8h5g">
+ <di:waypoint xsi:type="dc:Point" x="878" y="475" />
+ <di:waypoint xsi:type="dc:Point" x="926" y="475" />
+ <di:waypoint xsi:type="dc:Point" x="926" y="517" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="895" y="460" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_06llof4_di" bpmnElement="SequenceFlow_06llof4">
+ <di:waypoint xsi:type="dc:Point" x="159" y="1466" />
+ <di:waypoint xsi:type="dc:Point" x="237" y="1466" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="198" y="1441" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ </bpmndi:BPMNPlane>
+ </bpmndi:BPMNDiagram>
+</bpmn2:definitions>
<bpmn2:callActivity id="Task_0ob25pp" name="Delete VNF and Modules" calledElement="DoDeleteVnfAndModules">
<bpmn2:extensionElements>
<camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
- <camunda:in source="DELVI_requestId" target="requestId" />
+ <camunda:in source="DELVI_requestId" target="msoRequestId" />
<camunda:in source="DELVI_vnfId" target="vnfId" />
<camunda:in source="DELVI_serviceInstanceId" target="serviceInstanceId" />
<camunda:in source="DELVI_cloudConfiguration" target="cloudConfiguration" />
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd" id="_MagIIMOUEeW8asg-vCEgWQ" exporter="camunda modeler" exporterVersion="2.7.0" targetNamespace="http://camunda.org/schema/1.0/bpmn">
- <bpmn2:process id="UpdateNetworkInstanceInfra" name="UpdateNetworkInstanceInfra" isExecutable="true">
- <bpmn2:startEvent id="updateNetwork_startEvent" name="Start Flow">
- <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
- </bpmn2:startEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="updateNetwork_startEvent" targetRef="preProcessRequest_ScriptTask"/>
- <bpmn2:scriptTask id="prepareSDNCTopoRequest_ScriptTask" name="Prepare SDNC Topology Request" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_32</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_11</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.prepareSDNCRequest(execution)
-]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_11" name="" sourceRef="prepareSDNCTopoRequest_ScriptTask" targetRef="callAssignSDNCAdapter_CallActivity"/>
- <bpmn2:scriptTask id="validateSDNCResponse_ScriptTask" name="Validate SDNC Response" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_12</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_5</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.validateSDNCResponse(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:exclusiveGateway id="isSdncTopoOk_ExclusiveGateway" name="Is SDNC Ok?" default="sdncTopoNo_SequenceFlow">
- <bpmn2:incoming>SequenceFlow_5</bpmn2:incoming>
- <bpmn2:outgoing>sdncTopoNo_SequenceFlow</bpmn2:outgoing>
- <bpmn2:outgoing>sdncTopoYes_SequenceFlow</bpmn2:outgoing>
- </bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="sdncTopoNo_SequenceFlow" name="No" sourceRef="isSdncTopoOk_ExclusiveGateway" targetRef="sndcError_EndEvent"/>
- <bpmn2:sequenceFlow id="sdncTopoYes_SequenceFlow" name="Yes" sourceRef="isSdncTopoOk_ExclusiveGateway" targetRef="callRESTReQuery1NetworkID_ScriptTask">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("UPDNETI_sdncResponseSuccess" ) == true}]]></bpmn2:conditionExpression>
- </bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="validateSDNCResponse_ScriptTask" targetRef="isSdncTopoOk_ExclusiveGateway"/>
- <bpmn2:boundaryEvent id="BoundaryEvent_4" name="" attachedToRef="validateSDNCResponse_ScriptTask">
- <bpmn2:outgoing>SequenceFlow_34</bpmn2:outgoing>
- <bpmn2:errorEventDefinition id="_ErrorEventDefinition_84" errorRef="Error_2"/>
- </bpmn2:boundaryEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_34" name="" sourceRef="BoundaryEvent_4" targetRef="sndcError_EndEvent"/>
- <bpmn2:endEvent id="sndcError_EndEvent" name="SNDC Error">
- <bpmn2:incoming>sdncTopoNo_SequenceFlow</bpmn2:incoming>
- <bpmn2:incoming>SequenceFlow_34</bpmn2:incoming>
- <bpmn2:errorEventDefinition id="_ErrorEventDefinition_57" errorRef="Error_2"/>
- </bpmn2:endEvent>
- <bpmn2:callActivity id="callRollbackSDNCAdapter_CallActivity" name="Call Rollback SDNC Adapter" isForCompensation="true" calledElement="sdncAdapter">
- <bpmn2:extensionElements>
- <camunda:in source="UPDNETI_rollbackSDNCRequest" target="sdncAdapterWorkflowRequest"/>
- <camunda:in source="mso-request-id" target="mso-request-id"/>
- <camunda:in source="mso-service-instance-id" target="mso-service-instance-id"/>
- <camunda:out source="SDNCA_ResponseCode" target="UPDNETI_rollbackSDNCReturnCode"/>
- <camunda:out source="sdncAdapterResponse" target="UPDNETI_rollbackSDNCResponse"/>
- </bpmn2:extensionElements>
- </bpmn2:callActivity>
- <bpmn2:boundaryEvent id="sndcCompensation_BoundaryEvent" attachedToRef="callAssignSDNCAdapter_CallActivity">
- <bpmn2:compensateEventDefinition id="CompensateEventDefinition_1" waitForCompletion="true"/>
- </bpmn2:boundaryEvent>
- <bpmn2:callActivity id="callAssignSDNCAdapter_CallActivity" name="Call SDNC Assign Adapter V1 Sub-process" calledElement="sdncAdapter">
- <bpmn2:extensionElements>
- <camunda:in source="UPDNETI_changeAssignSDNCRequest" target="sdncAdapterWorkflowRequest"/>
- <camunda:out source="sdncAdapterResponse" target="UPDNETI_changeAssignSDNCResponse"/>
- <camunda:out source="SDNCA_ResponseCode" target="UPDNETI_sdncReturnCode"/>
- <camunda:in source="mso-request-id" target="mso-request-id"/>
- <camunda:in source="mso-service-instance-id" target="mso-service-instance-id"/>
- <camunda:out source="WorkflowException" target="UPDNETI_WorkflowException"/>
- <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator"/>
- <camunda:in variables="all"/>
- </bpmn2:extensionElements>
- <bpmn2:incoming>SequenceFlow_11</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_12</bpmn2:outgoing>
- </bpmn2:callActivity>
- <bpmn2:sequenceFlow id="SequenceFlow_12" name="" sourceRef="callAssignSDNCAdapter_CallActivity" targetRef="validateSDNCResponse_ScriptTask"/>
- <bpmn2:scriptTask id="postProcessAndCompletionRequest_ScriptTask" name="Post Process & Completion Request" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_27</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_29</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.postProcessResponse(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_29" name="" sourceRef="postProcessAndCompletionRequest_ScriptTask" targetRef="callCompleteMsoProcess_CallActivity"/>
- <bpmn2:subProcess id="subProcessException_SubProcess" name="Subprocess For Exception / FalloutHandler " triggeredByEvent="true">
- <bpmn2:exclusiveGateway id="isRollbackOn_Network_ExclusiveGateway" name="Is Rollback On?" default="isRollbackOn_NoNetwork_SequenceFlow">
- <bpmn2:incoming>SequenceFlow_23</bpmn2:incoming>
- <bpmn2:outgoing>isRollbackOn_YesNetwork_SequenceFlow</bpmn2:outgoing>
- <bpmn2:outgoing>isRollbackOn_NoNetwork_SequenceFlow</bpmn2:outgoing>
- </bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="isRollbackOn_YesNetwork_SequenceFlow" name="Yes" sourceRef="isRollbackOn_Network_ExclusiveGateway" targetRef="isPONR_ExclusiveGateway">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("UPDNETI_rollbackEnabled") == true}]]></bpmn2:conditionExpression>
- </bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="isRollbackOn_NoNetwork_SequenceFlow" name="No" sourceRef="isRollbackOn_Network_ExclusiveGateway" targetRef="InclusiveGateway_6"/>
- <bpmn2:startEvent id="subProcessStart_StartEvent" name="Fault Start">
- <bpmn2:outgoing>SequenceFlow_23</bpmn2:outgoing>
- <bpmn2:errorEventDefinition id="ErrorEventDefinition_1" errorRef="Error_2"/>
- </bpmn2:startEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_23" name="" sourceRef="subProcessStart_StartEvent" targetRef="isRollbackOn_Network_ExclusiveGateway"/>
- <bpmn2:exclusiveGateway id="isPONR_ExclusiveGateway" name="isPONR?" default="isPONR_No_SequenceFlow">
- <bpmn2:incoming>isRollbackOn_YesNetwork_SequenceFlow</bpmn2:incoming>
- <bpmn2:outgoing>isPONR_Yes_SequenceFlow</bpmn2:outgoing>
- <bpmn2:outgoing>isPONR_No_SequenceFlow</bpmn2:outgoing>
- </bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="isPONR_Yes_SequenceFlow" name="Yes" sourceRef="isPONR_ExclusiveGateway" targetRef="InclusiveGateway_6">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("UPDNETI_isPONR") == true}]]></bpmn2:conditionExpression>
- </bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="isPONR_No_SequenceFlow" name="No" sourceRef="isPONR_ExclusiveGateway" targetRef="isNetworkOk_ExclusiveGateway"/>
- <bpmn2:exclusiveGateway id="isNetworkOk_ExclusiveGateway" name="is Network Ok?" default="isNetworkOk_No_SequenceFlow">
- <bpmn2:incoming>isPONR_No_SequenceFlow</bpmn2:incoming>
- <bpmn2:outgoing>isNetworkOk_No_SequenceFlow</bpmn2:outgoing>
- <bpmn2:outgoing>isNetworkOk_Yes_SequenceFlow</bpmn2:outgoing>
- </bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="isNetworkOk_No_SequenceFlow" name="No" sourceRef="isNetworkOk_ExclusiveGateway" targetRef="sdncOk_ExclusiveGateway"/>
- <bpmn2:sequenceFlow id="isNetworkOk_Yes_SequenceFlow" name="Yes" sourceRef="isNetworkOk_ExclusiveGateway" targetRef="sdncOk_ExclusiveGateway">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("UPDNETI_isNetworkRollbackNeeded") == true}]]></bpmn2:conditionExpression>
- </bpmn2:sequenceFlow>
- <bpmn2:exclusiveGateway id="sdncOk_ExclusiveGateway" name="is Sdnc Ok?" default="sdncOk_No_ExclusiveGateway">
- <bpmn2:incoming>isNetworkOk_No_SequenceFlow</bpmn2:incoming>
- <bpmn2:incoming>isNetworkOk_Yes_SequenceFlow</bpmn2:incoming>
- <bpmn2:outgoing>sdncOk_Yeso_ExclusiveGateway</bpmn2:outgoing>
- <bpmn2:outgoing>sdncOk_No_ExclusiveGateway</bpmn2:outgoing>
- </bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="sdncOk_Yeso_ExclusiveGateway" name="Yes" sourceRef="sdncOk_ExclusiveGateway" targetRef="prepareSDNCRollbackRequest_ScriptTask">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("UPDNETI_isSdncRollbackNeeded" ) == true}]]></bpmn2:conditionExpression>
- </bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="sdncOk_No_ExclusiveGateway" name="No" sourceRef="sdncOk_ExclusiveGateway" targetRef="validateRollbacksResponse_ScriptTask_2"/>
- <bpmn2:scriptTask id="prepareSDNCRollbackRequest_ScriptTask" name="Prepare SDNCRollback Request" scriptFormat="groovy">
- <bpmn2:incoming>sdncOk_Yeso_ExclusiveGateway</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_53</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.prepareSDNCRollbackRequest(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_53" name="" sourceRef="prepareSDNCRollbackRequest_ScriptTask" targetRef="sdncTopoRollback_IntermediateThrowEvent"/>
- <bpmn2:intermediateThrowEvent id="sdncTopoRollback_IntermediateThrowEvent" name="SDNC Rollback">
- <bpmn2:incoming>SequenceFlow_53</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_55</bpmn2:outgoing>
- <bpmn2:compensateEventDefinition id="sndc_CompensateEventDefinition" activityRef="callRollbackSDNCAdapter_CallActivity" waitForCompletion="true"/>
- </bpmn2:intermediateThrowEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_55" name="" sourceRef="sdncTopoRollback_IntermediateThrowEvent" targetRef="validateRollbacksResponse_ScriptTask_2"/>
- <bpmn2:scriptTask id="prepareDBInfraErrorRequest_ScriptTask" name="Prepare DB Infra Error" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_47</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_22</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.prepareDBRequestError(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_22" name="" sourceRef="prepareDBInfraErrorRequest_ScriptTask" targetRef="callDBInfraErrorUpdate_ServiceTask_1"/>
- <bpmn2:serviceTask id="callDBInfraErrorUpdate_ServiceTask_1" name="Call DB Infra Error Update">
- <bpmn2:extensionElements>
- <camunda:connector>
- <camunda:connectorId>http-connector</camunda:connectorId>
- <camunda:inputOutput>
- <camunda:inputParameter name="url">${URN_mso_adapters_db_endpoint}</camunda:inputParameter>
- <camunda:inputParameter name="payload">${UPDNETI_updateDBRequest}</camunda:inputParameter>
- <camunda:inputParameter name="headers">
- <camunda:map>
- <camunda:entry key="content-type">application/soap+xml</camunda:entry>
- </camunda:map>
- </camunda:inputParameter>
- <camunda:inputParameter name="method">POST</camunda:inputParameter>
- <camunda:outputParameter name="UPDNETI_updateDBResponse">${response}</camunda:outputParameter>
- <camunda:outputParameter name="UPDNETI_dbReturnCode">${statusCode}</camunda:outputParameter>
- </camunda:inputOutput>
- </camunda:connector>
- </bpmn2:extensionElements>
- <bpmn2:incoming>SequenceFlow_22</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_19</bpmn2:outgoing>
- </bpmn2:serviceTask>
- <bpmn2:sequenceFlow id="SequenceFlow_19" name="" sourceRef="callDBInfraErrorUpdate_ServiceTask_1" targetRef="prepareFalloutHandler_ScriptTask"/>
- <bpmn2:callActivity id="faultHandler_CallActivity" name="Call FalloutHandlerV1" calledElement="FalloutHandler">
- <bpmn2:extensionElements>
- <camunda:in variables="all"/>
- <camunda:out variables="all"/>
- <camunda:in source="UPDNETI_FalloutHandlerRequest" target="FalloutHandlerRequest"/>
- <camunda:in source="mso-request-id" target="mso-request-id"/>
- <camunda:in source="mso-service-instance-id" target="mso-service-instance-id"/>
- <camunda:out source="FH_ResponseCode" target="FH_ResponseCode"/>
- <camunda:out source="FalloutHandlerResponse" target="FalloutHandlerResponse"/>
- <camunda:out source="FH_ErrorResponse" target="FH_ErrorResponse"/>
- </bpmn2:extensionElements>
- <bpmn2:incoming>SequenceFlow_25</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_18</bpmn2:outgoing>
- </bpmn2:callActivity>
- <bpmn2:sequenceFlow id="SequenceFlow_18" name="" sourceRef="faultHandler_CallActivity" targetRef="EndEvent_4"/>
- <bpmn2:endEvent id="EndEvent_4">
- <bpmn2:incoming>SequenceFlow_18</bpmn2:incoming>
- </bpmn2:endEvent>
- <bpmn2:scriptTask id="validateRollbacksResponse_ScriptTask_2" name="Validate Rollback Responses" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_55</bpmn2:incoming>
- <bpmn2:incoming>sdncOk_No_ExclusiveGateway</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.validateRollbackResponses(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="validateRollbacksResponse_ScriptTask_2" targetRef="InclusiveGateway_6"/>
- <bpmn2:inclusiveGateway id="InclusiveGateway_6">
- <bpmn2:incoming>isRollbackOn_NoNetwork_SequenceFlow</bpmn2:incoming>
- <bpmn2:incoming>isPONR_Yes_SequenceFlow</bpmn2:incoming>
- <bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_47</bpmn2:outgoing>
- </bpmn2:inclusiveGateway>
- <bpmn2:sequenceFlow id="SequenceFlow_47" name="" sourceRef="InclusiveGateway_6" targetRef="prepareDBInfraErrorRequest_ScriptTask"/>
- <bpmn2:scriptTask id="prepareFalloutHandler_ScriptTask" name="Prepare FalloutHandler" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_19</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_25</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def buildErrorResponse = new UpdateNetworkInstanceInfra()
-buildErrorResponse.buildErrorResponse(execution)
-]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_25" name="" sourceRef="prepareFalloutHandler_ScriptTask" targetRef="faultHandler_CallActivity"/>
- </bpmn2:subProcess>
- <bpmn2:scriptTask id="callRESTReQuery2NetworkID_ScriptTask" name="Call REST ReQuery2 Network Id in AAI" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_13</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_35</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.callRESTReQueryAAINetworkId(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_35" name="" sourceRef="callRESTReQuery2NetworkID_ScriptTask" targetRef="callRESTUpdateContrailNetwork_ScriptTask"/>
- <bpmn2:scriptTask id="callRESTUpdateContrailNetwork_ScriptTask" name="Call REST Update Contrail Network in AAI" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_35</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_46</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.callRESTUpdateContrailAAINetwork(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_46" name="PONR" sourceRef="callRESTUpdateContrailNetwork_ScriptTask" targetRef="prepareDBInfraRequest_ScriptTask"/>
- <bpmn2:scriptTask id="prepareDBInfraRequest_ScriptTask" name="Prepare DB Infra Request" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_46</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_37</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.prepareDBRequest(execution)
-
-]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_37" name="" sourceRef="prepareDBInfraRequest_ScriptTask" targetRef="callDBInfra_ServiceTask"/>
- <bpmn2:serviceTask id="callDBInfra_ServiceTask" name="Call DB Infra Update">
- <bpmn2:extensionElements>
- <camunda:connector>
- <camunda:connectorId>http-connector</camunda:connectorId>
- <camunda:inputOutput>
- <camunda:inputParameter name="url">${URN_mso_adapters_db_endpoint}</camunda:inputParameter>
- <camunda:inputParameter name="payload">${UPDNETI_updateDBRequest}</camunda:inputParameter>
- <camunda:inputParameter name="headers">
- <camunda:map>
- <camunda:entry key="content-type">application/soap+xml</camunda:entry>
- </camunda:map>
- </camunda:inputParameter>
- <camunda:inputParameter name="method">POST</camunda:inputParameter>
- <camunda:outputParameter name="UPDNETI_createDBResponse">${response}</camunda:outputParameter>
- <camunda:outputParameter name="UPDNETI_dbReturnCode">${statusCode}</camunda:outputParameter>
- </camunda:inputOutput>
- </camunda:connector>
- </bpmn2:extensionElements>
- <bpmn2:incoming>SequenceFlow_37</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_27</bpmn2:outgoing>
- </bpmn2:serviceTask>
- <bpmn2:sequenceFlow id="SequenceFlow_27" name="" sourceRef="callDBInfra_ServiceTask" targetRef="postProcessAndCompletionRequest_ScriptTask"/>
- <bpmn2:callActivity id="callCompleteMsoProcess_CallActivity" name="Call CompleteMsoProcess" calledElement="CompleteMsoProcess">
- <bpmn2:extensionElements>
- <camunda:in variables="all"/>
- <camunda:out variables="all"/>
- <camunda:in source="UPDNETI_CompleteMsoProcessRequest" target="CompleteMsoProcessRequest"/>
- <camunda:in source="mso-request-id" target="mso-request-id"/>
- <camunda:in source="mso-service-instance-id" target="mso-service-instance-id"/>
- <camunda:out source="CMSO_ResponseCode" target="CMSO_ResponseCode"/>
- <camunda:out source="CompleteMsoProcessResponse" target="CompleteMsoProcessResponse"/>
- <camunda:out source="CMSO_ErrorResponse" target="CMSO_ErrorResponse"/>
- </bpmn2:extensionElements>
- <bpmn2:incoming>SequenceFlow_29</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_17</bpmn2:outgoing>
- </bpmn2:callActivity>
- <bpmn2:sequenceFlow id="SequenceFlow_17" name="" sourceRef="callCompleteMsoProcess_CallActivity" targetRef="EndEvent_3"/>
- <bpmn2:endEvent id="EndEvent_3">
- <bpmn2:incoming>SequenceFlow_17</bpmn2:incoming>
- </bpmn2:endEvent>
- <bpmn2:subProcess id="unexpectedErrors_SubProcess" name="Sub-process for UnexpectedErrors" triggeredByEvent="true">
- <bpmn2:scriptTask id="ScriptTask_1" name="Log / Print Unexpected Error" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_10</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_14</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.processJavaException(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_14" name="" sourceRef="ScriptTask_1" targetRef="EndEvent_1"/>
- <bpmn2:startEvent id="StartEvent_1">
- <bpmn2:outgoing>SequenceFlow_10</bpmn2:outgoing>
- <bpmn2:errorEventDefinition id="ErrorEventDefinition_2" errorRef="Error_1"/>
- </bpmn2:startEvent>
- <bpmn2:sequenceFlow id="SequenceFlow_10" name="" sourceRef="StartEvent_1" targetRef="ScriptTask_1"/>
- <bpmn2:endEvent id="EndEvent_1">
- <bpmn2:incoming>SequenceFlow_14</bpmn2:incoming>
- </bpmn2:endEvent>
- </bpmn2:subProcess>
- <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.preProcessRequest(execution)
-]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="sendSyncAckResponse_ScriptTask"/>
- <bpmn2:scriptTask id="callRESTQueryCloudRegion_ScriptTask" name="Call REST Query Cloud Region " scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_24</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_32</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.callRESTQueryAAICloudRegion(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_32" name="" sourceRef="callRESTQueryCloudRegion_ScriptTask" targetRef="prepareSDNCTopoRequest_ScriptTask"/>
- <bpmn2:scriptTask id="callRESTQueryNetworkId_ScriptTask" name="Call REST Query Network Id In AAI" scriptFormat="groovy">
- <bpmn2:incoming>siFoundYes</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_24</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.callRESTQueryAAINetworkId(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_24" name="" sourceRef="callRESTQueryNetworkId_ScriptTask" targetRef="callRESTQueryCloudRegion_ScriptTask"/>
- <bpmn2:endEvent id="EndEvent_2">
- <bpmn2:incoming>SequenceFlow_30</bpmn2:incoming>
- <bpmn2:errorEventDefinition id="_ErrorEventDefinition_97" errorRef="Error_2"/>
- </bpmn2:endEvent>
- <bpmn2:scriptTask id="workflowExceptionSINotFound" name="Create Workflow Exception" scriptFormat="groovy">
- <bpmn2:incoming>siFoundNo</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_30</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.utils.*
-ExceptionUtil exceptionUtil = new ExceptionUtil()
-exceptionUtil.buildWorkflowException(execution, 404, "Service Instance Not Found")]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_30" name="" sourceRef="workflowExceptionSINotFound" targetRef="EndEvent_2"/>
- <bpmn2:exclusiveGateway id="siFoundCheck" name="is SI Found?" default="siFoundNo">
- <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
- <bpmn2:outgoing>siFoundYes</bpmn2:outgoing>
- <bpmn2:outgoing>siFoundNo</bpmn2:outgoing>
- </bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="siFoundYes" name="Yes" sourceRef="siFoundCheck" targetRef="callRESTQueryNetworkId_ScriptTask">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("GENGSI_FoundIndicator" ) == true && execution.getVariable("GENGSI_SuccessIndicator" ) == true}]]></bpmn2:conditionExpression>
- </bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="siFoundNo" name="No" sourceRef="siFoundCheck" targetRef="workflowExceptionSINotFound"/>
- <bpmn2:callActivity id="callGetServiceInstance" name="Get
Service
Instance" calledElement="GenericGetService">
- <bpmn2:extensionElements>
- <camunda:in source="UPDNETI_serviceInstanceId" target="GENGS_serviceInstanceId"/>
- <camunda:out source="GENGS_serviceInstance" target="UPDNETI_serviceInstanceId"/>
- <camunda:out source="GENGS_FoundIndicator" target="GENGSI_FoundIndicator"/>
- <camunda:out source="GENGS_SuccessIndicator" target="GENGSI_SuccessIndicator"/>
- <camunda:out source="GENGS_siResourceLink" target="GENGSI_siResourceLink"/>
- <camunda:out source="WorkflowException" target="WorkflowException"/>
- <camunda:in source="GENGS_type" target="GENGS_type"/>
- </bpmn2:extensionElements>
- <bpmn2:incoming>SequenceFlow_28</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
- </bpmn2:callActivity>
- <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="callGetServiceInstance" targetRef="siFoundCheck"/>
- <bpmn2:scriptTask id="sendSyncAckResponse_ScriptTask" name="Send Sync Ack Response" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_28</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.sendSyncResponse(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_28" name="" sourceRef="sendSyncAckResponse_ScriptTask" targetRef="callGetServiceInstance"/>
- <bpmn2:scriptTask id="validateUpdatePONetwork_ScriptTask" name="Validate Update PO Network" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_59</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_13</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.validateUpdateNetworkResponse(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_13" name="" sourceRef="validateUpdatePONetwork_ScriptTask" targetRef="callRESTReQuery2NetworkID_ScriptTask"/>
- <bpmn2:serviceTask id="callUpdateNetwork_ServiceTask" name="Call Update Network">
- <bpmn2:extensionElements>
- <camunda:connector>
- <camunda:connectorId>http-connector</camunda:connectorId>
- <camunda:inputOutput>
- <camunda:inputParameter name="payload">${UPDNETI_updateNetworkRequest}</camunda:inputParameter>
- <camunda:inputParameter name="url">${URN_mso_adapters_network_rest_endpoint}/${UPDNETI_networkId}</camunda:inputParameter>
- <camunda:inputParameter name="headers">
- <camunda:map>
- <camunda:entry key="Authorization">#{BasicAuthHeaderValuePO}</camunda:entry>
- <camunda:entry key="content-type">application/xml</camunda:entry>
- </camunda:map>
- </camunda:inputParameter>
- <camunda:inputParameter name="method">PUT</camunda:inputParameter>
- <camunda:outputParameter name="UPDNETI_networkReturnCode">${statusCode}</camunda:outputParameter>
- <camunda:outputParameter name="UPDNETI_updateNetworkResponse">${response}</camunda:outputParameter>
- </camunda:inputOutput>
- </camunda:connector>
- </bpmn2:extensionElements>
- <bpmn2:incoming>SequenceFlow_61</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_59</bpmn2:outgoing>
- </bpmn2:serviceTask>
- <bpmn2:sequenceFlow id="SequenceFlow_59" name="" sourceRef="callUpdateNetwork_ServiceTask" targetRef="validateUpdatePONetwork_ScriptTask"/>
- <bpmn2:scriptTask id="prepareNetworkRequest_ScriptTask" name="Prepare Create Network Request" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_61</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.prepareUpdateNetworkRequest(execution)
-]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_61" name="" sourceRef="prepareNetworkRequest_ScriptTask" targetRef="callUpdateNetwork_ServiceTask"/>
- <bpmn2:scriptTask id="callRESTQueryNetworkTableRef_ScriptTask" name="Call REST Query Network TableRef in AAI" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_38</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.callRESTQueryAAINetworkTableRef(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="callRESTQueryNetworkTableRef_ScriptTask" targetRef="prepareNetworkRequest_ScriptTask"/>
- <bpmn2:scriptTask id="callRESTReQuery1NetworkID_ScriptTask" name="Call REST ReQuery1 Network Id in AAI" scriptFormat="groovy">
- <bpmn2:incoming>sdncTopoYes_SequenceFlow</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.callRESTReQueryAAINetworkId(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="callRESTReQuery1NetworkID_ScriptTask" targetRef="callRESTQueryVpnBinding_ScriptTask"/>
- <bpmn2:scriptTask id="callRESTQueryVpnBinding_ScriptTask" name="Call REST Query Vpn Binding in AAI" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_15</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.callRESTQueryAAINetworkVpnBinding(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_15" name="" sourceRef="callRESTQueryVpnBinding_ScriptTask" targetRef="callRESTQueryNetworkPolicy_ScriptTask"/>
- <bpmn2:scriptTask id="callRESTQueryNetworkPolicy_ScriptTask" name="Call REST Query Network Policy in AAI" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_15</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_38</bpmn2:outgoing>
- <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-def UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()
-UpdateNetworkInstanceInfra.callRESTQueryAAINetworkPolicy(execution)]]></bpmn2:script>
- </bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_38" name="" sourceRef="callRESTQueryNetworkPolicy_ScriptTask" targetRef="callRESTQueryNetworkTableRef_ScriptTask"/>
- <bpmn2:association id="Association_1" sourceRef="sndcCompensation_BoundaryEvent" targetRef="callRollbackSDNCAdapter_CallActivity"/>
- </bpmn2:process>
- <bpmn2:error id="Error_2" errorCode="MSOWorkflowException" name="MSOWorkflowException"/>
- <bpmn2:error id="Error_1" errorCode="java.lang.Exception" name="java.lang.Exception"/>
- <bpmndi:BPMNDiagram id="BPMNDiagram_1">
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="UpdateNetworkInstanceInfra">
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="updateNetwork_startEvent">
- <dc:Bounds height="36.0" width="36.0" x="192.0" y="185.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="34.0" x="193.0" y="226.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="350.0" y="163.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">
- <di:waypoint xsi:type="dc:Point" x="228.0" y="203.0"/>
- <di:waypoint xsi:type="dc:Point" x="350.0" y="203.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="249.0" y="203.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_63" bpmnElement="validateUpdatePONetwork_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1343.0" y="1311.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_3" bpmnElement="faultHandler_CallActivity">
- <dc:Bounds height="80.0" width="100.0" x="996.0" y="806.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ServiceTask_83" bpmnElement="callUpdateNetwork_ServiceTask">
- <dc:Bounds height="80.0" width="100.0" x="1342.0" y="1176.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_67" bpmnElement="prepareSDNCTopoRequest_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1343.0" y="276.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_4" bpmnElement="callCompleteMsoProcess_CallActivity">
- <dc:Bounds height="80.0" width="100.0" x="137.0" y="1395.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_SubProcess_16" bpmnElement="subProcessException_SubProcess" isExpanded="true">
- <dc:Bounds height="567.0" width="1122.0" x="17.0" y="585.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_50" bpmnElement="subProcessStart_StartEvent">
- <dc:Bounds height="36.0" width="36.0" x="48.0" y="1040.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="67.0" x="33.0" y="1081.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_79" bpmnElement="prepareFalloutHandler_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="756.0" y="806.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_67" bpmnElement="isSdncTopoOk_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="1523.0" y="520.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="125.0" x="1487.0" y="569.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_26" bpmnElement="sdncTopoNo_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_67" targetElement="_BPMNShape_EndEvent_124">
- <di:waypoint xsi:type="dc:Point" x="1573.0" y="545.0"/>
- <di:waypoint xsi:type="dc:Point" x="1682.0" y="546.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="22.0" x="1577.0" y="546.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_28" bpmnElement="sdncTopoYes_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_67" targetElement="_BPMNShape_ScriptTask_336">
- <di:waypoint xsi:type="dc:Point" x="1523.0" y="545.0"/>
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="545.0"/>
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="576.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="29.0" x="1500.0" y="545.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_80" bpmnElement="postProcessAndCompletionRequest_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="347.0" y="1392.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_83" bpmnElement="prepareDBInfraRequest_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="792.0" y="1390.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ServiceTask_86" bpmnElement="callDBInfra_ServiceTask">
- <dc:Bounds height="80.0" width="100.0" x="564.0" y="1392.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_124" bpmnElement="sndcError_EndEvent">
- <dc:Bounds height="36.0" width="36.0" x="1682.0" y="528.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="74.0" x="1663.0" y="569.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_19" bpmnElement="callAssignSDNCAdapter_CallActivity">
- <dc:Bounds height="80.0" width="100.0" x="1341.0" y="395.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_BoundaryEvent_29" bpmnElement="sndcCompensation_BoundaryEvent">
- <dc:Bounds height="36.0" width="36.0" x="1323.0" y="434.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="82.0" x="1280.0" y="474.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_24" bpmnElement="SequenceFlow_11" sourceElement="_BPMNShape_ScriptTask_67" targetElement="_BPMNShape_CallActivity_19">
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="356.0"/>
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="374.0"/>
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="374.0"/>
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="395.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1389.0" y="374.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_29" bpmnElement="SequenceFlow_12" sourceElement="_BPMNShape_CallActivity_19" targetElement="_BPMNShape_ScriptTask_131">
- <di:waypoint xsi:type="dc:Point" x="1441.0" y="435.0"/>
- <di:waypoint xsi:type="dc:Point" x="1499.0" y="435.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1473.0" y="435.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_Association_1" bpmnElement="Association_1" sourceElement="_BPMNShape_BoundaryEvent_29" targetElement="_BPMNShape_CallActivity_21">
- <di:waypoint xsi:type="dc:Point" x="1323.0" y="447.0"/>
- <di:waypoint xsi:type="dc:Point" x="1290.0" y="438.0"/>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_61" targetElement="_BPMNShape_ScriptTask_127">
- <di:waypoint xsi:type="dc:Point" x="450.0" y="203.0"/>
- <di:waypoint xsi:type="dc:Point" x="516.0" y="203.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="481.0" y="203.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_127" bpmnElement="sendSyncAckResponse_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="516.0" y="163.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_35" bpmnElement="SequenceFlow_23" sourceElement="_BPMNShape_StartEvent_50" targetElement="_BPMNShape_ExclusiveGateway_90">
- <di:waypoint xsi:type="dc:Point" x="84.0" y="1058.0"/>
- <di:waypoint xsi:type="dc:Point" x="131.0" y="1058.0"/>
- <di:waypoint xsi:type="dc:Point" x="131.0" y="1057.0"/>
- <di:waypoint xsi:type="dc:Point" x="161.0" y="1057.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="96.0" y="1058.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_24" bpmnElement="sdncTopoRollback_IntermediateThrowEvent">
- <dc:Bounds height="36.0" width="36.0" x="470.0" y="867.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="96.0" x="440.0" y="906.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_38" bpmnElement="SequenceFlow_25" sourceElement="_BPMNShape_ScriptTask_79" targetElement="_BPMNShape_CallActivity_3">
- <di:waypoint xsi:type="dc:Point" x="856.0" y="846.0"/>
- <di:waypoint xsi:type="dc:Point" x="996.0" y="846.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="881.0" y="846.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_131" bpmnElement="validateSDNCResponse_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1499.0" y="395.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_11" bpmnElement="SequenceFlow_5" sourceElement="_BPMNShape_ScriptTask_131" targetElement="_BPMNShape_ExclusiveGateway_67">
- <di:waypoint xsi:type="dc:Point" x="1549.0" y="475.0"/>
- <di:waypoint xsi:type="dc:Point" x="1549.0" y="492.0"/>
- <di:waypoint xsi:type="dc:Point" x="1548.0" y="492.0"/>
- <di:waypoint xsi:type="dc:Point" x="1548.0" y="520.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1545.0" y="503.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_40" bpmnElement="SequenceFlow_27" sourceElement="_BPMNShape_ServiceTask_86" targetElement="_BPMNShape_ScriptTask_80">
- <di:waypoint xsi:type="dc:Point" x="564.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="506.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="506.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="447.0" y="1432.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="528.0" y="1432.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_42" bpmnElement="SequenceFlow_29" sourceElement="_BPMNShape_ScriptTask_80" targetElement="_BPMNShape_CallActivity_4">
- <di:waypoint xsi:type="dc:Point" x="347.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="292.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="292.0" y="1435.0"/>
- <di:waypoint xsi:type="dc:Point" x="237.0" y="1435.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="290.0" y="1512.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_21" bpmnElement="callRollbackSDNCAdapter_CallActivity">
- <dc:Bounds height="80.0" width="100.0" x="1190.0" y="384.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_133" bpmnElement="callRESTQueryNetworkId_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="984.0" y="100.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_134" bpmnElement="callRESTReQuery2NetworkID_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1176.0" y="1390.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_135" bpmnElement="callRESTUpdateContrailNetwork_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="984.0" y="1392.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_54" bpmnElement="SequenceFlow_35" sourceElement="_BPMNShape_ScriptTask_134" targetElement="_BPMNShape_ScriptTask_135">
- <di:waypoint xsi:type="dc:Point" x="1176.0" y="1430.0"/>
- <di:waypoint xsi:type="dc:Point" x="1118.0" y="1430.0"/>
- <di:waypoint xsi:type="dc:Point" x="1118.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="1084.0" y="1432.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1143.0" y="1657.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_58" bpmnElement="SequenceFlow_37" sourceElement="_BPMNShape_ScriptTask_83" targetElement="_BPMNShape_ServiceTask_86">
- <di:waypoint xsi:type="dc:Point" x="792.0" y="1430.0"/>
- <di:waypoint xsi:type="dc:Point" x="691.0" y="1430.0"/>
- <di:waypoint xsi:type="dc:Point" x="691.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="664.0" y="1432.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="773.0" y="1430.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_65" bpmnElement="SequenceFlow_46" sourceElement="_BPMNShape_ScriptTask_135" targetElement="_BPMNShape_ScriptTask_83">
- <di:waypoint xsi:type="dc:Point" x="984.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="926.0" y="1432.0"/>
- <di:waypoint xsi:type="dc:Point" x="926.0" y="1430.0"/>
- <di:waypoint xsi:type="dc:Point" x="892.0" y="1430.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="947.0" y="1432.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_156" bpmnElement="callRESTQueryVpnBinding_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1341.0" y="688.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_18" bpmnElement="SequenceFlow_15" sourceElement="_BPMNShape_ScriptTask_156" targetElement="_BPMNShape_ScriptTask_215">
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="768.0"/>
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="810.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1388.0" y="781.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_87" bpmnElement="SequenceFlow_59" sourceElement="_BPMNShape_ServiceTask_83" targetElement="_BPMNShape_ScriptTask_63">
- <di:waypoint xsi:type="dc:Point" x="1392.0" y="1256.0"/>
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="1311.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1390.0" y="1284.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_157" bpmnElement="prepareNetworkRequest_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1342.0" y="1052.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_89" bpmnElement="SequenceFlow_61" sourceElement="_BPMNShape_ScriptTask_157" targetElement="_BPMNShape_ServiceTask_83">
- <di:waypoint xsi:type="dc:Point" x="1392.0" y="1132.0"/>
- <di:waypoint xsi:type="dc:Point" x="1392.0" y="1176.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1389.0" y="1159.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_90" bpmnElement="isRollbackOn_Network_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="161.0" y="1032.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="98.0" x="138.0" y="1092.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_25" bpmnElement="isRollbackOn_YesNetwork_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_90" targetElement="_BPMNShape_ExclusiveGateway_215">
- <di:waypoint xsi:type="dc:Point" x="186.0" y="1032.0"/>
- <di:waypoint xsi:type="dc:Point" x="186.0" y="1004.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="29.0" x="186.0" y="1020.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_34" bpmnElement="isRollbackOn_NoNetwork_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_90" targetElement="_BPMNShape_InclusiveGateway_24">
- <di:waypoint xsi:type="dc:Point" x="211.0" y="1057.0"/>
- <di:waypoint xsi:type="dc:Point" x="361.0" y="1057.0"/>
- <di:waypoint xsi:type="dc:Point" x="361.0" y="1004.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="22.0" x="211.0" y="1062.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_215" bpmnElement="callRESTQueryNetworkPolicy_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1341.0" y="810.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_60" bpmnElement="SequenceFlow_38" sourceElement="_BPMNShape_ScriptTask_215" targetElement="_BPMNShape_ScriptTask_335">
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="890.0"/>
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="926.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1388.0" y="900.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_InclusiveGateway_24" bpmnElement="InclusiveGateway_6">
- <dc:Bounds height="50.0" width="50.0" x="336.0" y="954.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="361.0" y="1009.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_215" bpmnElement="isPONR_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="161.0" y="954.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="60.0" x="88.0" y="969.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_77" bpmnElement="isPONR_Yes_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_215" targetElement="_BPMNShape_InclusiveGateway_24">
- <di:waypoint xsi:type="dc:Point" x="211.0" y="979.0"/>
- <di:waypoint xsi:type="dc:Point" x="336.0" y="979.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="29.0" x="204.0" y="983.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_85" bpmnElement="isPONR_No_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_215" targetElement="_BPMNShape_ExclusiveGateway_216">
- <di:waypoint xsi:type="dc:Point" x="186.0" y="954.0"/>
- <di:waypoint xsi:type="dc:Point" x="186.0" y="884.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="22.0" x="191.0" y="933.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_216" bpmnElement="isNetworkOk_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="161.0" y="834.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="95.0" x="68.0" y="849.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_86" bpmnElement="isNetworkOk_No_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_216" targetElement="_BPMNShape_ExclusiveGateway_217">
- <di:waypoint xsi:type="dc:Point" x="211.0" y="859.0"/>
- <di:waypoint xsi:type="dc:Point" x="273.0" y="859.0"/>
- <di:waypoint xsi:type="dc:Point" x="273.0" y="781.0"/>
- <di:waypoint xsi:type="dc:Point" x="336.0" y="781.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="22.0" x="211.0" y="863.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_90" bpmnElement="isNetworkOk_Yes_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_216" targetElement="_BPMNShape_ExclusiveGateway_217">
- <di:waypoint xsi:type="dc:Point" x="186.0" y="834.0"/>
- <di:waypoint xsi:type="dc:Point" x="186.0" y="781.0"/>
- <di:waypoint xsi:type="dc:Point" x="273.0" y="781.0"/>
- <di:waypoint xsi:type="dc:Point" x="336.0" y="781.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="29.0" x="192.0" y="814.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_217" bpmnElement="sdncOk_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="336.0" y="756.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="78.0" x="323.0" y="722.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_92" bpmnElement="sdncOk_Yeso_ExclusiveGateway" sourceElement="_BPMNShape_ExclusiveGateway_217" targetElement="_BPMNShape_ScriptTask_261">
- <di:waypoint xsi:type="dc:Point" x="386.0" y="781.0"/>
- <di:waypoint xsi:type="dc:Point" x="438.0" y="781.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="29.0" x="386.0" y="779.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_93" bpmnElement="sdncOk_No_ExclusiveGateway" sourceElement="_BPMNShape_ExclusiveGateway_217" targetElement="_BPMNShape_ScriptTask_262">
- <di:waypoint xsi:type="dc:Point" x="361.0" y="806.0"/>
- <di:waypoint xsi:type="dc:Point" x="362.0" y="845.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="22.0" x="366.0" y="806.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="EndEvent_3">
- <dc:Bounds height="36.0" width="36.0" x="169.0" y="1536.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="187.0" y="1577.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_30" bpmnElement="SequenceFlow_17" sourceElement="_BPMNShape_CallActivity_4" targetElement="_BPMNShape_EndEvent_177">
- <di:waypoint xsi:type="dc:Point" x="187.0" y="1475.0"/>
- <di:waypoint xsi:type="dc:Point" x="187.0" y="1536.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="184.0" y="1475.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_178" bpmnElement="EndEvent_4">
- <dc:Bounds height="36.0" width="36.0" x="1028.0" y="924.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="1046.0" y="965.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_32" bpmnElement="SequenceFlow_18" sourceElement="_BPMNShape_CallActivity_3" targetElement="_BPMNShape_EndEvent_178">
- <di:waypoint xsi:type="dc:Point" x="1046.0" y="886.0"/>
- <di:waypoint xsi:type="dc:Point" x="1046.0" y="924.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1043.0" y="888.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_36" bpmnElement="SequenceFlow_19" sourceElement="_BPMNShape_ServiceTask_97" targetElement="_BPMNShape_ScriptTask_79">
- <di:waypoint xsi:type="dc:Point" x="676.0" y="846.0"/>
- <di:waypoint xsi:type="dc:Point" x="756.0" y="846.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="686.0" y="846.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ServiceTask_97" bpmnElement="callDBInfraErrorUpdate_ServiceTask_1">
- <dc:Bounds height="80.0" width="100.0" x="576.0" y="806.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_218" bpmnElement="prepareDBInfraErrorRequest_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="576.0" y="940.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_37" bpmnElement="SequenceFlow_22" sourceElement="_BPMNShape_ScriptTask_218" targetElement="_BPMNShape_ServiceTask_97">
- <di:waypoint xsi:type="dc:Point" x="626.0" y="940.0"/>
- <di:waypoint xsi:type="dc:Point" x="626.0" y="886.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="623.0" y="927.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_245" bpmnElement="callRESTQueryCloudRegion_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1200.0" y="100.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_53" bpmnElement="SequenceFlow_32" sourceElement="_BPMNShape_ScriptTask_245" targetElement="_BPMNShape_ScriptTask_67">
- <di:waypoint xsi:type="dc:Point" x="1300.0" y="140.0"/>
- <di:waypoint xsi:type="dc:Point" x="1394.0" y="140.0"/>
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="259.0"/>
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="276.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1314.0" y="140.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_BoundaryEvent_38" bpmnElement="BoundaryEvent_4">
- <dc:Bounds height="36.0" width="36.0" x="1581.0" y="377.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_69" bpmnElement="SequenceFlow_34" sourceElement="_BPMNShape_BoundaryEvent_38" targetElement="_BPMNShape_EndEvent_124">
- <di:waypoint xsi:type="dc:Point" x="1617.0" y="395.0"/>
- <di:waypoint xsi:type="dc:Point" x="1700.0" y="394.0"/>
- <di:waypoint xsi:type="dc:Point" x="1700.0" y="528.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1697.0" y="467.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_261" bpmnElement="prepareSDNCRollbackRequest_ScriptTask">
- <dc:Bounds height="79.0" width="100.0" x="438.0" y="742.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_262" bpmnElement="validateRollbacksResponse_ScriptTask_2">
- <dc:Bounds height="80.0" width="100.0" x="312.0" y="845.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_76" bpmnElement="SequenceFlow_47" sourceElement="_BPMNShape_InclusiveGateway_24" targetElement="_BPMNShape_ScriptTask_218">
- <di:waypoint xsi:type="dc:Point" x="386.0" y="979.0"/>
- <di:waypoint xsi:type="dc:Point" x="548.0" y="979.0"/>
- <di:waypoint xsi:type="dc:Point" x="548.0" y="980.0"/>
- <di:waypoint xsi:type="dc:Point" x="576.0" y="980.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="393.0" y="979.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_84" bpmnElement="SequenceFlow_53" sourceElement="_BPMNShape_ScriptTask_261" targetElement="_BPMNShape_IntermediateThrowEvent_24">
- <di:waypoint xsi:type="dc:Point" x="488.0" y="820.0"/>
- <di:waypoint xsi:type="dc:Point" x="488.0" y="867.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="485.0" y="847.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_88" bpmnElement="SequenceFlow_55" sourceElement="_BPMNShape_IntermediateThrowEvent_24" targetElement="_BPMNShape_ScriptTask_262">
- <di:waypoint xsi:type="dc:Point" x="470.0" y="885.0"/>
- <di:waypoint xsi:type="dc:Point" x="441.0" y="885.0"/>
- <di:waypoint xsi:type="dc:Point" x="441.0" y="885.0"/>
- <di:waypoint xsi:type="dc:Point" x="412.0" y="885.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="448.0" y="885.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_10" bpmnElement="SequenceFlow_4" sourceElement="_BPMNShape_ScriptTask_262" targetElement="_BPMNShape_InclusiveGateway_24">
- <di:waypoint xsi:type="dc:Point" x="362.0" y="925.0"/>
- <di:waypoint xsi:type="dc:Point" x="361.0" y="954.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="358.0" y="948.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_19" bpmnElement="SequenceFlow_13" sourceElement="_BPMNShape_ScriptTask_63" targetElement="_BPMNShape_ScriptTask_134">
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="1391.0"/>
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="1430.0"/>
- <di:waypoint xsi:type="dc:Point" x="1310.0" y="1430.0"/>
- <di:waypoint xsi:type="dc:Point" x="1276.0" y="1430.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1390.0" y="1425.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_SubProcess_28" bpmnElement="unexpectedErrors_SubProcess" isExpanded="true">
- <dc:Bounds height="188.0" width="394.0" x="21.0" y="381.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_71" bpmnElement="StartEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="54.0" y="458.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="72.0" y="499.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_270" bpmnElement="ScriptTask_1">
- <dc:Bounds height="80.0" width="100.0" x="169.0" y="436.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_220" bpmnElement="EndEvent_1">
- <dc:Bounds height="36.0" width="36.0" x="330.0" y="458.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="348.0" y="499.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_10" sourceElement="_BPMNShape_StartEvent_71" targetElement="_BPMNShape_ScriptTask_270">
- <di:waypoint xsi:type="dc:Point" x="90.0" y="476.0"/>
- <di:waypoint xsi:type="dc:Point" x="169.0" y="476.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="129.0" y="476.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_13" bpmnElement="SequenceFlow_14" sourceElement="_BPMNShape_ScriptTask_270" targetElement="_BPMNShape_EndEvent_220">
- <di:waypoint xsi:type="dc:Point" x="269.0" y="476.0"/>
- <di:waypoint xsi:type="dc:Point" x="330.0" y="476.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="301.0" y="476.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_72" bpmnElement="callGetServiceInstance">
- <dc:Bounds height="80.0" width="100.0" x="686.0" y="163.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_244" bpmnElement="siFoundCheck" isMarkerVisible="true">
- <dc:Bounds height="50.0" width="50.0" x="836.0" y="177.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="79.0" x="891.0" y="195.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_CallActivity_72" targetElement="_BPMNShape_ExclusiveGateway_244">
- <di:waypoint xsi:type="dc:Point" x="786.0" y="203.0"/>
- <di:waypoint xsi:type="dc:Point" x="805.0" y="203.0"/>
- <di:waypoint xsi:type="dc:Point" x="805.0" y="202.0"/>
- <di:waypoint xsi:type="dc:Point" x="836.0" y="202.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="799.0" y="203.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_17" bpmnElement="siFoundYes" sourceElement="_BPMNShape_ExclusiveGateway_244" targetElement="_BPMNShape_ScriptTask_133">
- <di:waypoint xsi:type="dc:Point" x="861.0" y="177.0"/>
- <di:waypoint xsi:type="dc:Point" x="861.0" y="140.0"/>
- <di:waypoint xsi:type="dc:Point" x="910.0" y="140.0"/>
- <di:waypoint xsi:type="dc:Point" x="984.0" y="140.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="29.0" x="868.0" y="157.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_247" bpmnElement="EndEvent_2">
- <dc:Bounds height="36.0" width="36.0" x="1155.0" y="278.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="0.0" width="0.0" x="1173.0" y="319.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_331" bpmnElement="workflowExceptionSINotFound">
- <dc:Bounds height="80.0" width="100.0" x="984.0" y="256.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_20" bpmnElement="siFoundNo" sourceElement="_BPMNShape_ExclusiveGateway_244" targetElement="_BPMNShape_ScriptTask_331">
- <di:waypoint xsi:type="dc:Point" x="861.0" y="227.0"/>
- <di:waypoint xsi:type="dc:Point" x="861.0" y="296.0"/>
- <di:waypoint xsi:type="dc:Point" x="984.0" y="296.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="22.0" width="22.0" x="871.0" y="233.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_21" bpmnElement="SequenceFlow_30" sourceElement="_BPMNShape_ScriptTask_331" targetElement="_BPMNShape_EndEvent_247">
- <di:waypoint xsi:type="dc:Point" x="1084.0" y="296.0"/>
- <di:waypoint xsi:type="dc:Point" x="1155.0" y="296.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1103.0" y="296.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_22" bpmnElement="SequenceFlow_24" sourceElement="_BPMNShape_ScriptTask_133" targetElement="_BPMNShape_ScriptTask_245">
- <di:waypoint xsi:type="dc:Point" x="1084.0" y="140.0"/>
- <di:waypoint xsi:type="dc:Point" x="1200.0" y="140.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1127.0" y="140.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_27" bpmnElement="SequenceFlow_28" sourceElement="_BPMNShape_ScriptTask_127" targetElement="_BPMNShape_CallActivity_72">
- <di:waypoint xsi:type="dc:Point" x="616.0" y="203.0"/>
- <di:waypoint xsi:type="dc:Point" x="686.0" y="203.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="632.0" y="203.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_335" bpmnElement="callRESTQueryNetworkTableRef_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1341.0" y="926.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_ScriptTask_335" targetElement="_BPMNShape_ScriptTask_157">
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="1006.0"/>
- <di:waypoint xsi:type="dc:Point" x="1392.0" y="1052.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1388.0" y="1028.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_336" bpmnElement="callRESTReQuery1NetworkID_ScriptTask">
- <dc:Bounds height="80.0" width="100.0" x="1343.0" y="576.0"/>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_ScriptTask_336" targetElement="_BPMNShape_ScriptTask_156">
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="656.0"/>
- <di:waypoint xsi:type="dc:Point" x="1393.0" y="672.0"/>
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="672.0"/>
- <di:waypoint xsi:type="dc:Point" x="1391.0" y="688.0"/>
- <bpmndi:BPMNLabel>
- <dc:Bounds height="6.0" width="6.0" x="1390.0" y="666.0"/>
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- </bpmndi:BPMNPlane>
- </bpmndi:BPMNDiagram>
-</bpmn2:definitions>
\ No newline at end of file
<dc:Bounds x="1590" y="155" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_SubProcess_16" bpmnElement="subProcessException_SubProcess" isExpanded="true">
- <dc:Bounds x="25" y="610" width="1266" height="686" />
+ <dc:Bounds x="31" y="608" width="1266" height="686" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_50" bpmnElement="subProcessStart_StartEvent">
- <dc:Bounds x="101" y="1168" width="36" height="36" />
+ <dc:Bounds x="107" y="1166" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="95" y="1209" width="50" height="12" />
+ <dc:Bounds x="101" y="1207" width="50" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_67" bpmnElement="isSdncTopoOk_ExclusiveGateway" isMarkerVisible="true">
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_35" bpmnElement="SequenceFlow_23" sourceElement="_BPMNShape_StartEvent_50">
- <di:waypoint xsi:type="dc:Point" x="137" y="1186" />
- <di:waypoint xsi:type="dc:Point" x="164" y="1186" />
+ <di:waypoint xsi:type="dc:Point" x="143" y="1184" />
+ <di:waypoint xsi:type="dc:Point" x="170" y="1184" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="151" y="1171" width="0" height="0" />
+ <dc:Bounds x="157" y="1169" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_131" bpmnElement="validateSDNCResponse_ScriptTask">
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_215" bpmnElement="isPONR_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds x="298" y="1062" width="50" height="50" />
+ <dc:Bounds x="304" y="1060" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="242" y="1080" width="46" height="12" />
+ <dc:Bounds x="248" y="1078" width="46" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_77" bpmnElement="isPONR_Yes_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_215">
- <di:waypoint xsi:type="dc:Point" x="348" y="1087" />
- <di:waypoint xsi:type="dc:Point" x="451" y="1087" />
- <di:waypoint xsi:type="dc:Point" x="451" y="1161" />
+ <di:waypoint xsi:type="dc:Point" x="354" y="1085" />
+ <di:waypoint xsi:type="dc:Point" x="457" y="1085" />
+ <di:waypoint xsi:type="dc:Point" x="457" y="1159" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="345" y="1090" width="18" height="12" />
+ <dc:Bounds x="351" y="1088" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_85" bpmnElement="isPONR_No_SequenceFlow" sourceElement="_BPMNShape_ExclusiveGateway_215">
- <di:waypoint xsi:type="dc:Point" x="323" y="1062" />
- <di:waypoint xsi:type="dc:Point" x="323" y="1005" />
+ <di:waypoint xsi:type="dc:Point" x="329" y="1060" />
+ <di:waypoint xsi:type="dc:Point" x="329" y="1003" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="333" y="1053" width="14" height="12" />
+ <dc:Bounds x="339" y="1051" width="14" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_217" bpmnElement="sdncOk_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds x="521" y="847" width="50" height="50" />
+ <dc:Bounds x="527" y="845" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="579" y="860" width="72" height="24" />
+ <dc:Bounds x="585" y="858" width="72" height="24" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_92" bpmnElement="sdncOk_Yeso_ExclusiveGateway" sourceElement="_BPMNShape_ExclusiveGateway_217" targetElement="_BPMNShape_ScriptTask_261">
- <di:waypoint xsi:type="dc:Point" x="546" y="847" />
- <di:waypoint xsi:type="dc:Point" x="546" y="778" />
- <di:waypoint xsi:type="dc:Point" x="707" y="778" />
+ <di:waypoint xsi:type="dc:Point" x="552" y="845" />
+ <di:waypoint xsi:type="dc:Point" x="552" y="776" />
+ <di:waypoint xsi:type="dc:Point" x="713" y="776" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="553" y="831" width="18" height="12" />
+ <dc:Bounds x="559" y="829" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_93" bpmnElement="sdncOk_No_ExclusiveGateway" sourceElement="_BPMNShape_ExclusiveGateway_217">
- <di:waypoint xsi:type="dc:Point" x="545" y="896" />
- <di:waypoint xsi:type="dc:Point" x="545" y="980" />
- <di:waypoint xsi:type="dc:Point" x="707" y="980" />
+ <di:waypoint xsi:type="dc:Point" x="551" y="894" />
+ <di:waypoint xsi:type="dc:Point" x="551" y="978" />
+ <di:waypoint xsi:type="dc:Point" x="713" y="978" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="553" y="897" width="14" height="12" />
+ <dc:Bounds x="559" y="895" width="14" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_245" bpmnElement="callRESTQueryCloudRegion_ScriptTask">
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_261" bpmnElement="prepareSDNCRollbackRequest_ScriptTask">
- <dc:Bounds x="880" y="832" width="100" height="79" />
+ <dc:Bounds x="886" y="830" width="100" height="79" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_19" bpmnElement="SequenceFlow_13" sourceElement="_BPMNShape_ScriptTask_63" targetElement="_BPMNShape_ScriptTask_134">
<di:waypoint xsi:type="dc:Point" x="1507" y="1338" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ExclusiveGateway_0f9d94i_di" bpmnElement="isSDNCActivate_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds x="298" y="955" width="50" height="50" />
+ <dc:Bounds x="304" y="953" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="204" y="968" width="84" height="24" />
+ <dc:Bounds x="210" y="966" width="84" height="24" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0cly7z2_di" bpmnElement="SequenceFlow_0cly7z2">
- <di:waypoint xsi:type="dc:Point" x="323" y="955" />
- <di:waypoint xsi:type="dc:Point" x="323" y="912" />
+ <di:waypoint xsi:type="dc:Point" x="329" y="953" />
+ <di:waypoint xsi:type="dc:Point" x="329" y="910" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="329" y="939" width="18" height="12" />
+ <dc:Bounds x="335" y="937" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_12tlymf_di" bpmnElement="SequenceFlow_12tlymf">
- <di:waypoint xsi:type="dc:Point" x="348" y="980" />
- <di:waypoint xsi:type="dc:Point" x="451" y="980" />
- <di:waypoint xsi:type="dc:Point" x="451" y="897" />
+ <di:waypoint xsi:type="dc:Point" x="354" y="978" />
+ <di:waypoint xsi:type="dc:Point" x="457" y="978" />
+ <di:waypoint xsi:type="dc:Point" x="457" y="895" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="344" y="990" width="14" height="12" />
+ <dc:Bounds x="350" y="988" width="14" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ExclusiveGateway_1ts3ph0_di" bpmnElement="isSdncRpc1_ExclusiveGateway1" isMarkerVisible="true">
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ExclusiveGateway_00dh41t_di" bpmnElement="isSdncRpc4_ExclusiveGateway4" isMarkerVisible="true">
- <dc:Bounds x="707" y="753" width="50" height="50" />
+ <dc:Bounds x="713" y="751" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="701" y="712" width="76" height="24" />
+ <dc:Bounds x="707" y="710" width="76" height="24" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0suu90e_di" bpmnElement="isSdncRpc4Yes_SequenceFlow4">
- <di:waypoint xsi:type="dc:Point" x="732" y="803" />
- <di:waypoint xsi:type="dc:Point" x="732" y="832" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="801" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="830" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="737" y="802" width="18" height="12" />
+ <dc:Bounds x="743" y="800" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0xnyl6e_di" bpmnElement="isSdncRpc4No_SequenceFlow4">
- <di:waypoint xsi:type="dc:Point" x="757" y="778" />
- <di:waypoint xsi:type="dc:Point" x="930" y="778" />
- <di:waypoint xsi:type="dc:Point" x="930" y="832" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="776" />
+ <di:waypoint xsi:type="dc:Point" x="936" y="776" />
+ <di:waypoint xsi:type="dc:Point" x="936" y="830" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="766" y="757" width="14" height="12" />
+ <dc:Bounds x="772" y="755" width="14" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ExclusiveGateway_1gghe34_di" bpmnElement="isSdncRpc2_ExclusiveGateway2" isMarkerVisible="true">
<dc:Bounds x="1312" y="395" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ScriptTask_19o9l99_di" bpmnElement="Task_0q6pzpn">
- <dc:Bounds x="682" y="832" width="100" height="80" />
+ <dc:Bounds x="688" y="830" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_1te02c4_di" bpmnElement="EndEvent_1te02c4">
<dc:Bounds x="467" y="1426" width="36" height="36" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_1kpt4kc_di" bpmnElement="EndEvent_1kpt4kc">
- <dc:Bounds x="1154" y="1077" width="36" height="36" />
+ <dc:Bounds x="1160" y="1075" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1173" y="1113" width="0" height="0" />
+ <dc:Bounds x="1179" y="1111" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_0ti2ctu_di" bpmnElement="EndEvent_0ti2ctu">
<dc:Bounds x="699" y="1404" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ScriptTask_0myjg9k_di" bpmnElement="ScriptTask_0myjg9k">
- <dc:Bounds x="682" y="1055" width="100" height="80" />
+ <dc:Bounds x="688" y="1053" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0b8j5rw_di" bpmnElement="SequenceFlow_0b8j5rw">
- <di:waypoint xsi:type="dc:Point" x="373" y="872" />
- <di:waypoint xsi:type="dc:Point" x="426" y="872" />
+ <di:waypoint xsi:type="dc:Point" x="379" y="870" />
+ <di:waypoint xsi:type="dc:Point" x="432" y="870" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="400" y="857" width="0" height="0" />
+ <dc:Bounds x="406" y="855" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_17adm0m_di" bpmnElement="Task_1imzwi3">
- <dc:Bounds x="273" y="832" width="100" height="80" />
+ <dc:Bounds x="279" y="830" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1ipz2ze_di" bpmnElement="SequenceFlow_1ipz2ze">
<di:waypoint xsi:type="dc:Point" x="1454" y="1578" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="CallActivity_1u07hp7_di" bpmnElement="CallActivity_1u07hp7">
- <dc:Bounds x="835" y="1055" width="100" height="80" />
+ <dc:Bounds x="841" y="1053" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0vzsyrd_di" bpmnElement="SequenceFlow_0vzsyrd">
- <di:waypoint xsi:type="dc:Point" x="935" y="1095" />
- <di:waypoint xsi:type="dc:Point" x="1001" y="1095" />
+ <di:waypoint xsi:type="dc:Point" x="941" y="1093" />
+ <di:waypoint xsi:type="dc:Point" x="1007" y="1093" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="968" y="1080" width="0" height="0" />
+ <dc:Bounds x="974" y="1078" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0bwpkkb_di" bpmnElement="SequenceFlow_0bwpkkb">
- <di:waypoint xsi:type="dc:Point" x="732" y="912" />
- <di:waypoint xsi:type="dc:Point" x="732" y="955" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="910" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="953" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="747" y="924" width="0" height="0" />
+ <dc:Bounds x="753" y="922" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0lndbvr_di" bpmnElement="SequenceFlow_0lndbvr">
- <di:waypoint xsi:type="dc:Point" x="930" y="911" />
- <di:waypoint xsi:type="dc:Point" x="930" y="980" />
- <di:waypoint xsi:type="dc:Point" x="757" y="980" />
+ <di:waypoint xsi:type="dc:Point" x="936" y="909" />
+ <di:waypoint xsi:type="dc:Point" x="936" y="978" />
+ <di:waypoint xsi:type="dc:Point" x="763" y="978" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="945" y="946" width="0" height="0" />
+ <dc:Bounds x="951" y="944" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_096tad6_di" bpmnElement="SequenceFlow_096tad6">
- <di:waypoint xsi:type="dc:Point" x="782" y="1095" />
- <di:waypoint xsi:type="dc:Point" x="835" y="1095" />
+ <di:waypoint xsi:type="dc:Point" x="788" y="1093" />
+ <di:waypoint xsi:type="dc:Point" x="841" y="1093" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="809" y="1080" width="0" height="0" />
+ <dc:Bounds x="815" y="1078" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="TextAnnotation_1py1p84_di" bpmnElement="TextAnnotation_1py1p84">
- <dc:Bounds x="1030" y="903" width="252" height="119" />
+ <dc:Bounds x="1036" y="901" width="252" height="119" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="Association_0nketgd_di" bpmnElement="Association_0nketgd">
- <di:waypoint xsi:type="dc:Point" x="935" y="1071" />
- <di:waypoint xsi:type="dc:Point" x="1035" y="1022" />
+ <di:waypoint xsi:type="dc:Point" x="941" y="1069" />
+ <di:waypoint xsi:type="dc:Point" x="1041" y="1020" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_0w2ekuz_di" bpmnElement="ScriptTask_0w2ekuz">
- <dc:Bounds x="1001" y="1055" width="100" height="80" />
+ <dc:Bounds x="1007" y="1053" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1qwubew_di" bpmnElement="SequenceFlow_1qwubew">
- <di:waypoint xsi:type="dc:Point" x="1101" y="1095" />
- <di:waypoint xsi:type="dc:Point" x="1154" y="1095" />
+ <di:waypoint xsi:type="dc:Point" x="1107" y="1093" />
+ <di:waypoint xsi:type="dc:Point" x="1160" y="1093" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1128" y="1070" width="0" height="0" />
+ <dc:Bounds x="1134" y="1068" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ExclusiveGateway_1r7vhm5_di" bpmnElement="isRollbackOn_ExclusiveGateway" isMarkerVisible="true">
- <dc:Bounds x="298" y="1161" width="50" height="50" />
+ <dc:Bounds x="304" y="1159" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="284" y="1211" width="78" height="12" />
+ <dc:Bounds x="290" y="1209" width="78" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_19kcbiw_di" bpmnElement="isRollbackOn_SequenceFlow_Yes">
- <di:waypoint xsi:type="dc:Point" x="323" y="1161" />
- <di:waypoint xsi:type="dc:Point" x="323" y="1112" />
+ <di:waypoint xsi:type="dc:Point" x="329" y="1159" />
+ <di:waypoint xsi:type="dc:Point" x="329" y="1110" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="331" y="1144" width="18" height="12" />
+ <dc:Bounds x="337" y="1142" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0pl3e54_di" bpmnElement="isRollbackOn_SequenceFlow_No">
- <di:waypoint xsi:type="dc:Point" x="348" y="1186" />
- <di:waypoint xsi:type="dc:Point" x="426" y="1186" />
+ <di:waypoint xsi:type="dc:Point" x="354" y="1184" />
+ <di:waypoint xsi:type="dc:Point" x="432" y="1184" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="349" y="1192" width="14" height="12" />
+ <dc:Bounds x="355" y="1190" width="14" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="InclusiveGateway_0zl5xa8_di" bpmnElement="ExclusiveGateway_1qb2vwe">
- <dc:Bounds x="707" y="955" width="50" height="50" />
+ <dc:Bounds x="713" y="953" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="732" y="1005" width="0" height="0" />
+ <dc:Bounds x="738" y="1003" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_15sffxc_di" bpmnElement="SequenceFlow_15sffxc">
- <di:waypoint xsi:type="dc:Point" x="732" y="1005" />
- <di:waypoint xsi:type="dc:Point" x="732" y="1055" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="1003" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="1053" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="747" y="1030" width="0" height="0" />
+ <dc:Bounds x="753" y="1028" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="InclusiveGateway_0t3i8it_di" bpmnElement="ExclusiveGateway_1bk0tqd">
- <dc:Bounds x="426" y="847" width="50" height="50" />
+ <dc:Bounds x="432" y="845" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="451" y="897" width="0" height="0" />
+ <dc:Bounds x="457" y="895" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0k7y7b5_di" bpmnElement="SequenceFlow_0k7y7b5">
- <di:waypoint xsi:type="dc:Point" x="476" y="872" />
- <di:waypoint xsi:type="dc:Point" x="521" y="872" />
+ <di:waypoint xsi:type="dc:Point" x="482" y="870" />
+ <di:waypoint xsi:type="dc:Point" x="527" y="870" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="499" y="847" width="0" height="0" />
+ <dc:Bounds x="505" y="845" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_0p3v749_di" bpmnElement="ScriptTask_0p3v749">
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="InclusiveGateway_1eochiz_di" bpmnElement="ExclusiveGateway_1umhuft">
- <dc:Bounds x="426" y="1161" width="50" height="50" />
+ <dc:Bounds x="432" y="1159" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="451" y="1211" width="0" height="0" />
+ <dc:Bounds x="457" y="1209" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_17nx822_di" bpmnElement="SequenceFlow_17nx822">
- <di:waypoint xsi:type="dc:Point" x="476" y="1186" />
- <di:waypoint xsi:type="dc:Point" x="1051" y="1186" />
- <di:waypoint xsi:type="dc:Point" x="1051" y="1135" />
+ <di:waypoint xsi:type="dc:Point" x="482" y="1184" />
+ <di:waypoint xsi:type="dc:Point" x="1057" y="1184" />
+ <di:waypoint xsi:type="dc:Point" x="1057" y="1133" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="764" y="1171" width="0" height="0" />
+ <dc:Bounds x="770" y="1169" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="TextAnnotation_1orb6o6_di" bpmnElement="TextAnnotation_1orb6o6">
<di:waypoint xsi:type="dc:Point" x="1621" y="1278" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="TextAnnotation_0wjpv6r_di" bpmnElement="TextAnnotation_0wjpv6r">
- <dc:Bounds x="335" y="737" width="180" height="36" />
+ <dc:Bounds x="341" y="735" width="180" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="Association_0eolbkz_di" bpmnElement="Association_0eolbkz">
- <di:waypoint xsi:type="dc:Point" x="446" y="852" />
- <di:waypoint xsi:type="dc:Point" x="429" y="773" />
+ <di:waypoint xsi:type="dc:Point" x="452" y="850" />
+ <di:waypoint xsi:type="dc:Point" x="435" y="771" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_0j3058g_di" bpmnElement="ScriptTask_0j3058g">
- <dc:Bounds x="164" y="1146" width="100" height="80" />
+ <dc:Bounds x="170" y="1144" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_10ttvwn_di" bpmnElement="SequenceFlow_10ttvwn">
- <di:waypoint xsi:type="dc:Point" x="264" y="1186" />
- <di:waypoint xsi:type="dc:Point" x="298" y="1186" />
+ <di:waypoint xsi:type="dc:Point" x="270" y="1184" />
+ <di:waypoint xsi:type="dc:Point" x="304" y="1184" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="281" y="1161" width="0" height="0" />
+ <dc:Bounds x="287" y="1159" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
-<?xml version="1.0" encoding="UTF-8"?>\r
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">\r
- <bpmn2:process id="DoCreateServiceInstance" name="DoCreateServiceInstance" isExecutable="true">\r
- <bpmn2:startEvent id="createSI_startEvent" name="Start Flow">\r
- <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>\r
- </bpmn2:startEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="createSI_startEvent" targetRef="preProcessRequest_ScriptTask" />\r
- <bpmn2:scriptTask id="getAAICustomerById_scriptTask" name="Get AAI Customer By globalCustomerId " scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+ <bpmn2:process id="DoCreateServiceInstance" name="DoCreateServiceInstance" isExecutable="true">
+ <bpmn2:startEvent id="createSI_startEvent" name="Start Flow">
+ <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
+ </bpmn2:startEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="createSI_startEvent" targetRef="preProcessRequest_ScriptTask" />
+ <bpmn2:scriptTask id="getAAICustomerById_scriptTask" name="Get AAI Customer By globalCustomerId " scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def dcsi = new DoCreateServiceInstance()\r
-dcsi.getAAICustomerById(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="getAAICustomerById_scriptTask" targetRef="ExclusiveGateway_09wkav2" />\r
- <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>\r
+def dcsi = new DoCreateServiceInstance()
+dcsi.getAAICustomerById(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="getAAICustomerById_scriptTask" targetRef="ExclusiveGateway_09wkav2" />
+ <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def dcsi = new DoCreateServiceInstance()\r
-dcsi.preProcessRequest(execution)\r
-]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="callGenericGetService" targetRef="ScriptTask_0i8cqdy" />\r
- <bpmn2:scriptTask id="PreProcessSDNCAssignRequest" name="PreProcess SDNC Assign Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_156ih25</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_14</bpmn2:outgoing>\r
+def dcsi = new DoCreateServiceInstance()
+dcsi.preProcessRequest(execution)
+]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="callGenericGetService" targetRef="ScriptTask_0i8cqdy" />
+ <bpmn2:scriptTask id="PreProcessSDNCAssignRequest" name="PreProcess SDNC Assign Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_156ih25</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_14</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def dcsi = new DoCreateServiceInstance()\r
-dcsi.preProcessSDNCAssignRequest(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:scriptTask id="PostProcessSDNCAssignRequest" name="Post Process SDNC Assign Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_9</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_10</bpmn2:outgoing>\r
+def dcsi = new DoCreateServiceInstance()
+dcsi.preProcessSDNCAssignRequest(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:scriptTask id="PostProcessSDNCAssignRequest" name="Post Process SDNC Assign Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_9</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_10</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def dcsi = new DoCreateServiceInstance()\r
-dcsi.postProcessSDNCAssign(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:callActivity id="CallSDNCAdapterServiceTopologyAssign" name="Call SDNC Adapter Service Topology Assign" calledElement="sdncAdapter">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="sdncAssignRequest" target="sdncAdapterWorkflowRequest" />\r
- <camunda:in source="msoRequestId" target="mso-request-id" />\r
- <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="sdncAdapterResponse" target="sdncAdapterResponse" />\r
- <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_14</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_9</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:endEvent id="EndEvent_3">\r
- <bpmn2:incoming>SequenceFlow_10</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="getAAICustomerById_scriptTask" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_14" name="" sourceRef="PreProcessSDNCAssignRequest" targetRef="CallSDNCAdapterServiceTopologyAssign" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_9" name="" sourceRef="CallSDNCAdapterServiceTopologyAssign" targetRef="PostProcessSDNCAssignRequest" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_10" name="" sourceRef="PostProcessSDNCAssignRequest" targetRef="EndEvent_3" />\r
- <bpmn2:callActivity id="callGenericGetService" name="Call GenericGetService" calledElement="GenericGetService">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="serviceInstanceName" target="GENGS_serviceInstanceName" />\r
- <camunda:in source="globalSubscriberId" target="GENGS_globalCustomerId" />\r
- <camunda:in sourceExpression="service-instance" target="GENGS_type" />\r
- <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />\r
- <camunda:out source="GENGS_SuccessIndicator" target="GENGS_SuccessIndicator" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_11fnnkb</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:callActivity id="callGenericPutService" name="Call Generic Put Service" calledElement="GenericPutService">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="globalSubscriberId" target="GENPS_globalSubscriberId" />\r
- <camunda:in source="serviceInstanceId" target="GENPS_serviceInstanceId" />\r
- <camunda:in source="subscriptionServiceType" target="GENPS_serviceType" />\r
- <camunda:in sourceExpression="service-instance" target="GENPS_type" />\r
- <camunda:in source="serviceInstanceData" target="GENPS_payload" />\r
- <camunda:out source="GENPS_SuccessIndicator" target="GENPS_SuccessIndicator" />\r
- <camunda:in source="msoRequestId" target="GENPS_requesId" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1uw2p9a</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1w01tqs</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_129ih1g</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:sequenceFlow id="SequenceFlow_129ih1g" sourceRef="callGenericPutService" targetRef="ScriptTask_0q37vn9" />\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_09wkav2" name="sdncVersion is 1610 or serviceInstance name is populated?" default="SequenceFlow_1uw2p9a">\r
- <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_11fnnkb</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1uw2p9a</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_11fnnkb" name="yes" sourceRef="ExclusiveGateway_09wkav2" targetRef="callGenericGetService">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{(execution.getVariable("serviceInstanceName" ) != null && execution.getVariable("serviceInstanceName" ) != "" ) || execution.getVariable("sdncVersion" ) == "1610" }]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1uw2p9a" name="no" sourceRef="ExclusiveGateway_09wkav2" targetRef="callGenericPutService" />\r
- <bpmn2:subProcess id="SubProcess_06d8lk8" name="Sub-process for Application Errors" triggeredByEvent="true">\r
- <bpmn2:startEvent id="StartEvent_0yljq9y">\r
- <bpmn2:outgoing>SequenceFlow_0tgrn11</bpmn2:outgoing>\r
- <bpmn2:errorEventDefinition />\r
- </bpmn2:startEvent>\r
- <bpmn2:endEvent id="EndEvent_117lkk3">\r
- <bpmn2:incoming>SequenceFlow_1xzgv5k</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:callActivity id="CallActivity_1srx6p6" name="Call DoCreateServiceInstanceRollback" calledElement="DoCreateServiceInstanceRollback">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="msoRequestId" target="mso-request-id" />\r
- <camunda:in source="rollbackData" target="rollbackData" />\r
- <camunda:out source="rolledBack" target="rolledBack" />\r
- <camunda:in source="disableRollback" target="disableRollback" />\r
- <camunda:out source="rollbackError" target="rollbackErrror" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1lqktwf</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0eumzpf</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0eumzpf" sourceRef="CallActivity_1srx6p6" targetRef="ScriptTask_1p0vyip" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0tgrn11" sourceRef="StartEvent_0yljq9y" targetRef="ScriptTask_0ocetux" />\r
- <bpmn2:scriptTask id="ScriptTask_0ocetux" name="Pre Process Rollback" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0tgrn11</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1lqktwf</bpmn2:outgoing>\r
+def dcsi = new DoCreateServiceInstance()
+dcsi.postProcessSDNCAssign(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:callActivity id="CallSDNCAdapterServiceTopologyAssign" name="Call SDNC Adapter Service Topology Assign" calledElement="sdncAdapter">
+ <bpmn2:extensionElements>
+ <camunda:in source="sdncAssignRequest" target="sdncAdapterWorkflowRequest" />
+ <camunda:in source="msoRequestId" target="mso-request-id" />
+ <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="sdncAdapterResponse" target="sdncAdapterResponse" />
+ <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_14</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_9</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:endEvent id="EndEvent_3">
+ <bpmn2:incoming>SequenceFlow_01q6pl4</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="getAAICustomerById_scriptTask" />
+ <bpmn2:sequenceFlow id="SequenceFlow_14" name="" sourceRef="PreProcessSDNCAssignRequest" targetRef="CallSDNCAdapterServiceTopologyAssign" />
+ <bpmn2:sequenceFlow id="SequenceFlow_9" name="" sourceRef="CallSDNCAdapterServiceTopologyAssign" targetRef="PostProcessSDNCAssignRequest" />
+ <bpmn2:sequenceFlow id="SequenceFlow_10" name="" sourceRef="PostProcessSDNCAssignRequest" targetRef="CallActivity_1707jgc" />
+ <bpmn2:callActivity id="callGenericGetService" name="Call GenericGetService" calledElement="GenericGetService">
+ <bpmn2:extensionElements>
+ <camunda:in source="serviceInstanceName" target="GENGS_serviceInstanceName" />
+ <camunda:in source="globalSubscriberId" target="GENGS_globalCustomerId" />
+ <camunda:in sourceExpression="service-instance" target="GENGS_type" />
+ <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />
+ <camunda:out source="GENGS_SuccessIndicator" target="GENGS_SuccessIndicator" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_11fnnkb</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:callActivity id="callGenericPutService" name="Call Generic Put Service" calledElement="GenericPutService">
+ <bpmn2:extensionElements>
+ <camunda:in source="globalSubscriberId" target="GENPS_globalSubscriberId" />
+ <camunda:in source="serviceInstanceId" target="GENPS_serviceInstanceId" />
+ <camunda:in source="subscriptionServiceType" target="GENPS_serviceType" />
+ <camunda:in sourceExpression="service-instance" target="GENPS_type" />
+ <camunda:in source="serviceInstanceData" target="GENPS_payload" />
+ <camunda:out source="GENPS_SuccessIndicator" target="GENPS_SuccessIndicator" />
+ <camunda:in source="msoRequestId" target="GENPS_requesId" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1uw2p9a</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1w01tqs</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_129ih1g</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_129ih1g" sourceRef="callGenericPutService" targetRef="ScriptTask_0q37vn9" />
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_09wkav2" name="sdncVersion is 1610 or serviceInstance name is populated?" default="SequenceFlow_1uw2p9a">
+ <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_11fnnkb</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1uw2p9a</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_11fnnkb" name="yes" sourceRef="ExclusiveGateway_09wkav2" targetRef="callGenericGetService">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{(execution.getVariable("serviceInstanceName" ) != null && execution.getVariable("serviceInstanceName" ) != "" ) || execution.getVariable("sdncVersion" ) == "1610" }]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_1uw2p9a" name="no" sourceRef="ExclusiveGateway_09wkav2" targetRef="callGenericPutService" />
+ <bpmn2:subProcess id="SubProcess_06d8lk8" name="Sub-process for Application Errors" triggeredByEvent="true">
+ <bpmn2:startEvent id="StartEvent_0yljq9y">
+ <bpmn2:outgoing>SequenceFlow_0tgrn11</bpmn2:outgoing>
+ <bpmn2:errorEventDefinition />
+ </bpmn2:startEvent>
+ <bpmn2:endEvent id="EndEvent_117lkk3">
+ <bpmn2:incoming>SequenceFlow_1xzgv5k</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:callActivity id="CallActivity_1srx6p6" name="Call DoCreateServiceInstanceRollback" calledElement="DoCreateServiceInstanceRollback">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="mso-request-id" />
+ <camunda:in source="rollbackData" target="rollbackData" />
+ <camunda:out source="rolledBack" target="rolledBack" />
+ <camunda:in source="disableRollback" target="disableRollback" />
+ <camunda:out source="rollbackError" target="rollbackErrror" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1lqktwf</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0eumzpf</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_0eumzpf" sourceRef="CallActivity_1srx6p6" targetRef="ScriptTask_1p0vyip" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0tgrn11" sourceRef="StartEvent_0yljq9y" targetRef="ScriptTask_0ocetux" />
+ <bpmn2:scriptTask id="ScriptTask_0ocetux" name="Pre Process Rollback" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0tgrn11</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1lqktwf</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def dcsi = new DoCreateServiceInstance()\r
-dcsi.preProcessRollback(execution)\r
-]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1lqktwf" sourceRef="ScriptTask_0ocetux" targetRef="CallActivity_1srx6p6" />\r
- <bpmn2:scriptTask id="ScriptTask_1p0vyip" name="Post Process Rollback" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0eumzpf</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1xzgv5k</bpmn2:outgoing>\r
+def dcsi = new DoCreateServiceInstance()
+dcsi.preProcessRollback(execution)
+]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_1lqktwf" sourceRef="ScriptTask_0ocetux" targetRef="CallActivity_1srx6p6" />
+ <bpmn2:scriptTask id="ScriptTask_1p0vyip" name="Post Process Rollback" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0eumzpf</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1xzgv5k</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def dcsi = new DoCreateServiceInstance()\r
-dcsi.postProcessRollback(execution)\r
-]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1xzgv5k" sourceRef="ScriptTask_1p0vyip" targetRef="EndEvent_117lkk3" />\r
- </bpmn2:subProcess>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1nk6aol" name="sdncVersion is 1610?" default="SequenceFlow_156ih25">\r
- <bpmn2:incoming>SequenceFlow_1dd86x8</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_156ih25</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_00v4npo</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_156ih25" name="no" sourceRef="ExclusiveGateway_1nk6aol" targetRef="PreProcessSDNCAssignRequest" />\r
- <bpmn2:endEvent id="EndEvent_10659gr">\r
- <bpmn2:incoming>SequenceFlow_00v4npo</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_00v4npo" name="yes" sourceRef="ExclusiveGateway_1nk6aol" targetRef="EndEvent_10659gr">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("sdncVersion" ) == "1610"}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:scriptTask id="ScriptTask_0i8cqdy" name="Post Process AAI GET" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1w01tqs</bpmn2:outgoing>\r
+def dcsi = new DoCreateServiceInstance()
+dcsi.postProcessRollback(execution)
+]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_1xzgv5k" sourceRef="ScriptTask_1p0vyip" targetRef="EndEvent_117lkk3" />
+ </bpmn2:subProcess>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1nk6aol" name="sdncVersion is 1610?" default="SequenceFlow_156ih25">
+ <bpmn2:incoming>SequenceFlow_1dd86x8</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_156ih25</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_00v4npo</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_156ih25" name="no" sourceRef="ExclusiveGateway_1nk6aol" targetRef="PreProcessSDNCAssignRequest" />
+ <bpmn2:endEvent id="EndEvent_10659gr">
+ <bpmn2:incoming>SequenceFlow_00v4npo</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_00v4npo" name="yes" sourceRef="ExclusiveGateway_1nk6aol" targetRef="EndEvent_10659gr">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("sdncVersion" ) == "1610"}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:scriptTask id="ScriptTask_0i8cqdy" name="Post Process AAI GET" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1w01tqs</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def dcsi = new DoCreateServiceInstance()\r
-dcsi.postProcessAAIGET(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1w01tqs" sourceRef="ScriptTask_0i8cqdy" targetRef="callGenericPutService" />\r
- <bpmn2:scriptTask id="ScriptTask_0q37vn9" name="Post Process AAI PUT" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_129ih1g</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1dd86x8</bpmn2:outgoing>\r
+def dcsi = new DoCreateServiceInstance()
+dcsi.postProcessAAIGET(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_1w01tqs" sourceRef="ScriptTask_0i8cqdy" targetRef="callGenericPutService" />
+ <bpmn2:scriptTask id="ScriptTask_0q37vn9" name="Post Process AAI PUT" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_129ih1g</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1dd86x8</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def ddsi = new DoCreateServiceInstance()\r
-ddsi.postProcessAAIPUT(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1dd86x8" sourceRef="ScriptTask_0q37vn9" targetRef="ExclusiveGateway_1nk6aol" />\r
- </bpmn2:process>\r
- <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />\r
- <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />\r
- <bpmndi:BPMNDiagram id="BPMNDiagram_1">\r
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoCreateServiceInstance">\r
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createSI_startEvent">\r
- <dc:Bounds x="152" y="79" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="147" y="120" width="48" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">\r
- <dc:Bounds x="245" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">\r
- <di:waypoint xsi:type="dc:Point" x="188" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="245" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="217" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_62" bpmnElement="getAAICustomerById_scriptTask">\r
- <dc:Bounds x="393" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_6" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_62">\r
- <di:waypoint xsi:type="dc:Point" x="493" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="565" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="529" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="EndEvent_3">\r
- <dc:Bounds x="1142" y="886" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1160" y="927" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_10" bpmnElement="SequenceFlow_4">\r
- <di:waypoint xsi:type="dc:Point" x="839" y="94" />\r
- <di:waypoint xsi:type="dc:Point" x="971" y="94" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="905" y="79" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_334" bpmnElement="PreProcessSDNCAssignRequest">\r
- <dc:Bounds x="972" y="578" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_335" bpmnElement="PostProcessSDNCAssignRequest">\r
- <dc:Bounds x="972" y="864" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_CallActivity_74" bpmnElement="CallSDNCAdapterServiceTopologyAssign">\r
- <dc:Bounds x="972" y="721" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_ScriptTask_61" targetElement="_BPMNShape_ScriptTask_62">\r
- <di:waypoint xsi:type="dc:Point" x="345" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="393" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="369" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_14" sourceElement="_BPMNShape_ScriptTask_334" targetElement="_BPMNShape_CallActivity_74">\r
- <di:waypoint xsi:type="dc:Point" x="1020" y="658" />\r
- <di:waypoint xsi:type="dc:Point" x="1020" y="692" />\r
- <di:waypoint xsi:type="dc:Point" x="1020" y="692" />\r
- <di:waypoint xsi:type="dc:Point" x="1020" y="715" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1035" y="692" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_11" bpmnElement="SequenceFlow_9" sourceElement="_BPMNShape_CallActivity_74" targetElement="_BPMNShape_ScriptTask_335">\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="801" />\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="840" />\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="840" />\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="864" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1037" y="840" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_10" sourceElement="_BPMNShape_ScriptTask_335">\r
- <di:waypoint xsi:type="dc:Point" x="1072" y="904" />\r
- <di:waypoint xsi:type="dc:Point" x="1111" y="904" />\r
- <di:waypoint xsi:type="dc:Point" x="1111" y="904" />\r
- <di:waypoint xsi:type="dc:Point" x="1142" y="904" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1126" y="904" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="CallActivity_1md4kyb_di" bpmnElement="callGenericGetService">\r
- <dc:Bounds x="739" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="CallActivity_0khp0qc_di" bpmnElement="callGenericPutService">\r
- <dc:Bounds x="972" y="206" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_129ih1g_di" bpmnElement="SequenceFlow_129ih1g">\r
- <di:waypoint xsi:type="dc:Point" x="1023" y="286" />\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="336" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1023" y="296" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_09wkav2_di" bpmnElement="ExclusiveGateway_09wkav2" isMarkerVisible="true">\r
- <dc:Bounds x="565" y="72" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="547" y="7" width="81" height="62" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_11fnnkb_di" bpmnElement="SequenceFlow_11fnnkb">\r
- <di:waypoint xsi:type="dc:Point" x="615" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="739" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="635" y="76" width="18" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1uw2p9a_di" bpmnElement="SequenceFlow_1uw2p9a">\r
- <di:waypoint xsi:type="dc:Point" x="590" y="122" />\r
- <di:waypoint xsi:type="dc:Point" x="590" y="246" />\r
- <di:waypoint xsi:type="dc:Point" x="972" y="246" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="594" y="132.89706349694825" width="12" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="SubProcess_06d8lk8_di" bpmnElement="SubProcess_06d8lk8" isExpanded="true">\r
- <dc:Bounds x="99" y="531" width="783" height="195" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="StartEvent_0yljq9y_di" bpmnElement="StartEvent_0yljq9y">\r
- <dc:Bounds x="195" y="608" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="213" y="649" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="EndEvent_117lkk3_di" bpmnElement="EndEvent_117lkk3">\r
- <dc:Bounds x="828" y="608" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="846" y="649" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="CallActivity_1srx6p6_di" bpmnElement="CallActivity_1srx6p6">\r
- <dc:Bounds x="493" y="586" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0eumzpf_di" bpmnElement="SequenceFlow_0eumzpf">\r
- <di:waypoint xsi:type="dc:Point" x="593" y="626" />\r
- <di:waypoint xsi:type="dc:Point" x="661" y="626" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="627" y="611" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0tgrn11_di" bpmnElement="SequenceFlow_0tgrn11">\r
- <di:waypoint xsi:type="dc:Point" x="231" y="626" />\r
- <di:waypoint xsi:type="dc:Point" x="330" y="626" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="281" y="611" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1nk6aol_di" bpmnElement="ExclusiveGateway_1nk6aol" isMarkerVisible="true">\r
- <dc:Bounds x="997" y="460" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="903" y="472" width="75" height="24" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_156ih25_di" bpmnElement="SequenceFlow_156ih25">\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="510" />\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="545" />\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="545" />\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="575" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1039" y="510.8721806797853" width="12" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="EndEvent_10659gr_di" bpmnElement="EndEvent_10659gr">\r
- <dc:Bounds x="1103" y="467" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1121" y="508" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_00v4npo_di" bpmnElement="SequenceFlow_00v4npo">\r
- <di:waypoint xsi:type="dc:Point" x="1047" y="485" />\r
- <di:waypoint xsi:type="dc:Point" x="1103" y="485" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1063" y="461" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_0i8cqdy_di" bpmnElement="ScriptTask_0i8cqdy">\r
- <dc:Bounds x="971" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1w01tqs_di" bpmnElement="SequenceFlow_1w01tqs">\r
- <di:waypoint xsi:type="dc:Point" x="1021" y="137" />\r
- <di:waypoint xsi:type="dc:Point" x="1021" y="172" />\r
- <di:waypoint xsi:type="dc:Point" x="1021" y="172" />\r
- <di:waypoint xsi:type="dc:Point" x="1021" y="206" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1036" y="172" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_0q37vn9_di" bpmnElement="ScriptTask_0q37vn9">\r
- <dc:Bounds x="972" y="336" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1dd86x8_di" bpmnElement="SequenceFlow_1dd86x8">\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="416" />\r
- <di:waypoint xsi:type="dc:Point" x="1022" y="460" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1037" y="438" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_0ocetux_di" bpmnElement="ScriptTask_0ocetux">\r
- <dc:Bounds x="330" y="586" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1lqktwf_di" bpmnElement="SequenceFlow_1lqktwf">\r
- <di:waypoint xsi:type="dc:Point" x="430" y="626" />\r
- <di:waypoint xsi:type="dc:Point" x="493" y="626" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="462" y="611" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_1p0vyip_di" bpmnElement="ScriptTask_1p0vyip">\r
- <dc:Bounds x="661" y="586" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1xzgv5k_di" bpmnElement="SequenceFlow_1xzgv5k">\r
- <di:waypoint xsi:type="dc:Point" x="761" y="626" />\r
- <di:waypoint xsi:type="dc:Point" x="793" y="626" />\r
- <di:waypoint xsi:type="dc:Point" x="793" y="626" />\r
- <di:waypoint xsi:type="dc:Point" x="828" y="626" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="808" y="626" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- </bpmndi:BPMNPlane>\r
- </bpmndi:BPMNDiagram>\r
-</bpmn2:definitions>\r
+def ddsi = new DoCreateServiceInstance()
+ddsi.postProcessAAIPUT(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_1dd86x8" sourceRef="ScriptTask_0q37vn9" targetRef="ExclusiveGateway_1nk6aol" />
+ <bpmn2:callActivity id="CallActivity_1707jgc" name="Call GenericGetService2" calledElement="GenericGetService">
+ <bpmn2:extensionElements>
+ <camunda:in source="serviceInstanceId" target="GENGS_serviceInstanceId" />
+ <camunda:in sourceExpression="service-instance" target="GENGS_type" />
+ <camunda:in source="globalSubscriberId" target="GENGS_globalCustomerId" />
+ <camunda:in source="subscriptionServiceType" target="GENGS_serviceType" />
+ <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />
+ <camunda:out source="GENGS_SuccessIndicator" target="GENGS_SuccessIndicator" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="GENGS_service" target="GENGS_service" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_10</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0tx5frq</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_0tx5frq" sourceRef="CallActivity_1707jgc" targetRef="ScriptTask_1tp0fcx" />
+ <bpmn2:sequenceFlow id="SequenceFlow_01q6pl4" sourceRef="ScriptTask_1tp0fcx" targetRef="EndEvent_3" />
+ <bpmn2:scriptTask id="ScriptTask_1tp0fcx" name="Post Process AAI GET2" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0tx5frq</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_01q6pl4</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+def dcsi = new DoCreateServiceInstance()
+dcsi.postProcessAAIGET2(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ </bpmn2:process>
+ <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
+ <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
+ <bpmndi:BPMNDiagram id="BPMNDiagram_1">
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoCreateServiceInstance">
+ <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createSI_startEvent">
+ <dc:Bounds x="152" y="79" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="147" y="120" width="48" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">
+ <dc:Bounds x="245" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">
+ <di:waypoint xsi:type="dc:Point" x="188" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="245" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="217" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_62" bpmnElement="getAAICustomerById_scriptTask">
+ <dc:Bounds x="393" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_6" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_62">
+ <di:waypoint xsi:type="dc:Point" x="493" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="565" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="529" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="EndEvent_3">
+ <dc:Bounds x="1115" y="1165" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1133" y="1206" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_10" bpmnElement="SequenceFlow_4">
+ <di:waypoint xsi:type="dc:Point" x="839" y="94" />
+ <di:waypoint xsi:type="dc:Point" x="971" y="94" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="905" y="79" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_334" bpmnElement="PreProcessSDNCAssignRequest">
+ <dc:Bounds x="972" y="578" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_335" bpmnElement="PostProcessSDNCAssignRequest">
+ <dc:Bounds x="972" y="864" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_CallActivity_74" bpmnElement="CallSDNCAdapterServiceTopologyAssign">
+ <dc:Bounds x="972" y="721" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_ScriptTask_61" targetElement="_BPMNShape_ScriptTask_62">
+ <di:waypoint xsi:type="dc:Point" x="345" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="393" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="369" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_14" sourceElement="_BPMNShape_ScriptTask_334" targetElement="_BPMNShape_CallActivity_74">
+ <di:waypoint xsi:type="dc:Point" x="1020" y="658" />
+ <di:waypoint xsi:type="dc:Point" x="1020" y="692" />
+ <di:waypoint xsi:type="dc:Point" x="1020" y="692" />
+ <di:waypoint xsi:type="dc:Point" x="1020" y="715" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1035" y="692" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_11" bpmnElement="SequenceFlow_9" sourceElement="_BPMNShape_CallActivity_74" targetElement="_BPMNShape_ScriptTask_335">
+ <di:waypoint xsi:type="dc:Point" x="1022" y="801" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="840" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="840" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="864" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1037" y="840" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_10" sourceElement="_BPMNShape_ScriptTask_335">
+ <di:waypoint xsi:type="dc:Point" x="1024" y="944" />
+ <di:waypoint xsi:type="dc:Point" x="1024" y="994" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1039" y="969" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_1md4kyb_di" bpmnElement="callGenericGetService">
+ <dc:Bounds x="739" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0khp0qc_di" bpmnElement="callGenericPutService">
+ <dc:Bounds x="972" y="206" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_129ih1g_di" bpmnElement="SequenceFlow_129ih1g">
+ <di:waypoint xsi:type="dc:Point" x="1023" y="286" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="336" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1023" y="296" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_09wkav2_di" bpmnElement="ExclusiveGateway_09wkav2" isMarkerVisible="true">
+ <dc:Bounds x="565" y="72" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="547" y="7" width="81" height="62" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_11fnnkb_di" bpmnElement="SequenceFlow_11fnnkb">
+ <di:waypoint xsi:type="dc:Point" x="615" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="739" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="635" y="76" width="18" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1uw2p9a_di" bpmnElement="SequenceFlow_1uw2p9a">
+ <di:waypoint xsi:type="dc:Point" x="590" y="122" />
+ <di:waypoint xsi:type="dc:Point" x="590" y="246" />
+ <di:waypoint xsi:type="dc:Point" x="972" y="246" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="594" y="132.89706349694825" width="12" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="SubProcess_06d8lk8_di" bpmnElement="SubProcess_06d8lk8" isExpanded="true">
+ <dc:Bounds x="99" y="531" width="783" height="195" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="StartEvent_0yljq9y_di" bpmnElement="StartEvent_0yljq9y">
+ <dc:Bounds x="195" y="608" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="213" y="649" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="EndEvent_117lkk3_di" bpmnElement="EndEvent_117lkk3">
+ <dc:Bounds x="828" y="608" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="846" y="649" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_1srx6p6_di" bpmnElement="CallActivity_1srx6p6">
+ <dc:Bounds x="493" y="586" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0eumzpf_di" bpmnElement="SequenceFlow_0eumzpf">
+ <di:waypoint xsi:type="dc:Point" x="593" y="626" />
+ <di:waypoint xsi:type="dc:Point" x="661" y="626" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="627" y="611" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0tgrn11_di" bpmnElement="SequenceFlow_0tgrn11">
+ <di:waypoint xsi:type="dc:Point" x="231" y="626" />
+ <di:waypoint xsi:type="dc:Point" x="330" y="626" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="281" y="611" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1nk6aol_di" bpmnElement="ExclusiveGateway_1nk6aol" isMarkerVisible="true">
+ <dc:Bounds x="997" y="460" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="903" y="472" width="75" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_156ih25_di" bpmnElement="SequenceFlow_156ih25">
+ <di:waypoint xsi:type="dc:Point" x="1022" y="510" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="545" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="545" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="575" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1039" y="510.8721806797853" width="12" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="EndEvent_10659gr_di" bpmnElement="EndEvent_10659gr">
+ <dc:Bounds x="1103" y="467" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1121" y="508" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_00v4npo_di" bpmnElement="SequenceFlow_00v4npo">
+ <di:waypoint xsi:type="dc:Point" x="1047" y="485" />
+ <di:waypoint xsi:type="dc:Point" x="1103" y="485" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1063" y="461" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_0i8cqdy_di" bpmnElement="ScriptTask_0i8cqdy">
+ <dc:Bounds x="971" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1w01tqs_di" bpmnElement="SequenceFlow_1w01tqs">
+ <di:waypoint xsi:type="dc:Point" x="1021" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="1021" y="172" />
+ <di:waypoint xsi:type="dc:Point" x="1021" y="172" />
+ <di:waypoint xsi:type="dc:Point" x="1021" y="206" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1036" y="172" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_0q37vn9_di" bpmnElement="ScriptTask_0q37vn9">
+ <dc:Bounds x="972" y="336" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1dd86x8_di" bpmnElement="SequenceFlow_1dd86x8">
+ <di:waypoint xsi:type="dc:Point" x="1022" y="416" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="460" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1037" y="438" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_0ocetux_di" bpmnElement="ScriptTask_0ocetux">
+ <dc:Bounds x="330" y="586" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1lqktwf_di" bpmnElement="SequenceFlow_1lqktwf">
+ <di:waypoint xsi:type="dc:Point" x="430" y="626" />
+ <di:waypoint xsi:type="dc:Point" x="493" y="626" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="462" y="611" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1p0vyip_di" bpmnElement="ScriptTask_1p0vyip">
+ <dc:Bounds x="661" y="586" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1xzgv5k_di" bpmnElement="SequenceFlow_1xzgv5k">
+ <di:waypoint xsi:type="dc:Point" x="761" y="626" />
+ <di:waypoint xsi:type="dc:Point" x="793" y="626" />
+ <di:waypoint xsi:type="dc:Point" x="793" y="626" />
+ <di:waypoint xsi:type="dc:Point" x="828" y="626" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="808" y="626" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_1707jgc_di" bpmnElement="CallActivity_1707jgc">
+ <dc:Bounds x="972" y="994" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0tx5frq_di" bpmnElement="SequenceFlow_0tx5frq">
+ <di:waypoint xsi:type="dc:Point" x="1022" y="1074" />
+ <di:waypoint xsi:type="dc:Point" x="1022" y="1143" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1037" y="1108.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_01q6pl4_di" bpmnElement="SequenceFlow_01q6pl4">
+ <di:waypoint xsi:type="dc:Point" x="1072" y="1183" />
+ <di:waypoint xsi:type="dc:Point" x="1115" y="1183" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1094" y="1168" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1tp0fcx_di" bpmnElement="ScriptTask_1tp0fcx">
+ <dc:Bounds x="972" y="1143" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ </bpmndi:BPMNPlane>
+ </bpmndi:BPMNDiagram>
+</bpmn2:definitions>
-<?xml version="1.0" encoding="UTF-8"?>\r
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">\r
- <bpmn2:process id="DoCreateServiceInstanceRollback" name="DoCreateServiceInstanceRollback" isExecutable="true">\r
- <bpmn2:startEvent id="createSIRollback_startEvent" name="Start Flow">\r
- <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>\r
- </bpmn2:startEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="createSIRollback_startEvent" targetRef="preProcessRequest_ScriptTask" />\r
- <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+ <bpmn2:process id="DoCreateServiceInstanceRollback" name="DoCreateServiceInstanceRollback" isExecutable="true">
+ <bpmn2:startEvent id="createSIRollback_startEvent" name="Start Flow">
+ <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
+ </bpmn2:startEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="createSIRollback_startEvent" targetRef="preProcessRequest_ScriptTask" />
+ <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def rbk = new DoCreateServiceInstanceRollback()\r
-rbk.preProcessRequest(execution)\r
-]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:endEvent id="EndEvent_3">\r
- <bpmn2:incoming>SequenceFlow_01l4ssl</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:subProcess id="UnexpectedError_SubProcess_1" name="Sub-process for Errors" triggeredByEvent="true">\r
- <bpmn2:startEvent id="StartEvent_1">\r
- <bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>\r
- <bpmn2:errorEventDefinition id="_ErrorEventDefinition_92" />\r
- </bpmn2:startEvent>\r
- <bpmn2:endEvent id="EndEvent_1">\r
- <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="StartEvent_1" targetRef="ScriptTask_1" />\r
- <bpmn2:scriptTask id="ScriptTask_1" name="Handle Errors" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>\r
+def rbk = new DoCreateServiceInstanceRollback()
+rbk.preProcessRequest(execution)
+]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:endEvent id="EndEvent_3">
+ <bpmn2:incoming>SequenceFlow_01l4ssl</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:subProcess id="UnexpectedError_SubProcess_1" name="Sub-process for Errors" triggeredByEvent="true">
+ <bpmn2:startEvent id="StartEvent_1">
+ <bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>
+ <bpmn2:errorEventDefinition id="_ErrorEventDefinition_92" />
+ </bpmn2:startEvent>
+ <bpmn2:endEvent id="EndEvent_1">
+ <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="StartEvent_1" targetRef="ScriptTask_1" />
+ <bpmn2:scriptTask id="ScriptTask_1" name="Handle Errors" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def rbk= new DoCreateServiceInstanceRollback()\r
-rbk.processRollbackException(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="ScriptTask_1" targetRef="EndEvent_1" />\r
- </bpmn2:subProcess>\r
- <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="ExclusiveGateway_19tbjgn" />\r
- <bpmn2:callActivity id="callGenericDeleteService" name="Call AAI GenericDelete Service " calledElement="GenericDeleteService">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="serviceInstanceId" target="GENDS_serviceInstanceId" />\r
- <camunda:in source="subscriptionServiceType" target="GENDS_serviceType" />\r
- <camunda:in source="globalSubscriberId" target="GENDS_globalCustomerId" />\r
- <camunda:in sourceExpression="service-instance" target="GENDS_type" />\r
- <camunda:out source="GENDS_FoundIndicator" target="GENDS_FoundIndicator" />\r
- <camunda:in sourceExpression="""" target="GENGS_serviceType" />\r
- <camunda:out source="GENDS_SuccessIndicator" target="GENDS_SuccessIndicator" />\r
- <camunda:out source="WorkflowException" target="WorkflowExecption" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1x9eh33</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_05wu9i7</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_09wkav2" name="RollbackSDNC?" default="SequenceFlow_1uw2p9a">\r
- <bpmn2:incoming>SequenceFlow_06aasqh</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_11fnnkb</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1uw2p9a</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_11fnnkb" name="yes" sourceRef="ExclusiveGateway_09wkav2" targetRef="CallActivity_0ak0ezb">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("rollbackSDNC" ) == "true"}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1uw2p9a" name="no" sourceRef="ExclusiveGateway_09wkav2" targetRef="ExclusiveGateway_0ii31dq" />\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_0ii31dq" name="RollBackAAI?" default="SequenceFlow_1n7wade">\r
- <bpmn2:documentation>rollback AAI</bpmn2:documentation>\r
- <bpmn2:incoming>SequenceFlow_1uw2p9a</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0khjo7l</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1n7wade</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1x9eh33</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1n7wade" name="no" sourceRef="ExclusiveGateway_0ii31dq" targetRef="PostProcess_ScriptTask" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_05wu9i7" sourceRef="callGenericDeleteService" targetRef="PostProcess_ScriptTask" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1x9eh33" name="yes" sourceRef="ExclusiveGateway_0ii31dq" targetRef="callGenericDeleteService">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("rollbackAAI" ) == "true"}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0k28xib" sourceRef="CallActivity_0ak0ezb" targetRef="ScriptTask_1uxr0cx" />\r
- <bpmn2:callActivity id="CallActivity_0ak0ezb" name="Call SDNC Service Topology Rollback" calledElement="sdncAdapter">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="sdncRollbackRequest" target="sdncAdapterWorkflowRequest" />\r
- <camunda:in source="msoRequestId" target="mso-request-id" />\r
- <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="sdncAdapterResponse" target="sdncAdapterResponse" />\r
- <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_11fnnkb</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0k28xib</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:scriptTask id="ScriptTask_1uxr0cx" name="Post Process SDNC Rollback " scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0k28xib</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0khjo7l</bpmn2:outgoing>\r
+def rbk= new DoCreateServiceInstanceRollback()
+rbk.processRollbackException(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="ScriptTask_1" targetRef="EndEvent_1" />
+ </bpmn2:subProcess>
+ <bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="preProcessRequest_ScriptTask" targetRef="ExclusiveGateway_19tbjgn" />
+ <bpmn2:callActivity id="callGenericDeleteService" name="Call AAI GenericDelete Service " calledElement="GenericDeleteService">
+ <bpmn2:extensionElements>
+ <camunda:in source="serviceInstanceId" target="GENDS_serviceInstanceId" />
+ <camunda:in source="subscriptionServiceType" target="GENDS_serviceType" />
+ <camunda:in source="globalSubscriberId" target="GENDS_globalCustomerId" />
+ <camunda:in sourceExpression="service-instance" target="GENDS_type" />
+ <camunda:out source="GENDS_FoundIndicator" target="GENDS_FoundIndicator" />
+ <camunda:in sourceExpression="""" target="GENGS_serviceType" />
+ <camunda:out source="GENDS_SuccessIndicator" target="GENDS_SuccessIndicator" />
+ <camunda:out source="WorkflowException" target="WorkflowExecption" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1x9eh33</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_05wu9i7</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_09wkav2" name="RollbackSDNC?" default="SequenceFlow_1uw2p9a">
+ <bpmn2:incoming>SequenceFlow_06aasqh</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_11fnnkb</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1uw2p9a</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_11fnnkb" name="yes" sourceRef="ExclusiveGateway_09wkav2" targetRef="CallActivity_0ak0ezb">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("rollbackSDNC" ) == "true"}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_1uw2p9a" name="no" sourceRef="ExclusiveGateway_09wkav2" targetRef="ExclusiveGateway_0ii31dq" />
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0ii31dq" name="RollBackAAI?" default="SequenceFlow_1n7wade">
+ <bpmn2:documentation>rollback AAI</bpmn2:documentation>
+ <bpmn2:incoming>SequenceFlow_1uw2p9a</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1njogr1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1n7wade</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1x9eh33</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_1n7wade" name="no" sourceRef="ExclusiveGateway_0ii31dq" targetRef="PostProcess_ScriptTask" />
+ <bpmn2:sequenceFlow id="SequenceFlow_05wu9i7" sourceRef="callGenericDeleteService" targetRef="PostProcess_ScriptTask" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1x9eh33" name="yes" sourceRef="ExclusiveGateway_0ii31dq" targetRef="callGenericDeleteService">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("rollbackAAI" ) == "true"}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0k28xib" sourceRef="CallActivity_0ak0ezb" targetRef="ScriptTask_1uxr0cx" />
+ <bpmn2:callActivity id="CallActivity_0ak0ezb" name="Call SDNC Service Topology Deactivate" calledElement="sdncAdapter">
+ <bpmn2:extensionElements>
+ <camunda:in source="sdncDeactivate" target="sdncAdapterWorkflowRequest" />
+ <camunda:in source="msoRequestId" target="mso-request-id" />
+ <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="sdncAdapterResponse" target="sdncDeactivateResponse" />
+ <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_11fnnkb</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0k28xib</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_1uxr0cx" name="Post Process SDNC Deactivate" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0k28xib</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0khjo7l</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def rbk= new DoCreateServiceInstanceRollback()\r
-rbk.validateSDNCResponse(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0khjo7l" sourceRef="ScriptTask_1uxr0cx" targetRef="ExclusiveGateway_0ii31dq" />\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_19tbjgn" name="skip Rollback" default="SequenceFlow_06aasqh">\r
- <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_06aasqh</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1rzlaoy</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:scriptTask id="PostProcess_ScriptTask" name="Post Process Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_05wu9i7</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1n7wade</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_1rzlaoy</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_01l4ssl</bpmn2:outgoing>\r
+String response = execution.getVariable("sdncDeactivateResponse")
+def rbk= new DoCreateServiceInstanceRollback()
+rbk.validateSDNCResponse(execution, response, "deactivate")]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_0khjo7l" sourceRef="ScriptTask_1uxr0cx" targetRef="CallActivity_0ppz9nd" />
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_19tbjgn" name="skip Rollback" default="SequenceFlow_06aasqh">
+ <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_06aasqh</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1rzlaoy</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:scriptTask id="PostProcess_ScriptTask" name="Post Process Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_05wu9i7</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1n7wade</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1rzlaoy</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_01l4ssl</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def rbk = new DoCreateServiceInstanceRollback()\r
-rbk.postProcessRequest(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_01l4ssl" sourceRef="PostProcess_ScriptTask" targetRef="EndEvent_3" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_06aasqh" name="no" sourceRef="ExclusiveGateway_19tbjgn" targetRef="ExclusiveGateway_09wkav2" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1rzlaoy" name="yes" sourceRef="ExclusiveGateway_19tbjgn" targetRef="PostProcess_ScriptTask">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("skipRollback" ) == true}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:subProcess id="SubProcess_11bi8mc" name="Java Exception Handling Sub Process" triggeredByEvent="true">\r
- <bpmn2:startEvent id="StartEvent_1gxe17c">\r
- <bpmn2:outgoing>SequenceFlow_1ch4xrf</bpmn2:outgoing>\r
- <bpmn2:errorEventDefinition errorRef="Error_1" />\r
- </bpmn2:startEvent>\r
- <bpmn2:scriptTask id="ScriptTask_15yddb0" name="Process Java Error" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1ch4xrf</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1pjk2ff</bpmn2:outgoing>\r
+def rbk = new DoCreateServiceInstanceRollback()
+rbk.postProcessRequest(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_01l4ssl" sourceRef="PostProcess_ScriptTask" targetRef="EndEvent_3" />
+ <bpmn2:sequenceFlow id="SequenceFlow_06aasqh" name="no" sourceRef="ExclusiveGateway_19tbjgn" targetRef="ExclusiveGateway_09wkav2" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1rzlaoy" name="yes" sourceRef="ExclusiveGateway_19tbjgn" targetRef="PostProcess_ScriptTask">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("skipRollback" ) == true}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:subProcess id="SubProcess_11bi8mc" name="Java Exception Handling Sub Process" triggeredByEvent="true">
+ <bpmn2:startEvent id="StartEvent_1gxe17c">
+ <bpmn2:outgoing>SequenceFlow_1ch4xrf</bpmn2:outgoing>
+ <bpmn2:errorEventDefinition errorRef="Error_1" />
+ </bpmn2:startEvent>
+ <bpmn2:scriptTask id="ScriptTask_15yddb0" name="Process Java Error" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1ch4xrf</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1pjk2ff</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def rbk= new DoCreateServiceInstanceRollback()\r
-rbk.processRollbackJavaException(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:endEvent id="EndEvent_12e3h6k">\r
- <bpmn2:incoming>SequenceFlow_1pjk2ff</bpmn2:incoming>\r
- <bpmn2:terminateEventDefinition />\r
- </bpmn2:endEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1ch4xrf" name="" sourceRef="StartEvent_1gxe17c" targetRef="ScriptTask_15yddb0" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1pjk2ff" name="" sourceRef="ScriptTask_15yddb0" targetRef="EndEvent_12e3h6k" />\r
- </bpmn2:subProcess>\r
- </bpmn2:process>\r
- <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />\r
- <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />\r
- <bpmndi:BPMNDiagram id="BPMNDiagram_1">\r
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoCreateServiceInstanceRollback">\r
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createSIRollback_startEvent">\r
- <dc:Bounds x="151" y="79" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="146" y="120" width="48" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">\r
- <dc:Bounds x="234" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">\r
- <di:waypoint xsi:type="dc:Point" x="187" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="234" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="211" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="EndEvent_3">\r
- <dc:Bounds x="1166" y="358" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1184" y="399" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_SubProcess_27" bpmnElement="UnexpectedError_SubProcess_1" isExpanded="true">\r
- <dc:Bounds x="286" y="318" width="467" height="193" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_70" bpmnElement="StartEvent_1">\r
- <dc:Bounds x="354" y="384" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="372" y="425" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_219" bpmnElement="EndEvent_1">\r
- <dc:Bounds x="647" y="384" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="665" y="425" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_StartEvent_70" targetElement="_BPMNShape_ScriptTask_269">\r
- <di:waypoint xsi:type="dc:Point" x="390" y="402" />\r
- <di:waypoint xsi:type="dc:Point" x="458" y="402" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="425" y="387" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_ScriptTask_61">\r
- <di:waypoint xsi:type="dc:Point" x="334" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="367" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="367" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="393" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="382" y="97" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="CallActivity_1md4kyb_di" bpmnElement="callGenericDeleteService">\r
- <dc:Bounds x="1134" y="53" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_09wkav2_di" bpmnElement="ExclusiveGateway_09wkav2" isMarkerVisible="true">\r
- <dc:Bounds x="527" y="72" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="512" y="129" width="80" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_11fnnkb_di" bpmnElement="SequenceFlow_11fnnkb">\r
- <di:waypoint xsi:type="dc:Point" x="577" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="640" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="601" y="101.351489674803" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1uw2p9a_di" bpmnElement="SequenceFlow_1uw2p9a">\r
- <di:waypoint xsi:type="dc:Point" x="552" y="72" />\r
- <di:waypoint xsi:type="dc:Point" x="552" y="-23" />\r
- <di:waypoint xsi:type="dc:Point" x="1021" y="-23" />\r
- <di:waypoint xsi:type="dc:Point" x="1021" y="72" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="635" y="-43" width="12" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_0ii31dq_di" bpmnElement="ExclusiveGateway_0ii31dq" isMarkerVisible="true">\r
- <dc:Bounds x="996" y="72" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="939" y="113" width="66" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1n7wade_di" bpmnElement="SequenceFlow_1n7wade">\r
- <di:waypoint xsi:type="dc:Point" x="1021" y="122" />\r
- <di:waypoint xsi:type="dc:Point" x="1021" y="246" />\r
- <di:waypoint xsi:type="dc:Point" x="1134" y="246" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1030" y="124.63737966405313" width="13" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_05wu9i7_di" bpmnElement="SequenceFlow_05wu9i7">\r
- <di:waypoint xsi:type="dc:Point" x="1184" y="133" />\r
- <di:waypoint xsi:type="dc:Point" x="1184" y="206" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1199" y="169.5" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1x9eh33_di" bpmnElement="SequenceFlow_1x9eh33">\r
- <di:waypoint xsi:type="dc:Point" x="1046" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="1134" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1082" y="82" width="18" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0k28xib_di" bpmnElement="SequenceFlow_0k28xib">\r
- <di:waypoint xsi:type="dc:Point" x="743" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="820" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="782" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="CallActivity_0ak0ezb_di" bpmnElement="CallActivity_0ak0ezb">\r
- <dc:Bounds x="640" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_1uxr0cx_di" bpmnElement="ScriptTask_1uxr0cx">\r
- <dc:Bounds x="823" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0khjo7l_di" bpmnElement="SequenceFlow_0khjo7l">\r
- <di:waypoint xsi:type="dc:Point" x="923" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="996" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="960" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_19tbjgn_di" bpmnElement="ExclusiveGateway_19tbjgn" isMarkerVisible="true">\r
- <dc:Bounds x="393" y="72" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="385" y="38" width="65" height="12" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_269" bpmnElement="ScriptTask_1">\r
- <dc:Bounds x="458" y="362" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_269" targetElement="_BPMNShape_EndEvent_219">\r
- <di:waypoint xsi:type="dc:Point" x="558" y="402" />\r
- <di:waypoint xsi:type="dc:Point" x="647" y="402" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="603" y="387" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_1wk55es_di" bpmnElement="PostProcess_ScriptTask">\r
- <dc:Bounds x="1134" y="206" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_01l4ssl_di" bpmnElement="SequenceFlow_01l4ssl">\r
- <di:waypoint xsi:type="dc:Point" x="1184" y="286" />\r
- <di:waypoint xsi:type="dc:Point" x="1184" y="358" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1199" y="322" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_06aasqh_di" bpmnElement="SequenceFlow_06aasqh">\r
- <di:waypoint xsi:type="dc:Point" x="443" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="527" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="479" y="82" width="12" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1rzlaoy_di" bpmnElement="SequenceFlow_1rzlaoy">\r
- <di:waypoint xsi:type="dc:Point" x="418" y="122" />\r
- <di:waypoint xsi:type="dc:Point" x="418" y="268" />\r
- <di:waypoint xsi:type="dc:Point" x="1131" y="272" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="424" y="195" width="18" height="14" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="SubProcess_11bi8mc_di" bpmnElement="SubProcess_11bi8mc" isExpanded="true">\r
- <dc:Bounds x="325" y="576" width="419" height="150" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="StartEvent_1gxe17c_di" bpmnElement="StartEvent_1gxe17c">\r
- <dc:Bounds x="360" y="628" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="378" y="669" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_15yddb0_di" bpmnElement="ScriptTask_15yddb0">\r
- <dc:Bounds x="468" y="606" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="EndEvent_12e3h6k_di" bpmnElement="EndEvent_12e3h6k">\r
- <dc:Bounds x="618" y="628" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="636" y="669" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1ch4xrf_di" bpmnElement="SequenceFlow_1ch4xrf">\r
- <di:waypoint xsi:type="dc:Point" x="396" y="646" />\r
- <di:waypoint xsi:type="dc:Point" x="468" y="646" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="421" y="646" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1pjk2ff_di" bpmnElement="SequenceFlow_1pjk2ff">\r
- <di:waypoint xsi:type="dc:Point" x="568" y="646" />\r
- <di:waypoint xsi:type="dc:Point" x="618" y="646" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="593" y="646" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- </bpmndi:BPMNPlane>\r
- </bpmndi:BPMNDiagram>\r
-</bpmn2:definitions>\r
+def rbk= new DoCreateServiceInstanceRollback()
+rbk.processRollbackJavaException(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:endEvent id="EndEvent_12e3h6k">
+ <bpmn2:incoming>SequenceFlow_1pjk2ff</bpmn2:incoming>
+ <bpmn2:terminateEventDefinition />
+ </bpmn2:endEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_1ch4xrf" name="" sourceRef="StartEvent_1gxe17c" targetRef="ScriptTask_15yddb0" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1pjk2ff" name="" sourceRef="ScriptTask_15yddb0" targetRef="EndEvent_12e3h6k" />
+ </bpmn2:subProcess>
+ <bpmn2:scriptTask id="ScriptTask_1awt1ds" name="Post Process SDNC Delete">
+ <bpmn2:incoming>SequenceFlow_006g9e8</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1njogr1</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+String response = execution.getVariable("sdncDeleteResponse")
+def rbk= new DoCreateServiceInstanceRollback()
+rbk.validateSDNCResponse(execution, response, "delete")]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:callActivity id="CallActivity_0ppz9nd" name="Call SDNC Service Topology Dekete" calledElement="sdncAdapter">
+ <bpmn2:extensionElements>
+ <camunda:in source="sdncDelete" target="sdncAdapterWorkflowRequest" />
+ <camunda:in source="msoRequestId" target="mso-request-id" />
+ <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="sdncAdapterResponse" target="sdncDeleteResponse" />
+ <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0khjo7l</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_006g9e8</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_006g9e8" sourceRef="CallActivity_0ppz9nd" targetRef="ScriptTask_1awt1ds" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1njogr1" sourceRef="ScriptTask_1awt1ds" targetRef="ExclusiveGateway_0ii31dq" />
+ </bpmn2:process>
+ <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
+ <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
+ <bpmndi:BPMNDiagram id="BPMNDiagram_1">
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoCreateServiceInstanceRollback">
+ <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createSIRollback_startEvent">
+ <dc:Bounds x="151" y="79" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="146" y="120" width="48" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">
+ <dc:Bounds x="234" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">
+ <di:waypoint xsi:type="dc:Point" x="187" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="234" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="211" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="EndEvent_3">
+ <dc:Bounds x="1208" y="350" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1226" y="391" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_SubProcess_27" bpmnElement="UnexpectedError_SubProcess_1" isExpanded="true">
+ <dc:Bounds x="508" y="323" width="467" height="193" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_StartEvent_70" bpmnElement="StartEvent_1">
+ <dc:Bounds x="576" y="389" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="594" y="430" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_EndEvent_219" bpmnElement="EndEvent_1">
+ <dc:Bounds x="869" y="389" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="887" y="430" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_StartEvent_70" targetElement="_BPMNShape_ScriptTask_269">
+ <di:waypoint xsi:type="dc:Point" x="612" y="407" />
+ <di:waypoint xsi:type="dc:Point" x="680" y="407" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="647" y="392" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_ScriptTask_61">
+ <di:waypoint xsi:type="dc:Point" x="334" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="366" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="350" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_1md4kyb_di" bpmnElement="callGenericDeleteService">
+ <dc:Bounds x="1167" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_09wkav2_di" bpmnElement="ExclusiveGateway_09wkav2" isMarkerVisible="true">
+ <dc:Bounds x="448" y="72" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="433" y="129" width="79" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_11fnnkb_di" bpmnElement="SequenceFlow_11fnnkb">
+ <di:waypoint xsi:type="dc:Point" x="498" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="539" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="501" y="100" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1uw2p9a_di" bpmnElement="SequenceFlow_1uw2p9a">
+ <di:waypoint xsi:type="dc:Point" x="473" y="72" />
+ <di:waypoint xsi:type="dc:Point" x="473" y="-23" />
+ <di:waypoint xsi:type="dc:Point" x="1071" y="-23" />
+ <di:waypoint xsi:type="dc:Point" x="1071" y="72" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="751" y="-41" width="12" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0ii31dq_di" bpmnElement="ExclusiveGateway_0ii31dq" isMarkerVisible="true">
+ <dc:Bounds x="1046" y="72" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1094" y="104" width="66" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1n7wade_di" bpmnElement="SequenceFlow_1n7wade">
+ <di:waypoint xsi:type="dc:Point" x="1071" y="122" />
+ <di:waypoint xsi:type="dc:Point" x="1071" y="241" />
+ <di:waypoint xsi:type="dc:Point" x="1176" y="241" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1081" y="124.63709677419354" width="12" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_05wu9i7_di" bpmnElement="SequenceFlow_05wu9i7">
+ <di:waypoint xsi:type="dc:Point" x="1217" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="1217" y="201" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1232" y="169" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1x9eh33_di" bpmnElement="SequenceFlow_1x9eh33">
+ <di:waypoint xsi:type="dc:Point" x="1096" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="1167" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1126" y="82" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0k28xib_di" bpmnElement="SequenceFlow_0k28xib">
+ <di:waypoint xsi:type="dc:Point" x="639" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="671" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="655" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0ak0ezb_di" bpmnElement="CallActivity_0ak0ezb">
+ <dc:Bounds x="539" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1uxr0cx_di" bpmnElement="ScriptTask_1uxr0cx">
+ <dc:Bounds x="671" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0khjo7l_di" bpmnElement="SequenceFlow_0khjo7l">
+ <di:waypoint xsi:type="dc:Point" x="771" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="796" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="784" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_19tbjgn_di" bpmnElement="ExclusiveGateway_19tbjgn" isMarkerVisible="true">
+ <dc:Bounds x="366" y="72" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="358" y="54" width="65" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_269" bpmnElement="ScriptTask_1">
+ <dc:Bounds x="680" y="367" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_269" targetElement="_BPMNShape_EndEvent_219">
+ <di:waypoint xsi:type="dc:Point" x="780" y="407" />
+ <di:waypoint xsi:type="dc:Point" x="869" y="407" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="825" y="392" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1wk55es_di" bpmnElement="PostProcess_ScriptTask">
+ <dc:Bounds x="1176" y="201" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_01l4ssl_di" bpmnElement="SequenceFlow_01l4ssl">
+ <di:waypoint xsi:type="dc:Point" x="1226" y="281" />
+ <di:waypoint xsi:type="dc:Point" x="1226" y="350" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1241" y="315.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_06aasqh_di" bpmnElement="SequenceFlow_06aasqh">
+ <di:waypoint xsi:type="dc:Point" x="416" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="448" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="426" y="82" width="12" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1rzlaoy_di" bpmnElement="SequenceFlow_1rzlaoy">
+ <di:waypoint xsi:type="dc:Point" x="391" y="122" />
+ <di:waypoint xsi:type="dc:Point" x="391" y="268" />
+ <di:waypoint xsi:type="dc:Point" x="1176" y="267" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="397" y="195" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="SubProcess_11bi8mc_di" bpmnElement="SubProcess_11bi8mc" isExpanded="true">
+ <dc:Bounds x="325" y="576" width="419" height="150" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="StartEvent_1gxe17c_di" bpmnElement="StartEvent_1gxe17c">
+ <dc:Bounds x="360" y="628" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="378" y="669" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_15yddb0_di" bpmnElement="ScriptTask_15yddb0">
+ <dc:Bounds x="468" y="606" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="EndEvent_12e3h6k_di" bpmnElement="EndEvent_12e3h6k">
+ <dc:Bounds x="618" y="628" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="636" y="669" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1ch4xrf_di" bpmnElement="SequenceFlow_1ch4xrf">
+ <di:waypoint xsi:type="dc:Point" x="396" y="646" />
+ <di:waypoint xsi:type="dc:Point" x="468" y="646" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="421" y="646" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1pjk2ff_di" bpmnElement="SequenceFlow_1pjk2ff">
+ <di:waypoint xsi:type="dc:Point" x="568" y="646" />
+ <di:waypoint xsi:type="dc:Point" x="618" y="646" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="593" y="646" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1awt1ds_di" bpmnElement="ScriptTask_1awt1ds">
+ <dc:Bounds x="921" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0ppz9nd_di" bpmnElement="CallActivity_0ppz9nd">
+ <dc:Bounds x="796" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_006g9e8_di" bpmnElement="SequenceFlow_006g9e8">
+ <di:waypoint xsi:type="dc:Point" x="896" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="921" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="909" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1njogr1_di" bpmnElement="SequenceFlow_1njogr1">
+ <di:waypoint xsi:type="dc:Point" x="1021" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="1046" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1034" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ </bpmndi:BPMNPlane>
+ </bpmndi:BPMNDiagram>
+</bpmn2:definitions>
<bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-DoCreateVnf createVnf = new DoCreateVnf()\r
+DoCreateVnf createVnf = new DoCreateVnf()
createVnf.preProcessRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="initialization" targetRef="callGetService" />
<bpmn2:outgoing>found</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
<bpmn2:sequenceFlow id="notFound" name="No" sourceRef="serviceInstanceFound" targetRef="buildWorkflowException" />
- <bpmn2:sequenceFlow id="found" name="Yes" sourceRef="serviceInstanceFound" targetRef="callGetVnf">
+ <bpmn2:sequenceFlow id="found" name="Yes" sourceRef="serviceInstanceFound" targetRef="ExclusiveGateway_0j73e7c">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("GENGS_FoundIndicator" ) == true && execution.getVariable("GENGS_SuccessIndicator" ) == true}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
<bpmn2:exclusiveGateway id="vnfExist" name="Vnf Already Exist?" default="vnfExistYes">
<camunda:out source="WorkflowException" target="WorkflowException" />
<camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
</bpmn2:extensionElements>
- <bpmn2:incoming>found</bpmn2:incoming>
+ <bpmn2:incoming>VnfNameSpecified1</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
</bpmn2:callActivity>
<bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="callGetVnf" targetRef="vnfExist" />
</bpmn2:endEvent>
<bpmn2:scriptTask id="prepareCreateGenericVnf" name="Prepare Create Vnf Payload" scriptFormat="groovy">
<bpmn2:incoming>vnfExistNo</bpmn2:incoming>
+ <bpmn2:incoming>VnfNameNotSpecified1</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_11</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-DoCreateVnf createVnf = new DoCreateVnf()\r
+DoCreateVnf createVnf = new DoCreateVnf()
createVnf.prepareCreateGenericVnf(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_11" name="" sourceRef="prepareCreateGenericVnf" targetRef="callPutVnf" />
<bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="StartEvent_2" targetRef="processJavaError" />
</bpmn2:subProcess>
<bpmn2:endEvent id="EndEvent_3">
- <bpmn2:incoming>SequenceFlow_15z3gpq</bpmn2:incoming>
- <bpmn2:incoming>SequenceFlow_0ay5l4b</bpmn2:incoming>
+ <bpmn2:incoming>SdncInteractionNotEnabled</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0bj7c4s</bpmn2:incoming>
<bpmn2:terminateEventDefinition id="_TerminateEventDefinition_35" />
</bpmn2:endEvent>
<bpmn2:sequenceFlow id="SequenceFlow_1q6udwm" sourceRef="preProcessSDNCAssignRequest" targetRef="callSDNCAdapterVNFTopologyAssign" />
<bpmn2:sequenceFlow id="SequenceFlow_15knw0q" sourceRef="callSDNCAdapterVNFTopologyAssign" targetRef="postProcessSDNCAssignRequest" />
- <bpmn2:sequenceFlow id="SequenceFlow_0c5h00o" sourceRef="postProcessSDNCAssignRequest" targetRef="preProcessSDNCActivateRequest" />
<bpmn2:sequenceFlow id="SequenceFlow_1lalmvp" sourceRef="preProcessSDNCActivateRequest" targetRef="callSDNCAdapterVNFTopologyActivate" />
<bpmn2:sequenceFlow id="SequenceFlow_0eb41vb" sourceRef="callSDNCAdapterVNFTopologyActivate" targetRef="postProcessSDNCActivateRequest" />
- <bpmn2:sequenceFlow id="SequenceFlow_15z3gpq" sourceRef="postProcessSDNCActivateRequest" targetRef="EndEvent_3" />
+ <bpmn2:sequenceFlow id="SequenceFlow_15z3gpq" sourceRef="postProcessSDNCActivateRequest" targetRef="Task_053tb0h" />
<bpmn2:scriptTask id="preProcessSDNCAssignRequest" name="PreProcess SDNC Assign Request" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_0ttqcwx</bpmn2:incoming>
+ <bpmn2:incoming>SdncInteractionEnabled</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1q6udwm</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-DoCreateVnf createVnf = new DoCreateVnf()\r
+DoCreateVnf createVnf = new DoCreateVnf()
createVnf.preProcessSDNCAssignRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:callActivity id="callSDNCAdapterVNFTopologyAssign" name="Call SDNC Adapter VNF Topology Assign" calledElement="sdncAdapter">
</bpmn2:callActivity>
<bpmn2:scriptTask id="postProcessSDNCAssignRequest" name="PostProcess SDNC Assign Request" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_15knw0q</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_0c5h00o</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-\r
-String response = execution.getVariable("DoCVNF_assignSDNCAdapterResponse")\r
-\r
-def createVnfInfra = new DoCreateVnf()\r
+ <bpmn2:outgoing>SequenceFlow_0lnh79j</bpmn2:outgoing>
+
+String response = execution.getVariable("DoCVNF_assignSDNCAdapterResponse")
+
+def createVnfInfra = new DoCreateVnf()
createVnfInfra.validateSDNCResponse(execution, response, "assign")]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:scriptTask id="preProcessSDNCActivateRequest" name="PreProcess SDNC Activate Request" scriptFormat="groovy">
- <bpmn2:incoming>SequenceFlow_0c5h00o</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1q1poly</bpmn2:incoming>
+ <bpmn2:incoming>VnfNameSpecified2</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1lalmvp</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-DoCreateVnf createVnf = new DoCreateVnf()\r
+DoCreateVnf createVnf = new DoCreateVnf()
createVnf.preProcessSDNCActivateRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:callActivity id="callSDNCAdapterVNFTopologyActivate" name="Call SDNC Adapter VNF Topology Activate" calledElement="sdncAdapter">
<bpmn2:incoming>SequenceFlow_0eb41vb</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_15z3gpq</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-\r
-String response = execution.getVariable("DoCVNF_assignSDNCAdapterResponse")\r
-\r
-def createVnfInfra = new DoCreateVnf()\r
+
+String response = execution.getVariable("DoCVNF_assignSDNCAdapterResponse")
+
+def createVnfInfra = new DoCreateVnf()
createVnfInfra.validateSDNCResponse(execution, response, "activate")]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:exclusiveGateway id="ExclusiveGateway_045rm8i" name="Is SDNC Interaction Enabled?" default="SequenceFlow_0ay5l4b">
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_045rm8i" name="Is SDNC Interaction Enabled?" default="SdncInteractionNotEnabled">
<bpmn2:incoming>SequenceFlow_1gc18ih</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_0ttqcwx</bpmn2:outgoing>
- <bpmn2:outgoing>SequenceFlow_0ay5l4b</bpmn2:outgoing>
+ <bpmn2:outgoing>SdncInteractionEnabled</bpmn2:outgoing>
+ <bpmn2:outgoing>SdncInteractionNotEnabled</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
- <bpmn2:sequenceFlow id="SequenceFlow_0ttqcwx" name="yes" sourceRef="ExclusiveGateway_045rm8i" targetRef="preProcessSDNCAssignRequest">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("sdncVersion" ) == '1707'}]]></bpmn2:conditionExpression>
+ <bpmn2:sequenceFlow id="SdncInteractionEnabled" name="Yes" sourceRef="ExclusiveGateway_045rm8i" targetRef="preProcessSDNCAssignRequest">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DoCVNF_sdncVersion" ) != '1702'}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
- <bpmn2:sequenceFlow id="SequenceFlow_0ay5l4b" name="no" sourceRef="ExclusiveGateway_045rm8i" targetRef="EndEvent_3" />
+ <bpmn2:sequenceFlow id="SdncInteractionNotEnabled" name="No" sourceRef="ExclusiveGateway_045rm8i" targetRef="EndEvent_3" />
<bpmn2:sequenceFlow id="SequenceFlow_0seif8n" sourceRef="callPutVnf" targetRef="postProcessCreateGenericVnf" />
<bpmn2:sequenceFlow id="SequenceFlow_1gc18ih" sourceRef="postProcessCreateGenericVnf" targetRef="ExclusiveGateway_045rm8i" />
<bpmn2:scriptTask id="postProcessCreateGenericVnf" name="PostProcess Create Generic Vnf" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_0seif8n</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1gc18ih</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-DoCreateVnf createVnf = new DoCreateVnf()\r
+DoCreateVnf createVnf = new DoCreateVnf()
createVnf.postProcessCreateGenericVnf(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0j73e7c" name="Vnf-name specified?" default="VnfNameSpecified1">
+ <bpmn2:incoming>found</bpmn2:incoming>
+ <bpmn2:outgoing>VnfNameNotSpecified1</bpmn2:outgoing>
+ <bpmn2:outgoing>VnfNameSpecified1</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="VnfNameNotSpecified1" name="No" sourceRef="ExclusiveGateway_0j73e7c" targetRef="prepareCreateGenericVnf">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DoCVNF_vnfName" ) == null}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="VnfNameSpecified1" name="Yes" sourceRef="ExclusiveGateway_0j73e7c" targetRef="callGetVnf" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1h9jdgr" sourceRef="PreProcessSDNCGetRequest" targetRef="CallSDNCAdapterVNFTopologyGet" />
+ <bpmn2:sequenceFlow id="SequenceFlow_14xac2y" sourceRef="CallSDNCAdapterVNFTopologyGet" targetRef="PostProcessSDNCGetRequest" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1q1poly" sourceRef="PostProcessSDNCGetRequest" targetRef="preProcessSDNCActivateRequest" />
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0qnhlm1" name="Vnf-name specified?" default="VnfNameSpecified2">
+ <bpmn2:incoming>SequenceFlow_0lnh79j</bpmn2:incoming>
+ <bpmn2:outgoing>VnfNameNotSpecified2</bpmn2:outgoing>
+ <bpmn2:outgoing>VnfNameSpecified2</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_0lnh79j" sourceRef="postProcessSDNCAssignRequest" targetRef="ExclusiveGateway_0qnhlm1" />
+ <bpmn2:sequenceFlow id="VnfNameNotSpecified2" name="No" sourceRef="ExclusiveGateway_0qnhlm1" targetRef="PreProcessSDNCGetRequest">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DoCVNF_vnfName" ) == null}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="VnfNameSpecified2" name="Yes" sourceRef="ExclusiveGateway_0qnhlm1" targetRef="preProcessSDNCActivateRequest" />
+ <bpmn2:scriptTask id="PreProcessSDNCGetRequest" name="PreProcess SDNC Get Request" scriptFormat="groovy">
+ <bpmn2:incoming>VnfNameNotSpecified2</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1h9jdgr</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+DoCreateVnf createVnf = new DoCreateVnf()
+createVnf.preProcessSDNCGetRequest(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:callActivity id="CallSDNCAdapterVNFTopologyGet" name="Call SDNC Adapter VNF Topology Get" calledElement="sdncAdapter">
+ <bpmn2:extensionElements>
+ <camunda:in source="DoCVNF_getSDNCRequest" target="sdncAdapterWorkflowRequest" />
+ <camunda:in source="mso-request-id" target="mso-request-id" />
+ <camunda:in source="mso-service-instance-id" target="mso-service-instance-id" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="sdncAdapterResponse" target="DoCVNF_getSDNCAdapterResponse" />
+ <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1h9jdgr</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_14xac2y</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="PostProcessSDNCGetRequest" name="PostProcess SDNC Get Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_14xac2y</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1q1poly</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+
+String response = execution.getVariable("DoCVNF_getSDNCAdapterResponse")
+
+def createVnfInfra = new DoCreateVnf()
+createVnfInfra.validateSDNCResponse(execution, response, "get")]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_0bj7c4s" sourceRef="UpdateAAIOrchestrationStatus" targetRef="EndEvent_3" />
+ <bpmn2:callActivity id="UpdateAAIOrchestrationStatus" name="Update AAI Orchestration Status to Active" calledElement="UpdateAAIGenericVnf">
+ <bpmn2:extensionElements>
+ <camunda:in source="DoCVNF_updateAAIGenericVnfRequest" target="UpdateAAIGenericVnfRequest" />
+ <camunda:in source="mso-request-id" target="mso-request-id" />
+ <camunda:in source="mso-service-id" target="mso-service-id" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0nhsdmj</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0bj7c4s</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_0nhsdmj" sourceRef="Task_053tb0h" targetRef="UpdateAAIOrchestrationStatus" />
+ <bpmn2:scriptTask id="Task_053tb0h" name="Prepare Update AAI Generic VNF" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_15z3gpq</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0nhsdmj</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+def doCreateVnf = new DoCreateVnf()
+doCreateVnf.prepUpdateAAIGenericVnf(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
</bpmn2:process>
<bpmn2:error id="Error_1" name="Java Lang Exception" errorCode="java.lang.Exception" />
<bpmn2:error id="Error_2" name="MSO Workflow Exception" errorCode="MSOWorkflowException" />
<dc:Bounds x="406" y="200" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_229" bpmnElement="serviceInstanceFound" isMarkerVisible="true">
- <dc:Bounds x="642" y="214" width="50" height="50" />
+ <dc:Bounds x="552" y="215" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="678" y="244" width="148" height="22" />
+ <dc:Bounds x="536" y="267" width="82" height="24" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_4" sourceElement="_BPMNShape_CallActivity_59" targetElement="_BPMNShape_ExclusiveGateway_229">
<di:waypoint xsi:type="dc:Point" x="506" y="240" />
- <di:waypoint xsi:type="dc:Point" x="642" y="239" />
+ <di:waypoint xsi:type="dc:Point" x="552" y="240" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="574" y="224.5" width="0" height="0" />
+ <dc:Bounds x="529" y="225" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_293" bpmnElement="buildWorkflowException">
<dc:Bounds x="720" y="115" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="notFound" sourceElement="_BPMNShape_ExclusiveGateway_229" targetElement="_BPMNShape_ScriptTask_293">
- <di:waypoint xsi:type="dc:Point" x="667" y="214" />
- <di:waypoint xsi:type="dc:Point" x="667" y="155" />
+ <di:waypoint xsi:type="dc:Point" x="577" y="215" />
+ <di:waypoint xsi:type="dc:Point" x="577" y="155" />
<di:waypoint xsi:type="dc:Point" x="720" y="155" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="666" y="174" width="22" height="22" />
+ <dc:Bounds x="580" y="174.4237288135593" width="14" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_225" bpmnElement="EndEvent_1">
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_7" bpmnElement="found" sourceElement="_BPMNShape_ExclusiveGateway_229" targetElement="_BPMNShape_CallActivity_60">
- <di:waypoint xsi:type="dc:Point" x="667" y="264" />
- <di:waypoint xsi:type="dc:Point" x="667" y="328" />
- <di:waypoint xsi:type="dc:Point" x="720" y="328" />
+ <di:waypoint xsi:type="dc:Point" x="602" y="240" />
+ <di:waypoint xsi:type="dc:Point" x="646" y="240" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="666" y="282" width="29" height="22" />
+ <dc:Bounds x="614" y="216.01288698145387" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_CallActivity_60" bpmnElement="callGetVnf">
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_228" bpmnElement="EndEvent_3">
- <dc:Bounds x="1126" y="537" width="36" height="36" />
+ <dc:Bounds x="1765" y="537" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1144" y="578" width="0" height="0" />
+ <dc:Bounds x="1783" y="578" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_13" bpmnElement="SequenceFlow_11" sourceElement="_BPMNShape_ScriptTask_300" targetElement="_BPMNShape_CallActivity_61">
<dc:Bounds x="470" y="540" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0c5h00o_di" bpmnElement="SequenceFlow_0c5h00o">
- <di:waypoint xsi:type="dc:Point" x="593" y="555" />
- <di:waypoint xsi:type="dc:Point" x="640" y="555" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="617" y="540" width="0" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1lalmvp_di" bpmnElement="SequenceFlow_1lalmvp">
- <di:waypoint xsi:type="dc:Point" x="740" y="555" />
- <di:waypoint xsi:type="dc:Point" x="794" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1100" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1156" y="555" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="767" y="540" width="0" height="0" />
+ <dc:Bounds x="1128" y="540" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0eb41vb_di" bpmnElement="SequenceFlow_0eb41vb">
- <di:waypoint xsi:type="dc:Point" x="894" y="555" />
- <di:waypoint xsi:type="dc:Point" x="949" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1256" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1304" y="555" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="922" y="540" width="0" height="0" />
+ <dc:Bounds x="1280" y="540" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_15z3gpq_di" bpmnElement="SequenceFlow_15z3gpq">
- <di:waypoint xsi:type="dc:Point" x="1049" y="555" />
- <di:waypoint xsi:type="dc:Point" x="1126" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1404" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1445" y="555" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1088" y="540" width="0" height="0" />
+ <dc:Bounds x="1425" y="540" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_01h1rx2_di" bpmnElement="preProcessSDNCAssignRequest">
<dc:Bounds x="493" y="515" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ScriptTask_1rr2xrc_di" bpmnElement="preProcessSDNCActivateRequest">
- <dc:Bounds x="640" y="515" width="100" height="80" />
+ <dc:Bounds x="1000" y="515" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="CallActivity_1ieo30p_di" bpmnElement="callSDNCAdapterVNFTopologyActivate">
- <dc:Bounds x="794" y="515" width="100" height="80" />
+ <dc:Bounds x="1156" y="515" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ScriptTask_04votlb_di" bpmnElement="postProcessSDNCActivateRequest">
- <dc:Bounds x="949" y="515" width="100" height="80" />
+ <dc:Bounds x="1304" y="515" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ExclusiveGateway_045rm8i_di" bpmnElement="ExclusiveGateway_045rm8i" isMarkerVisible="true">
- <dc:Bounds x="1336" y="215" width="50" height="50" />
+ <dc:Bounds x="1758" y="215" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1334" y="163" width="54" height="36" />
+ <dc:Bounds x="1756" y="163" width="54" height="36" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_0ttqcwx_di" bpmnElement="SequenceFlow_0ttqcwx">
- <di:waypoint xsi:type="dc:Point" x="1361" y="265" />
- <di:waypoint xsi:type="dc:Point" x="1361" y="475" />
+ <bpmndi:BPMNEdge id="SequenceFlow_0ttqcwx_di" bpmnElement="SdncInteractionEnabled">
+ <di:waypoint xsi:type="dc:Point" x="1783" y="265" />
+ <di:waypoint xsi:type="dc:Point" x="1783" y="475" />
<di:waypoint xsi:type="dc:Point" x="106" y="475" />
<di:waypoint xsi:type="dc:Point" x="106" y="555" />
<di:waypoint xsi:type="dc:Point" x="206" y="555" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="726" y="460" width="18" height="12" />
+ <dc:Bounds x="941" y="460" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0ay5l4b_di" bpmnElement="SequenceFlow_0ay5l4b">
- <di:waypoint xsi:type="dc:Point" x="1361" y="265" />
- <di:waypoint xsi:type="dc:Point" x="1361" y="555" />
- <di:waypoint xsi:type="dc:Point" x="1162" y="555" />
+ <bpmndi:BPMNEdge id="SequenceFlow_0ay5l4b_di" bpmnElement="SdncInteractionNotEnabled">
+ <di:waypoint xsi:type="dc:Point" x="1783" y="265" />
+ <di:waypoint xsi:type="dc:Point" x="1783" y="401" />
+ <di:waypoint xsi:type="dc:Point" x="1783" y="401" />
+ <di:waypoint xsi:type="dc:Point" x="1783" y="537" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1400" y="398" width="12" height="12" />
+ <dc:Bounds x="1812" y="431.09791911764705" width="14" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0seif8n_di" bpmnElement="SequenceFlow_0seif8n">
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1gc18ih_di" bpmnElement="SequenceFlow_1gc18ih">
<di:waypoint xsi:type="dc:Point" x="1313" y="240" />
- <di:waypoint xsi:type="dc:Point" x="1336" y="240" />
+ <di:waypoint xsi:type="dc:Point" x="1758" y="240" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1325" y="225" width="0" height="0" />
+ <dc:Bounds x="1536" y="225" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_0y55cyz_di" bpmnElement="postProcessCreateGenericVnf">
<dc:Bounds x="1213" y="200" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0j73e7c_di" bpmnElement="ExclusiveGateway_0j73e7c" isMarkerVisible="true">
+ <dc:Bounds x="646" y="215" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="653" y="184" width="51" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0k2oavy_di" bpmnElement="VnfNameNotSpecified1">
+ <di:waypoint xsi:type="dc:Point" x="696" y="240" />
+ <di:waypoint xsi:type="dc:Point" x="935" y="240" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="809" y="215" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1pwgmrg_di" bpmnElement="VnfNameSpecified1">
+ <di:waypoint xsi:type="dc:Point" x="671" y="265" />
+ <di:waypoint xsi:type="dc:Point" x="671" y="328" />
+ <di:waypoint xsi:type="dc:Point" x="720" y="328" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="677" y="286.5" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1h9jdgr_di" bpmnElement="SequenceFlow_1h9jdgr">
+ <di:waypoint xsi:type="dc:Point" x="777" y="693" />
+ <di:waypoint xsi:type="dc:Point" x="799" y="693" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="788" y="678" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_14xac2y_di" bpmnElement="SequenceFlow_14xac2y">
+ <di:waypoint xsi:type="dc:Point" x="899" y="693" />
+ <di:waypoint xsi:type="dc:Point" x="926" y="693" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="913" y="678" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1q1poly_di" bpmnElement="SequenceFlow_1q1poly">
+ <di:waypoint xsi:type="dc:Point" x="1026" y="693" />
+ <di:waypoint xsi:type="dc:Point" x="1050" y="693" />
+ <di:waypoint xsi:type="dc:Point" x="1050" y="595" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1038" y="678" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0qnhlm1_di" bpmnElement="ExclusiveGateway_0qnhlm1" isMarkerVisible="true">
+ <dc:Bounds x="625" y="530" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="624" y="495" width="51" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0lnh79j_di" bpmnElement="SequenceFlow_0lnh79j">
+ <di:waypoint xsi:type="dc:Point" x="593" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="625" y="555" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="609" y="530" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1mh1y3w_di" bpmnElement="VnfNameNotSpecified2">
+ <di:waypoint xsi:type="dc:Point" x="650" y="580" />
+ <di:waypoint xsi:type="dc:Point" x="650" y="693" />
+ <di:waypoint xsi:type="dc:Point" x="677" y="693" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="626" y="622" width="14" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_175qbtt_di" bpmnElement="VnfNameSpecified2">
+ <di:waypoint xsi:type="dc:Point" x="675" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1000" y="555" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="829" y="530" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1cpb0sg_di" bpmnElement="PreProcessSDNCGetRequest">
+ <dc:Bounds x="677" y="653" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0h8tpji_di" bpmnElement="CallSDNCAdapterVNFTopologyGet">
+ <dc:Bounds x="799" y="653" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1orism0_di" bpmnElement="PostProcessSDNCGetRequest">
+ <dc:Bounds x="926" y="653" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0bj7c4s_di" bpmnElement="SequenceFlow_0bj7c4s">
+ <di:waypoint xsi:type="dc:Point" x="1700" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1765" y="555" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1733" y="540" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0a4a9lx_di" bpmnElement="UpdateAAIOrchestrationStatus">
+ <dc:Bounds x="1600" y="515" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0nhsdmj_di" bpmnElement="SequenceFlow_0nhsdmj">
+ <di:waypoint xsi:type="dc:Point" x="1545" y="555" />
+ <di:waypoint xsi:type="dc:Point" x="1600" y="555" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1573" y="540" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_0aonzix_di" bpmnElement="Task_053tb0h">
+ <dc:Bounds x="1445" y="515" width="100" height="80" />
+ </bpmndi:BPMNShape>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>
</bpmn:scriptTask>
<bpmn:callActivity id="CreateBaseVfModule" name="Create Base VF Module" calledElement="DoCreateVfModule">
<bpmn:extensionElements>
- <camunda:in source="requestId" target="requestId" />
+ <camunda:in source="msoRequestId" target="msoRequestId" />
<camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
<camunda:in source="disableRollback" target="disableRollback" />
<camunda:in source="vnfType" target="vnfType" />
<camunda:in source="vnfModelInfo" target="vnfModelInfo" />
<camunda:in source="globalSubscriberId" target="globalSubscriberId" />
<camunda:in source="sdncVersion" target="sdncVersion" />
+ <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="tenantId" target="tenantId" />
+ <camunda:in source="false" target="usePreload" />
</bpmn:extensionElements>
<bpmn:incoming>SequenceFlow_1hf7k7q</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_1ixcnb6</bpmn:outgoing>
<bpmn:sequenceFlow id="SequenceFlow_1xd3ri5" sourceRef="PreProcessRequest" targetRef="CreateVNF" />
<bpmn:callActivity id="CreateAddOnVfModule" name="Create Add-On VF Module" calledElement="DoCreateVfModule">
<bpmn:extensionElements>
- <camunda:in source="requestId" target="requestId" />
+ <camunda:in source="msoRequestId" target="msoRequestId" />
<camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
<camunda:in source="disableRollback" target="disableRollback" />
<camunda:in source="vnfType" target="vnfType" />
<camunda:in source="vnfModelInfo" target="vnfModelInfo" />
<camunda:in source="globalSubscriberId" target="globalSubscriberId" />
<camunda:in source="sdncVersion" target="sdncVersion" />
+ <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="tenantId" target="tenantId" />
+ <camunda:in source="false" target="usePreload" />
</bpmn:extensionElements>
<bpmn:incoming>SequenceFlow_1lh21yl</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_1llbx0k</bpmn:outgoing>
<bpmn:sequenceFlow id="SequenceFlow_132bohl" name="No" sourceRef="ExclusiveGateway_1vyqr5o" targetRef="EndEvent_0v6povc" />
<bpmn:callActivity id="CreateVNF" name="Create VNF" calledElement="DoCreateVnf">
<bpmn:extensionElements>
- <camunda:in source="requestId" target="requestId" />
+ <camunda:in source="msoRequestId" target="msoRequestId" />
<camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
<camunda:in source="disableRollback" target="disableRollback" />
<camunda:in source="serviceInstanceId" target="serviceInstanceId" />
<camunda:in source="vnfType" target="vnfType" />
<camunda:in source="vnfName" target="vnfName" />
<camunda:in source="vnfId" target="vnfId" />
- <camunda:in source="cloudConfiguration" target="cloudConfiguration" />
<camunda:in source="vnfInputParameters" target="vnfInputParameters" />
<camunda:in source="productFamilyId" target="productFamilyId" />
<camunda:out source="vnfId" target="vnfId" />
<camunda:in source="serviceModelInfo" target="serviceModelInfo" />
<camunda:in source="globalSubscriberId" target="globalSubscriberId" />
<camunda:in source="sdncVersion" target="sdncVersion" />
+ <camunda:out source="vnfName" target="vnfName" />
+ <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="tenantId" target="tenantId" />
</bpmn:extensionElements>
<bpmn:incoming>SequenceFlow_1xd3ri5</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_08i3uo6</bpmn:outgoing>
<bpmn:outgoing>SequenceFlow_1vrogpr</bpmn:outgoing>
</bpmn:exclusiveGateway>
<bpmn:sequenceFlow id="SequenceFlow_0jz6bqn" name="yes" sourceRef="ExclusiveGateway_1vyqr5o" targetRef="PreProcessAddOnModule">
- <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[![CDATA[#{execution.getVariable("addOnModulesDeployed") < execution.getVariable("addOnModulesToDeploy")}]]]]></bpmn:conditionExpression>
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[#{execution.getVariable("addOnModulesDeployed") < execution.getVariable("addOnModulesToDeploy")}]]></bpmn:conditionExpression>
</bpmn:sequenceFlow>
<bpmn:sequenceFlow id="SequenceFlow_0kld3qt" name="yes" sourceRef="ExclusiveGateway_1hx9s0y" targetRef="GenerateAddOnModuleName">
- <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[![CDATA[#{execution.getVariable("instancesOfThisModuleDeployed") < execution.getVariable("initialCount")}]]]]></bpmn:conditionExpression>
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[#{execution.getVariable("instancesOfThisModuleDeployed") < execution.getVariable("initialCount")}]]></bpmn:conditionExpression>
</bpmn:sequenceFlow>
<bpmn:sequenceFlow id="SequenceFlow_1mguf2m" sourceRef="Task_1lfmdks" targetRef="ExclusiveGateway_1hx9s0y" />
<bpmn:sequenceFlow id="SequenceFlow_1vrogpr" name="no" sourceRef="ExclusiveGateway_1hx9s0y" targetRef="FinishProcessingInitialCountDeployment" />
<camunda:in source="basePersonaModelId" target="personaModelId" />
<camunda:out source="vfModuleName" target="baseVfModuleName" />
<camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
</bpmn:extensionElements>
<bpmn:incoming>SequenceFlow_1ifw9tw</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_1hf7k7q</bpmn:outgoing>
<camunda:in source="addOnPersonaModelId" target="personaModelId" />
<camunda:out source="vfModuleName" target="addOnVfModuleName" />
<camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
</bpmn:extensionElements>
<bpmn:incoming>SequenceFlow_0kld3qt</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_1lh21yl</bpmn:outgoing>
def doCreateVnfAndModules = new DoCreateVnfAndModules()
doCreateVnfAndModules.validateBaseModule(execution)]]></bpmn:script>
</bpmn:scriptTask>
+ <bpmn:subProcess id="SubProcess_1ktx0cx" name="Java Exception Handling Sub Process" triggeredByEvent="true">
+ <bpmn:scriptTask id="processJavaError" name="Process Error" scriptFormat="groovy">
+ <bpmn:incoming>SequenceFlow_11bmhi4</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1kjlzrn</bpmn:outgoing>
+ <bpmn:script><![CDATA[import org.openecomp.mso.bpmn.common.scripts.*
+ExceptionUtil exceptionUtil = new ExceptionUtil()
+exceptionUtil.processJavaException(execution)]]></bpmn:script>
+ </bpmn:scriptTask>
+ <bpmn:endEvent id="EndEvent_2">
+ <bpmn:incoming>SequenceFlow_1kjlzrn</bpmn:incoming>
+ </bpmn:endEvent>
+ <bpmn:startEvent id="StartEvent_2">
+ <bpmn:outgoing>SequenceFlow_11bmhi4</bpmn:outgoing>
+ <bpmn:errorEventDefinition errorRef="Error_1" />
+ </bpmn:startEvent>
+ <bpmn:sequenceFlow id="SequenceFlow_11bmhi4" name="" sourceRef="StartEvent_2" targetRef="processJavaError" />
+ <bpmn:sequenceFlow id="SequenceFlow_1kjlzrn" name="" sourceRef="processJavaError" targetRef="EndEvent_2" />
+ </bpmn:subProcess>
</bpmn:process>
+ <bpmn:error id="Error_1" name="Java Lang Exception" errorCode="java.lang.Exception" />
+ <bpmn:error id="Error_2" name="MSO Workflow Exception" errorCode="MSOWorkflowException" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoCreateVnfAndModules">
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1">
<bpmndi:BPMNShape id="ScriptTask_1obevnp_di" bpmnElement="Task_054rz9i">
<dc:Bounds x="1030" y="125" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="SubProcess_1ktx0cx_di" bpmnElement="SubProcess_1ktx0cx" isExpanded="true">
+ <dc:Bounds x="208" y="438" width="313" height="169" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1j93kr8_di" bpmnElement="processJavaError">
+ <dc:Bounds x="316" y="484" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="EndEvent_1s63ccl_di" bpmnElement="EndEvent_2">
+ <dc:Bounds x="461" y="506" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="479" y="547" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="StartEvent_028j51v_di" bpmnElement="StartEvent_2">
+ <dc:Bounds x="233" y="506" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="251" y="547" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_11bmhi4_di" bpmnElement="SequenceFlow_11bmhi4">
+ <di:waypoint xsi:type="dc:Point" x="269" y="524" />
+ <di:waypoint xsi:type="dc:Point" x="316" y="524" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="290" y="524" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1kjlzrn_di" bpmnElement="SequenceFlow_1kjlzrn">
+ <di:waypoint xsi:type="dc:Point" x="416" y="524" />
+ <di:waypoint xsi:type="dc:Point" x="461" y="524" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="436" y="524" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
-<?xml version="1.0" encoding="UTF-8"?>\r
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.6.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">\r
- <bpmn2:process id="DoDeleteServiceInstance" name="DoDeleteServiceInstance" isExecutable="true">\r
- <bpmn2:startEvent id="deleteSI_startEven" name="Start Flow">\r
- <bpmn2:outgoing>SequenceFlow_0jfgn05</bpmn2:outgoing>\r
- </bpmn2:startEvent>\r
- <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0jfgn05</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1jqc16k</bpmn2:outgoing>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+ <bpmn2:process id="DoDeleteServiceInstance" name="DoDeleteServiceInstance" isExecutable="true">
+ <bpmn2:startEvent id="deleteSI_startEven" name="Start Flow">
+ <bpmn2:outgoing>SequenceFlow_0jfgn05</bpmn2:outgoing>
+ </bpmn2:startEvent>
+ <bpmn2:scriptTask id="preProcessRequest_ScriptTask" name="PreProcess Incoming Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0jfgn05</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1jqc16k</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def ddsi = new DoDeleteServiceInstance()\r
-ddsi.preProcessRequest(execution)\r
-]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:endEvent id="EndEvent_3">\r
- <bpmn2:incoming>SequenceFlow_1wyvxwi</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:callActivity id="callGenericDeleteService" name="Call AAI GenericDelete Service " calledElement="GenericDeleteService">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="serviceInstanceId" target="GENDS_serviceInstanceId" />\r
- <camunda:in source="subscriptionServiceType" target="GENDS_serviceType" />\r
- <camunda:in source="globalSubscriberId" target="GENDS_globalCustomerId" />\r
- <camunda:in sourceExpression="service-instance" target="GENDS_type" />\r
- <camunda:out source="GENDS_FoundIndicator" target="GENDS_FoundIndicator" />\r
- <camunda:in sourceExpression="""" target="GENGS_serviceType" />\r
- <camunda:out source="GENDS_SuccessIndicator" target="GENDS_SuccessIndicator" />\r
- <camunda:out source="WorkflowException" target="WorkflowExcpeton" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1w8ao21</bpmn2:incoming>\r
- <bpmn2:incoming>SequenceFlow_0riudmc</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_05wu9i7</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:sequenceFlow id="SequenceFlow_05wu9i7" sourceRef="callGenericDeleteService" targetRef="ScriptTask_1ybdq3e" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0k28xib" sourceRef="CallActivity_0ak0ezb" targetRef="ScriptTask_1uxr0cx" />\r
- <bpmn2:callActivity id="CallActivity_0ak0ezb" name="Call SDNC Service Topology Delete" calledElement="sdncAdapter">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="sdncDelete" target="sdncAdapterWorkflowRequest" />\r
- <camunda:in source="msoRequestId" target="mso-request-id" />\r
- <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="sdncAdapterResponse" target="sdncAdapterResponse" />\r
- <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_0rtflal</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0k28xib</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:scriptTask id="ScriptTask_1uxr0cx" name="Post Process SDNC Delete" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0k28xib</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1w8ao21</bpmn2:outgoing>\r
+def ddsi = new DoDeleteServiceInstance()
+ddsi.preProcessRequest(execution)
+]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:endEvent id="EndEvent_3">
+ <bpmn2:incoming>SequenceFlow_1wyvxwi</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:callActivity id="callGenericDeleteService" name="Call AAI GenericDelete Service " calledElement="GenericDeleteService">
+ <bpmn2:extensionElements>
+ <camunda:in source="serviceInstanceId" target="GENDS_serviceInstanceId" />
+ <camunda:in source="subscriptionServiceType" target="GENDS_serviceType" />
+ <camunda:in source="globalSubscriberId" target="GENDS_globalCustomerId" />
+ <camunda:in sourceExpression="service-instance" target="GENDS_type" />
+ <camunda:out source="GENDS_FoundIndicator" target="GENDS_FoundIndicator" />
+ <camunda:in sourceExpression="""" target="GENGS_serviceType" />
+ <camunda:out source="GENDS_SuccessIndicator" target="GENDS_SuccessIndicator" />
+ <camunda:out source="WorkflowException" target="WorkflowExcpeton" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0riudmc</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0znbzxu</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_05wu9i7</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_05wu9i7" sourceRef="callGenericDeleteService" targetRef="ScriptTask_1ybdq3e" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0k28xib" sourceRef="CallActivity_0ak0ezb" targetRef="ScriptTask_1uxr0cx" />
+ <bpmn2:callActivity id="CallActivity_0ak0ezb" name="Call SDNC Service Topology Deactivate" calledElement="sdncAdapter">
+ <bpmn2:extensionElements>
+ <camunda:in source="sdncDeactivate" target="sdncAdapterWorkflowRequest" />
+ <camunda:in source="msoRequestId" target="mso-request-id" />
+ <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="sdncAdapterResponse" target="sdncDeactivateResponse" />
+ <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0rtflal</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0k28xib</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_1uxr0cx" name="Post Process SDNC Deactivate" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0k28xib</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1w8ao21</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def ddsi = new DoDeleteServiceInstance()\r
-ddsi.postProcessSDNCDelete(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0jfgn05" sourceRef="deleteSI_startEven" targetRef="preProcessRequest_ScriptTask" />\r
- <bpmn2:scriptTask id="ScriptTask_0xxwbdq" name="PreProcess SDNC Delete" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1dwch0k</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0rtflal</bpmn2:outgoing>\r
+
+String response = execution.getVariable("sdncDeactivateResponse")
+def ddsi = new DoDeleteServiceInstance()
+ddsi.postProcessSDNCDelete(execution, response, "deactivate")]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_0jfgn05" sourceRef="deleteSI_startEven" targetRef="preProcessRequest_ScriptTask" />
+ <bpmn2:scriptTask id="ScriptTask_0xxwbdq" name="PreProcess SDNC Delete" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1dwch0k</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0rtflal</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def ddsi = new DoDeleteServiceInstance()\r
-ddsi.preProcessSDNCDelete(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0rtflal" sourceRef="ScriptTask_0xxwbdq" targetRef="CallActivity_0ak0ezb" />\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_0590oev" name="SI found in AAI" default="SequenceFlow_05jfuko">\r
- <bpmn2:incoming>SequenceFlow_1up0j5r</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1hcfvcj</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_05jfuko</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1hcfvcj" name="yes" sourceRef="ExclusiveGateway_0590oev" targetRef="ExclusiveGateway_1mrh7us">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("GENGS_FoundIndicator" ) == true}]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:endEvent id="EndEvent_0ronxsz">\r
- <bpmn2:incoming>SequenceFlow_05jfuko</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:sequenceFlow id="SequenceFlow_05jfuko" name="no" sourceRef="ExclusiveGateway_0590oev" targetRef="EndEvent_0ronxsz" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1w8ao21" sourceRef="ScriptTask_1uxr0cx" targetRef="callGenericDeleteService" />\r
- <bpmn2:exclusiveGateway id="ExclusiveGateway_1mrh7us" name="sdncVersion is 1610 " default="SequenceFlow_1dwch0k">\r
- <bpmn2:incoming>SequenceFlow_1hcfvcj</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0riudmc</bpmn2:outgoing>\r
- <bpmn2:outgoing>SequenceFlow_1dwch0k</bpmn2:outgoing>\r
- </bpmn2:exclusiveGateway>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0riudmc" name="yes" sourceRef="ExclusiveGateway_1mrh7us" targetRef="callGenericDeleteService">\r
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("sdncVersion" ) == "1610" }]]></bpmn2:conditionExpression>\r
- </bpmn2:sequenceFlow>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1dwch0k" name="no" sourceRef="ExclusiveGateway_1mrh7us" targetRef="ScriptTask_0xxwbdq" />\r
- <bpmn2:callActivity id="CallActivity_1s8pf0x" name="Call AAI Generic GetService" calledElement="GenericGetService">\r
- <bpmn2:extensionElements>\r
- <camunda:in source="serviceInstanceId" target="GENGS_serviceInstanceId" />\r
- <camunda:in sourceExpression="service-instance" target="GENGS_type" />\r
- <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />\r
- <camunda:out source="GENGS_SuccessIndicator" target="GENGS_SuccessIndicator" />\r
- <camunda:out source="WorkflowException" target="WorkflowException" />\r
- <camunda:out source="GENGS_siResourceLink" target="GENGS_siResourceLink" />\r
- <camunda:out source="GENGS_service" target="GENGS_service" />\r
- </bpmn2:extensionElements>\r
- <bpmn2:incoming>SequenceFlow_1jqc16k</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1grea1r</bpmn2:outgoing>\r
- </bpmn2:callActivity>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1jqc16k" sourceRef="preProcessRequest_ScriptTask" targetRef="CallActivity_1s8pf0x" />\r
- <bpmn2:scriptTask id="ScriptTask_02da0lj" name="Post Process AAI GET" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_1grea1r</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1up0j5r</bpmn2:outgoing>\r
+def ddsi = new DoDeleteServiceInstance()
+ddsi.preProcessSDNCDelete(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_0rtflal" sourceRef="ScriptTask_0xxwbdq" targetRef="CallActivity_0ak0ezb" />
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0590oev" name="SI found in AAI" default="SequenceFlow_05jfuko">
+ <bpmn2:incoming>SequenceFlow_1up0j5r</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1hcfvcj</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_05jfuko</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_1hcfvcj" name="yes" sourceRef="ExclusiveGateway_0590oev" targetRef="ExclusiveGateway_1mrh7us">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("GENGS_FoundIndicator" ) == true}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:endEvent id="EndEvent_0ronxsz">
+ <bpmn2:incoming>SequenceFlow_05jfuko</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_05jfuko" name="no" sourceRef="ExclusiveGateway_0590oev" targetRef="EndEvent_0ronxsz" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1w8ao21" sourceRef="ScriptTask_1uxr0cx" targetRef="CallActivity_1c5wru8" />
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_1mrh7us" name="sdncVersion is 1610 " default="SequenceFlow_1dwch0k">
+ <bpmn2:incoming>SequenceFlow_1hcfvcj</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0riudmc</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1dwch0k</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_0riudmc" name="yes" sourceRef="ExclusiveGateway_1mrh7us" targetRef="callGenericDeleteService">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{ execution.getVariable("sdncVersion" ) == "1610" }]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_1dwch0k" name="no" sourceRef="ExclusiveGateway_1mrh7us" targetRef="ScriptTask_0xxwbdq" />
+ <bpmn2:callActivity id="CallActivity_1s8pf0x" name="Call AAI Generic GetService" calledElement="GenericGetService">
+ <bpmn2:extensionElements>
+ <camunda:in source="serviceInstanceId" target="GENGS_serviceInstanceId" />
+ <camunda:in sourceExpression="service-instance" target="GENGS_type" />
+ <camunda:out source="GENGS_FoundIndicator" target="GENGS_FoundIndicator" />
+ <camunda:out source="GENGS_SuccessIndicator" target="GENGS_SuccessIndicator" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="GENGS_siResourceLink" target="GENGS_siResourceLink" />
+ <camunda:out source="GENGS_service" target="GENGS_service" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1jqc16k</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1grea1r</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_1jqc16k" sourceRef="preProcessRequest_ScriptTask" targetRef="CallActivity_1s8pf0x" />
+ <bpmn2:scriptTask id="ScriptTask_02da0lj" name="Post Process AAI GET" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1grea1r</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1up0j5r</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def ddsi = new DoDeleteServiceInstance()\r
-ddsi.postProcessAAIGET(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1grea1r" sourceRef="CallActivity_1s8pf0x" targetRef="ScriptTask_02da0lj" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_1up0j5r" sourceRef="ScriptTask_02da0lj" targetRef="ExclusiveGateway_0590oev" />\r
- <bpmn2:scriptTask id="ScriptTask_1ybdq3e" name="Post Process AAI Delete" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_05wu9i7</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_1wyvxwi</bpmn2:outgoing>\r
+def ddsi = new DoDeleteServiceInstance()
+ddsi.postProcessAAIGET(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_1grea1r" sourceRef="CallActivity_1s8pf0x" targetRef="ScriptTask_02da0lj" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1up0j5r" sourceRef="ScriptTask_02da0lj" targetRef="ExclusiveGateway_0590oev" />
+ <bpmn2:scriptTask id="ScriptTask_1ybdq3e" name="Post Process AAI Delete" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_05wu9i7</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1wyvxwi</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*\r
-def ddsi = new DoDeleteServiceInstance()\r
-ddsi.postProcessAAIDEL(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_1wyvxwi" sourceRef="ScriptTask_1ybdq3e" targetRef="EndEvent_3" />\r
- <bpmn2:subProcess id="SubProcess_1jggn82" name="Sub-process for UnexpectedErrors" triggeredByEvent="true">\r
- <bpmn2:startEvent id="StartEvent_1antv0y">\r
- <bpmn2:outgoing>SequenceFlow_0u33vy6</bpmn2:outgoing>\r
- <bpmn2:errorEventDefinition errorRef="Error_1" />\r
- </bpmn2:startEvent>\r
- <bpmn2:endEvent id="EndEvent_03iywf6">\r
- <bpmn2:incoming>SequenceFlow_0hevfee</bpmn2:incoming>\r
- </bpmn2:endEvent>\r
- <bpmn2:scriptTask id="ScriptTask_1va95un" name="Log / Print Unexpected Error" scriptFormat="groovy">\r
- <bpmn2:incoming>SequenceFlow_0u33vy6</bpmn2:incoming>\r
- <bpmn2:outgoing>SequenceFlow_0hevfee</bpmn2:outgoing>\r
+def ddsi = new DoDeleteServiceInstance()
+ddsi.postProcessAAIDEL(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_1wyvxwi" sourceRef="ScriptTask_1ybdq3e" targetRef="EndEvent_3" />
+ <bpmn2:subProcess id="SubProcess_1jggn82" name="Sub-process for UnexpectedErrors" triggeredByEvent="true">
+ <bpmn2:startEvent id="StartEvent_1antv0y">
+ <bpmn2:outgoing>SequenceFlow_0u33vy6</bpmn2:outgoing>
+ <bpmn2:errorEventDefinition errorRef="Error_1" />
+ </bpmn2:startEvent>
+ <bpmn2:endEvent id="EndEvent_03iywf6">
+ <bpmn2:incoming>SequenceFlow_0hevfee</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:scriptTask id="ScriptTask_1va95un" name="Log / Print Unexpected Error" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0u33vy6</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0hevfee</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.common.scripts.*\r
-ExceptionUtil ex = new ExceptionUtil()\r
-ex.processJavaException(execution)]]></bpmn2:script>\r
- </bpmn2:scriptTask>\r
- <bpmn2:sequenceFlow id="SequenceFlow_0u33vy6" name="" sourceRef="StartEvent_1antv0y" targetRef="ScriptTask_1va95un" />\r
- <bpmn2:sequenceFlow id="SequenceFlow_0hevfee" name="" sourceRef="ScriptTask_1va95un" targetRef="EndEvent_03iywf6" />\r
- </bpmn2:subProcess>\r
- </bpmn2:process>\r
- <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />\r
- <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />\r
- <bpmndi:BPMNDiagram id="BPMNDiagram_1">\r
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoDeleteServiceInstance">\r
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="deleteSI_startEven">\r
- <dc:Bounds x="-334" y="79" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="-340" y="120" width="49" height="13" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">\r
- <dc:Bounds x="-229" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="EndEvent_3">\r
- <dc:Bounds x="1384" y="201" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1402" y="242" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="CallActivity_1md4kyb_di" bpmnElement="callGenericDeleteService">\r
- <dc:Bounds x="1159" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_05wu9i7_di" bpmnElement="SequenceFlow_05wu9i7">\r
- <di:waypoint xsi:type="dc:Point" x="1259" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="1350" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1305" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0k28xib_di" bpmnElement="SequenceFlow_0k28xib">\r
- <di:waypoint xsi:type="dc:Point" x="902" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="972" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="937" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="CallActivity_0ak0ezb_di" bpmnElement="CallActivity_0ak0ezb">\r
- <dc:Bounds x="802" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_1uxr0cx_di" bpmnElement="ScriptTask_1uxr0cx">\r
- <dc:Bounds x="972" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0jfgn05_di" bpmnElement="SequenceFlow_0jfgn05">\r
- <di:waypoint xsi:type="dc:Point" x="-298" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="-262" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="-262" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="-229" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="-247" y="97" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_0xxwbdq_di" bpmnElement="ScriptTask_0xxwbdq">\r
- <dc:Bounds x="617" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0rtflal_di" bpmnElement="SequenceFlow_0rtflal">\r
- <di:waypoint xsi:type="dc:Point" x="717" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="802" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="760" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_0590oev_di" bpmnElement="ExclusiveGateway_0590oev" isMarkerVisible="true">\r
- <dc:Bounds x="305" y="72" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="293" y="51" width="73" height="13" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1hcfvcj_di" bpmnElement="SequenceFlow_1hcfvcj">\r
- <di:waypoint xsi:type="dc:Point" x="355" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="420" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="459" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="384" y="99.03416045409814" width="17" height="13" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="EndEvent_0ronxsz_di" bpmnElement="EndEvent_0ronxsz">\r
- <dc:Bounds x="312" y="186" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="330" y="227" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_05jfuko_di" bpmnElement="SequenceFlow_05jfuko">\r
- <di:waypoint xsi:type="dc:Point" x="330" y="122" />\r
- <di:waypoint xsi:type="dc:Point" x="330" y="186" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="310" y="127.1200546314796" width="13" height="13" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1w8ao21_di" bpmnElement="SequenceFlow_1w8ao21">\r
- <di:waypoint xsi:type="dc:Point" x="1072" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="1127" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="1156" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1100" y="82" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ExclusiveGateway_1mrh7us_di" bpmnElement="ExclusiveGateway_1mrh7us" isMarkerVisible="true">\r
- <dc:Bounds x="463" y="72" width="50" height="50" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="451" y="122" width="73" height="25" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0riudmc_di" bpmnElement="SequenceFlow_0riudmc">\r
- <di:waypoint xsi:type="dc:Point" x="488" y="72" />\r
- <di:waypoint xsi:type="dc:Point" x="488" y="-20" />\r
- <di:waypoint xsi:type="dc:Point" x="1209" y="-20" />\r
- <di:waypoint xsi:type="dc:Point" x="1209" y="57" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="841" y="-35" width="17" height="13" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1dwch0k_di" bpmnElement="SequenceFlow_1dwch0k">\r
- <di:waypoint xsi:type="dc:Point" x="513" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="558" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="558" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="617" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="526" y="73" width="12" height="13" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="CallActivity_1s8pf0x_di" bpmnElement="CallActivity_1s8pf0x">\r
- <dc:Bounds x="-64" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1jqc16k_di" bpmnElement="SequenceFlow_1jqc16k">\r
- <di:waypoint xsi:type="dc:Point" x="-129" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="-100" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="-100" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="-64" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="-85" y="97" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_02da0lj_di" bpmnElement="ScriptTask_02da0lj">\r
- <dc:Bounds x="107" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1grea1r_di" bpmnElement="SequenceFlow_1grea1r">\r
- <di:waypoint xsi:type="dc:Point" x="36" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="73" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="73" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="107" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="88" y="97" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1up0j5r_di" bpmnElement="SequenceFlow_1up0j5r">\r
- <di:waypoint xsi:type="dc:Point" x="207" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="256" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="256" y="97" />\r
- <di:waypoint xsi:type="dc:Point" x="305" y="97" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="271" y="97" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="ScriptTask_1ybdq3e_di" bpmnElement="ScriptTask_1ybdq3e">\r
- <dc:Bounds x="1352" y="57" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_1wyvxwi_di" bpmnElement="SequenceFlow_1wyvxwi">\r
- <di:waypoint xsi:type="dc:Point" x="1402" y="137" />\r
- <di:waypoint xsi:type="dc:Point" x="1402" y="201" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="1417" y="169" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNShape id="SubProcess_1jggn82_di" bpmnElement="SubProcess_1jggn82" isExpanded="true">\r
- <dc:Bounds x="266" y="409" width="467" height="193" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="StartEvent_1antv0y_di" bpmnElement="StartEvent_1antv0y">\r
- <dc:Bounds x="334" y="475" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="352" y="516" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="EndEvent_03iywf6_di" bpmnElement="EndEvent_03iywf6">\r
- <dc:Bounds x="627" y="475" width="36" height="36" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="645" y="516" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNShape id="ScriptTask_1va95un_di" bpmnElement="ScriptTask_1va95un">\r
- <dc:Bounds x="438" y="453" width="100" height="80" />\r
- </bpmndi:BPMNShape>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0u33vy6_di" bpmnElement="SequenceFlow_0u33vy6">\r
- <di:waypoint xsi:type="dc:Point" x="370" y="493" />\r
- <di:waypoint xsi:type="dc:Point" x="438" y="493" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="404" y="478" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- <bpmndi:BPMNEdge id="SequenceFlow_0hevfee_di" bpmnElement="SequenceFlow_0hevfee">\r
- <di:waypoint xsi:type="dc:Point" x="538" y="493" />\r
- <di:waypoint xsi:type="dc:Point" x="627" y="493" />\r
- <bpmndi:BPMNLabel>\r
- <dc:Bounds x="583" y="478" width="0" height="0" />\r
- </bpmndi:BPMNLabel>\r
- </bpmndi:BPMNEdge>\r
- </bpmndi:BPMNPlane>\r
- </bpmndi:BPMNDiagram>\r
-</bpmn2:definitions>\r
+ExceptionUtil ex = new ExceptionUtil()
+ex.processJavaException(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_0u33vy6" name="" sourceRef="StartEvent_1antv0y" targetRef="ScriptTask_1va95un" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0hevfee" name="" sourceRef="ScriptTask_1va95un" targetRef="EndEvent_03iywf6" />
+ </bpmn2:subProcess>
+ <bpmn2:callActivity id="CallActivity_1c5wru8" name="Call SDNC Service Topology Delete" calledElement="sdncAdapter">
+ <bpmn2:extensionElements>
+ <camunda:in source="sdncDelete" target="sdncAdapterWorkflowRequest" />
+ <camunda:in source="msoRequestId" target="mso-request-id" />
+ <camunda:in source="serviceInstanceId" target="mso-service-instance-id" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="sdncAdapterResponse" target="sdncDeleteResponse" />
+ <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1w8ao21</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_14x55db</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_0lc115e" name="Post Process SDNC Delete" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_14x55db</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0znbzxu</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+
+String response = execution.getVariable("sdncDeleteResponse")
+def ddsi = new DoDeleteServiceInstance()
+ddsi.postProcessSDNCDelete(execution, response, "delete")]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:sequenceFlow id="SequenceFlow_14x55db" sourceRef="CallActivity_1c5wru8" targetRef="ScriptTask_0lc115e" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0znbzxu" sourceRef="ScriptTask_0lc115e" targetRef="callGenericDeleteService" />
+ </bpmn2:process>
+ <bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
+ <bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
+ <bpmndi:BPMNDiagram id="BPMNDiagram_1">
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoDeleteServiceInstance">
+ <bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="deleteSI_startEven">
+ <dc:Bounds x="-334" y="79" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="-340" y="120" width="49" height="13" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">
+ <dc:Bounds x="-229" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="_BPMNShape_EndEvent_177" bpmnElement="EndEvent_3">
+ <dc:Bounds x="1384" y="201" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1402" y="242" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_1md4kyb_di" bpmnElement="callGenericDeleteService">
+ <dc:Bounds x="1202" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_05wu9i7_di" bpmnElement="SequenceFlow_05wu9i7">
+ <di:waypoint xsi:type="dc:Point" x="1302" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="1352" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1327" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0k28xib_di" bpmnElement="SequenceFlow_0k28xib">
+ <di:waypoint xsi:type="dc:Point" x="738" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="776" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="757" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0ak0ezb_di" bpmnElement="CallActivity_0ak0ezb">
+ <dc:Bounds x="638" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1uxr0cx_di" bpmnElement="ScriptTask_1uxr0cx">
+ <dc:Bounds x="776" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0jfgn05_di" bpmnElement="SequenceFlow_0jfgn05">
+ <di:waypoint xsi:type="dc:Point" x="-298" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="-262" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="-262" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="-229" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="-247" y="97" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_0xxwbdq_di" bpmnElement="ScriptTask_0xxwbdq">
+ <dc:Bounds x="492" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0rtflal_di" bpmnElement="SequenceFlow_0rtflal">
+ <di:waypoint xsi:type="dc:Point" x="592" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="638" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="615" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0590oev_di" bpmnElement="ExclusiveGateway_0590oev" isMarkerVisible="true">
+ <dc:Bounds x="305" y="72" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="293" y="51" width="73" height="13" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1hcfvcj_di" bpmnElement="SequenceFlow_1hcfvcj">
+ <di:waypoint xsi:type="dc:Point" x="355" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="403" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="384" y="99" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="EndEvent_0ronxsz_di" bpmnElement="EndEvent_0ronxsz">
+ <dc:Bounds x="312" y="186" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="330" y="227" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_05jfuko_di" bpmnElement="SequenceFlow_05jfuko">
+ <di:waypoint xsi:type="dc:Point" x="330" y="122" />
+ <di:waypoint xsi:type="dc:Point" x="330" y="186" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="310" y="127.1200546314796" width="13" height="13" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1w8ao21_di" bpmnElement="SequenceFlow_1w8ao21">
+ <di:waypoint xsi:type="dc:Point" x="876" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="917" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="897" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ExclusiveGateway_1mrh7us_di" bpmnElement="ExclusiveGateway_1mrh7us" isMarkerVisible="true">
+ <dc:Bounds x="403" y="72" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="390" y="122" width="75" height="24" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0riudmc_di" bpmnElement="SequenceFlow_0riudmc">
+ <di:waypoint xsi:type="dc:Point" x="428" y="72" />
+ <di:waypoint xsi:type="dc:Point" x="428" y="-20" />
+ <di:waypoint xsi:type="dc:Point" x="1252" y="-20" />
+ <di:waypoint xsi:type="dc:Point" x="1252" y="57" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="834" y="-35" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1dwch0k_di" bpmnElement="SequenceFlow_1dwch0k">
+ <di:waypoint xsi:type="dc:Point" x="453" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="492" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="464" y="73" width="12" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_1s8pf0x_di" bpmnElement="CallActivity_1s8pf0x">
+ <dc:Bounds x="-64" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1jqc16k_di" bpmnElement="SequenceFlow_1jqc16k">
+ <di:waypoint xsi:type="dc:Point" x="-129" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="-100" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="-100" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="-64" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="-85" y="97" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_02da0lj_di" bpmnElement="ScriptTask_02da0lj">
+ <dc:Bounds x="107" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1grea1r_di" bpmnElement="SequenceFlow_1grea1r">
+ <di:waypoint xsi:type="dc:Point" x="36" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="73" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="73" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="107" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="88" y="97" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1up0j5r_di" bpmnElement="SequenceFlow_1up0j5r">
+ <di:waypoint xsi:type="dc:Point" x="207" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="256" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="256" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="305" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="271" y="97" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1ybdq3e_di" bpmnElement="ScriptTask_1ybdq3e">
+ <dc:Bounds x="1352" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1wyvxwi_di" bpmnElement="SequenceFlow_1wyvxwi">
+ <di:waypoint xsi:type="dc:Point" x="1402" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="1402" y="201" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1417" y="169" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="SubProcess_1jggn82_di" bpmnElement="SubProcess_1jggn82" isExpanded="true">
+ <dc:Bounds x="266" y="409" width="467" height="193" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="StartEvent_1antv0y_di" bpmnElement="StartEvent_1antv0y">
+ <dc:Bounds x="334" y="475" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="352" y="516" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="EndEvent_03iywf6_di" bpmnElement="EndEvent_03iywf6">
+ <dc:Bounds x="627" y="475" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="645" y="516" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1va95un_di" bpmnElement="ScriptTask_1va95un">
+ <dc:Bounds x="438" y="453" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0u33vy6_di" bpmnElement="SequenceFlow_0u33vy6">
+ <di:waypoint xsi:type="dc:Point" x="370" y="493" />
+ <di:waypoint xsi:type="dc:Point" x="438" y="493" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="404" y="478" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0hevfee_di" bpmnElement="SequenceFlow_0hevfee">
+ <di:waypoint xsi:type="dc:Point" x="538" y="493" />
+ <di:waypoint xsi:type="dc:Point" x="627" y="493" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="583" y="478" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_1c5wru8_di" bpmnElement="CallActivity_1c5wru8">
+ <dc:Bounds x="917" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_0lc115e_di" bpmnElement="ScriptTask_0lc115e">
+ <dc:Bounds x="1058" y="57" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_14x55db_di" bpmnElement="SequenceFlow_14x55db">
+ <di:waypoint xsi:type="dc:Point" x="1017" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="1058" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1038" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0znbzxu_di" bpmnElement="SequenceFlow_0znbzxu">
+ <di:waypoint xsi:type="dc:Point" x="1158" y="97" />
+ <di:waypoint xsi:type="dc:Point" x="1202" y="97" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1180" y="82" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ </bpmndi:BPMNPlane>
+ </bpmndi:BPMNDiagram>
+</bpmn2:definitions>
<?xml version="1.0" encoding="UTF-8"?>
<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_Wblj8GyfEeWUWLTvug7ZOg" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:process id="DoDeleteVfModule" name="DoDeleteVfModule" isExecutable="true">
- <bpmn2:scriptTask id="UpdateAAIVfModulePrep" name="UpdateAAIVfModule
- Prep" scriptFormat="groovy">
+ <bpmn2:scriptTask id="UpdateAAIVfModulePrep" name="UpdateAAIVfModule\r Prep" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_0fp1wqz</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_28</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
dvm.prepUpdateAAIVfModule(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_28" name="" sourceRef="UpdateAAIVfModulePrep" targetRef="InvokeUpdateAAIVfModule" />
- <bpmn2:callActivity id="InvokeUpdateAAIVfModule" name="Invoke
- UpdateAAIVfModule" calledElement="UpdateAAIVfModule">
+ <bpmn2:callActivity id="InvokeUpdateAAIVfModule" name="Invoke\r UpdateAAIVfModule" calledElement="UpdateAAIVfModule">
<bpmn2:extensionElements>
<camunda:out source="WorkflowException" target="WorkflowException" />
<camunda:in source="UpdateAAIVfModuleRequest" target="UpdateAAIVfModuleRequest" />
<bpmn2:outgoing>SequenceFlow_31</bpmn2:outgoing>
</bpmn2:callActivity>
<bpmn2:sequenceFlow id="SequenceFlow_31" name="" sourceRef="InvokeUpdateAAIVfModule" targetRef="SDNCAdapterPrep2" />
- <bpmn2:callActivity id="InvokePrepareUpdateAAIVfModule" name="Invoke
- PrepareUpdateAAIVfModule" calledElement="PrepareUpdateAAIVfModule">
+ <bpmn2:callActivity id="InvokePrepareUpdateAAIVfModule" name="Invoke\r PrepareUpdateAAIVfModule" calledElement="PrepareUpdateAAIVfModule">
<bpmn2:extensionElements>
<camunda:in source="PrepareUpdateAAIVfModuleRequest" target="PrepareUpdateAAIVfModuleRequest" />
<camunda:out source="WorkflowException" target="WorkflowException" />
<bpmn2:outgoing>SequenceFlow_1j9dvfx</bpmn2:outgoing>
</bpmn2:callActivity>
<bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="VNFAdapterPrep" targetRef="InvokeVNFAdapterRestV1" />
- <bpmn2:callActivity id="InvokeSDNCAdapterV1_2" name="Invoke
- SDNCAdapterV1" calledElement="sdncAdapter">
+ <bpmn2:callActivity id="InvokeSDNCAdapterV1_2" name="Invoke\r SDNCAdapterV1" calledElement="sdncAdapter">
<bpmn2:extensionElements>
<camunda:out source="WorkflowException" target="WorkflowException" />
<camunda:in source="sdncAdapterWorkflowRequest" target="sdncAdapterWorkflowRequest" />
<bpmn2:outgoing>SequenceFlow_33</bpmn2:outgoing>
</bpmn2:callActivity>
<bpmn2:sequenceFlow id="SequenceFlow_33" name="" sourceRef="InvokeSDNCAdapterV1_2" targetRef="validateSDNCResponse" />
- <bpmn2:scriptTask id="VNFAdapterPrep" name="VNFAdapter
- Prep" scriptFormat="groovy">
+ <bpmn2:scriptTask id="VNFAdapterPrep" name="VNFAdapter\r Prep" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_1j9dvfx</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
def dvm = new DoDeleteVfModule()
dvm.prepVNFAdapterRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:scriptTask id="SDNCAdapterPrep2" name="SDNCAdapter
- Prep" scriptFormat="groovy">
+ <bpmn2:scriptTask id="SDNCAdapterPrep2" name="SDNCAdapter\r Prep" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_31</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_32</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
dvm.prepSDNCAdapterRequest(execution, "delete")]]></bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_32" name="" sourceRef="SDNCAdapterPrep2" targetRef="InvokeSDNCAdapterV1_2" />
- <bpmn2:callActivity id="InvokeVNFAdapterRestV1" name="Invoke
- VNFAdapterRestV1" calledElement="vnfAdapterRestV1">
+ <bpmn2:callActivity id="InvokeVNFAdapterRestV1" name="Invoke\r VNFAdapterRestV1" calledElement="vnfAdapterRestV1">
<bpmn2:extensionElements>
<camunda:out source="WorkflowException" target="WorkflowException" />
<camunda:in source="vnfAdapterRestV1Request" target="vnfAdapterRestV1Request" />
<bpmn2:endEvent id="EndEvent_9">
<bpmn2:incoming>SequenceFlow_35</bpmn2:incoming>
</bpmn2:endEvent>
- <bpmn2:callActivity id="InvokeDeleteAAIVfModule" name="Invoke
- DeleteAAIVfModule" calledElement="DeleteAAIVfModule">
+ <bpmn2:callActivity id="InvokeDeleteAAIVfModule" name="Invoke\r DeleteAAIVfModule" calledElement="DeleteAAIVfModule">
<bpmn2:extensionElements>
<camunda:in source="DeleteAAIVfModuleRequest" target="DeleteAAIVfModuleRequest" />
<camunda:in source="isVidRequest" target="isVidRequest" />
<bpmn2:outgoing>SequenceFlow_35</bpmn2:outgoing>
</bpmn2:callActivity>
<bpmn2:sequenceFlow id="SequenceFlow_35" name="" sourceRef="InvokeDeleteAAIVfModule" targetRef="EndEvent_9" />
- <bpmn2:scriptTask id="DeleteAAIVfModulePrep" name="DeleteAAIVfModule
- Prep" scriptFormat="groovy">
+ <bpmn2:scriptTask id="DeleteAAIVfModulePrep" name="DeleteAAIVfModule\r Prep" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_34</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
</bpmn2:endEvent>
<bpmn2:exclusiveGateway id="ExclusiveGateway_1amun4k" name="Are there VF modules to delete?" default="SequenceFlow_1936oc0">
<bpmn2:incoming>SequenceFlow_0t4yszi</bpmn2:incoming>
- <bpmn2:incoming>SequenceFlow_0lu7b1v</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1tt31qu</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1fccvli</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1qrkdn3</bpmn2:outgoing>
<bpmn2:outgoing>SequenceFlow_1936oc0</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
<bpmn2:callActivity id="DeleteVNF" name="Delete VNF" calledElement="DoDeleteVnf">
<bpmn2:extensionElements>
- <camunda:in source="IsDebugLogEnabled" target="IsDebugLogEnabled" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
<camunda:out source="WorkflowException" target="WorkflowException" />
<camunda:in source="vnfId" target="vnfId" />
</bpmn2:extensionElements>
<bpmn2:incoming>SequenceFlow_05ujwz8</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1x25m7t</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1uqlr6b</bpmn2:outgoing>
</bpmn2:callActivity>
<bpmn2:sequenceFlow id="SequenceFlow_08nd69s" sourceRef="intialization" targetRef="QueryVnf" />
<bpmn2:sequenceFlow id="SequenceFlow_1qrkdn3" name="yes" sourceRef="ExclusiveGateway_1amun4k" targetRef="PrepareModuleList">
- <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression" language="groovy"><![CDATA[execution.getVariable("DDVAM_nextModule") < execution.getVariable("DDVAM_modulesSize")]]></bpmn2:conditionExpression>
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression" language="groovy"><![CDATA[execution.getVariable("DDVAM_nextModule") < execution.getVariable("DDVAM_moduleCount")]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
<bpmn2:callActivity id="DeleteVFModule" name="Delete VF Module" calledElement="DoDeleteVfModule">
<bpmn2:extensionElements>
<camunda:in source="DDVAM_vfModuleName" target="vfModuleName" />
<camunda:in source="DDVAM_vfModuleModelInfo" target="vfModuleModelInfo" />
<camunda:in source="cloudConfiguration" target="cloudConfiguration" />
- <camunda:in source=""1610"" target="sdncVersion" />
+ <camunda:in source="DDVAM_sdncVersion" target="sdncVersion" />
<camunda:in source=""true"" target="isVidRequest" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
</bpmn2:extensionElements>
- <bpmn2:incoming>SequenceFlow_1qoor0l</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1xujrk5</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1p4ycii</bpmn2:outgoing>
</bpmn2:callActivity>
- <bpmn2:exclusiveGateway id="ExclusiveGateway_0189gqf">
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0189gqf" name="Is SDNC Interaction Enabled?" default="SequenceFlow_05ujwz8">
<bpmn2:incoming>SequenceFlow_1936oc0</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_05ujwz8</bpmn2:outgoing>
+ <bpmn2:outgoing>SDNCInteractionEnabled2</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
<bpmn2:sequenceFlow id="SequenceFlow_1p4ycii" sourceRef="DeleteVFModule" targetRef="PostProcessDeleteVfModule" />
<bpmn2:sequenceFlow id="SequenceFlow_0t4yszi" sourceRef="PostProcessDeleteVfModule" targetRef="ExclusiveGateway_1amun4k" />
<bpmn2:sequenceFlow id="SequenceFlow_1936oc0" name="no" sourceRef="ExclusiveGateway_1amun4k" targetRef="ExclusiveGateway_0189gqf" />
- <bpmn2:sequenceFlow id="SequenceFlow_05ujwz8" sourceRef="ExclusiveGateway_0189gqf" targetRef="DeleteVNF" />
+ <bpmn2:sequenceFlow id="SequenceFlow_05ujwz8" name="no" sourceRef="ExclusiveGateway_0189gqf" targetRef="DeleteVNF" />
<bpmn2:sequenceFlow id="SequenceFlow_1uqlr6b" sourceRef="DeleteVNF" targetRef="EndEvent_2" />
<bpmn2:scriptTask id="QueryVnf" name="Query VNF" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_08nd69s</bpmn2:incoming>
def ddvam = new DoDeleteVnfAndModules()
ddvam.prepareNextModuleToDelete(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
- <bpmn2:sequenceFlow id="SequenceFlow_0lu7b1v" sourceRef="QueryVnf" targetRef="ExclusiveGateway_1amun4k" />
- <bpmn2:sequenceFlow id="SequenceFlow_1qoor0l" sourceRef="PrepareModuleList" targetRef="DeleteVFModule" />
- <bpmn2:scriptTask id="PostProcessDeleteVfModule" name="PostProcess Delete VF Module">
+ <bpmn2:sequenceFlow id="SequenceFlow_0lu7b1v" sourceRef="QueryVnf" targetRef="ExclusiveGateway_027lai5" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1qoor0l" sourceRef="PrepareModuleList" targetRef="ExclusiveGateway_0b36mti" />
+ <bpmn2:scriptTask id="PostProcessDeleteVfModule" name="PostProcess Delete VF Module" scriptFormat="groovy">
<bpmn2:incoming>SequenceFlow_1p4ycii</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0xl033m</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0t4yszi</bpmn2:outgoing>
<bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
-int nextModule = execution.getVariable("nextModule")
- execution.setVariable("nextModule", nextModule + 1)]]></bpmn2:script>
+int nextModule = execution.getVariable("DDVAM_nextModule")
+ execution.setVariable("DDVAM_nextModule", nextModule + 1)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_027lai5" name="Is SDNC Interaction Enabled?" default="SequenceFlow_1tt31qu">
+ <bpmn2:incoming>SequenceFlow_0lu7b1v</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1tt31qu</bpmn2:outgoing>
+ <bpmn2:outgoing>SDNCInteractionEnabled1</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:sequenceFlow id="SequenceFlow_1tt31qu" name="no" sourceRef="ExclusiveGateway_027lai5" targetRef="ExclusiveGateway_1amun4k" />
+ <bpmn2:sequenceFlow id="SDNCInteractionEnabled1" name="yes" sourceRef="ExclusiveGateway_027lai5" targetRef="preProcessSDNCDeactivateRequest">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DDVAM_sdncVersion" ) != '1702'}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0fhhsyo" sourceRef="preProcessSDNCDeactivateRequest" targetRef="callSDNCAdapterTopologyDeactivate" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0qdn8k4" sourceRef="callSDNCAdapterTopologyDeactivate" targetRef="postProcessSDNCDeactivateRequest" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1fccvli" sourceRef="postProcessSDNCDeactivateRequest" targetRef="ExclusiveGateway_1amun4k" />
+ <bpmn2:scriptTask id="preProcessSDNCDeactivateRequest" name="PreProcess SDNC Deactivate Request" scriptFormat="groovy">
+ <bpmn2:incoming>SDNCInteractionEnabled1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0fhhsyo</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+def ddvam = new DoDeleteVnfAndModules()
+ddvam.preProcessSDNCDeactivateRequest(execution)]]></bpmn2:script>
</bpmn2:scriptTask>
+ <bpmn2:scriptTask id="postProcessSDNCDeactivateRequest" name="PostProcess SDNC Deactivate Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0qdn8k4</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1fccvli</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+def ddvam = new DoDeleteVnfAndModules()
+String response = execution.getVariable("DDVAM_deactivateSDNCAdapterResponse")
+ddvam.validateSDNCResponse(execution, response, "deactivate")]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:callActivity id="callSDNCAdapterTopologyDeactivate" name="Call SDNC Adapter Topology Deactivate" calledElement="sdncAdapter">
+ <bpmn2:extensionElements>
+ <camunda:in source="DDVAM_deactivateSDNCRequest" target="sdncAdapterWorkflowRequest" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="mso-request-id" target="mso-request-id" />
+ <camunda:in source="mso-service-instance-id" target="mso-service-instance-id" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="sdncAdapterResponse" target="DDVAM_deactivateSDNCAdapterResponse" />
+ <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0fhhsyo</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0qdn8k4</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SDNCInteractionEnabled2" name="yes" sourceRef="ExclusiveGateway_0189gqf" targetRef="preProcessSDNCUnassignRequest">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DDVAM_sdncVersion" ) != '1702'}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_001uxa1" sourceRef="preProcessSDNCUnassignRequest" targetRef="callSDNCAdapterTopologyUnassign" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1x29mht" sourceRef="callSDNCAdapterTopologyUnassign" targetRef="postProcessSDNCUnassignRequest" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1x25m7t" sourceRef="postProcessSDNCUnassignRequest" targetRef="DeleteVNF" />
+ <bpmn2:scriptTask id="preProcessSDNCUnassignRequest" name="PreProcess SDNC Unassign Request" scriptFormat="groovy">
+ <bpmn2:incoming>SDNCInteractionEnabled2</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_001uxa1</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+def ddvam = new DoDeleteVnfAndModules()
+ddvam.preProcessSDNCUnassignRequest(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:callActivity id="callSDNCAdapterTopologyUnassign" name="Call SDNC Adapter Topology Unassign" calledElement="sdncAdapter">
+ <bpmn2:extensionElements>
+ <camunda:in source="DDVAM_unassignSDNCRequest" target="sdncAdapterWorkflowRequest" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="mso-request-id" target="mso-request-id" />
+ <camunda:in source="mso-service-instance-id" target="mso-service-instance-id" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="sdncAdapterResponse" target="DDVAM_unassignSDNCAdapterResponse" />
+ <camunda:out source="SDNCA_SuccessIndicator" target="SDNCA_SuccessIndicator" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_001uxa1</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1x29mht</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="postProcessSDNCUnassignRequest" name="PostProcess SDNC Unassign Request" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1x29mht</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1x25m7t</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.*
+def ddvam = new DoDeleteVnfAndModules()
+String response = execution.getVariable("DDVAM_unassignSDNCAdapterResponse")
+ddvam.validateSDNCResponse(execution, response, "unassign")]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:exclusiveGateway id="ExclusiveGateway_0b36mti" name="Is SDNC Interaction Enabled?" default="SequenceFlow_1xujrk5">
+ <bpmn2:incoming>SequenceFlow_1qoor0l</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1xujrk5</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1laeenc</bpmn2:outgoing>
+ </bpmn2:exclusiveGateway>
+ <bpmn2:callActivity id="DoDeleteVfModuleFromVnf" name="Deiete VF Module From VNF" calledElement="DoDeleteVfModuleFromVnf">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:in source="vnfId" target="vnfId" />
+ <camunda:in source="lcpCloudRegionId" target="lcpCloudRegionId" />
+ <camunda:in source="tenantId" target="tenantId" />
+ <camunda:in source="DDVAM_sdncVersion" target="sdncVersion" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:in source="DDVAM_vfModuleId" target="vfModuleId" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1laeenc</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0xl033m</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_1xujrk5" name="no" sourceRef="ExclusiveGateway_0b36mti" targetRef="DeleteVFModule" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1laeenc" name="yes" sourceRef="ExclusiveGateway_0b36mti" targetRef="DoDeleteVfModuleFromVnf">
+ <bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[#{execution.getVariable("DDVAM_sdncVersion" ) != '1702'}]]></bpmn2:conditionExpression>
+ </bpmn2:sequenceFlow>
+ <bpmn2:sequenceFlow id="SequenceFlow_0xl033m" sourceRef="DoDeleteVfModuleFromVnf" targetRef="PostProcessDeleteVfModule" />
</bpmn2:process>
<bpmn2:error id="Error_1" name="MSO Workflow Exception" errorCode="MSOWorkflowException" />
<bpmn2:error id="Error_2" name="Java Lang Exception" errorCode="java.lang.Exception" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_237" bpmnElement="EndEvent_2">
- <dc:Bounds x="1605" y="209" width="36" height="36" />
+ <dc:Bounds x="1983" y="372" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1623" y="250" width="0" height="0" />
+ <dc:Bounds x="2001" y="413" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_SubProcess_35" bpmnElement="javaErrorHandlingSubProcess" isExpanded="true">
- <dc:Bounds x="226" y="401" width="431" height="157" />
+ <dc:Bounds x="229" y="616" width="431" height="157" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_81" bpmnElement="StartEvent_3">
- <dc:Bounds x="374" y="462" width="36" height="36" />
+ <dc:Bounds x="377" y="677" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="392" y="503" width="0" height="0" />
+ <dc:Bounds x="395" y="718" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_239" bpmnElement="EndEvent_4">
- <dc:Bounds x="590" y="462" width="36" height="36" />
+ <dc:Bounds x="593" y="677" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="608" y="503" width="0" height="0" />
+ <dc:Bounds x="611" y="718" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_319" bpmnElement="processJavaException">
- <dc:Bounds x="444" y="440" width="100" height="80" />
+ <dc:Bounds x="447" y="655" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_20" bpmnElement="SequenceFlow_18" sourceElement="_BPMNShape_StartEvent_81" targetElement="_BPMNShape_ScriptTask_319">
- <di:waypoint xsi:type="dc:Point" x="410" y="480" />
- <di:waypoint xsi:type="dc:Point" x="444" y="480" />
+ <di:waypoint xsi:type="dc:Point" x="413" y="695" />
+ <di:waypoint xsi:type="dc:Point" x="447" y="695" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="427" y="465" width="0" height="0" />
+ <dc:Bounds x="430" y="680" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_21" bpmnElement="SequenceFlow_19" sourceElement="_BPMNShape_ScriptTask_319" targetElement="_BPMNShape_EndEvent_239">
- <di:waypoint xsi:type="dc:Point" x="544" y="480" />
- <di:waypoint xsi:type="dc:Point" x="590" y="480" />
+ <di:waypoint xsi:type="dc:Point" x="547" y="695" />
+ <di:waypoint xsi:type="dc:Point" x="593" y="695" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="567" y="465" width="0" height="0" />
+ <dc:Bounds x="570" y="680" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ExclusiveGateway_1amun4k_di" bpmnElement="ExclusiveGateway_1amun4k" isMarkerVisible="true">
- <dc:Bounds x="691" y="202" width="50" height="50" />
+ <dc:Bounds x="1271" y="200" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="683" y="252" width="65" height="36" />
+ <dc:Bounds x="1263" y="250" width="65" height="36" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="CallActivity_0laaqvh_di" bpmnElement="DeleteVNF">
- <dc:Bounds x="1436" y="187" width="100" height="80" />
+ <dc:Bounds x="1812" y="350" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_08nd69s_di" bpmnElement="SequenceFlow_08nd69s">
<di:waypoint xsi:type="dc:Point" x="444" y="227" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1qrkdn3_di" bpmnElement="SequenceFlow_1qrkdn3">
- <di:waypoint xsi:type="dc:Point" x="716" y="202" />
- <di:waypoint xsi:type="dc:Point" x="716" y="104" />
- <di:waypoint xsi:type="dc:Point" x="788" y="104" />
+ <di:waypoint xsi:type="dc:Point" x="1296" y="200" />
+ <di:waypoint xsi:type="dc:Point" x="1296" y="102" />
+ <di:waypoint xsi:type="dc:Point" x="1368" y="102" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="722" y="156.4750449879038" width="18" height="12" />
+ <dc:Bounds x="1302" y="154" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="CallActivity_0qmp9y5_di" bpmnElement="DeleteVFModule">
- <dc:Bounds x="962" y="64" width="100" height="80" />
+ <dc:Bounds x="1648" y="-9" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ExclusiveGateway_0189gqf_di" bpmnElement="ExclusiveGateway_0189gqf" isMarkerVisible="true">
- <dc:Bounds x="1304" y="202" width="50" height="50" />
+ <dc:Bounds x="1271" y="365" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1329" y="252" width="0" height="0" />
+ <dc:Bounds x="1302" y="319" width="54" height="36" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1p4ycii_di" bpmnElement="SequenceFlow_1p4ycii">
- <di:waypoint xsi:type="dc:Point" x="1062" y="104" />
- <di:waypoint xsi:type="dc:Point" x="1096" y="104" />
- <di:waypoint xsi:type="dc:Point" x="1096" y="104" />
- <di:waypoint xsi:type="dc:Point" x="1127" y="104" />
+ <di:waypoint xsi:type="dc:Point" x="1748" y="31" />
+ <di:waypoint xsi:type="dc:Point" x="1904" y="31" />
+ <di:waypoint xsi:type="dc:Point" x="1904" y="62" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1111" y="104" width="0" height="0" />
+ <dc:Bounds x="1826" y="16" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0t4yszi_di" bpmnElement="SequenceFlow_0t4yszi">
- <di:waypoint xsi:type="dc:Point" x="1177" y="144" />
- <di:waypoint xsi:type="dc:Point" x="1177" y="227" />
- <di:waypoint xsi:type="dc:Point" x="741" y="227" />
+ <di:waypoint xsi:type="dc:Point" x="1904" y="142" />
+ <di:waypoint xsi:type="dc:Point" x="1904" y="225" />
+ <di:waypoint xsi:type="dc:Point" x="1321" y="225" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1192" y="185.5" width="0" height="0" />
+ <dc:Bounds x="1919" y="183.5" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1936oc0_di" bpmnElement="SequenceFlow_1936oc0">
- <di:waypoint xsi:type="dc:Point" x="716" y="252" />
- <di:waypoint xsi:type="dc:Point" x="716" y="301" />
- <di:waypoint xsi:type="dc:Point" x="1329" y="301" />
- <di:waypoint xsi:type="dc:Point" x="1329" y="252" />
+ <di:waypoint xsi:type="dc:Point" x="1296" y="250" />
+ <di:waypoint xsi:type="dc:Point" x="1296" y="365" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1017" y="286" width="12" height="12" />
+ <dc:Bounds x="1270" y="305.40625" width="12" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_05ujwz8_di" bpmnElement="SequenceFlow_05ujwz8">
- <di:waypoint xsi:type="dc:Point" x="1354" y="227" />
- <di:waypoint xsi:type="dc:Point" x="1436" y="227" />
+ <di:waypoint xsi:type="dc:Point" x="1321" y="390" />
+ <di:waypoint xsi:type="dc:Point" x="1812" y="390" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1395" y="202" width="0" height="0" />
+ <dc:Bounds x="1361" y="362" width="12" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1uqlr6b_di" bpmnElement="SequenceFlow_1uqlr6b">
- <di:waypoint xsi:type="dc:Point" x="1536" y="227" />
- <di:waypoint xsi:type="dc:Point" x="1605" y="227" />
+ <di:waypoint xsi:type="dc:Point" x="1912" y="390" />
+ <di:waypoint xsi:type="dc:Point" x="1983" y="390" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1571" y="212" width="0" height="0" />
+ <dc:Bounds x="1948" y="375" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_12xsp2f_di" bpmnElement="QueryVnf">
<dc:Bounds x="512" y="187" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ScriptTask_01c9qas_di" bpmnElement="PrepareModuleList">
- <dc:Bounds x="788" y="64" width="100" height="80" />
+ <dc:Bounds x="1368" y="62" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0lu7b1v_di" bpmnElement="SequenceFlow_0lu7b1v">
<di:waypoint xsi:type="dc:Point" x="612" y="227" />
- <di:waypoint xsi:type="dc:Point" x="691" y="227" />
+ <di:waypoint xsi:type="dc:Point" x="701" y="227" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="652" y="202" width="0" height="0" />
+ <dc:Bounds x="657" y="212" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1qoor0l_di" bpmnElement="SequenceFlow_1qoor0l">
- <di:waypoint xsi:type="dc:Point" x="888" y="104" />
- <di:waypoint xsi:type="dc:Point" x="928" y="104" />
- <di:waypoint xsi:type="dc:Point" x="928" y="104" />
- <di:waypoint xsi:type="dc:Point" x="962" y="104" />
+ <di:waypoint xsi:type="dc:Point" x="1468" y="102" />
+ <di:waypoint xsi:type="dc:Point" x="1525" y="102" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="943" y="104" width="0" height="0" />
+ <dc:Bounds x="1497" y="87" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_11i0rnd_di" bpmnElement="PostProcessDeleteVfModule">
- <dc:Bounds x="1127" y="64" width="100" height="80" />
+ <dc:Bounds x="1854" y="62" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_027lai5_di" bpmnElement="ExclusiveGateway_027lai5" isMarkerVisible="true">
+ <dc:Bounds x="701" y="202" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="699" y="145" width="54" height="36" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1tt31qu_di" bpmnElement="SequenceFlow_1tt31qu">
+ <di:waypoint xsi:type="dc:Point" x="751" y="227" />
+ <di:waypoint xsi:type="dc:Point" x="1271" y="225" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1005" y="201" width="12" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_04lnhgt_di" bpmnElement="SDNCInteractionEnabled1">
+ <di:waypoint xsi:type="dc:Point" x="726" y="252" />
+ <di:waypoint xsi:type="dc:Point" x="726" y="337" />
+ <di:waypoint xsi:type="dc:Point" x="776" y="337" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="694" y="280.5" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0fhhsyo_di" bpmnElement="SequenceFlow_0fhhsyo">
+ <di:waypoint xsi:type="dc:Point" x="876" y="337" />
+ <di:waypoint xsi:type="dc:Point" x="926" y="337" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="901" y="322" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0qdn8k4_di" bpmnElement="SequenceFlow_0qdn8k4">
+ <di:waypoint xsi:type="dc:Point" x="1026" y="337" />
+ <di:waypoint xsi:type="dc:Point" x="1070" y="337" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1048" y="322" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1fccvli_di" bpmnElement="SequenceFlow_1fccvli">
+ <di:waypoint xsi:type="dc:Point" x="1170" y="337" />
+ <di:waypoint xsi:type="dc:Point" x="1225" y="337" />
+ <di:waypoint xsi:type="dc:Point" x="1225" y="225" />
+ <di:waypoint xsi:type="dc:Point" x="1271" y="225" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1240" y="281" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_1cj4pgd_di" bpmnElement="preProcessSDNCDeactivateRequest">
+ <dc:Bounds x="776" y="297" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1nug5hb_di" bpmnElement="postProcessSDNCDeactivateRequest">
+ <dc:Bounds x="1070" y="297" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0sl24xf_di" bpmnElement="callSDNCAdapterTopologyDeactivate">
+ <dc:Bounds x="926" y="297" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0ftrgor_di" bpmnElement="SDNCInteractionEnabled2">
+ <di:waypoint xsi:type="dc:Point" x="1296" y="415" />
+ <di:waypoint xsi:type="dc:Point" x="1296" y="501" />
+ <di:waypoint xsi:type="dc:Point" x="1356" y="501" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1266" y="445.36046511627904" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_001uxa1_di" bpmnElement="SequenceFlow_001uxa1">
+ <di:waypoint xsi:type="dc:Point" x="1456" y="501" />
+ <di:waypoint xsi:type="dc:Point" x="1517" y="501" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1487" y="486" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1x29mht_di" bpmnElement="SequenceFlow_1x29mht">
+ <di:waypoint xsi:type="dc:Point" x="1617" y="501" />
+ <di:waypoint xsi:type="dc:Point" x="1678" y="501" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1648" y="486" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1x25m7t_di" bpmnElement="SequenceFlow_1x25m7t">
+ <di:waypoint xsi:type="dc:Point" x="1778" y="501" />
+ <di:waypoint xsi:type="dc:Point" x="1862" y="501" />
+ <di:waypoint xsi:type="dc:Point" x="1862" y="430" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1820" y="486" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="ScriptTask_167oslm_di" bpmnElement="preProcessSDNCUnassignRequest">
+ <dc:Bounds x="1356" y="461" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0cv258c_di" bpmnElement="callSDNCAdapterTopologyUnassign">
+ <dc:Bounds x="1517" y="461" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1gb4lqf_di" bpmnElement="postProcessSDNCUnassignRequest">
+ <dc:Bounds x="1678" y="461" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ExclusiveGateway_0b36mti_di" bpmnElement="ExclusiveGateway_0b36mti" isMarkerVisible="true">
+ <dc:Bounds x="1525" y="77" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1581" y="84" width="54" height="36" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_1y4alqc_di" bpmnElement="DoDeleteVfModuleFromVnf">
+ <dc:Bounds x="1648" y="121" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1xujrk5_di" bpmnElement="SequenceFlow_1xujrk5">
+ <di:waypoint xsi:type="dc:Point" x="1550" y="77" />
+ <di:waypoint xsi:type="dc:Point" x="1550" y="31" />
+ <di:waypoint xsi:type="dc:Point" x="1648" y="31" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1524" y="42" width="12" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1laeenc_di" bpmnElement="SequenceFlow_1laeenc">
+ <di:waypoint xsi:type="dc:Point" x="1550" y="127" />
+ <di:waypoint xsi:type="dc:Point" x="1550" y="161" />
+ <di:waypoint xsi:type="dc:Point" x="1648" y="161" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1523" y="135" width="18" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0xl033m_di" bpmnElement="SequenceFlow_0xl033m">
+ <di:waypoint xsi:type="dc:Point" x="1748" y="161" />
+ <di:waypoint xsi:type="dc:Point" x="1828" y="161" />
+ <di:waypoint xsi:type="dc:Point" x="1828" y="102" />
+ <di:waypoint xsi:type="dc:Point" x="1854" y="102" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1843" y="131.5" width="0" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>
+++ /dev/null
-/*- \r
- * ============LICENSE_START======================================================= \r
- * OPENECOMP - MSO \r
- * ================================================================================ \r
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. \r
- * ================================================================================ \r
- * Licensed under the Apache License, Version 2.0 (the "License"); \r
- * you may not use this file except in compliance with the License. \r
- * You may obtain a copy of the License at \r
- * \r
- * http://www.apache.org/licenses/LICENSE-2.0 \r
- * \r
- * Unless required by applicable law or agreed to in writing, software \r
- * distributed under the License is distributed on an "AS IS" BASIS, \r
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. \r
- * See the License for the specific language governing permissions and \r
- * limitations under the License. \r
- * ============LICENSE_END========================================================= \r
- */ \r
-\r
-package org.openecomp.mso.bpmn.infrastructure.scripts;\r
-\r
-import static org.junit.Assert.*\r
-import static org.mockito.Mockito.*\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetCloudRegion\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetwork\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutNetwork\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetworkPolicy\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetworkRouteTable\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetworkVpnBinding\r
-\r
-import org.apache.commons.lang3.*\r
-import org.camunda.bpm.engine.ProcessEngineServices\r
-import org.camunda.bpm.engine.RepositoryService\r
-import org.camunda.bpm.engine.impl.persistence.entity.ExecutionEntity\r
-import org.camunda.bpm.engine.repository.ProcessDefinition\r
-import org.camunda.bpm.engine.runtime.Execution\r
-import org.junit.Before\r
-import org.junit.Ignore;\r
-import org.junit.Rule\r
-import org.junit.Test\r
-import org.junit.runner.RunWith\r
-import org.mockito.ArgumentCaptor\r
-import org.mockito.MockitoAnnotations\r
-import org.mockito.runners.MockitoJUnitRunner\r
-import org.openecomp.mso.bpmn.common.scripts.MsoUtils\r
-import org.openecomp.mso.bpmn.core.WorkflowException\r
-\r
-import com.github.tomakehurst.wiremock.client.WireMock\r
-import com.github.tomakehurst.wiremock.junit.WireMockRule\r
-\r
-\r
-@RunWith(MockitoJUnitRunner.class)\r
-class UpdateNetworkInstanceInfraTest {\r
- \r
- @Rule\r
- public WireMockRule wireMockRule = new WireMockRule(28090);\r
- \r
- def utils = new MsoUtils()\r
-\r
- String jsonIncomingRequest =\r
- """{ "requestDetails": {\r
- "modelInfo": {\r
- "modelType": "networkTyp",\r
- "modelId": "modelId",\r
- "modelNameVersionId": "modelNameVersionId",\r
- "modelName": "CONTRAIL_EXTERNAL",\r
- "modelVersion": "1"\r
- },\r
- "cloudConfiguration": {\r
- "lcpCloudRegionId": "RDM2WAGPLCP",\r
- "tenantId": "7dd5365547234ee8937416c65507d266"\r
- },\r
- "requestInfo": {\r
- "instanceName": "MNS-25180-L-01-dmz_direct_net_1",\r
- "source": "VID",\r
- "callbackUrl": "",\r
- "suppressRollback": true,\r
- "productFamilyId": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb"\r
- },\r
- "relatedInstanceList": [ \r
- { \r
- "relatedInstance": {\r
- "instanceId": "f70e927b-6087-4974-9ef8-c5e4d5847ca4",\r
- "modelInfo": { \r
- "modelType": "serviceT",\r
- "modelId": "modelI",\r
- "modelNameVersionId": "modelNameVersionI",\r
- "modelName": "modleNam",\r
- "modelVersion": "1"\r
- }\r
- }\r
- }\r
- ],\r
- "requestParameters": {\r
- "userParams": [ \r
- {\r
- "name": "someUserParam1",\r
- "value": "someValue1"\r
- }\r
- ]\r
- }\r
- }}""" \r
- \r
- String jsonIncomingRequest_Missingname =\r
- """{ "requestDetails": {\r
- "modelInfo": {\r
- "modelType": "networkTyp",\r
- "modelId": "modelId",\r
- "modelNameVersionId": "modelNameVersionId",\r
- "modelName": "CONTRAIL_EXTERNAL",\r
- "modelVersion": "1"\r
- },\r
- "cloudConfiguration": {\r
- "lcpCloudRegionId": "RDM2WAGPLCP",\r
- "tenantId": "7dd5365547234ee8937416c65507d266"\r
- },\r
- "requestInfo": {\r
- "source": "VID",\r
- "callbackUrl": "",\r
- "suppressRollback": true,\r
- "productFamilyId": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb"\r
- },\r
- "relatedInstanceList": [ \r
- { \r
- "relatedInstance": {\r
- "instanceId": "f70e927b-6087-4974-9ef8-c5e4d5847ca4",\r
- "modelInfo": { \r
- "modelType": "serviceT",\r
- "modelId": "modelI",\r
- "modelNameVersionId": "modelNameVersionI",\r
- "modelName": "modleNam",\r
- "modelVersion": "1"\r
- }\r
- }\r
- }\r
- ],\r
- "requestParameters": {\r
- "userParams": []\r
- }\r
- }}""" \r
- \r
- String jsonIncomingRequest_MissingCloudRegion =\r
- """{ "requestDetails": {\r
- "modelInfo": {\r
- "modelType": "networkTyp",\r
- "modelId": "modelId",\r
- "modelNameVersionId": "modelNameVersionId",\r
- "modelName": "CONTRAIL_EXTERNAL",\r
- "modelVersion": "1"\r
- },\r
- "cloudConfiguration": {\r
- "tenantId": "7dd5365547234ee8937416c65507d266"\r
- },\r
- "requestInfo": {\r
- "instanceName": "MNS-25180-L-01-dmz_direct_net_1",\r
- "source": "VID",\r
- "callbackUrl": "",\r
- "suppressRollback": true,\r
- "productFamilyId": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb"\r
- },\r
- "relatedInstanceList": [ \r
- { \r
- "relatedInstance": {\r
- "instanceId": "f70e927b-6087-4974-9ef8-c5e4d5847ca4",\r
- "modelInfo": { \r
- "modelType": "serviceT",\r
- "modelId": "modelI",\r
- "modelNameVersionId": "modelNameVersionI",\r
- "modelName": "modleNam",\r
- "modelVersion": "1"\r
- }\r
- }\r
- }\r
- ],\r
- "requestParameters": {\r
- "userParams": []\r
- }\r
- }}""" \r
- \r
- \r
-\r
- String expectedNetworkRequestMissingNetworkId =\r
- """<network-request xmlns="http://www.w3.org/2001/XMLSchema"> \r
- <request-info> \r
- <request-id>88f65519-9a38-4c4b-8445-9eb4a5a5af56</request-id> \r
- <action>UPDATE</action> \r
- <source>VID</source> \r
- <service-instance-id>f70e927b-6087-4974-9ef8-c5e4d5847ca4</service-instance-id> \r
- </request-info> \r
- <network-inputs> \r
- <network-id/> \r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name> \r
- <network-type>CONTRAIL_EXTERNAL</network-type> \r
- <aic-cloud-region>RDM2WAGPLCP</aic-cloud-region> \r
- <tenant-id>7dd5365547234ee8937416c65507d266</tenant-id> \r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id> \r
- <backout-on-failure>true</backout-on-failure> \r
- </network-inputs> \r
- <network-params>\r
- <param name="some_user_param1">someValue1</param> \r
- </network-params> \r
-</network-request>\r
-"""\r
-\r
- \r
-String expectedNetworkRequestMissingCloudRegion =\r
-"""<network-request xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-info>\r
- <request-id>88f65519-9a38-4c4b-8445-9eb4a5a5af56</request-id>\r
- <action>UPDATE</action>\r
- <source>PORTAL</source>\r
- </request-info>\r
- <network-inputs>\r
- <network-name>HSL_direct_net_2</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <aic-cloud-region/>\r
- <tenant-id>e81d842d3e8b45c5a59f57cd76af3aaf</tenant-id>\r
- </network-inputs>\r
- <network-params>\r
- <param name="shared">1</param>\r
- </network-params>\r
-</network-request>"""\r
-\r
- // vnfRESTRequest\r
- String networkRESTRequest =\r
-"""<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- xmlns:vnfreq="http://org.openecomp/mso/infra/vnf-request/v1"\r
- statusCode="200">\r
- <rest:payload contentType="text/xml">\r
- <vnfreq:network-request>\r
- <vnfreq:request-info>\r
- <vnfreq:request-id>1ef47428-cade-45bd-a103-0751e8b2deb0</vnfreq:request-id>\r
- <vnfreq:action>UPDATE</vnfreq:action>\r
- <vnfreq:source>PORTAL</vnfreq:source>\r
- </vnfreq:request-info>\r
- <vnfreq:network-inputs>\r
- <vnfreq:network-name>MNS-25180-L-01-dmz_direct_net_1</vnfreq:network-name>\r
- <vnfreq:network-type>CONTRAIL_EXTERNAL</vnfreq:network-type>\r
- <vnfreq:service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</vnfreq:service-id>\r
- <vnfreq:aic-cloud-region>RDM2WAGPLCP</vnfreq:aic-cloud-region>\r
- <vnfreq:tenant-id>7dd5365547234ee8937416c65507d266</vnfreq:tenant-id>\r
- <vnfreq:physicalNetworkName>dvs-slcp3-01</vnfreq:physicalNetworkName>\r
- <vnfreq:vlans>3008</vnfreq:vlans>\r
- </vnfreq:network-inputs>\r
- <vnfreq:network-params>\r
- <param name="shared">1</param>\r
- <param name="external">0</param>\r
- </vnfreq:network-params>\r
- </vnfreq:network-request>\r
- </rest:payload>\r
- </rest:RESTResponse>"""\r
-\r
- String networkInputsMissingName =\r
- """<network-inputs xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <network-name/>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <aic-cloud-region>RDM2WAGPLCP</aic-cloud-region>\r
- <tenant-id>e81d842d3e8b45c5a59f57cd76af3aaf</tenant-id>\r
- </network-inputs>"""\r
-\r
-String networkInputsMissingCloudRegion =\r
-"""<network-inputs xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <network-name>HSL_direct_net_2</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <aic-cloud-region/>\r
- <tenant-id>e81d842d3e8b45c5a59f57cd76af3aaf</tenant-id>\r
-</network-inputs>"""\r
- \r
- String expectedUpdateNetworkInstanceInfraRequest =\r
- """<rest:payload xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- xmlns:vnfreq="http://org.openecomp/mso/infra/vnf-request/v1"\r
- contentType="text/xml">\r
- <vnfreq:network-request>\r
- <vnfreq:request-info>\r
- <vnfreq:request-id>1ef47428-cade-45bd-a103-0751e8b2deb0</vnfreq:request-id>\r
- <vnfreq:action>UPDATE</vnfreq:action>\r
- <vnfreq:source>PORTAL</vnfreq:source>\r
- </vnfreq:request-info>\r
- <vnfreq:network-inputs>\r
- <vnfreq:network-name>MNS-25180-L-01-dmz_direct_net_1</vnfreq:network-name>\r
- <vnfreq:network-type>CONTRAIL_EXTERNAL</vnfreq:network-type>\r
- <vnfreq:service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</vnfreq:service-id>\r
- <vnfreq:aic-cloud-region>RDM2WAGPLCP</vnfreq:aic-cloud-region>\r
- <vnfreq:tenant-id>7dd5365547234ee8937416c65507d266</vnfreq:tenant-id>\r
- <vnfreq:physicalNetworkName>dvs-slcp3-01</vnfreq:physicalNetworkName>\r
- <vnfreq:vlans>3008</vnfreq:vlans>\r
- </vnfreq:network-inputs>\r
- <vnfreq:network-params>\r
- <param name="shared">1</param>\r
- <param name="external">0</param>\r
- </vnfreq:network-params>\r
- </vnfreq:network-request>\r
-</rest:payload>"""\r
- \r
- String expectedUpdateNetworkInstanceInfraRequest_Output =\r
- """<rest:payload xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- xmlns:vnfreq="http://org.openecomp/mso/infra/vnf-request/v1"\r
- contentType="text/xml">\r
- <vnfreq:network-request>\r
- <vnfreq:request-info>\r
- <vnfreq:request-id>1ef47428-cade-45bd-a103-0751e8b2deb0</vnfreq:request-id>\r
- <vnfreq:action>UPDATE</vnfreq:action>\r
- <vnfreq:source>PORTAL</vnfreq:source>\r
- </vnfreq:request-info>\r
- <vnfreq:network-inputs>\r
- <vnfreq:network-name>MNS-25180-L-01-dmz_direct_net_1</vnfreq:network-name>\r
- <vnfreq:network-type>CONTRAIL_EXTERNAL</vnfreq:network-type>\r
- <vnfreq:service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</vnfreq:service-id>\r
- <vnfreq:aic-cloud-region>RDM2WAGPLCP</vnfreq:aic-cloud-region>\r
- <vnfreq:tenant-id>7dd5365547234ee8937416c65507d266</vnfreq:tenant-id>\r
- </vnfreq:network-inputs>\r
- <vnfreq:network-outputs>\r
- <vnfreq:network-name>MNS-25180-L-01-dmz_direct_net_1</vnfreq:network-name>\r
- <vnfreq:network-id>bdc5efe8-404a-409b-85f6-0dcc9eebae30</vnfreq:network-id>\r
- </vnfreq:network-outputs>\r
- <vnfreq:network-params>\r
- <param name="shared">1</param>\r
- <param name="external">0</param>\r
- </vnfreq:network-params>\r
- </vnfreq:network-request>\r
-</rest:payload>"""\r
- \r
- // expectedNetworkRequest\r
- String expectedNetworkRequest =\r
- """<network-request xmlns="http://www.w3.org/2001/XMLSchema"> \r
- <request-info> \r
- <action>UPDATE</action> \r
- <source>VID</source> \r
- <service-instance-id>f70e927b-6087-4974-9ef8-c5e4d5847ca4</service-instance-id> \r
- </request-info> \r
- <network-inputs> \r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id> \r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name> \r
- <network-type>CONTRAIL_EXTERNAL</network-type> \r
- <aic-cloud-region>RDM2WAGPLCP</aic-cloud-region> \r
- <tenant-id>7dd5365547234ee8937416c65507d266</tenant-id> \r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id> \r
- <backout-on-failure>true</backout-on-failure> \r
- </network-inputs>\r
- <network-params>\r
- <param name="dhcp-enabled">true</param>\r
- <param name="serviceId">a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</param>\r
- <param name="cidr-mask">true</param>\r
- <param name="backoutOnFailure">true</param>\r
- <param name="gateway-address">10.10.125.1</param>\r
- </network-params> \r
-</network-request>"""\r
- \r
-String expectedNetworkInputs =\r
-"""<network-inputs xmlns="http://www.w3.org/2001/XMLSchema">\r
- <network-id/>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <aic-cloud-region>RDM2WAGPLCP</aic-cloud-region>\r
- <tenant-id>7dd5365547234ee8937416c65507d266</tenant-id>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <backout-on-failure>true</backout-on-failure>\r
-</network-inputs>"""\r
-\r
- \r
- String NetworkRequest_noPhysicalName =\r
- """<vnfreq:network-request xmlns:vnfreq="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <vnfreq:request-info>\r
- <vnfreq:request-id>1ef47428-cade-45bd-a103-0751e8b2deb0</vnfreq:request-id>\r
- <vnfreq:action>UPDATE</vnfreq:action>\r
- <vnfreq:source>PORTAL</vnfreq:source>\r
- </vnfreq:request-info>\r
- <vnfreq:network-inputs>\r
- <vnfreq:network-name>MNS-25180-L-01-dmz_direct_net_1</vnfreq:network-name>\r
- <vnfreq:network-type>CONTRAIL_EXTERNAL</vnfreq:network-type>\r
- <vnfreq:service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</vnfreq:service-id>\r
- <vnfreq:aic-cloud-region>RDM2WAGPLCP</vnfreq:aic-cloud-region>\r
- <vnfreq:tenant-id>7dd5365547234ee8937416c65507d266</vnfreq:tenant-id>\r
- <vnfreq:vlans>3008</vnfreq:vlans>\r
- </vnfreq:network-inputs>\r
- <vnfreq:network-params>\r
- <network-params>\r
- <param name="dhcp-enabled">true</param>\r
- <param name="serviceId">a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</param>\r
- <param name="cidr-mask">true</param>\r
- <param name="backoutOnFailure">true</param>\r
- <param name="gateway-address">10.10.125.1</param>\r
- </network-params> \r
- </vnfreq:network-params>\r
-</vnfreq:network-request>"""\r
- \r
- String vnfRequestFakeRegion =\r
- """<vnfreq:network-request xmlns:vnfreq="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <vnfreq:request-info>\r
- <vnfreq:request-id>1ef47428-cade-45bd-a103-0751e8b2deb0</vnfreq:request-id>\r
- <vnfreq:action>UPDATE</vnfreq:action>\r
- <vnfreq:source>PORTAL</vnfreq:source>\r
- </vnfreq:request-info>\r
- <vnfreq:network-inputs>\r
- <vnfreq:network-name>MNS-25180-L-01-dmz_direct_net_1</vnfreq:network-name>\r
- <vnfreq:network-type>CONTRAIL_EXTERNAL</vnfreq:network-type>\r
- <vnfreq:service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</vnfreq:service-id>\r
- <vnfreq:aic-cloud-region>MDTWNJ21</vnfreq:aic-cloud-region>\r
- <vnfreq:tenant-id>7dd5365547234ee8937416c65507d266</vnfreq:tenant-id>\r
- </vnfreq:network-inputs>\r
- <vnfreq:network-params>\r
- <param name="shared">1</param>\r
- <param name="external">0</param>\r
- </vnfreq:network-params>\r
-</vnfreq:network-request>"""\r
- \r
- // expectedNetworkRequest\r
- String expectedNetworkRequest_Outputs =\r
- """<vnfreq:network-request xmlns:vnfreq="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <vnfreq:request-info>\r
- <vnfreq:request-id>1ef47428-cade-45bd-a103-0751e8b2deb0</vnfreq:request-id>\r
- <vnfreq:action>UPDATE</vnfreq:action>\r
- <vnfreq:source>PORTAL</vnfreq:source>\r
- </vnfreq:request-info>\r
- <vnfreq:network-inputs>\r
- <vnfreq:network-name>MNS-25180-L-01-dmz_direct_net_1</vnfreq:network-name>\r
- <vnfreq:network-type>CONTRAIL_EXTERNAL</vnfreq:network-type>\r
- <vnfreq:service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</vnfreq:service-id>\r
- <vnfreq:aic-cloud-region>RDM2WAGPLCP</vnfreq:aic-cloud-region>\r
- <vnfreq:tenant-id>7dd5365547234ee8937416c65507d266</vnfreq:tenant-id>\r
- </vnfreq:network-inputs>\r
- <vnfreq:network-outputs>\r
- <vnfreq:network-name>MNS-25180-L-01-dmz_direct_net_1</vnfreq:network-name>\r
- <vnfreq:network-id>bdc5efe8-404a-409b-85f6-0dcc9eebae30</vnfreq:network-id>\r
- </vnfreq:network-outputs>\r
- <vnfreq:network-params>\r
- <param name="shared">1</param>\r
- <param name="external">0</param>\r
- </vnfreq:network-params>\r
-</vnfreq:network-request>"""\r
- \r
- \r
- // expectedNetworkRequest\r
- String networkInputs_404 =\r
- """<network-inputs xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <network-name>myOwn_Network</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <aic-cloud-region>RDM2WAGPLCP</aic-cloud-region>\r
- <tenant-id>e81d842d3e8b45c5a59f57cd76af3aaf</tenant-id>\r
- </network-inputs>"""\r
- \r
- String networkInputs =\r
- """<network-inputs xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <network-id>bdc5efe8-404a-409b-85f6-0dcc9eebae30</network-id>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <aic-cloud-region>RDM2WAGPLCP</aic-cloud-region>\r
- <tenant-id>e81d842d3e8b45c5a59f57cd76af3aaf</tenant-id>\r
-</network-inputs>"""\r
- \r
- String networkOutputs =\r
- """<network-outputs>\r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id> \r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- </network-outputs>"""\r
-\r
- String queryAAIResponse =\r
- """<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- statusCode="200">\r
- <rest:headers>\r
- <rest:header name="Transfer-Encoding" value="chunked"/>\r
- <rest:header name="Date" value="Thu,10 Mar 2016 00:01:18 GMT"/>\r
- <rest:header name="Expires" value="Thu,01 Jan 1970 00:00:00 UTC"/>\r
- <rest:header name="X-AAI-TXID" value="mtcnjv9aaas03-20160310-00:01:18:502-132671"/>\r
- <rest:header name="Content-Type" value="application/xml"/>\r
- <rest:header name="Server" value="Apache-Coyote/1.1"/>\r
- <rest:header name="Cache-Control" value="private"/>\r
- </rest:headers>\r
- <rest:payload contentType="text/xml">\r
- <l3-network xmlns="http://org.openecomp.aai.inventory/v3">\r
- <network-id>bdc5efe8-404a-409b-85f6-0dcc9eebae30</network-id>\r
- <network-name>HSL_direct_net_2</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <network-role>dmz_direct</network-role>\r
- <network-technology>contrail</network-technology>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <network-role-instance>0</network-role-instance>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <subnets>\r
- <subnet>\r
- <subnet-id>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</subnet-id>\r
- <gateway-address>107.239.52.1</gateway-address>\r
- <network-start-address>107.239.52.0</network-start-address>\r
- <cidr-mask>24</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <relationship-list/>\r
- </subnet>\r
- </subnets>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>85f015d0-2e32-4c30-96d2-87a1a27f8017</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/c980a6ef-3b88-49f0-9751-dbad8608d0a6/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>c980a6ef-3b88-49f0-9751-dbad8608d0a6</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>tenant</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/cloud-infrastructure/tenants/tenant/7dd5365547234ee8937416c65507d266/</related-link>\r
- <relationship-data>\r
- <relationship-key>tenant.tenant-id</relationship-key>\r
- <relationship-value>7dd5365547234ee8937416c65507d266</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- </relationship-list>\r
- </l3-network>\r
- </rest:payload>\r
-</rest:RESTResponse>"""\r
- \r
- String queryIdAIIResponse =\r
- """<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- statusCode="200">\r
- <rest:headers>\r
- <rest:header name="Transfer-Encoding" value="chunked"/>\r
- <rest:header name="Date" value="Thu,10 Mar 2016 00:01:18 GMT"/>\r
- <rest:header name="Expires" value="Thu,01 Jan 1970 00:00:00 UTC"/>\r
- <rest:header name="X-AAI-TXID" value="mtcnjv9aaas03-20160310-00:01:18:502-132671"/>\r
- <rest:header name="Content-Type" value="application/xml"/>\r
- <rest:header name="Server" value="Apache-Coyote/1.1"/>\r
- <rest:header name="Cache-Control" value="private"/>\r
- </rest:headers>\r
- <rest:payload contentType="text/xml">\r
- <l3-network xmlns="http://org.openecomp.aai.inventory/v6">\r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <network-role>dmz_direct</network-role>\r
- <network-technology>contrail</network-technology>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <network-role-instance>0</network-role-instance>\r
- <resource-version>l3-version</resource-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <heat-stack-id>ST_2Bindings_6006/55288ef0-595c-47d3-819e-cf93aaac6326</heat-stack-id>\r
- <physical-network-name>networkName</physical-network-name>\r
- <is-provider-network>false</is-provider-network>\r
- <is-shared-network>true</is-shared-network>\r
- <is-external-network>false</is-external-network>\r
- <subnets>\r
- <subnet>\r
- <subnet-id>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</subnet-id>\r
- <gateway-address>107.239.52.1</gateway-address>\r
- <network-start-address>107.239.52.0</network-start-address>\r
- <cidr-mask>24</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <subnet-name>subnetName</subnet-name>\r
- <relationship-list/>\r
- </subnet>\r
- <subnet>\r
- <subnet-id>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</subnet-id>\r
- <gateway-address>107.239.52.1</gateway-address>\r
- <network-start-address>107.239.52.0</network-start-address>\r
- <cidr-mask>24</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <subnet-name>subnetName</subnet-name>\r
- <relationship-list/>\r
- </subnet>\r
- </subnets>\r
- <segmentation-assignments>\r
- <segmentation-id>414</segmentation-id>\r
- <resource-version>4132176</resource-version>\r
- </segmentation-assignments> \r
- <segmentation-assignments>\r
- <segmentation-id>415</segmentation-id>\r
- <resource-version>4132176</resource-version>\r
- </segmentation-assignments> \r
- <ctag-assignments> \r
- <ctag-assignment> \r
- <vlan-id-inner>inner</vlan-id-inner> \r
- <resource-version>ctag-version</resource-version> \r
- <relationship-list>\r
- <relationship>\r
- <related-to>tenant</related-to>\r
- <related-link>https://aai-ext1.test.com:8443/aai/v8/cloud-infrastructure/tenants/tenant/897deadc2b954a6bac6d3c197fb3525e/</related-link>\r
- <relationship-data>\r
- <relationship-key>tenant.tenant-id</relationship-key>\r
- <relationship-value>897deadc2b954a6bac6d3c197fb3525e</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>tenant.tenant-name</property-key>\r
- <property-value>MSOTest1</property-value>\r
- </related-to-property>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-ext1.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/a290b841-f672-44dd-b9cd-6f8c20d7d8c8/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>a290b841-f672-44dd-b9cd-6f8c20d7d8c8</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>vpn-binding.vpn-name</property-key>\r
- <property-value>oam_protected_net_6_MTN5_msotest2</property-value>\r
- </related-to-property>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-ext1.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/24a4b507-853a-4a38-99aa-05fcc54be24d/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>24a4b507-853a-4a38-99aa-05fcc54be24d</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>vpn-binding.vpn-name</property-key>\r
- <property-value>oam_protected_net_6_MTN5_msotest1</property-value>\r
- </related-to-property>\r
- </relationship>\r
- </relationship-list> \r
- </ctag-assignment> \r
- </ctag-assignments>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>85f015d0-2e32-4c30-96d2-87a1a27f8017</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/c980a6ef-3b88-49f0-9751-dbad8608d0a6/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>c980a6ef-3b88-49f0-9751-dbad8608d0a6</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>tenant</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/cloud-infrastructure/tenants/tenant/7dd5365547234ee8937416c65507d266/</related-link>\r
- <relationship-data>\r
- <relationship-key>tenant.tenant-id</relationship-key>\r
- <relationship-value>7dd5365547234ee8937416c65507d266</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>network-policy</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/network-policies/network-policy/cee6d136-e378-4678-a024-2cd15f0ee0cg</related-link>\r
- <relationship-data>\r
- <relationship-key>network-policy.network-policy-id</relationship-key>\r
- <relationship-value>cee6d136-e378-4678-a024-2cd15f0ee0cg</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>route-table-reference</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/route-table-references/route-table-reference/refFQDN1</related-link>\r
- <relationship-data>\r
- <relationship-key>route-table-reference.route-table-reference-id</relationship-key>\r
- <relationship-value>cee6d136-e378-4678-a024-2cd15f0ee0hi</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>route-table-reference</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/route-table-references/route-table-reference/refFQDN2</related-link>\r
- <relationship-data>\r
- <relationship-key>route-table-reference.route-table-reference-id</relationship-key>\r
- <relationship-value>cee6d136-e378-4678-a024-2cd15f0ee0hi</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- </relationship-list>\r
- </l3-network>\r
- </rest:payload>\r
-</rest:RESTResponse>"""\r
- \r
- String queryIdAIIResponseTestScenario01 =\r
- """<?xml version="1.0" encoding="UTF-8"?>\r
-<l3-network xmlns="http://org.openecomp.aai.inventory/v7">\r
- <network-id>4da55fe4-7a9e-478c-a434-8a98d62265ab</network-id>\r
- <network-name>GN_EVPN_direct_net_0_ST1</network-name>\r
- <network-type>CONTRAIL30_BASIC</network-type>\r
- <network-role>GN_EVPN_direct</network-role>\r
- <network-technology>contrail</network-technology>\r
- <is-bound-to-vpn>false</is-bound-to-vpn>\r
- <service-id>9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <network-role-instance>0</network-role-instance>\r
- <resource-version>1465398611</resource-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <physical-network-name>networkName</physical-network-name>\r
- <is-provider-network>false</is-provider-network>\r
- <is-shared-network>true</is-shared-network>\r
- <is-external-network>false</is-external-network>\r
- <subnets>\r
- <subnet>\r
- <subnet-id>cb1a7b47-5428-44c9-89c2-8b17541c3228</subnet-id>\r
- <gateway-address>108.239.40.1</gateway-address>\r
- <network-start-address>108.239.40.0</network-start-address>\r
- <cidr-mask>28</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <dhcp-start>108.239.40.0</dhcp-start>\r
- <dhcp-end>108.239.40.0</dhcp-end>\r
- <resource-version>1465398611</resource-version>\r
- <subnet-name>subnetName</subnet-name>\r
- <relationship-list />\r
- </subnet>\r
- <subnet>\r
- <subnet-id>e2cc7c14-90f0-4205-840d-b4e07f04e621</subnet-id>\r
- <gateway-address>2606:ae00:2e01:604::1</gateway-address>\r
- <network-start-address>2606:ae00:2e01:604::</network-start-address>\r
- <cidr-mask>64</cidr-mask>\r
- <ip-version>6</ip-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <dhcp-start>2606:ae00:2e01:604::</dhcp-start>\r
- <dhcp-end>2606:ae00:2e01:604::</dhcp-end>\r
- <resource-version>1465398611</resource-version>\r
- <subnet-name>subnetName</subnet-name>\r
- <relationship-list />\r
- </subnet>\r
- </subnets>\r
- <ctag-assignments />\r
- <segmentation-assignments>\r
- <segmentation-id>416</segmentation-id>\r
- <resource-version>4132176</resource-version>\r
- </segmentation-assignments>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>cloud-region</related-to>\r
- <related-link>https://mtanjv9aaas03.aic.cip.com:8443/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic/AAIAIC25/\r
- </related-link>\r
- <relationship-data>\r
- <relationship-key>cloud-region.cloud-region-id</relationship-key>\r
- <relationship-value>AAIAIC25</relationship-value>\r
- </relationship-data>\r
- <relationship-data>\r
- <relationship-key>cloud-region.cloud-owner</relationship-key>\r
- <relationship-value>att-aic</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>cloud-region.owner-defined-type</property-key>\r
- <property-value></property-value>\r
- </related-to-property>\r
- </relationship>\r
- <relationship>\r
- <related-to>tenant</related-to>\r
- <related-link>https://mtanjv9aaas03.aic.cip.com:8443/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic/AAIAIC25/tenants/tenant/4ae1d3446a4c48b2bec44b6cfba06d68/</related-link>\r
- <relationship-data>\r
- <relationship-key>tenant.tenant-id</relationship-key>\r
- <relationship-value>4ae1d3446a4c48b2bec44b6cfba06d68\r
- </relationship-value>\r
- </relationship-data>\r
- <relationship-data>\r
- <relationship-key>cloud-region.cloud-owner</relationship-key>\r
- <relationship-value>att-aic</relationship-value>\r
- </relationship-data>\r
- <relationship-data>\r
- <relationship-key>cloud-region.cloud-region-id</relationship-key>\r
- <relationship-value>AAIAIC25</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>tenant.tenant-name</property-key>\r
- <property-value>Ruchira Contrail 3.0 test</property-value>\r
- </related-to-property>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://mtanjv9aaas03.aic.cip.com:8443/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>9a7b327d9-287aa00-82c4b0-100001</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>vpn-binding.vpn-name</property-key>\r
- <property-value>GN_EVPN_direct_net_0_ST1</property-value>\r
- </related-to-property>\r
- </relationship>\r
- <relationship>\r
- <related-to>route-table-reference</related-to>\r
- <relationship-data>\r
- <relationship-key>route-table-reference.route-table-reference-id</relationship-key>\r
- <relationship-value>cee6d136-e378-4678-a024-2cd15f0ee0hi</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- </relationship-list>\r
-</l3-network>""" \r
- \r
- String queryIdAIIResponseVpnNotPresent =\r
- """<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- statusCode="200">\r
- <rest:headers>\r
- <rest:header name="Transfer-Encoding" value="chunked"/>\r
- <rest:header name="Date" value="Thu,10 Mar 2016 00:01:18 GMT"/>\r
- <rest:header name="Expires" value="Thu,01 Jan 1970 00:00:00 UTC"/>\r
- <rest:header name="X-AAI-TXID" value="mtcnjv9aaas03-20160310-00:01:18:502-132671"/>\r
- <rest:header name="Content-Type" value="application/xml"/>\r
- <rest:header name="Server" value="Apache-Coyote/1.1"/>\r
- <rest:header name="Cache-Control" value="private"/>\r
- </rest:headers>\r
- <rest:payload contentType="text/xml">\r
- <l3-network xmlns="http://org.openecomp.aai.inventory/v6">\r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <network-role>dmz_direct</network-role>\r
- <network-technology>contrail</network-technology>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <network-role-instance>0</network-role-instance>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <physical-network-name>networkName</physical-network-name>\r
- <is-provider-network>false</is-provider-network>\r
- <is-shared-network>true</is-shared-network>\r
- <is-external-network>false</is-external-network>\r
- <subnets>\r
- <subnet>\r
- <subnet-id>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</subnet-id>\r
- <gateway-address>107.239.52.1</gateway-address>\r
- <network-start-address>107.239.52.0</network-start-address>\r
- <cidr-mask>24</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <subnet-name>subnetName</subnet-name>\r
- <relationship-list/>\r
- </subnet>\r
- </subnets>\r
- <relationship-list/>\r
- </l3-network>\r
- </rest:payload>\r
-</rest:RESTResponse>"""\r
- \r
- String queryNameAIIResponse =\r
- """<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- statusCode="200">\r
- <rest:headers>\r
- <rest:header name="Transfer-Encoding" value="chunked"/>\r
- <rest:header name="Date" value="Thu,10 Mar 2016 00:01:18 GMT"/>\r
- <rest:header name="Expires" value="Thu,01 Jan 1970 00:00:00 UTC"/>\r
- <rest:header name="X-AAI-TXID" value="mtcnjv9aaas03-20160310-00:01:18:502-132671"/>\r
- <rest:header name="Content-Type" value="application/xml"/>\r
- <rest:header name="Server" value="Apache-Coyote/1.1"/>\r
- <rest:header name="Cache-Control" value="private"/>\r
- </rest:headers>\r
- <rest:payload contentType="text/xml">\r
- <l3-network xmlns="http://org.openecomp.aai.inventory/v6">\r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <network-role>dmz_direct</network-role>\r
- <network-technology>contrail</network-technology>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <network-role-instance>0</network-role-instance>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <subnets>\r
- <subnet>\r
- <subnet-id>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</subnet-id>\r
- <gateway-address>107.239.52.1</gateway-address>\r
- <network-start-address>107.239.52.0</network-start-address>\r
- <cidr-mask>24</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <relationship-list/>\r
- </subnet>\r
- </subnets>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>85f015d0-2e32-4c30-96d2-87a1a27f8017</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/c980a6ef-3b88-49f0-9751-dbad8608d0a6/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>c980a6ef-3b88-49f0-9751-dbad8608d0a6</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>tenant</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/cloud-infrastructure/tenants/tenant/7dd5365547234ee8937416c65507d266/</related-link>\r
- <relationship-data>\r
- <relationship-key>tenant.tenant-id</relationship-key>\r
- <relationship-value>7dd5365547234ee8937416c65507d266</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- </relationship-list>\r
- </l3-network>\r
- </rest:payload>\r
- </rest:RESTResponse>"""\r
- \r
- String queryNameAIIResponseVpnNotPresent =\r
- """<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- statusCode="200">\r
- <rest:headers>\r
- <rest:header name="Transfer-Encoding" value="chunked"/>\r
- <rest:header name="Date" value="Thu,10 Mar 2016 00:01:18 GMT"/>\r
- <rest:header name="Expires" value="Thu,01 Jan 1970 00:00:00 UTC"/>\r
- <rest:header name="X-AAI-TXID" value="mtcnjv9aaas03-20160310-00:01:18:502-132671"/>\r
- <rest:header name="Content-Type" value="application/xml"/>\r
- <rest:header name="Server" value="Apache-Coyote/1.1"/>\r
- <rest:header name="Cache-Control" value="private"/>\r
- </rest:headers>\r
- <rest:payload contentType="text/xml">\r
- <l3-network xmlns="http://org.openecomp.aai.inventory/v6>\r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <network-role>dmz_direct</network-role>\r
- <network-technology>contrail</network-technology>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <network-role-instance>0</network-role-instance>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <subnets>\r
- <subnet>\r
- <subnet-id>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</subnet-id>\r
- <gateway-address>107.239.52.1</gateway-address>\r
- <network-start-address>107.239.52.0</network-start-address>\r
- <cidr-mask>24</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>pending-delete</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <relationship-list/>\r
- </subnet>\r
- </subnets>\r
- </l3-network>\r
- </rest:payload>\r
- </rest:RESTResponse>"""\r
- \r
- String aaiVpnResponseStub =\r
- """<rest:payload xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- xmlns="http://org.openecomp.aai.inventory/v8"\r
- contentType="text/xml">\r
- <vpn-binding>\r
- <global-route-target/>\r
- </vpn-binding>\r
-</rest:payload>""" \r
- \r
- String queryVpnBindingAAIResponse =\r
- """<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- statusCode="200">\r
- <rest:headers>\r
- <rest:header name="Transfer-Encoding" value="chunked"/>\r
- <rest:header name="Date" value="Mon,14 Mar 2016 20:53:33 GMT"/>\r
- <rest:header name="Expires" value="Thu,01 Jan 1970 00:00:00 UTC"/>\r
- <rest:header name="X-AAI-TXID"\r
- value="mtcnjv9aaas01.mtcnj.aic.cip.com-20160314-20:53:33:487-134392"/>\r
- <rest:header name="Content-Type" value="application/xml"/>\r
- <rest:header name="Server" value="Apache-Coyote/1.1"/>\r
- <rest:header name="Cache-Control" value="private"/>\r
- </rest:headers>\r
- <rest:payload contentType="text/xml">\r
- <vpn-binding xmlns="http://org.openecomp.aai.inventory/v6">\r
- <vpn-id>9a7b327d9-287aa00-82c4b0-105757</vpn-id>\r
- <vpn-name>GN_EVPN_Test</vpn-name>\r
- <global-route-target>13979:105757</global-route-target>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>l3-network</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v3/network/l3-networks/l3-network/689ec39e-c5fc-4462-8db2-4f760763ad28/</related-link>\r
- <relationship-data>\r
- <relationship-key>l3-network.network-id</relationship-key>\r
- <relationship-value>689ec39e-c5fc-4462-8db2-4f760763ad28</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>l3-network</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v3/network/l3-networks/l3-network/1a49396b-19b3-40a4-8792-aa2fbd0f0704/</related-link>\r
- <relationship-data>\r
- <relationship-key>l3-network.network-id</relationship-key>\r
- <relationship-value>1a49396b-19b3-40a4-8792-aa2fbd0f0704</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>l3-network</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v3/network/l3-networks/l3-network/774f3329-3c83-4771-86c7-9e6207cd50fd/</related-link>\r
- <relationship-data>\r
- <relationship-key>l3-network.network-id</relationship-key>\r
- <relationship-value>774f3329-3c83-4771-86c7-9e6207cd50fd</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- </relationship-list>\r
- </vpn-binding>\r
- </rest:payload>\r
-</rest:RESTResponse>"""\r
- \r
- String updateDBRequest_Active =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"\r
- xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
- <ns:updateInfraRequest>\r
- <requestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>Network MNS-25180-L-01-dmz_direct_net_1 already exists. Silent success.</statusMessage>\r
- <responseBody/>\r
- <requestStatus>COMPLETED</requestStatus>\r
- <progress>100</progress>\r
- <vnfOutputs><network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id><network-name>MNS-25180-L-01-dmz_direct_net_1</network-names></vnfOutputs>\r
- <networkId>49c86598-f766-46f8-84f8-8d1c1b10f9b4</networkId>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
-</soapenv:Envelope>"""\r
- \r
- String updateDBRequest =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"\r
- xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
- <ns:updateInfraRequest>\r
- <requestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>Network successfully updated.</statusMessage>\r
- <responseBody/>\r
- <requestStatus>COMPLETED</requestStatus>\r
- <progress>100</progress>\r
- <vnfOutputs><network-id></network-id><network-name></network-names></vnfOutputs>\r
- <networkId/>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
-</soapenv:Envelope>""" \r
- \r
- String updateDBRequestError =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
- <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <requestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>Received error from SDN-C: No availability zone available</statusMessage>\r
- <responseBody></responseBody>\r
- <requestStatus>FAILED</requestStatus>\r
- <vnfOutputs><network-id></network-id><network-name></network-names></vnfOutputs>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
- </soapenv:Envelope>"""\r
- \r
- String updateDBRequestError01 =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
- <ns:updateInfraRequest xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <requestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>Received error unexpectedly from SDN-C.</statusMessage>\r
- <responseBody></responseBody>\r
- <requestStatus>FAILED</requestStatus>\r
- <vnfOutputs><network-id></network-id><network-name></network-names></vnfOutputs>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
- </soapenv:Envelope>"""\r
- \r
- String updateDBRequest_Outputs =\r
- """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"\r
- xmlns:ns="http://org.openecomp.mso/requestsdb">\r
- <soapenv:Header/>\r
- <soapenv:Body>\r
- <ns:updateInfraRequest>\r
- <requestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</requestId>\r
- <lastModifiedBy>BPMN</lastModifiedBy>\r
- <statusMessage>Network successfully updated.</statusMessage>\r
- <responseBody/>\r
- <requestStatus>COMPLETED</requestStatus>\r
- <progress>100</progress>\r
- <vnfOutputs><network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id><network-name>MNS-25180-L-01-dmz_direct_net_1</network-names></vnfOutputs>\r
- <networkId>49c86598-f766-46f8-84f8-8d1c1b10f9b4</networkId>\r
- </ns:updateInfraRequest>\r
- </soapenv:Body>\r
-</soapenv:Envelope>""" \r
- \r
- String updateNetworkRequest =\r
- """<updateNetworkRequest>\r
- <cloudSiteId>RDM2WAGPLCP</cloudSiteId>\r
- <tenantId>7dd5365547234ee8937416c65507d266</tenantId>\r
- <networkId>49c86598-f766-46f8-84f8-8d1c1b10f9b4</networkId>\r
- <networkStackId>ST_2Bindings_6006/55288ef0-595c-47d3-819e-cf93aaac6326</networkStackId>\r
- <networkName>MNS-25180-L-01-dmz_direct_net_1</networkName>\r
- <networkType>CONTRAIL_EXTERNAL</networkType>\r
- <modelCustomizationUuid/>\r
- <networkTypeVersion/>\r
- <networkTechnology>CONTRAIL</networkTechnology>\r
- <providerVlanNetwork>\r
- <physicalNetworkName>networkName</physicalNetworkName>\r
- <vlans>414,415</vlans>\r
- </providerVlanNetwork>\r
- <contrailNetwork>\r
- <shared>true</shared>\r
- <external>false</external>\r
- <routeTargets>13979:105757</routeTargets>\r
- <routeTargets>13979:105757</routeTargets>\r
- <policyFqdns>GN_EVPN_Test</policyFqdns>\r
- <routeTableFqdns>refFQDN1</routeTableFqdns>\r
- <routeTableFqdns>refFQDN2</routeTableFqdns>\r
- </contrailNetwork>\r
- <skipAAI>true</skipAAI>\r
- <backout>true</backout>\r
- <failIfExists>false</failIfExists>\r
- <networkParams>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <serviceId>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</serviceId>\r
- <cidr-mask>true</cidr-mask>\r
- <backoutOnFailure>true</backoutOnFailure>\r
- <gateway-address>10.10.125.1</gateway-address>\r
- </networkParams>\r
- <msoRequest>\r
- <requestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</requestId>\r
- <serviceInstanceId>f70e927b-6087-4974-9ef8-c5e4d5847ca4</serviceInstanceId>\r
- </msoRequest>\r
- <messageId>messageId_generated</messageId>\r
- <notificationUrl/>\r
-</updateNetworkRequest>"""\r
- \r
- \r
- String updateNetworkRequest_noPhysicalName =\r
- """<updateNetworkRequest>\r
- <cloudSiteId>RDM2WAGPLCP</cloudSiteId>\r
- <tenantId>7dd5365547234ee8937416c65507d266</tenantId>\r
- <networkId>49c86598-f766-46f8-84f8-8d1c1b10f9b4</networkId>\r
- <networkStackId>ST_2Bindings_6006/55288ef0-595c-47d3-819e-cf93aaac6326</networkStackId>\r
- <networkName>MNS-25180-L-01-dmz_direct_net_1</networkName>\r
- <networkType>CONTRAIL_EXTERNAL</networkType>\r
- <modelCustomizationUuid/>\r
- <networkTypeVersion/>\r
- <networkTechnology>CONTRAIL</networkTechnology>\r
- <providerVlanNetwork>\r
- <physicalNetworkName>networkName</physicalNetworkName>\r
- <vlans>414,415</vlans>\r
- </providerVlanNetwork>\r
- <contrailNetwork>\r
- <shared>true</shared>\r
- <external>false</external>\r
- <routeTargets>13979:105757</routeTargets>\r
- <routeTargets>13979:105757</routeTargets>\r
- <policyFqdns>GN_EVPN_Test</policyFqdns>\r
- </contrailNetwork>\r
- <skipAAI>true</skipAAI>\r
- <backout>true</backout>\r
- <failIfExists>false</failIfExists>\r
- <networkParams>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <serviceId>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</serviceId>\r
- <cidr-mask>true</cidr-mask>\r
- <backoutOnFailure>true</backoutOnFailure>\r
- <gateway-address>10.10.125.1</gateway-address>\r
- </networkParams>\r
- <msoRequest>\r
- <requestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</requestId>\r
- <serviceInstanceId>null</serviceInstanceId>\r
- </msoRequest>\r
- <messageId>messageId_generated</messageId>\r
- <notificationUrl/>\r
-</updateNetworkRequest>"""\r
- \r
- String updateNetworkResponseREST =\r
- """<ns2:updateNetworkContrailResponse xmlns:ns2="http://org.openecomp.mso/network">\r
- <networkId>MNS-25180-L-01-dmz_direct_net_1/2c88a3a9-69b9-43a7-ada6-1aca577c3641</networkId>\r
- <neutronNetworkId>c4f4e878-cde0-4b15-ae9a-bda857759cea</neutronNetworkId>\r
- <networkFqdn>default-domain:MSOTest:GN_EVPN_direct_net_0_ST1</networkFqdn>\r
- <networkStackId></networkStackId>\r
- <subnetMap>\r
- <entry>\r
- <key>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</key>\r
- <value>bd8e87c6-f4e2-41b8-b0bc-9596aa00cd73</value>\r
- </entry>\r
- <entry>\r
- <key>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</key>\r
- <value>bd8e87c6-f4e2-41b8-b0bc-9596aa00cd73</value>\r
- </entry>\r
- </subnetMap>\r
- <rollback>\r
- <networkId>MNS-25180-L-01-dmz_direct_net_1/2c88a3a9-69b9-43a7-ada6-1aca577c3641</networkId>\r
- <neutronNetworkId>c4f4e878-cde0-4b15-ae9a-bda857759cea</neutronNetworkId>\r
- <networkStackId></networkStackId>\r
- <networkType>CONTRAIL_EXTERNAL</networkType>\r
- <networkUpdated>true</networkUpdated>\r
- <tenantId>7dd5365547234ee8937416c65507d266</tenantId>\r
- <cloudSiteId>RDM2WAGPLCP</cloudSiteId>\r
- <msoRequest>\r
- <requestId>1ef47428-cade-45bd-a103-0751e8b2deb0</requestId>\r
- <serviceInstanceId></serviceInstanceId>\r
- </msoRequest>\r
- </rollback>\r
- <messageId>messageId_generated</messageId>\r
-</ns2:updateNetworkContrailResponse>"""\r
- \r
- String updateRollbackNetworkRequest =\r
- """<NetworkAdapter:rollbackNetwork xmlns:NetworkAdapter="http://org.openecomp.mso/network">\r
- <rollback>\r
- <networkId>MNS-25180-L-01-dmz_direct_net_1/2c88a3a9-69b9-43a7-ada6-1aca577c3641</networkId>\r
- <neutronNetworkId>c4f4e878-cde0-4b15-ae9a-bda857759cea</neutronNetworkId>\r
- <networkStackId/>\r
- <networkType>CONTRAIL_EXTERNAL</networkType>\r
- <networkUpdated>true</networkUpdated>\r
- <tenantId>7dd5365547234ee8937416c65507d266</tenantId>\r
- <cloudSiteId>RDM2WAGPLCP</cloudSiteId>\r
- <msoRequest>\r
- <requestId>1ef47428-cade-45bd-a103-0751e8b2deb0</requestId>\r
- <serviceInstanceId/>\r
- </msoRequest>\r
- </rollback>\r
-</NetworkAdapter:rollbackNetwork>""" \r
- \r
- String updateNetworkResponse =\r
- """<ns2:updateNetworkContrailResponse xmlns:ns2="http://org.openecomp.mso/network"\r
- xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">\r
- <networkId>MNS-25180-L-01-dmz_direct_net_1/2c88a3a9-69b9-43a7-ada6-1aca577c3641</networkId>\r
- <neutronNetworkId>c4f4e878-cde0-4b15-ae9a-bda857759cea</neutronNetworkId>\r
- <networkStackId>MNS-25180-L-01-dmz_direct_net_1/2c88a3a9-69b9-43a7-ada6-1aca577c3641</networkStackId>\r
- <networkFqdn>default-domain:MSOTest:GN_EVPN_direct_net_0_ST1</networkFqdn>\r
- <subnetIdMap>\r
- <entry>\r
- <key>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</key>\r
- <value>bd8e87c6-f4e2-41b8-b0bc-9596aa00cd73</value>\r
- </entry>\r
- </subnetIdMap>\r
- <rollback>\r
- <cloudId>RDM2WAGPLCP</cloudId>\r
- <msoRequest>\r
- <requestId>1ef47428-cade-45bd-a103-0751e8b2deb0</requestId>\r
- <serviceInstanceId/>\r
- </msoRequest>\r
- <networkUpdated>true</networkUpdated>\r
- <networkId>MNS-25180-L-01-dmz_direct_net_1/2c88a3a9-69b9-43a7-ada6-1aca577c3641</networkId>\r
- <networkType>CONTRAIL_EXTERNAL</networkType>\r
- <networkUpdated>false</networkUpdated>\r
- <neutronNetworkId>c4f4e878-cde0-4b15-ae9a-bda857759cea</neutronNetworkId>\r
- <tenantId>7dd5365547234ee8937416c65507d266</tenantId>\r
- </rollback>\r
-</ns2:updateNetworkContrailResponse>"""\r
- \r
- String updateContrailAAIPayloadRequest =\r
- """<l3-network xmlns="http://org.openecomp.aai.inventory/v8">\r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <network-role>dmz_direct</network-role>\r
- <network-technology>contrail</network-technology>\r
- <neutron-network-id>c4f4e878-cde0-4b15-ae9a-bda857759cea</neutron-network-id>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <network-role-instance>0</network-role-instance>\r
- <resource-version>l3-version</resource-version>\r
- <orchestration-status>active</orchestration-status>\r
- <heat-stack-id>ST_2Bindings_6006/55288ef0-595c-47d3-819e-cf93aaac6326</heat-stack-id>\r
- <contrail-network-fqdn>default-domain:MSOTest:GN_EVPN_direct_net_0_ST1</contrail-network-fqdn>\r
- <physical-network-name>networkName</physical-network-name>\r
- <is-provider-network>false</is-provider-network>\r
- <is-shared-network>true</is-shared-network>\r
- <is-external-network>false</is-external-network>\r
- <subnets>\r
- <subnet>\r
- <subnet-id>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</subnet-id>\r
- <neutron-subnet-id>bd8e87c6-f4e2-41b8-b0bc-9596aa00cd73</neutron-subnet-id>\r
- <gateway-address>107.239.52.1</gateway-address>\r
- <network-start-address>107.239.52.0</network-start-address>\r
- <cidr-mask>24</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>active</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <subnet-name>subnetName</subnet-name>\r
- </subnet>\r
- <subnet>\r
- <subnet-id>57e9a1ff-d14f-4071-a828-b19ae98eb2fc</subnet-id>\r
- <neutron-subnet-id>bd8e87c6-f4e2-41b8-b0bc-9596aa00cd73</neutron-subnet-id>\r
- <gateway-address>107.239.52.1</gateway-address>\r
- <network-start-address>107.239.52.0</network-start-address>\r
- <cidr-mask>24</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>active</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <subnet-name>subnetName</subnet-name>\r
- </subnet>\r
- </subnets>\r
- <segmentation-assignments>\r
- <segmentation-id>414</segmentation-id>\r
- </segmentation-assignments>\r
- <segmentation-assignments>\r
- <segmentation-id>415</segmentation-id>\r
- </segmentation-assignments>\r
- <ctag-assignments>\r
- <ctag-assignment>\r
- <vlan-id-inner>inner</vlan-id-inner>\r
- <resource-version>ctag-version</resource-version>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>tenant</related-to>\r
- <related-link>https://aai-ext1.test.com:8443/aai/v8/cloud-infrastructure/tenants/tenant/897deadc2b954a6bac6d3c197fb3525e/</related-link>\r
- <relationship-data>\r
- <relationship-key>tenant.tenant-id</relationship-key>\r
- <relationship-value>897deadc2b954a6bac6d3c197fb3525e</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>tenant.tenant-name</property-key>\r
- <property-value>MSOTest1</property-value>\r
- </related-to-property>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-ext1.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/a290b841-f672-44dd-b9cd-6f8c20d7d8c8/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>a290b841-f672-44dd-b9cd-6f8c20d7d8c8</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>vpn-binding.vpn-name</property-key>\r
- <property-value>oam_protected_net_6_MTN5_msotest2</property-value>\r
- </related-to-property>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-ext1.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/24a4b507-853a-4a38-99aa-05fcc54be24d/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>24a4b507-853a-4a38-99aa-05fcc54be24d</relationship-value>\r
- </relationship-data>\r
- <related-to-property>\r
- <property-key>vpn-binding.vpn-name</property-key>\r
- <property-value>oam_protected_net_6_MTN5_msotest1</property-value>\r
- </related-to-property>\r
- </relationship>\r
- </relationship-list>\r
- </ctag-assignment>\r
- </ctag-assignments>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>85f015d0-2e32-4c30-96d2-87a1a27f8017</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>vpn-binding</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/vpn-bindings/vpn-binding/c980a6ef-3b88-49f0-9751-dbad8608d0a6/</related-link>\r
- <relationship-data>\r
- <relationship-key>vpn-binding.vpn-id</relationship-key>\r
- <relationship-value>c980a6ef-3b88-49f0-9751-dbad8608d0a6</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>tenant</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/cloud-infrastructure/tenants/tenant/7dd5365547234ee8937416c65507d266/</related-link>\r
- <relationship-data>\r
- <relationship-key>tenant.tenant-id</relationship-key>\r
- <relationship-value>7dd5365547234ee8937416c65507d266</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>network-policy</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/network-policies/network-policy/cee6d136-e378-4678-a024-2cd15f0ee0cg</related-link>\r
- <relationship-data>\r
- <relationship-key>network-policy.network-policy-id</relationship-key>\r
- <relationship-value>cee6d136-e378-4678-a024-2cd15f0ee0cg</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>route-table-reference</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/route-table-references/route-table-reference/refFQDN1</related-link>\r
- <relationship-data>\r
- <relationship-key>route-table-reference.route-table-reference-id</relationship-key>\r
- <relationship-value>cee6d136-e378-4678-a024-2cd15f0ee0hi</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- <relationship>\r
- <related-to>route-table-reference</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v8/network/route-table-references/route-table-reference/refFQDN2</related-link>\r
- <relationship-data>\r
- <relationship-key>route-table-reference.route-table-reference-id</relationship-key>\r
- <relationship-value>cee6d136-e378-4678-a024-2cd15f0ee0hi</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- </relationship-list>\r
-</l3-network>"""\r
- \r
- String updateContrailAAIResponse =\r
- """<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- statusCode="200">\r
- <rest:headers>\r
- <rest:header name="Date" value="Thu,10 Mar 2016 00:01:18 GMT"/>\r
- <rest:header name="Content-Length" value="0"/>\r
- <rest:header name="Expires" value="Thu,01 Jan 1970 00:00:00 UTC"/>\r
- <rest:header name="X-AAI-TXID" value="mtcnjv9aaas03-20160310-00:01:18:551-132672"/>\r
- <rest:header name="Server" value="Apache-Coyote/1.1"/>\r
- <rest:header name="Cache-Control" value="private"/>\r
- </rest:headers>\r
-</rest:RESTResponse>"""\r
- \r
- String updateNetworkErrorResponse =\r
- """<updateNetworkError>\r
- <messageId>680bd458-5ec1-4a16-b77c-509022e53450</messageId><category>INTERNAL</category>\r
- <message>400 Bad Request: The server could not comply with the request since it is either malformed or otherwise incorrect., error.type=StackValidationFailed, error.message=Property error: : resources.network.properties: : Unknown Property network_ipam_refs_data</message>\r
- <rolledBack>true</rolledBack>\r
- </updateNetworkError>"""\r
- \r
- \r
- String networkException500 =\r
- """<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Body><soap:Fault><faultcode>soap:VersionMismatch</faultcode><faultstring>"http://org.openecomp.mso/network", the namespace on the "updateNetworkContrail" element, is not a valid SOAP version.</faultstring></soap:Fault></soap:Body></soap:Envelope>"""\r
- \r
- String aaiResponse = \r
- """<rest:RESTResponse xmlns:rest="http://schemas.activebpel.org/REST/2007/12/01/aeREST.xsd"\r
- statusCode="200">\r
- <rest:headers>\r
- <rest:header name="Transfer-Encoding" value="chunked"/>\r
- <rest:header name="Date" value="Sat,30 Jan 2016 20:09:24 GMT"/>\r
- <rest:header name="Expires" value="Thu,01 Jan 1970 00:00:00 UTC"/>\r
- <rest:header name="X-AAI-TXID"\r
- value="mtcnjv9aaas01.mtcnj.aic.cip.com-20160130-20:09:24:814-165843"/>\r
- <rest:header name="Content-Type" value="application/xml"/>\r
- <rest:header name="Server" value="Apache-Coyote/1.1"/>\r
- <rest:header name="Cache-Control" value="private"/>\r
- </rest:headers>\r
- <rest:payload contentType="text/xml">\r
- <l3-network xmlns="http://org.openecomp.aai.inventory/v3">\r
- <network-id>bdc5efe8-404a-409b-85f6-0dcc9eebae30</network-id>\r
- <network-name>HSL_direct_net_2</network-name>\r
- <network-type>CONTRAIL_BASIC</network-type>\r
- <network-role>HSL_direct</network-role>\r
- <network-technology>contrail</network-technology>\r
- <neutron-network-id>8bbd3edf-b835-4610-96a2-a5cafa029042</neutron-network-id>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <orchestration-status>active</orchestration-status>\r
- <heat-stack-id>HSL_direct_net_2/57594a56-1c92-4a38-9caa-641c1fa3d4b6</heat-stack-id>\r
- <subnets>\r
- <subnet>\r
- <subnet-id>ea5f2a2c-604f-47ff-a9c5-253ee4f0ef0a</subnet-id>\r
- <neutron-subnet-id>5a77fdc2-7789-4649-a1b9-6eaf1db1813a</neutron-subnet-id>\r
- <gateway-address>172.16.34.1</gateway-address>\r
- <network-start-address>172.16.34.0</network-start-address>\r
- <cidr-mask>28</cidr-mask>\r
- <ip-version>4</ip-version>\r
- <orchestration-status>active</orchestration-status>\r
- <dhcp-enabled>true</dhcp-enabled>\r
- <relationship-list/>\r
- </subnet>\r
- </subnets>\r
- <relationship-list>\r
- <relationship>\r
- <related-to>tenant</related-to>\r
- <related-link>https://aai-app-e2e.test.com:8443/aai/v3/cloud-infrastructure/tenants/tenant/e81d842d3e8b45c5a59f57cd76af3aaf/</related-link>\r
- <relationship-data>\r
- <relationship-key>tenant.tenant-id</relationship-key>\r
- <relationship-value>e81d842d3e8b45c5a59f57cd76af3aaf</relationship-value>\r
- </relationship-data>\r
- </relationship>\r
- </relationship-list>\r
- </l3-network>\r
- </rest:payload>\r
- </rest:RESTResponse>"""\r
-\r
- String changeAssignSDNCRequest = \r
- """<aetgt:SDNCAdapterWorkflowRequest xmlns:aetgt="http://openecomp.com/mso/workflow/schema/v1"\r
- xmlns:ns5="http://openecomp.com/mso/request/types/v1"\r
- xmlns:sdncadapter="http://domain2.openecomp.com/workflow/sdnc/adapter/schema/v1">\r
- <sdncadapter:RequestHeader>\r
- <sdncadapter:RequestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</sdncadapter:RequestId>\r
- <sdncadapter:SvcInstanceId>f70e927b-6087-4974-9ef8-c5e4d5847ca4</sdncadapter:SvcInstanceId>\r
- <sdncadapter:SvcAction>changeassign</sdncadapter:SvcAction>\r
- <sdncadapter:SvcOperation>network-topology-operation</sdncadapter:SvcOperation>\r
- <sdncadapter:CallbackUrl>sdncCallback</sdncadapter:CallbackUrl>\r
- </sdncadapter:RequestHeader>\r
- <aetgt:SDNCRequestData>\r
- <request-information>\r
- <request-id>88f65519-9a38-4c4b-8445-9eb4a5a5af56</request-id>\r
- <request-action>NetworkActivateRequest</request-action>\r
- <source>VID</source>\r
- <notification-url/>\r
- <order-number/>\r
- <order-version/>\r
- </request-information>\r
- <service-information>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <service-type>MSO-dev-service-type</service-type>\r
- <service-instance-id>f70e927b-6087-4974-9ef8-c5e4d5847ca4</service-instance-id>\r
- <subscriber-name>MSO_1610_dev</subscriber-name>\r
- </service-information>\r
- <network-request-information>\r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <tenant>7dd5365547234ee8937416c65507d266</tenant>\r
- <aic-cloud-region>RDM2WAGPLCP</aic-cloud-region>\r
- </network-request-information>\r
- </aetgt:SDNCRequestData>\r
-</aetgt:SDNCAdapterWorkflowRequest>"""\r
-\r
-String assignResponse =\r
-"""<sdncadapterworkflow:SDNCAdapterWorkflowResponse xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1" xmlns:tag0="http://org.openecomp/workflow/sdnc/adapter/schema/v1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <sdncadapterworkflow:response-data> <tag0:CallbackHeader> <tag0:RequestId>006927ca-f5a3-47fd-880c-dfcbcd81a093</tag0:RequestId> <tag0:ResponseCode>200</tag0:ResponseCode> <tag0:ResponseMessage>OK</tag0:ResponseMessage> </tag0:CallbackHeader> <tag0:RequestData xsi:type="xs:string"><output xmlns="org:openecomp:sdnctltl:vnf"><response-code>200</response-code><svc-request-id>006927ca-f5a3-47fd-880c-dfcbcd81a093</svc-request-id><ack-final-indicator>Y</ack-final-indicator><service-information><subscriber-name>notsurewecare</subscriber-name><service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id><service-instance-id>GN_EVPN_direct_net_0_ST_noGW</service-instance-id></service-information><network-information><network-id>8abc633a-810b-4ca5-8b3a-09511d13a2ce</network-id></network-information></output></tag0:RequestData> </sdncadapterworkflow:response-data> </sdncadapterworkflow:SDNCAdapterWorkflowResponse>"""\r
- \r
- String sdncRollbackRequest =\r
- """<aetgt:SDNCAdapterWorkflowRequest xmlns:aetgt="http://openecomp.com/mso/workflow/schema/v1"\r
- xmlns:ns5="http://openecomp.com/mso/request/types/v1"\r
- xmlns:sdncadapter="http://domain2.openecomp.com/workflow/sdnc/adapter/schema/v1">\r
- <sdncadapter:RequestHeader>\r
- <sdncadapter:RequestId>88f65519-9a38-4c4b-8445-9eb4a5a5af56</sdncadapter:RequestId>\r
- <sdncadapter:SvcInstanceId>f70e927b-6087-4974-9ef8-c5e4d5847ca4</sdncadapter:SvcInstanceId>\r
- <sdncadapter:SvcAction>rollback</sdncadapter:SvcAction>\r
- <sdncadapter:SvcOperation>network-topology-operation</sdncadapter:SvcOperation>\r
- <sdncadapter:CallbackUrl>sdncCallback</sdncadapter:CallbackUrl>\r
- </sdncadapter:RequestHeader>\r
- <aetgt:SDNCRequestData>\r
- <request-information>\r
- <request-id>88f65519-9a38-4c4b-8445-9eb4a5a5af56</request-id>\r
- <request-action>NetworkActivateRequest</request-action>\r
- <source>VID</source>\r
- <notification-url/>\r
- <order-number/>\r
- <order-version/>\r
- </request-information>\r
- <service-information>\r
- <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
- <service-type>MSO-dev-service-type</service-type>\r
- <service-instance-id>f70e927b-6087-4974-9ef8-c5e4d5847ca4</service-instance-id>\r
- <subscriber-name>MSO_1610_dev</subscriber-name>\r
- </service-information>\r
- <network-request-information>\r
- <network-id>8abc633a-810b-4ca5-8b3a-09511d13a2ce</network-id>\r
- <network-type>CONTRAIL_EXTERNAL</network-type>\r
- <network-name>MNS-25180-L-01-dmz_direct_net_1</network-name>\r
- <tenant>7dd5365547234ee8937416c65507d266</tenant>\r
- <aic-cloud-region>RDM2WAGPLCP</aic-cloud-region>\r
- </network-request-information>\r
- </aetgt:SDNCRequestData>\r
-</aetgt:SDNCAdapterWorkflowRequest>"""\r
- \r
- String sdncAdapterWorkflowResponse =\r
- """<aetgt:SDNCAdapterWorkflowResponse xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1">\r
- <sdncadapterworkflow:response-data>\r
-<tag0:CallbackHeader xmlns:tag0="http://org.openecomp/workflow/sdnc/adapter/schema/v1">\r
- <tag0:RequestId>745b1b50-e39e-4685-9cc8-c71f0bde8bf0</tag0:RequestId>\r
- <tag0:ResponseCode>200</tag0:ResponseCode>\r
- <tag0:ResponseMessage>OK</tag0:ResponseMessage>\r
-</tag0:CallbackHeader>\r
- <tag0:RequestData xmlns:tag0="http://org.openecomp/workflow/sdnc/adapter/schema/v1"\r
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\r
- xsi:type="xs:string"><output xmlns="org:openecomp:sdnctl:vnf"><svc-request-id>00703dc8-71ff-442d-a4a8-3adc5beef6a9</svc-request-id><response-code>200</response-code><ack-final-indicator>Y</ack-final-indicator><network-information><network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id></network-information><service-information><service-type>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-type><service-instance-id>MNS-25180-L-01-dmz_direct_net_1</service-instance-id><subscriber-name>notsurewecare</subscriber-name></service-information></output></tag0:RequestData>\r
- </sdncadapterworkflow:response-data>\r
-</aetgt:SDNCAdapterWorkflowResponse>"""\r
- \r
- \r
- String sdncAdapterWorkflowResponse_Error =\r
- """<sdncadapterworkflow:SDNCAdapterWorkflowResponse xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:tag0="http://org.openecomp/workflow/sdnc/adapter/schema/v1"\r
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\r
- xmlns="org:openecomp:sdnctl:vnf">\r
- <sdncadapterworkflow:response-data>\r
- <tag0:RequestData xsi:type="xs:string">\r
- <output>\r
- <response-code>400</response-code>\r
- <response-message>Error writing to l3-netework</response-message>\r
- <ack-final-indicator>Y</ack-final-indicator>\r
- <svc-request-id>c79240d8-34b5-4853-af69-2021928dba00</svc-request-id>\r
- </output>\r
- </tag0:RequestData>\r
- </sdncadapterworkflow:response-data>\r
-</sdncadapterworkflow:SDNCAdapterWorkflowResponse>"""\r
- \r
- String expected_sdncAdapterWorkflowResponse_Error =\r
- """<sdncadapterworkflow:SDNCAdapterWorkflowResponse xmlns="org:openecomp:sdnctl:vnf"\r
- xmlns:sdncadapterworkflow="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:tag0="http://org.openecomp/workflow/sdnc/adapter/schema/v1"\r
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">\r
- <sdncadapterworkflow:response-data>\r
- <tag0:RequestData xsi:type="xs:string">\r
- <output>\r
- <response-code>400</response-code>\r
- <response-message>Error writing to l3-netework</response-message>\r
- <ack-final-indicator>Y</ack-final-indicator>\r
- <svc-request-id>c79240d8-34b5-4853-af69-2021928dba00</svc-request-id>\r
- </output>\r
- </tag0:RequestData>\r
- </sdncadapterworkflow:response-data>\r
-</sdncadapterworkflow:SDNCAdapterWorkflowResponse>"""\r
- \r
- String sdncAdapterWorkflowFormattedResponse =\r
- """<aetgt:SDNCAdapterWorkflowResponse xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns="org:openecomp:sdnctl:vnf">\r
- <aetgt:response-data>\r
- <output>\r
- <svc-request-id>00703dc8-71ff-442d-a4a8-3adc5beef6a9</svc-request-id>\r
- <response-code>200</response-code>\r
- <ack-final-indicator>Y</ack-final-indicator>\r
- <network-information>\r
- <network-id>49c86598-f766-46f8-84f8-8d1c1b10f9b4</network-id>\r
- </network-information>\r
- <service-information>\r
- <service-type>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-type>\r
- <service-instance-id>f70e927b-6087-4974-9ef8-c5e4d5847ca4</service-instance-id>\r
- <subscriber-name>notsurewecare</subscriber-name>\r
- </service-information>\r
- </output>\r
- </aetgt:response-data>\r
-</aetgt:SDNCAdapterWorkflowResponse>""" \r
- \r
- String falloutHandlerRequest =\r
- """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>b69c9054-da09-4a2c-adf5-51042b62bfac</request-id>\r
- <action>UPDATE</action>\r
- <source>PORTAL</source>\r
- </request-info>\r
- <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>Received error from SDN-C: No availability zone available.</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>5300</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>\r
- </aetgt:FalloutHandlerRequest>"""\r
- \r
- String falloutHandlerRequestObject =\r
- """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>b69c9054-da09-4a2c-adf5-51042b62bfac</request-id>\r
- <action>UPDATE</action>\r
- <source>VID</source>\r
- </request-info>\r
- <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>Received error from SDN-C: No availability zone available</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>7000</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>\r
- </aetgt:FalloutHandlerRequest>"""\r
- \r
- \r
- String falloutHandlerRequest_Scenario01 =\r
- """<aetgt:FalloutHandlerRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns:wfsch="http://org.openecomp/mso/workflow/schema/v1">\r
- <request-info xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-id>b69c9054-da09-4a2c-adf5-51042b62bfac</request-id>\r
- <action>UPDATE</action>\r
- <source>VID</source>\r
- </request-info>\r
- <aetgt:WorkflowException xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1">\r
- <aetgt:ErrorMessage>Unexpected Response from AAI - 400</aetgt:ErrorMessage>\r
- <aetgt:ErrorCode>7020</aetgt:ErrorCode>\r
- </aetgt:WorkflowException>\r
- </aetgt:FalloutHandlerRequest>"""\r
- \r
- String completeMsoProcessRequest =\r
- """<aetgt:MsoCompletionRequest xmlns:aetgt="http://org.openecomp/mso/workflow/schema/v1"\r
- xmlns:ns="http://org.openecomp/mso/request/types/v1"\r
- xmlns="http://org.openecomp/mso/infra/vnf-request/v1">\r
- <request-info>\r
- <request-id>88f65519-9a38-4c4b-8445-9eb4a5a5af56</request-id>\r
- <action>UPDATE</action>\r
- <source>PORTAL</source>\r
- </request-info>\r
- <aetgt:mso-bpel-name>BPMN Network action: UPDATE</aetgt:mso-bpel-name>\r
-</aetgt:MsoCompletionRequest>"""\r
-\r
-// - - - - - - - -\r
-\r
-\r
- @Before\r
- public void init()\r
- {\r
- MockitoAnnotations.initMocks(this)\r
- \r
- }\r
- \r
- public void initializeVariables (Execution mockExecution) {\r
- \r
- verify(mockExecution).setVariable("UPDNETI_messageId", "")\r
- verify(mockExecution).setVariable("BasicAuthHeaderValuePO", "")\r
- verify(mockExecution).setVariable("BasicAuthHeaderValueSDNC", "")\r
- verify(mockExecution).setVariable("UPDNETI_UpdateNetworkInstanceInfraJsonRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_networkRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_networkInputs", "")\r
- verify(mockExecution).setVariable("UPDNETI_networkOutputs", "")\r
- verify(mockExecution).setVariable("UPDNETI_requestId", "")\r
- verify(mockExecution).setVariable("UPDNETI_source", "")\r
- verify(mockExecution).setVariable("UPDNETI_networkId", "")\r
- \r
- verify(mockExecution).setVariable("UPDNETI_CompleteMsoProcessRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_FalloutHandlerRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_isSilentSuccess", false)\r
- verify(mockExecution).setVariable("UPDNETI_isPONR", false)\r
- \r
- // AAI query Cloud Region\r
- verify(mockExecution).setVariable("UPDNETI_queryCloudRegionRequest","")\r
- verify(mockExecution).setVariable("UPDNETI_queryCloudRegionReturnCode","")\r
- verify(mockExecution).setVariable("UPDNETI_queryCloudRegionResponse","")\r
- verify(mockExecution).setVariable("UPDNETI_cloudRegionPo","")\r
- verify(mockExecution).setVariable("UPDNETI_cloudRegionSdnc","")\r
- verify(mockExecution).setVariable("UPDNETI_isCloudRegionGood", false)\r
- \r
- // AAI query Id\r
- verify(mockExecution).setVariable("UPDNETI_queryIdAAIRequest","")\r
- verify(mockExecution).setVariable("UPDNETI_queryIdAAIResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_aaiIdReturnCode", "")\r
-\r
- // AAI query vpn binding\r
- verify(mockExecution).setVariable("UPDNETI_queryVpnBindingAAIRequest","")\r
- verify(mockExecution).setVariable("UPDNETI_queryVpnBindingAAIResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_aaiQqueryVpnBindingReturnCode", "")\r
- verify(mockExecution).setVariable("UPDNETI_vpnBindings", null)\r
- verify(mockExecution).setVariable("UPDNETI_vpnCount", 0)\r
- verify(mockExecution).setVariable("UPDNETI_routeCollection", "")\r
- \r
- // AAI query network policy\r
- verify(mockExecution).setVariable("UPDNETI_queryNetworkPolicyAAIRequest","")\r
- verify(mockExecution).setVariable("UPDNETI_queryNetworkPolicyAAIResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_aaiQqueryNetworkPolicyReturnCode", "")\r
- verify(mockExecution).setVariable("UPDNETI_networkPolicyUriList", null)\r
- verify(mockExecution).setVariable("UPDNETI_networkPolicyCount", 0)\r
- verify(mockExecution).setVariable("UPDNETI_networkCollection", "")\r
- \r
- // AAI query route table reference\r
- verify(mockExecution).setVariable("UPDNETI_queryNetworkTableRefAAIRequest","")\r
- verify(mockExecution).setVariable("UPDNETI_queryNetworkTableRefAAIResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_aaiQqueryNetworkTableRefReturnCode", "")\r
- verify(mockExecution).setVariable("UPDNETI_networkTableRefUriList", null)\r
- verify(mockExecution).setVariable("UPDNETI_networkTableRefCount", 0)\r
- verify(mockExecution).setVariable("UPDNETI_tableRefCollection", "")\r
- \r
- \r
- // AAI requery Id\r
- verify(mockExecution).setVariable("UPDNETI_requeryIdAAIRequest","")\r
- verify(mockExecution).setVariable("UPDNETI_requeryIdAAIResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_aaiRequeryIdReturnCode", "")\r
-\r
- // AAI update contrail\r
- verify(mockExecution).setVariable("UPDNETI_updateContrailAAIUrlRequest","")\r
- verify(mockExecution).setVariable("UPDNETI_updateContrailAAIPayloadRequest","")\r
- verify(mockExecution).setVariable("UPDNETI_updateContrailAAIResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_aaiUpdateContrailReturnCode", "")\r
- \r
- verify(mockExecution).setVariable("UPDNETI_updateNetworkRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_updateNetworkResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_rollbackNetworkRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_rollbackNetworkResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_networkReturnCode", "")\r
- verify(mockExecution).setVariable("UPDNETI_rollbackNetworkReturnCode", "")\r
- verify(mockExecution).setVariable("UPDNETI_isNetworkRollbackNeeded", false)\r
- \r
- verify(mockExecution).setVariable("UPDNETI_changeAssignSDNCRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_changeAssignSDNCResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_rollbackSDNCRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_rollbackSDNCResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_sdncReturnCode", "")\r
- verify(mockExecution).setVariable("UPDNETI_rollbackSDNCReturnCode", "")\r
- verify(mockExecution).setVariable("UPDNETI_isSdncRollbackNeeded", false)\r
- verify(mockExecution).setVariable("UPDNETI_sdncResponseSuccess", false)\r
-\r
- verify(mockExecution).setVariable("UPDNETI_updateDBRequest", "")\r
- verify(mockExecution).setVariable("UPDNETI_updateDBResponse", "")\r
- verify(mockExecution).setVariable("UPDNETI_dbReturnCode", "")\r
- \r
- verify(mockExecution).setVariable("UPDNETI_isVnfBindingPresent", false)\r
- verify(mockExecution).setVariable("UPDNETI_Success", false)\r
- verify(mockExecution).setVariable("UPDNETI_serviceInstanceId", "")\r
- verify(mockExecution).setVariable("GENGS_type", "service-instance") // Setting for Generic Sub Flow use\r
- \r
- \r
- }\r
- \r
- @Test\r
- //@Ignore \r
- public void preProcessRequest_NetworkRequest() {\r
- \r
- println "************ preProcessRequest_Payload ************* " \r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("mso-request-id")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("isBaseVfModule")).thenReturn(true)\r
- when(mockExecution.getVariable("recipeTimeout")).thenReturn(0)\r
- when(mockExecution.getVariable("requestAction")).thenReturn("UPDATE")\r
- when(mockExecution.getVariable("serviceInstanceId")).thenReturn("f70e927b-6087-4974-9ef8-c5e4d5847ca4")\r
- when(mockExecution.getVariable("vnfId")).thenReturn("")\r
- when(mockExecution.getVariable("volumeGroupId")).thenReturn("")\r
- when(mockExecution.getVariable("networkId")).thenReturn("49c86598-f766-46f8-84f8-8d1c1b10f9b4")\r
- when(mockExecution.getVariable("serviceType")).thenReturn("MOG")\r
- when(mockExecution.getVariable("networkType")).thenReturn("modelName")\r
- when(mockExecution.getVariable("bpmnRequest")).thenReturn(jsonIncomingRequest)\r
- \r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("URN_mso_adapters_po_auth")).thenReturn("3141634BF7E070AA289CF2892C986C0B")\r
- when(mockExecution.getVariable("URN_mso_adapters_db_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_mso_rollback")).thenReturn("true")\r
- \r
- // preProcessRequest(Execution execution) \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.preProcessRequest(mockExecution)\r
- \r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).getVariable("isDebugLogEnabled")\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- \r
- //verify variable initialization\r
- initializeVariables(mockExecution)\r
-\r
- // Authentications\r
- verify(mockExecution).setVariable("BasicAuthHeaderValuePO", "Basic cGFzc3dvcmQ=")\r
- verify(mockExecution).setVariable("BasicAuthHeaderValueSDNC", "Basic cGFzc3dvcmQ=")\r
-\r
- verify(mockExecution).setVariable("UPDNETI_UpdateNetworkInstanceInfraJsonRequest", jsonIncomingRequest)\r
- //verify(mockExecution).setVariable("UPDNETI_networkRequest", expectedNetworkRequest)\r
- //verify(mockExecution).setVariable("UPDNETI_networkInputs", expectedNetworkInputs)\r
- //verify(mockExecution, atLeast(3)).setVariable("UPDNETI_networkOutputs", "")\r
- \r
- //verify(mockExecution).setVariable("UPDNETI_requestId", "88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- //verify(mockExecution).setVariable("UPDNETI_source", "VID")\r
- //verify(mockExecution).setVariable("UPDNETI_messageId", "88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- //verify(mockExecution, atLeast(1)).setVariable("GENGS_type", "service-instance")\r
- \r
- }\r
-\r
- \r
- @Test\r
- //@Ignore\r
- public void preProcessRequest_MissingNetworkId() {\r
-\r
- println "************ preProcessRequest_MissingName() ************* "\r
- \r
- WorkflowException missingNameWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 2500, "Variable 'network-id' value/element is missing.")\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("mso-request-id")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("isBaseVfModule")).thenReturn(true)\r
- when(mockExecution.getVariable("recipeTimeout")).thenReturn(0)\r
- when(mockExecution.getVariable("requestAction")).thenReturn("UPDATE")\r
- when(mockExecution.getVariable("serviceInstanceId")).thenReturn("f70e927b-6087-4974-9ef8-c5e4d5847ca4")\r
- when(mockExecution.getVariable("vnfId")).thenReturn("")\r
- when(mockExecution.getVariable("volumeGroupId")).thenReturn("")\r
- //when(mockExecution.getVariable("networkId")).thenReturn("49c86598-f766-46f8-84f8-8d1c1b10f9b4")\r
- when(mockExecution.getVariable("serviceType")).thenReturn("MOG")\r
- when(mockExecution.getVariable("networkType")).thenReturn("modelName")\r
- when(mockExecution.getVariable("bpmnRequest")).thenReturn(jsonIncomingRequest)\r
- \r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("URN_mso_adapters_po_auth")).thenReturn("3141634BF7E070AA289CF2892C986C0B")\r
- when(mockExecution.getVariable("URN_mso_adapters_db_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_mso_rollback")).thenReturn("true")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- try {\r
- UpdateNetworkInstanceInfra.preProcessRequest(mockExecution)\r
- } catch (Exception ex) {\r
- println " Test End - Handle catch-throw BpmnError()! "\r
- }\r
- \r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution, atLeast(1)).getVariable("isDebugLogEnabled")\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- \r
- //verify variable initialization\r
- initializeVariables(mockExecution)\r
-\r
- // Authentications\r
- verify(mockExecution).setVariable("BasicAuthHeaderValuePO", "Basic cGFzc3dvcmQ=")\r
- verify(mockExecution).setVariable("BasicAuthHeaderValueSDNC", "Basic cGFzc3dvcmQ=")\r
-\r
- verify(mockExecution).setVariable("UPDNETI_UpdateNetworkInstanceInfraJsonRequest", jsonIncomingRequest)\r
- //verify(mockExecution, atLeast(1)).setVariable("UPDNETI_networkOutputs", networkOutputs)\r
- //verify(mockExecution).setVariable("UPDNETI_networkRequest", expectedNetworkRequestMissingNetworkId)\r
- //verify(mockExecution).setVariable("UPDNETI_networkInputs", expectedNetworkInputs)\r
- \r
- //verify(mockExecution).setVariable("UPDNETI_requestId", "88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- //verify(mockExecution).setVariable("UPDNETI_source", "VID")\r
- //verify(mockExecution).setVariable("UPDNETI_messageId", "88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- \r
- verify(mockExecution).setVariable(eq("WorkflowException"), refEq(missingNameWorkflowException))\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void preProcessRequest_MissingCloudRegion() {\r
- \r
- println "************ preProcessRequest_MissingCloudRegion() ************* "\r
- \r
- WorkflowException missingCloudRegionWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 2500, "requestDetails has missing 'aic-cloud-region' value/element.")\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("mso-request-id")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("isBaseVfModule")).thenReturn(true)\r
- when(mockExecution.getVariable("recipeTimeout")).thenReturn(0)\r
- when(mockExecution.getVariable("requestAction")).thenReturn("UPDATE")\r
- when(mockExecution.getVariable("serviceInstanceId")).thenReturn("f70e927b-6087-4974-9ef8-c5e4d5847ca4")\r
- when(mockExecution.getVariable("vnfId")).thenReturn("")\r
- when(mockExecution.getVariable("volumeGroupId")).thenReturn("")\r
- when(mockExecution.getVariable("networkId")).thenReturn("networkId")\r
- when(mockExecution.getVariable("serviceType")).thenReturn("MOG")\r
- when(mockExecution.getVariable("networkType")).thenReturn("modelName")\r
- \r
- when(mockExecution.getVariable("bpmnRequest")).thenReturn(jsonIncomingRequest_MissingCloudRegion)\r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("URN_mso_adapters_po_auth")).thenReturn("3141634BF7E070AA289CF2892C986C0B")\r
- when(mockExecution.getVariable("URN_mso_adapters_db_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_mso_rollback")).thenReturn("true")\r
-\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- try {\r
- UpdateNetworkInstanceInfra.preProcessRequest(mockExecution)\r
- } catch (Exception ex) {\r
- println " Test End - Handle catch-throw BpmnError()! "\r
- }\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution, atLeast(1)).getVariable("isDebugLogEnabled")\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- \r
- //verify variable initialization\r
- initializeVariables(mockExecution)\r
-\r
- verify(mockExecution).setVariable("UPDNETI_messageId", "88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- // Authentications\r
- verify(mockExecution).setVariable("BasicAuthHeaderValuePO", "Basic cGFzc3dvcmQ=")\r
- verify(mockExecution).setVariable("BasicAuthHeaderValueSDNC", "Basic cGFzc3dvcmQ=")\r
-\r
- verify(mockExecution).setVariable("UPDNETI_UpdateNetworkInstanceInfraJsonRequest", jsonIncomingRequest_MissingCloudRegion)\r
- //verify(mockExecution).setVariable("UPDNETI_networkRequest", "")\r
- //verify(mockExecution).setVariable("UPDNETI_networkInputs", "")\r
- //verify(mockExecution, atLeast(1)).setVariable("UPDNETI_networkOutputs", "")\r
- \r
- //verify(mockExecution).setVariable("UPDNETI_requestId", "88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- //verify(mockExecution).setVariable("UPDNETI_source", "VID")\r
- \r
- verify(mockExecution).setVariable(eq("WorkflowException"), refEq(missingCloudRegionWorkflowException))\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void sendSyncResponse() {\r
- \r
- println "************ sendSyncResponse ************* "\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("isAsyncProcess")).thenReturn(true)\r
- when(mockExecution.getVariable("mso-request-id")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- //when(mockExecution.getVariable("serviceInstanceId")).thenReturn("f70e927b-6087-4974-9ef8-c5e4d5847ca4")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.sendSyncResponse(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UpdateNetworkInstanceInfraResponseCode", "202")\r
-\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void sendSyncError() {\r
- \r
- println "************ sendSyncError ************* "\r
- \r
- ExecutionEntity mockExecution = setupMock() \r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("isAsyncProcess")).thenReturn(true)\r
- when(mockExecution.getVariable("mso-request-id")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- //when(mockExecution.getVariable("serviceInstanceId")).thenReturn("f70e927b-6087-4974-9ef8-c5e4d5847ca4")\r
-\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.sendSyncError(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UpdateNetworkInstanceInfraResponseCode", "500")\r
- \r
- }\r
- \r
- \r
- @Test\r
- //@Ignore\r
- public void prepareDBRequest() {\r
- \r
- println "************ prepareDBRequest ************* "\r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("UPDNETI_networkOutputs")).thenReturn("")\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("UPDNETI_orchestrationStatus")).thenReturn("")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_mso_adapters_db_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.prepareDBRequest(mockExecution)\r
- \r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_updateDBRequest", updateDBRequest)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void prepareDBRequestErro_ExceptionObject() {\r
- \r
- println "************ prepareDBRequest ************* "\r
- \r
- WorkflowException sndcWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 500, "Received error from SDN-C: No availability zone available")\r
- \r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("UPDNETI_networkOutputs")).thenReturn("")\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("UPDNETI_networkOutputs")).thenReturn("")\r
- when(mockExecution.getVariable("UPDNETI_orchestrationStatus")).thenReturn("")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(sndcWorkflowException)\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_mso_adapters_db_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
-\r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.prepareDBRequestError(mockExecution)\r
- \r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_updateDBRequest", updateDBRequestError)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void prepareDBRequest_Outputs() {\r
- \r
- println "************ prepareDBRequest ************* "\r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("UPDNETI_networkOutputs")).thenReturn(networkOutputs)\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("UPDNETI_orchestrationStatus")).thenReturn("")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_mso_adapters_db_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
-\r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.prepareDBRequest(mockExecution)\r
- \r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_updateDBRequest", updateDBRequest_Outputs)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void prepareUpdateNetworkRequest() {\r
- \r
- println "************ prepareNetworkRequest ************* "\r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("UPDNETI_networkRequest")).thenReturn(expectedNetworkRequest)\r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponse)\r
- when(mockExecution.getVariable("UPDNETI_cloudRegionPo")).thenReturn("RDM2WAGPLCP")\r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("messageId_generated")\r
- when(mockExecution.getVariable("UPDNETI_source")).thenReturn("VID")\r
- //when(mockExecution.getVariable("UPDNETI_queryVpnBindingAAIResponse")).thenReturn(queryVpnBindingAAIResponse)\r
- when(mockExecution.getVariable("UPDNETI_routeCollection")).thenReturn("<routeTargets>13979:105757</routeTargets><routeTargets>13979:105757</routeTargets>")\r
- when(mockExecution.getVariable("UPDNETI_networkCollection")).thenReturn("<policyFqdns>GN_EVPN_Test</policyFqdns>")\r
- when(mockExecution.getVariable("UPDNETI_tableRefCollection")).thenReturn("<routeTableFqdns>refFQDN1</routeTableFqdns><routeTableFqdns>refFQDN2</routeTableFqdns>")\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- //when(mockExecution.getVariable("URN_?????")).thenReturn("") // notificationUrl, //TODO - is this coming from URN? What variable/value to use?\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_rollbackEnabled")).thenReturn("true")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.prepareUpdateNetworkRequest(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- \r
- verify(mockExecution).setVariable("UPDNETI_updateNetworkRequest", updateNetworkRequest)\r
- \r
- }\r
- \r
-\r
- @Test\r
- //@Ignore\r
- public void prepareUpdateNetworkRequest_NoPhysicalname() {\r
- \r
- println "************ prepareNetworkRequest ************* "\r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("UPDNETI_networkRequest")).thenReturn(NetworkRequest_noPhysicalName)\r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponse)\r
- when(mockExecution.getVariable("UPDNETI_cloudRegionPo")).thenReturn("RDM2WAGPLCP")\r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("messageId_generated")\r
- when(mockExecution.getVariable("UPDNETI_source")).thenReturn("VID")\r
- //when(mockExecution.getVariable("UPDNETI_queryVpnBindingAAIResponse")).thenReturn(queryVpnBindingAAIResponse)\r
- when(mockExecution.getVariable("UPDNETI_routeCollection")).thenReturn("<routeTargets>13979:105757</routeTargets><routeTargets>13979:105757</routeTargets>")\r
- when(mockExecution.getVariable("UPDNETI_networkCollection")).thenReturn("<policyFqdns>GN_EVPN_Test</policyFqdns>")\r
- when(mockExecution.getVariable("UPDNETI_tableRefCollection")).thenReturn("")\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- //when(mockExecution.getVariable("URN_?????")).thenReturn("") // notificationUrl, //TODO - is this coming from URN? What variable/value to use?\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_rollbackEnabled")).thenReturn("true")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.prepareUpdateNetworkRequest(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- \r
- verify(mockExecution).setVariable("UPDNETI_updateNetworkRequest", updateNetworkRequest_noPhysicalName)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void prepareSDNCRequest() {\r
- \r
- println "************ prepareSDNCRequest ************* "\r
- \r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("UPDNETI_networkRequest")).thenReturn(expectedNetworkRequest)\r
- when(mockExecution.getVariable("UPDNETI_cloudRegionSdnc")).thenReturn("RDM2WAGPLCP")\r
- when(mockExecution.getVariable("UPDNETI_serviceInstanceId")).thenReturn("f70e927b-6087-4974-9ef8-c5e4d5847ca4")\r
- when(mockExecution.getVariable("mso-request-id")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("URN_mso_workflow_sdncadapter_callback")).thenReturn("http://localhost:28090/SDNCAdapterCallback")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("GENGSI_siResourceLink")).thenReturn("https://aai-int1.test.com:8443/aai/v8/business/customers/customer/MSO_1610_dev/service-subscriptions/service-subscription/MSO-dev-service-type/service-instances/service-instance/6d4eb22a-82f1-4257-9f80-4176262cfe69/")\r
- \r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.prepareSDNCRequest(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_changeAssignSDNCRequest", changeAssignSDNCRequest)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void prepareSDNCRollbackRequest() {\r
- \r
- println "************ prepareSDNCRollbackRequest ************* "\r
- \r
-\r
- \r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("UPDNETI_networkRequest")).thenReturn(expectedNetworkRequest)\r
- when(mockExecution.getVariable("UPDNETI_cloudRegionSdnc")).thenReturn("RDM2WAGPLCP")\r
- when(mockExecution.getVariable("UPDNETI_serviceInstanceId")).thenReturn("f70e927b-6087-4974-9ef8-c5e4d5847ca4")\r
- when(mockExecution.getVariable("UPDNETI_changeAssignSDNCResponse")).thenReturn(assignResponse)\r
- when(mockExecution.getVariable("mso-request-id")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("URN_mso_workflow_sdncadapter_callback")).thenReturn("http://localhost:28090/SDNCAdapterCallback")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("GENGSI_siResourceLink")).thenReturn("https://aai-int1.test.com:8443/aai/v8/business/customers/customer/MSO_1610_dev/service-subscriptions/service-subscription/MSO-dev-service-type/service-instances/service-instance/6d4eb22a-82f1-4257-9f80-4176262cfe69/")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.prepareSDNCRollbackRequest(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_rollbackSDNCRequest", sdncRollbackRequest)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAINetworkId_200() {\r
-\r
- println "************ callRESTQueryAAINetworkId ************* "\r
- \r
- WireMock.reset();\r
- \r
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200);\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("UPDNETI_networkRequest")).thenReturn(expectedNetworkRequest)\r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn("/aai/v8/network/l3-networks/l3-network")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAINetworkId(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_queryIdAAIRequest", "http://localhost:28090/aai/v8/network/l3-networks/l3-network/49c86598-f766-46f8-84f8-8d1c1b10f9b4")\r
- verify(mockExecution).setVariable("UPDNETI_aaiIdReturnCode", "200")\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAICloudRegion30_200() {\r
-\r
- println "************ callRESTQueryAAICloudRegion30_200 ************* "\r
- \r
- WireMock.reset();\r
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion30_AAIResponse_Success.xml")\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
- when(mockExecution.getVariable("UPDNETI_networkInputs")).thenReturn(expectedNetworkRequest)\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_cloud_region_uri")).thenReturn("/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAICloudRegion(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_queryCloudRegionRequest", "http://localhost:28090/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic/RDM2WAGPLCP")\r
- verify(mockExecution, atLeast(2)).setVariable("UPDNETI_queryCloudRegionReturnCode", "200")\r
- verify(mockExecution).setVariable("UPDNETI_isCloudRegionGood", true)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAICloudRegion25_200() {\r
-\r
- println "************ callRESTQueryAAICloudRegion25_200 ************* "\r
- \r
- WireMock.reset();\r
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml")\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
- when(mockExecution.getVariable("UPDNETI_networkInputs")).thenReturn(expectedNetworkRequest)\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_cloud_region_uri")).thenReturn("/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAICloudRegion(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_queryCloudRegionRequest", "http://localhost:28090/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic/RDM2WAGPLCP")\r
- verify(mockExecution, atLeast(2)).setVariable("UPDNETI_queryCloudRegionReturnCode", "200")\r
- verify(mockExecution).setVariable("UPDNETI_isCloudRegionGood", true)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAICloudRegion_NotFound() {\r
-\r
- println "************ callRESTQueryAAICloudRegionFake ************* "\r
- \r
- WireMock.reset();\r
- MockGetCloudRegion("MDTWNJ21", 404, "")\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
- when(mockExecution.getVariable("UPDNETI_networkInputs")).thenReturn(vnfRequestFakeRegion)\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_cloud_region_uri")).thenReturn("/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAICloudRegion(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_queryCloudRegionRequest", "http://localhost:28090/aai/v8/cloud-infrastructure/cloud-regions/cloud-region/att-aic/MDTWNJ21")\r
- verify(mockExecution, atLeast(1)).setVariable("UPDNETI_queryCloudRegionReturnCode", "404")\r
- verify(mockExecution).setVariable("UPDNETI_cloudRegionPo", "MDTWNJ21")\r
- verify(mockExecution).setVariable("UPDNETI_cloudRegionSdnc", "AAIAIC25")\r
- verify(mockExecution).setVariable("UPDNETI_isCloudRegionGood", true)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAINetworkVpnBinding_200() {\r
-\r
- println "************ callRESTQueryAAINetworkVpnBinding_200 ************* "\r
- \r
- WireMock.reset();\r
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200)\r
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponse) // v6\r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_vpn_binding_uri")).thenReturn("/aai/v8/network/vpn-bindings/vpn-binding")\r
-// when(mockExecution.getVariable("URN_mso_workflow_UpdateNetworkInstanceInfra_aai_network_vpn-binding_uri")).thenReturn("")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true") \r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAINetworkVpnBinding(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_vpnCount", 2)\r
- verify(mockExecution).setVariable("UPDNETI_vpnBindings", ['/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017/', '/aai/v8/network/vpn-bindings/vpn-binding/c980a6ef-3b88-49f0-9751-dbad8608d0a6/'])\r
- // the last vpnBinding value is saved.\r
- verify(mockExecution).setVariable("UPDNETI_queryVpnBindingAAIRequest", "http://localhost:28090/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017")\r
- verify(mockExecution, atLeast(2)).setVariable("UPDNETI_aaiQqueryVpnBindingReturnCode", "200")\r
- \r
- }\r
-\r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAINetworkVpnBinding_TestScenario01_200() {\r
-\r
- println "************ callRESTQueryAAINetworkVpnBinding_200 ************* "\r
- \r
- WireMock.reset();\r
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200)\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponseTestScenario01) \r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_vpn_binding_uri")).thenReturn("/aai/v8/network/vpn-bindings/vpn-binding")\r
-// when(mockExecution.getVariable("URN_mso_workflow_UpdateNetworkInstanceInfra_aai_network_vpn-binding_uri")).thenReturn("")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAINetworkVpnBinding(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_vpnCount", 1)\r
- verify(mockExecution).setVariable("UPDNETI_vpnBindings", ['/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017/'])\r
- // the last vpnBinding value is saved.\r
- verify(mockExecution).setVariable("UPDNETI_queryVpnBindingAAIRequest", "http://localhost:28090/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017")\r
- verify(mockExecution).setVariable("UPDNETI_aaiQqueryVpnBindingReturnCode", "200")\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAINetworkVpnBinding_200_URN_Uri() {\r
-\r
- println "************ callRESTQueryAAINetworkVpnBinding_200 ************* "\r
- \r
- WireMock.reset();\r
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200)\r
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponse) \r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_vpn_binding_uri")).thenReturn("/aai/v8/network/vpn-bindings/vpn-binding")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAINetworkVpnBinding(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_vpnCount", 2)\r
- verify(mockExecution).setVariable("UPDNETI_vpnBindings", ['/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017/', '/aai/v8/network/vpn-bindings/vpn-binding/c980a6ef-3b88-49f0-9751-dbad8608d0a6/'])\r
- // the last vpnBinding value is saved.\r
- verify(mockExecution).setVariable("UPDNETI_queryVpnBindingAAIRequest", "http://localhost:28090/aai/v8/network/vpn-bindings/vpn-binding/85f015d0-2e32-4c30-96d2-87a1a27f8017")\r
- verify(mockExecution, atLeast(2)).setVariable("UPDNETI_aaiQqueryVpnBindingReturnCode", "200")\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAINetworkVpnBinding_NotPresent() {\r
-\r
- println "************ callRESTQueryAAINetworkVpnBinding_NotPresent ************* "\r
- \r
- WireMock.reset();\r
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200)\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- \r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponseVpnNotPresent) \r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn("/aai/v8/network/l3-networks/l3-network")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAINetworkVpnBinding(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_aaiQqueryVpnBindingReturnCode", "200")\r
- verify(mockExecution).setVariable("UPDNETI_vpnCount", 0)\r
- verify(mockExecution).setVariable("UPDNETI_queryVpnBindingAAIResponse", aaiVpnResponseStub)\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAINetworkTableRef_200() {\r
-\r
- println "************ callRESTQueryAAINetworkTableRef_200 ************* "\r
- \r
- WireMock.reset();\r
- MockGetNetworkRouteTable("refFQDN1", "CreateNetworkV2/createNetwork_queryNetworkTableRef1_AAIResponse_Success.xml", 200)\r
- MockGetNetworkRouteTable("refFQDN2", "CreateNetworkV2/createNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200)\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponse)\r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_route_table_reference_uri")).thenReturn("/aai/v8/network/route-table-references/route-table-reference")\r
-// when(mockExecution.getVariable("URN_mso_workflow_CreateNetworkInstanceInfra_aai_network_table_reference_uri")).thenReturn("")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAINetworkTableRef(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_networkTableRefCount", 2)\r
- verify(mockExecution).setVariable("UPDNETI_networkTableRefUriList", ['/aai/v8/network/route-table-references/route-table-reference/refFQDN1','/aai/v8/network/route-table-references/route-table-reference/refFQDN2'])\r
- // the last vpnBinding value is saved.\r
- verify(mockExecution).setVariable("UPDNETI_queryNetworkTableRefAAIRequest", "http://localhost:28090/aai/v8/network/route-table-references/route-table-reference/refFQDN1")\r
- verify(mockExecution, atLeast(2)).setVariable("UPDNETI_aaiQqueryNetworkTableRefReturnCode", "200")\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTQueryAAINetworkPolicy_200() {\r
-\r
- println "************ callRESTQueryAAINetworkPolicy_200 ************* "\r
- \r
- WireMock.reset();\r
- MockGetNetworkPolicy("cee6d136-e378-4678-a024-2cd15f0ee0cg", "UpdateNetworkV2/updateNetwork_queryNetworkPolicy_AAIResponse_Success.xml", 200)\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponse) \r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_network_policy_uri")).thenReturn("/aai/v8/network/network-policies/network-policy")\r
-// when(mockExecution.getVariable("URN_mso_workflow_UpdateNetworkInstanceInfra_aai_network_policy_uri")).thenReturn("")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTQueryAAINetworkPolicy(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_networkPolicyCount", 1)\r
- verify(mockExecution).setVariable("UPDNETI_networkPolicyUriList", ['/aai/v8/network/network-policies/network-policy/cee6d136-e378-4678-a024-2cd15f0ee0cg'])\r
- // the last vpnBinding value is saved.\r
- verify(mockExecution).setVariable("UPDNETI_queryNetworkPolicyAAIRequest", "http://localhost:28090/aai/v8/network/network-policies/network-policy/cee6d136-e378-4678-a024-2cd15f0ee0cg")\r
- verify(mockExecution).setVariable("UPDNETI_aaiQqueryNetworkPolicyReturnCode", "200")\r
- \r
- }\r
- \r
- \r
- @Test\r
- //@Ignore\r
- public void callRESTReQueryAAINetworkId_200() {\r
-\r
- println "************ callRESTReQueryAAINetworkId ************* "\r
- \r
- WireMock.reset();\r
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200)\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("UPDNETI_changeAssignSDNCResponse")).thenReturn(sdncAdapterWorkflowFormattedResponse)\r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn("/aai/v8/network/l3-networks/l3-network")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTReQueryAAINetworkId(mockExecution)\r
- \r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_requeryIdAAIRequest", "http://localhost:28090/aai/v8/network/l3-networks/l3-network/49c86598-f766-46f8-84f8-8d1c1b10f9b4")\r
- verify(mockExecution).setVariable("UPDNETI_aaiRequeryIdReturnCode", "200")\r
- \r
- }\r
- \r
-\r
- @Test\r
- @Ignore\r
- public void callRESTUpdateContrailAAINetworkREST_200() {\r
-\r
- println "************ callRESTUpdateContrailAAINetwork ************* "\r
- \r
- WireMock.reset();\r
- MockPutNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", 200, "UpdateNetworkV2/updateNetwork_updateContrail_AAIResponse_Success.xml")\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- when(mockExecution.getVariable("UPDNETI_changeAssignSDNCResponse")).thenReturn(sdncAdapterWorkflowFormattedResponse)\r
- when(mockExecution.getVariable("UPDNETI_requeryIdAAIResponse")).thenReturn(queryIdAIIResponse)\r
- when(mockExecution.getVariable("UPDNETI_updateNetworkResponse")).thenReturn(updateNetworkResponseREST)\r
- when(mockExecution.getVariable("UPDNETI_messageId")).thenReturn("e8ebf6a0-f8ea-4dc0-8b99-fe98a87722d6")\r
- when(mockExecution.getVariable("URN_aai_endpoint")).thenReturn("http://localhost:28090")\r
- when(mockExecution.getVariable("URN_mso_workflow_global_default_aai_version")).thenReturn("8")\r
- when(mockExecution.getVariable("URN_mso_workflow_default_aai_v8_l3_network_uri")).thenReturn("/aai/v8/network/l3-networks/l3-network")\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("URN_aai_auth")).thenReturn("757A94191D685FD2092AC1490730A4FC")\r
- when(mockExecution.getVariable("URN_mso_msoKey")).thenReturn("07a7159d3bf51a0e53be7a8f89699be7")\r
- \r
- // preProcessRequest(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.callRESTUpdateContrailAAINetwork(mockExecution)\r
-\r
- // Capture the arguments to setVariable\r
- ArgumentCaptor<String> captor1 = ArgumentCaptor.forClass(String.class);\r
- ArgumentCaptor<String> captor2 = ArgumentCaptor.forClass(String.class);\r
- \r
- verify(mockExecution, times(6)).setVariable(captor1.capture(), captor2.capture())\r
- List<String> arg2List = captor2.getAllValues()\r
- String payloadResponseActual = arg2List.get(4)\r
- \r
- assertEquals(updateContrailAAIResponse.replaceAll("\\s+", ""), payloadResponseActual.replaceAll("\\s+", ""))\r
- \r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_updateContrailAAIUrlRequest", "http://localhost:28090/aai/v8/network/l3-networks/l3-network/49c86598-f766-46f8-84f8-8d1c1b10f9b4")\r
- verify(mockExecution).setVariable("UPDNETI_updateContrailAAIPayloadRequest", updateContrailAAIPayloadRequest)\r
- verify(mockExecution).setVariable("UPDNETI_aaiUpdateContrailReturnCode", "200")\r
- verify(mockExecution).setVariable("UPDNETI_isPONR", true)\r
- \r
- }\r
- \r
-\r
- \r
- @Test\r
- //@Ignore\r
- public void validateUpdateNetworkResponseREST() {\r
- \r
- println "************ validateNetworkResponse ************* "\r
- \r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_updateNetworkResponse")).thenReturn(updateNetworkResponseREST)\r
- when(mockExecution.getVariable("UPDNETI_networkReturnCode")).thenReturn('200')\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.validateUpdateNetworkResponse(mockExecution)\r
-\r
- //MockitoDebuggerImpl debugger = new MockitoDebuggerImpl()\r
- //debugger.printInvocations(mockExecution)\r
- \r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_updateNetworkResponse", updateNetworkResponseREST)\r
- verify(mockExecution).setVariable("UPDNETI_isNetworkRollbackNeeded", true)\r
- verify(mockExecution).setVariable("UPDNETI_rollbackNetworkRequest", updateRollbackNetworkRequest)\r
-\r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void validateUpdateNetworkResponseREST_Error() {\r
- \r
- println "************ validateNetworkResponse ************* "\r
- \r
- WorkflowException workflowException = new WorkflowException("UpdateNetworkInstanceInfra", 2500, "Received error from Network Adapter: JBWEB000065: HTTP Status 500.")\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_updateNetworkResponse")).thenReturn(networkException500)\r
- when(mockExecution.getVariable("UPDNETI_networkReturnCode")).thenReturn('500')\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- try {\r
- UpdateNetworkInstanceInfra.validateUpdateNetworkResponse(mockExecution)\r
- } catch (Exception ex) {\r
- println " Test End - Handle catch-throw BpmnError()! "\r
- }\r
- \r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution, atLeast(1)).setVariable("WorkflowException", refEq(workflowException, any(WorkflowException.class)))\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore \r
- public void validateSDNCResponse() {\r
- \r
- println "************ validateSDNCResponse ************* "\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_changeAssignSDNCResponse")).thenReturn(sdncAdapterWorkflowResponse)\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
- when(mockExecution.getVariable("SDNCA_SuccessIndicator")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_sdncReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_isResponseGood")).thenReturn(true)\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- try {\r
- UpdateNetworkInstanceInfra.validateSDNCResponse(mockExecution)\r
- verify(mockExecution).setVariable("UPDNETI_isSdncRollbackNeeded", true)\r
- verify(mockExecution).setVariable("UPDNETI_rollbackSDNCRequest", "")\r
- \r
- } catch (Exception ex) {\r
- println " Graceful Exit - " + ex.getMessage()\r
- }\r
- //MockitoDebuggerImpl debugger = new MockitoDebuggerImpl()\r
- //debugger.printInvocations(mockExecution)\r
- \r
- //verify(mockExecution).setVariable("UPDNETI_isSdncRollbackNeeded", true)\r
- \r
- }\r
-\r
- @Test\r
- //@Ignore\r
- public void validateSDNCResponse_Error() {\r
- \r
- println "************ validateSDNCResponse ************* "\r
- //ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_changeAssignSDNCResponse")).thenReturn(sdncAdapterWorkflowResponse_Error)\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
- when(mockExecution.getVariable("SDNCA_SuccessIndicator")).thenReturn(false)\r
- when(mockExecution.getVariable("UPDNETI_sdncReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_isResponseGood")).thenReturn(true)\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- try {\r
- UpdateNetworkInstanceInfra.validateSDNCResponse(mockExecution)\r
- } catch (Exception ex) {\r
- println " Graceful Exit! - " + ex.getMessage() \r
- }\r
- //MockitoDebuggerImpl debugger = new MockitoDebuggerImpl()\r
- //debugger.printInvocations(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- //verify(mockExecution).setVariable("UPDNETI_sdncResponseSuccess", false)\r
- \r
- }\r
-\r
- \r
- \r
- @Test\r
- //@Ignore\r
- public void postProcessResponse() {\r
- \r
- println "************ postProcessResponse ************* "\r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_source")).thenReturn("PORTAL")\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")\r
- when(mockExecution.getVariable("UPDNETI_dbReturnCode")).thenReturn("200")\r
- \r
- // postProcessResponse(Execution execution) \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.postProcessResponse(mockExecution)\r
-\r
- // check the sequence of variable invocation\r
- //MockitoDebuggerImpl preDebugger = new MockitoDebuggerImpl()\r
- //preDebugger.printInvocations(mockExecution)\r
-\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_Success", true)\r
- verify(mockExecution).setVariable("UPDNETI_CompleteMsoProcessRequest", completeMsoProcessRequest)\r
- \r
- }\r
-\r
- @Test\r
- //@Ignore\r
- public void validateRollbackResponses_Good() {\r
- \r
- WorkflowException workflowException = new WorkflowException("UpdateNetworkInstanceInfra", 2500, "AAI Update Contrail Failed. Error 404.")\r
- WorkflowException expectedWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 2500, "AAI Update Contrail Failed. Error 404. + PO Network rollback is not supported for Update. Submit another Update to restore/rollback. + SNDC rollback completed.")\r
- \r
- println "************ validateRollbackResponses_Good() ************* "\r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
-\r
- when(mockExecution.getVariable("UPDNETI_isNetworkRollbackNeeded")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkResponse")).thenReturn("GoodResponse")\r
- when(mockExecution.getVariable("UPDNETI_isSdncRollbackNeeded")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCResponse")).thenReturn("GoodResponse")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(workflowException)\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.validateRollbackResponses(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("WorkflowException", refEq(expectedWorkflowException, any(WorkflowException.class)))\r
- \r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void validateRollbackResponses_Failed() {\r
- \r
- WorkflowException workflowException = new WorkflowException("UpdateNetworkInstanceInfra", 7020, "AAI Update Contrail Failed. Error 404.")\r
- WorkflowException expectedWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 7020, "AAI Update Contrail Failed. Error 404. + PO Network rollback is not supported for Update. Submit another Update to restore/rollback. + SDNC rollback failed. ")\r
- \r
- println "************ validateRollbackResponses_Failed() ************* "\r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
-\r
- when(mockExecution.getVariable("UPDNETI_isNetworkRollbackNeeded")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkReturnCode")).thenReturn("404")\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkResponse")).thenReturn("BadResponse")\r
- when(mockExecution.getVariable("UPDNETI_isSdncRollbackNeeded")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCReturnCode")).thenReturn("500")\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCResponse")).thenReturn("BadResponse")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(workflowException)\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.validateRollbackResponses(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution, atLeast(1)).setVariable("WorkflowException", refEq(expectedWorkflowException, any(WorkflowException.class)))\r
-\r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void validateRollbackResponses_NetworkFailed() {\r
- \r
- WorkflowException workflowException = new WorkflowException("UpdateNetworkInstanceInfra", 7020, "AAI Update Contrail Failed. Error 404.")\r
- WorkflowException expectedWorkflowExceptionFailed = new WorkflowException("UpdateNetworkInstanceInfra", 7020, "AAI Update Contrail Failed. Error 404. + PO Network rollback is not supported for Update. Submit another Update to restore/rollback. + SNDC rollback completed.")\r
- \r
- println "************ validateRollbackResponses_NetworkFailed() ************* "\r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
-\r
- when(mockExecution.getVariable("UPDNETI_isNetworkRollbackNeeded")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkReturnCode")).thenReturn("404")\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkResponse")).thenReturn("BadResponse")\r
- when(mockExecution.getVariable("UPDNETI_isSdncRollbackNeeded")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCResponse")).thenReturn("GoodResponse")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(workflowException)\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.validateRollbackResponses(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution, atLeast(1)).setVariable("WorkflowException", refEq(expectedWorkflowExceptionFailed , any(WorkflowException.class)))\r
-\r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void validateRollbackResponses_SdncFailed() {\r
- \r
- WorkflowException workflowException = new WorkflowException("UpdateNetworkInstanceInfra", 7020, "AAI Update Contrail Failed. Error 404.")\r
- WorkflowException expectedWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 7020, "AAI Update Contrail Failed. Error 404. + PO Network rollback is not supported for Update. Submit another Update to restore/rollback. + SDNC rollback failed. ")\r
- \r
- println "************ validateRollbackResponses_SdncFailed() ************* "\r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
-\r
- when(mockExecution.getVariable("UPDNETI_isNetworkRollbackNeeded")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkResponse")).thenReturn("GoodResponse")\r
- when(mockExecution.getVariable("UPDNETI_isSdncRollbackNeeded")).thenReturn(true)\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCResponse")).thenReturn("<response-code>400</response-code>")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(workflowException)\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.validateRollbackResponses(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("WorkflowException", refEq(expectedWorkflowException , any(WorkflowException.class)))\r
-\r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void validateRollbackResponses_NoRollbacks() {\r
- \r
- WorkflowException workflowException = new WorkflowException("UpdateNetworkInstanceInfra", 2500, " AAI Update Contrail Failed. Error 404")\r
- WorkflowException expectedWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 2500, " AAI Update Contrail Failed. Error 404")\r
- \r
- println "************ validateRollbackResponses_NoRollbacks() ************* "\r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("prefix")).thenReturn("UPDNETI_")\r
-\r
- when(mockExecution.getVariable("UPDNETI_isNetworkRollbackNeeded")).thenReturn(false)\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_rollbackNetworkResponse")).thenReturn("GoodResponse")\r
- when(mockExecution.getVariable("UPDNETI_isSdncRollbackNeeded")).thenReturn(false)\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_rollbackSDNCResponse")).thenReturn("GoodResponse")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(workflowException)\r
- \r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.validateRollbackResponses(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- //verify(mockExecution, atLeast(1)).setVariable("WorkflowException", any(expectedWorkflowException))\r
- verify(mockExecution, atLeast(1)).setVariable("WorkflowException", refEq(expectedWorkflowException, any(WorkflowException.class)))\r
-\r
- }\r
- \r
- \r
- @Test\r
- //@Ignore \r
- public void buildErrorResponse() {\r
- \r
- println "************ buildErrorResponse ************* "\r
- \r
- \r
- WorkflowException sndcWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 5300, "Received error from SDN-C: No availability zone available.")\r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("b69c9054-da09-4a2c-adf5-51042b62bfac")\r
- when(mockExecution.getVariable("UPDNETI_source")).thenReturn("PORTAL")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(sndcWorkflowException)\r
- \r
- // buildErrorResponse(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.buildErrorResponse(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_Success", false)\r
- verify(mockExecution).setVariable("UPDNETI_FalloutHandlerRequest", falloutHandlerRequest)\r
- \r
- //MockitoDebuggerImpl debugger = new MockitoDebuggerImpl()\r
- //debugger.printInvocations(mockExecution)\r
-\r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void buildErrorResponse_WorkflowExceptionObject() {\r
- \r
- println "************ buildErrorResponse ************* "\r
- \r
- WorkflowException sndcWorkflowException = new WorkflowException("UpdateNetworkInstanceInfra", 7000, "Received error from SDN-C: No availability zone available") \r
- \r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("b69c9054-da09-4a2c-adf5-51042b62bfac")\r
- when(mockExecution.getVariable("UPDNETI_source")).thenReturn("VID")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(sndcWorkflowException)\r
- \r
- // buildErrorResponse(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.buildErrorResponse(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_Success", false)\r
- verify(mockExecution).setVariable("UPDNETI_FalloutHandlerRequest", falloutHandlerRequestObject)\r
- \r
- //MockitoDebuggerImpl debugger = new MockitoDebuggerImpl()\r
- //debugger.printInvocations(mockExecution)\r
-\r
- }\r
- \r
- @Test\r
- //@Ignore\r
- public void buildErrorResponse_Scenario01() {\r
- \r
- WorkflowException aaiWorkflowException_Secnario01 = new WorkflowException("UpdateNetworkInstanceInfra", 7020, "Unexpected Response from AAI - 400")\r
- \r
- println "************ buildErrorResponse ************* "\r
- ExecutionEntity mockExecution = setupMock()\r
- // Initialize prerequisite variables\r
- when(mockExecution.getVariable("isDebugLogEnabled")).thenReturn("true")\r
- when(mockExecution.getVariable("UPDNETI_requestId")).thenReturn("b69c9054-da09-4a2c-adf5-51042b62bfac")\r
- when(mockExecution.getVariable("UPDNETI_source")).thenReturn("VID")\r
- when(mockExecution.getVariable("WorkflowException")).thenReturn(aaiWorkflowException_Secnario01)\r
- when(mockExecution.getVariable("UPDNETI_dbReturnCode")).thenReturn("200")\r
- when(mockExecution.getVariable("UPDNETI_updateDBResponse")).thenReturn("<GoodResponse>")\r
- \r
- when(mockExecution.getVariable("UPDNETI_aaiRequeryIdReturnCode")).thenReturn("400")\r
- \r
- // buildErrorResponse(Execution execution)\r
- UpdateNetworkInstanceInfra UpdateNetworkInstanceInfra = new UpdateNetworkInstanceInfra()\r
- UpdateNetworkInstanceInfra.buildErrorResponse(mockExecution)\r
- \r
- // verify set prefix = "UPDNETI_"\r
- verify(mockExecution, atLeast(1)).setVariable("prefix", "UPDNETI_")\r
- verify(mockExecution).setVariable("UPDNETI_Success", false)\r
- verify(mockExecution).setVariable("UPDNETI_FalloutHandlerRequest", falloutHandlerRequest_Scenario01)\r
- \r
- //MockitoDebuggerImpl debugger = new MockitoDebuggerImpl()\r
- //debugger.printInvocations(mockExecution)\r
-\r
- }\r
- \r
-\r
- private ExecutionEntity setupMock() {\r
- \r
- ProcessDefinition mockProcessDefinition = mock(ProcessDefinition.class)\r
- when(mockProcessDefinition.getKey()).thenReturn("UpdateNetworkInstanceInfra")\r
- RepositoryService mockRepositoryService = mock(RepositoryService.class)\r
- when(mockRepositoryService.getProcessDefinition()).thenReturn(mockProcessDefinition)\r
- when(mockRepositoryService.getProcessDefinition().getKey()).thenReturn("UpdateNetworkInstanceInfra")\r
- when(mockRepositoryService.getProcessDefinition().getId()).thenReturn("100")\r
- ProcessEngineServices mockProcessEngineServices = mock(ProcessEngineServices.class)\r
- when(mockProcessEngineServices.getRepositoryService()).thenReturn(mockRepositoryService)\r
- \r
- ExecutionEntity mockExecution = mock(ExecutionEntity.class)\r
- // Initialize prerequisite variables\r
- \r
- when(mockExecution.getId()).thenReturn("100")\r
- when(mockExecution.getProcessDefinitionId()).thenReturn("UpdateNetworkInstanceInfra")\r
- when(mockExecution.getProcessInstanceId()).thenReturn("UpdateNetworkInstanceInfra")\r
- when(mockExecution.getProcessEngineServices()).thenReturn(mockProcessEngineServices)\r
- when(mockExecution.getProcessEngineServices().getRepositoryService().getProcessDefinition(mockExecution.getProcessDefinitionId())).thenReturn(mockProcessDefinition)\r
- \r
- return mockExecution\r
- }\r
- \r
- \r
-}\r
\r
package org.openecomp.mso.bpmn.infrastructure;\r
\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetCloudRegion;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfById;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfByIdWithDepth;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfByIdWithPriority;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetworkPolicyfqdn;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetVolumeGroupById;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPatchGenericVnf;\r
import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPatchVfModuleId;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutGenericVnf;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutNetwork;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutVfModuleIdNoResponse;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseDatabase.mockUpdateRequestDB;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseSDNCAdapter.mockSDNCAdapter;\r
-import static org.openecomp.mso.bpmn.mock.StubResponseVNFAdapter.mockVNFPost;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockAAIVfModule;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockSDNCAdapterVfModule;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockVNFAdapterRestVfModule;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockDBUpdateVfModule;\r
\r
import java.io.IOException;\r
import java.util.HashMap;\r
import java.util.Map;\r
import java.util.UUID;\r
-\r
+import org.junit.Ignore;\r
import org.camunda.bpm.engine.test.Deployment;\r
import org.junit.Test;\r
import org.openecomp.mso.bpmn.common.WorkflowTest;\r
\r
\r
/**\r
- * Sunny day VID scenario.\r
+ * Sunny day VID scenario with preloads.\r
* \r
* @throws Exception\r
*/\r
@Deployment(resources = {\r
"process/CreateVfModuleInfra.bpmn",\r
"subprocess/DoCreateVfModule.bpmn",\r
+ "subprocess/GenericGetVnf.bpmn",\r
"subprocess/SDNCAdapterV1.bpmn",\r
+ "subprocess/GenericNotificationService.bpmn",\r
"subprocess/VnfAdapterRestV1.bpmn",\r
"subprocess/ConfirmVolumeGroupTenant.bpmn",\r
"subprocess/ConfirmVolumeGroupName.bpmn",\r
"subprocess/CompleteMsoProcess.bpmn",\r
"subprocess/FalloutHandler.bpmn"\r
})\r
- public void sunnyDayVID() throws Exception {\r
+ public void sunnyDayVIDWithPreloads() throws Exception {\r
\r
logStart();\r
\r
- MockGetGenericVnfByIdWithDepth("skask", 1, "VfModularity/GenericVnf.xml");\r
- MockGetGenericVnfByIdWithPriority("skask", ".*", 200, "VfModularity/VfModule-new.xml", 5);\r
- MockGetGenericVnfById("skask", "VfModularity/GenericVnf.xml", 200);\r
- MockPutVfModuleIdNoResponse("skask", "PCRF", ".*");\r
- MockPutNetwork(".*", "VfModularity/AddNetworkPolicy_AAIResponse_Success.xml", 200);\r
- MockPutGenericVnf("skask");\r
- mockVNFPost("", 202, "skask");\r
- mockSDNCAdapter("/SDNCAdapter", "vnf-type>STMTN", 200, "VfModularity/StandardSDNCSynchResponse.xml");\r
- mockSDNCAdapter("/SDNCAdapter", "SvcAction>query", 200, "VfModularity/StandardSDNCSynchResponse.xml");\r
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");\r
+ MockAAIVfModule();\r
MockPatchGenericVnf("skask");\r
MockPatchVfModuleId("skask", ".*");\r
+ MockSDNCAdapterVfModule(); \r
+ MockVNFAdapterRestVfModule();\r
+ MockDBUpdateVfModule();\r
\r
String businessKey = UUID.randomUUID().toString();\r
String createVfModuleRequest =\r
FileUtil.readResourceFile("__files/CreateVfModule_VID_request.json");\r
\r
- Map<String, Object> variables = setupVariablesSunnyDayVID();\r
+ Map<String, Object> variables = setupVariablesSunnyDayVID(); \r
+ \r
+ TestAsyncResponse asyncResponse = invokeAsyncProcess("CreateVfModuleInfra",\r
+ "v1", businessKey, createVfModuleRequest, variables);\r
+ \r
+ WorkflowResponse response = receiveResponse(businessKey, asyncResponse, 10000);\r
+ \r
+ String responseBody = response.getResponse();\r
+ System.out.println("Workflow (Synch) Response:\n" + responseBody);\r
+ \r
+ injectSDNCCallbacks(callbacks, "assign, query");\r
+ injectVNFRestCallbacks(callbacks, "vnfCreate");\r
+ injectSDNCCallbacks(callbacks, "activate");\r
+ \r
+ // TODO add appropriate assertions\r
+\r
+ waitForProcessEnd(businessKey, 10000);\r
+ checkVariable(businessKey, "CreateVfModuleSuccessIndicator", true);\r
+ \r
+ logEnd();\r
+ }\r
+ \r
+ /**\r
+ * Sunny day VID scenario with no preloads.\r
+ * \r
+ * @throws Exception\r
+ */\r
+ @Test \r
+ @Deployment(resources = {\r
+ "process/CreateVfModuleInfra.bpmn",\r
+ "subprocess/DoCreateVfModule.bpmn",\r
+ "subprocess/GenericGetVnf.bpmn",\r
+ "subprocess/SDNCAdapterV1.bpmn",\r
+ "subprocess/VnfAdapterRestV1.bpmn",\r
+ "subprocess/ConfirmVolumeGroupTenant.bpmn",\r
+ "subprocess/GenericNotificationService.bpmn",\r
+ "subprocess/ConfirmVolumeGroupName.bpmn",\r
+ "subprocess/CreateAAIVfModule.bpmn",\r
+ "subprocess/UpdateAAIVfModule.bpmn",\r
+ "subprocess/UpdateAAIGenericVnf.bpmn",\r
+ "subprocess/CompleteMsoProcess.bpmn",\r
+ "subprocess/FalloutHandler.bpmn"\r
+ })\r
+ public void sunnyDayVIDNoPreloads() throws Exception {\r
+ \r
+ logStart();\r
+ \r
+ MockAAIVfModule();\r
+ MockPatchGenericVnf("skask");\r
+ MockPatchVfModuleId("skask", ".*");\r
+ MockSDNCAdapterVfModule(); \r
+ MockVNFAdapterRestVfModule();\r
+ MockDBUpdateVfModule();\r
+ \r
+ String businessKey = UUID.randomUUID().toString();\r
+ String createVfModuleRequest =\r
+ FileUtil.readResourceFile("__files/CreateVfModule_VID_request_noPreloads.json");\r
+ \r
+ Map<String, Object> variables = setupVariablesSunnyDayVID(); \r
\r
TestAsyncResponse asyncResponse = invokeAsyncProcess("CreateVfModuleInfra",\r
"v1", businessKey, createVfModuleRequest, variables);\r
private Map<String, Object> setupVariablesSunnyDayVID() {\r
Map<String, Object> variables = new HashMap<String, Object>();\r
//try {\r
- // variables.put("bpmnRequest", FileUtil.readResourceFile("__files/CreateVfModule_VID_request.json"));\r
+ //variables.put("bpmnRequest", FileUtil.readResourceFile("__files/CreateVfModule_VID_request.json"));\r
//}\r
//catch (Exception e) {\r
\r
* @throws Exception\r
*/\r
@Test\r
+ @Ignore\r
@Deployment(resources = {\r
"process/CreateVfModuleInfra.bpmn",\r
"subprocess/DoCreateVfModule.bpmn",\r
+ "subprocess/GenericGetVnf.bpmn",\r
"subprocess/SDNCAdapterV1.bpmn",\r
"subprocess/VnfAdapterRestV1.bpmn",\r
"subprocess/ConfirmVolumeGroupTenant.bpmn",\r
"subprocess/ConfirmVolumeGroupName.bpmn",\r
"subprocess/CreateAAIVfModule.bpmn",\r
"subprocess/CreateAAIVfModuleVolumeGroup.bpmn",\r
+ "subprocess/GenericNotificationService.bpmn",\r
"subprocess/UpdateAAIVfModule.bpmn",\r
"subprocess/UpdateAAIGenericVnf.bpmn",\r
"subprocess/CompleteMsoProcess.bpmn",\r
"subprocess/FalloutHandler.bpmn"\r
})\r
+ \r
public void sunnyDayVIDWithVolumeGroupAttach() throws Exception {\r
\r
logStart();\r
\r
- MockGetVolumeGroupById("AAIAIC25", "78987", "VfModularity/VolumeGroup.xml");\r
- MockGetGenericVnfByIdWithDepth("skask", 1, "VfModularity/GenericVnf.xml");\r
- MockGetCloudRegion("MDTWNJ21", 200, "CreateNetworkV2/cloudRegion30_AAIResponse_Success.xml");\r
- MockGetVolumeGroupById("RDM2WAGPLCP", "78987", "DeleteVfModuleVolumeInfraV1/queryVolumeId_AAIResponse_Success.xml");\r
- MockPutVfModuleIdNoResponse("skask", "PCRF", ".*");\r
- mockVNFPost("", 202, "skask");\r
- MockGetNetworkPolicyfqdn(".*", "VfModularity/QueryNetworkPolicy_AAIResponse_Success.xml", 200);\r
- MockPutGenericVnf("skask");\r
- MockGetGenericVnfByIdWithPriority("skask", ".*", 200, "VfModularity/VfModule-new.xml", 5);\r
- mockSDNCAdapter("/SDNCAdapter", "vnf-type>STMTN", 200, "VfModularity/StandardSDNCSynchResponse.xml");\r
- mockSDNCAdapter("/SDNCAdapter", "SvcAction>query", 200, "VfModularity/StandardSDNCSynchResponse.xml");\r
- mockVNFPost("", 202, "skask");\r
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");\r
+\r
+ MockAAIVfModule();\r
MockPatchGenericVnf("skask");\r
MockPatchVfModuleId("skask", ".*");\r
+ MockSDNCAdapterVfModule(); \r
+ MockVNFAdapterRestVfModule();\r
+ MockDBUpdateVfModule();\r
\r
String businessKey = UUID.randomUUID().toString();\r
String createVfModuleRequest =\r
+++ /dev/null
-/*-
- * ============LICENSE_START=======================================================
- * OPENECOMP - MSO
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-
-package org.openecomp.mso.bpmn.infrastructure;
-
-import static org.junit.Assert.assertEquals;
-import static org.openecomp.mso.bpmn.common.BPMNUtil.executeAsyncWorkflow;
-import static org.openecomp.mso.bpmn.common.BPMNUtil.getVariable;
-import static org.openecomp.mso.bpmn.common.BPMNUtil.waitForWorkflowToFinish;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetCloudRegion;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetwork;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetworkPolicy;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetworkRouteTable;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetNetworkVpnBinding;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockNodeQueryServiceInstanceById;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockPutNetwork;
-import static org.openecomp.mso.bpmn.mock.StubResponseDatabase.mockUpdateRequestDB;
-import static org.openecomp.mso.bpmn.mock.StubResponseNetworkAdapter.MockPutNetworkAdapter;
-import static org.openecomp.mso.bpmn.mock.StubResponseSDNCAdapter.mockSDNCAdapter;
-import static org.openecomp.mso.bpmn.mock.StubResponseSDNCAdapter.mockSDNCAdapterTopology;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.camunda.bpm.engine.test.Deployment;
-import org.junit.Assert;
-import org.junit.Rule;
-import org.junit.Test;
-import org.openecomp.mso.bpmn.common.BPMNUtil;
-import org.openecomp.mso.bpmn.common.SDNCAdapterCallbackRule;
-import org.openecomp.mso.bpmn.common.WorkflowTest;
-import org.openecomp.mso.bpmn.common.WorkflowTestTransformer;
-import org.openecomp.mso.bpmn.common.workflow.service.WorkflowResponse;
-import org.openecomp.mso.bpmn.mock.SDNCAdapterNetworkTopologyMockTransformer;
-
-import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
-
-/**
- * Unit test cases for UpdateNetworkInstanceInfra.bpmn
- *
- */
-public class UpdateNetworkInstanceInfraTest extends WorkflowTest {
- @WorkflowTestTransformer
- public static final ResponseTransformer sdncAdapterMockTransformer =
- new SDNCAdapterNetworkTopologyMockTransformer();
-
- @Rule
- public final SDNCAdapterCallbackRule sdncAdapterCallbackRule =
- new SDNCAdapterCallbackRule(processEngineRule);
-
- /**
- * End-to-End flow - Unit test for UpdateNetworkInstanceInfra.bpmn
- * - String input & String response
- */
-
- @Test
- //@Ignore
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_Success1() throws Exception {
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" Success1 - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("----------------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign"); //
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 200, "UpdateNetworkV2/updateNetworkResponse_Success.xml");
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkPolicy("cee6d136-e378-4678-a024-2cd15f0ee0cg", "UpdateNetworkV2/updateNetwork_queryNetworkPolicy_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN1", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef1_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN2", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200);
- MockPutNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", 200, "UpdateNetworkV2/updateNetwork_updateContrail_AAIResponse_Success.xml");
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariables1();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- System.out.println("----------------------------------------------------------");
- System.out.println("- got workflow response -");
- System.out.println("----------------------------------------------------------");
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("true", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_CompleteMsoProcessRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_CompleteMsoProcessRequest"));
-
- String workflowResp = BPMNUtil.getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "WorkflowResponse");
- Assert.assertNotNull(workflowResp);
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" Success1 - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("----------------------------------------------------------");
-
- }
-
- @Test
- //@Ignore
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_Success2() throws Exception {
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" Success2 - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("----------------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign");
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 200, "UpdateNetworkV2/updateNetworkResponse_Success.xml");
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkPolicy("cee6d136-e378-4678-a024-2cd15f0ee0cg", "UpdateNetworkV2/updateNetwork_queryNetworkPolicy_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN1", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef1_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN2", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200);
- MockPutNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", 200, "UpdateNetworkV2/updateNetwork_updateContrail_AAIResponse_Success.xml");
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariables2();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("true", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_CompleteMsoProcessRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_CompleteMsoProcessRequest"));
-
- String completeMsoProcessRequest =
- "<aetgt:MsoCompletionRequest xmlns:aetgt=\"http://org.openecomp/mso/workflow/schema/v1\"" + '\n'
- + " xmlns:ns=\"http://org.openecomp/mso/request/types/v1\"" + '\n'
- + " xmlns=\"http://org.openecomp/mso/infra/vnf-request/v1\">" + '\n'
- + " <request-info>" + '\n'
- + " <request-id>testRequestId</request-id>" + '\n'
- + " <action>UPDATE</action>" + '\n'
- + " <source>VID</source>" + '\n'
- + " </request-info>" + '\n'
- + " <aetgt:mso-bpel-name>BPMN Network action: UPDATE</aetgt:mso-bpel-name>" + '\n'
- + "</aetgt:MsoCompletionRequest>";
-
- Assert.assertEquals(completeMsoProcessRequest, getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_CompleteMsoProcessRequest"));
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" Success2 - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("----------------------------------------------------------");
-
- }
-
-
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_MissingNetworkId() throws Exception {
-
- System.out.println("--------------------------------------------------------------------");
- System.out.println(" Missing networkId - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("--------------------------------------------------------------------");
-
- // setup simulators
-
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariablesMissingNetworkId();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_FalloutHandlerRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- String falloutHandlerActual = getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest");
- String falloutHandlerExpected =
-"<aetgt:FalloutHandlerRequest xmlns:aetgt=\"http://org.openecomp/mso/workflow/schema/v1\"" + "\n" +
-" xmlns:ns=\"http://org.openecomp/mso/request/types/v1\"" + "\n" +
-" xmlns:wfsch=\"http://org.openecomp/mso/workflow/schema/v1\">" + "\n" +
-" <request-info xmlns=\"http://org.openecomp/mso/infra/vnf-request/v1\">" + "\n" +
-" <request-id>88f65519-9a38-4c4b-8445-9eb4a5a5af56</request-id>" + "\n" +
-" <action>UPDATE</action>" + "\n" +
-" <source>VID</source>" + "\n" +
-" </request-info>" + "\n" +
-" <aetgt:WorkflowException xmlns:aetgt=\"http://org.openecomp/mso/workflow/schema/v1\">" + "\n" +
-" <aetgt:ErrorMessage>Variable 'network-id' value/element is missing.</aetgt:ErrorMessage>" + "\n" +
-" <aetgt:ErrorCode>2500</aetgt:ErrorCode>" + "\n" +
-" </aetgt:WorkflowException>" + "\n" +
-" </aetgt:FalloutHandlerRequest>";
-
- assertEquals("Response", falloutHandlerExpected, falloutHandlerActual);
-
- System.out.println("------------------------------------------------------------------");
- System.out.println(" Missing networkId - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("------------------------------------------------------------------");
-
- }
-
- /* NOT NEEDED
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_SDNCRollback1() throws Exception {
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" SDNCRollback1 - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("----------------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign");
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>rollback");
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 200, "UpdateNetworkV2/updateNetworkResponse_Success.xml");
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockAAIResponse_queryId_UpdateNetwork_404V2(); // failure in queryId in AAI
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariablesSDNCRollback();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_FalloutHandlerRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" SDNCRollback1 - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("----------------------------------------------------------");
-
- } */
-
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_SDNCRollback_Scenario01() throws Exception {
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" SDNCRollback - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("----------------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign"); //
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>rollback");
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 200, "UpdateNetworkV2/updateNetworkResponse_Success.xml");
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_NoPayload_Success.xml", 200); // no 'payload' response from NetworkAdapter, version 2
- //MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200); // let it fail (404) to see SDNC compensation
- //MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200); // let it fail (404) to see SDNC compensation
- //MockGetNetworkRouteTable("refFQDN2", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200);
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariablesSDNCRollback();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_FalloutHandlerRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" SDNCRollback - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("----------------------------------------------------------");
-
- }
-
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_Network_SDNC_Rollback() throws Exception {
-
- System.out.println("---------------------------------------------------------------");
- System.out.println(" Network and SDNC Rollback - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("---------------------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign"); //
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>rollback");
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 200, "UpdateNetworkV2/updateNetworkResponse_Success.xml");
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkPolicy("cee6d136-e378-4678-a024-2cd15f0ee0cg", "UpdateNetworkV2/updateNetwork_queryNetworkPolicy_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN1", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef1_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN2", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200);
- //MockAAIResponse_updateContrail_CreateNetwork_SuccessV2(); // designed to fail in AAI Update
- //mockUpdateRequestDB(500, "Database/DBUpdateResponse.xml");
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariables1();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_FalloutHandlerRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- System.out.println("---------------------------------------------------------------------");
- System.out.println(" Network and SCNC Rollback - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("---------------------------------------------------------------------");
-
- }
-
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_Network_SDNC_Rollback_Failed() throws Exception {
-
- System.out.println("---------------------------------------------------------------");
- System.out.println(" Network and SDNC Rollback - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("---------------------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign"); //
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySim500Response.xml", "SvcAction>rollback");
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 200, "UpdateNetworkV2/updateNetworkResponse_Success.xml");
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkPolicy("cee6d136-e378-4678-a024-2cd15f0ee0cg", "UpdateNetworkV2/updateNetwork_queryNetworkPolicy_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN1", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef1_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN2", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200);
- //MockAAIResponse_updateContrail_CreateNetwork_SuccessV2(); // designed to fail in AAI Update
- //mockUpdateRequestDB(500, "Database/DBUpdateResponse.xml");
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariables1();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_FalloutHandlerRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- System.out.println("---------------------------------------------------------------------");
- System.out.println(" Network and SCNC Rollback - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("---------------------------------------------------------------------");
-
- }
-
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_SDNCRollback2() throws Exception {
-
- System.out.println("----------------------------------------------------");
- System.out.println(" SDNCRollback2 - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("----------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign");
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>rollback");
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 500, "UpdateNetworkV2/updateNetworkResponse_500.xml"); // failure 500 in NetworkAdapter
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkPolicy("cee6d136-e378-4678-a024-2cd15f0ee0cg", "UpdateNetworkV2/updateNetwork_queryNetworkPolicy_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN1", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef1_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN2", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200);
- //MockPutNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", 200, "UpdateNetworkV2/updateNetwork_updateContrail_AAIResponse_Success.xml");
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariables1();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_FalloutHandlerRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- System.out.println("------------------------------------------------------------");
- System.out.println(" SDNCRollback2 - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("------------------------------------------------------------");
-
- }
-
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_SDNCRollback3() throws Exception {
-
- System.out.println("----------------------------------------------------");
- System.out.println(" SDNCRollback3 - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("----------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign");
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>rollback");
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 400, "UpdateNetworkV2/updateNetworkResponse_400.xml"); // failure 400 in NetworkAdapter
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkPolicy("cee6d136-e378-4678-a024-2cd15f0ee0cg", "UpdateNetworkV2/updateNetwork_queryNetworkPolicy_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN1", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef1_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN2", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200);
- //MockPutNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", 200, "UpdateNetworkV2/updateNetwork_updateContrail_AAIResponse_Success.xml");
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariables1();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_FalloutHandlerRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- System.out.println("------------------------------------------------------------");
- System.out.println(" SDNCRollback3 - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("------------------------------------------------------------");
-
- }
-
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_PONR() throws Exception {
-
- System.out.println("--------------------------------------------------------------------");
- System.out.println(" PONR (Point-of-no-Return) - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("--------------------------------------------------------------------");
-
- // setup simulators
-
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>changeassign"); //
- mockSDNCAdapterTopology("UpdateNetworkV2mock/sdncUpdateNetworkTopologySimResponse.xml", "SvcAction>rollback");
- MockPutNetworkAdapter("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "updateNetworkRequest", 200, "UpdateNetworkV2/updateNetworkResponse_Success.xml");
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- MockGetNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", "UpdateNetworkV2/updateNetwork_queryNetworkId_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("85f015d0-2e32-4c30-96d2-87a1a27f8017", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkVpnBinding("c980a6ef-3b88-49f0-9751-dbad8608d0a6", "UpdateNetworkV2/updateNetwork_queryVpnBinding_AAIResponse_Success.xml", 200);
- MockGetNetworkPolicy("cee6d136-e378-4678-a024-2cd15f0ee0cg", "UpdateNetworkV2/updateNetwork_queryNetworkPolicy_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN1", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef1_AAIResponse_Success.xml", 200);
- MockGetNetworkRouteTable("refFQDN2", "UpdateNetworkV2/updateNetwork_queryNetworkTableRef2_AAIResponse_Success.xml", 200);
- MockPutNetwork("49c86598-f766-46f8-84f8-8d1c1b10f9b4", 200, "UpdateNetworkV2/updateNetwork_updateContrail_AAIResponse_Success.xml");
- mockUpdateRequestDB(500, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariables1();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_FalloutHandlerRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- String falloutHandlerRequest =
- "<aetgt:FalloutHandlerRequest xmlns:aetgt=\"http://org.openecomp/mso/workflow/schema/v1\"" + '\n'
- + " xmlns:ns=\"http://org.openecomp/mso/request/types/v1\"" + '\n'
- + " xmlns:wfsch=\"http://org.openecomp/mso/workflow/schema/v1\">" + '\n'
- + " <request-info xmlns=\"http://org.openecomp/mso/infra/vnf-request/v1\">" + '\n'
- + " <request-id>testRequestId</request-id>" + '\n'
- + " <action>CREATE</action>" + '\n'
- + " <source>VID</source>" + '\n'
- + " </request-info>" + '\n'
- + " <aetgt:WorkflowException xmlns:aetgt=\"http://org.openecomp/mso/workflow/schema/v1\">" + '\n'
- + " <aetgt:ErrorMessage> DB Update failed, code: 500</aetgt:ErrorMessage>" + '\n'
- + " <aetgt:ErrorCode>2500</aetgt:ErrorCode>" + '\n'
- + " </aetgt:WorkflowException>" + '\n'
- + " </aetgt:FalloutHandlerRequest>";
-
- System.out.println("Display UPDNETI_FalloutHandlerRequest - " + getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
- //Assert.assertEquals(falloutHandlerRequest, getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_FalloutHandlerRequest"));
-
- System.out.println("--------------------------------------------------------------------");
- System.out.println(" PONR (Point-of-no-Return) - UpdateNetworkInstanceInfra flow Completed! ");
- System.out.println("--------------------------------------------------------------------");
-
-
- }
-
- @Test
- @Deployment(resources = {"process/UpdateNetworkInstanceInfra.bpmn",
- "subprocess/GenericGetService.bpmn",
- "subprocess/FalloutHandler.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/SDNCAdapterV1.bpmn"})
-
- public void shouldInvokeServiceUpdateNetworkInstanceInfra_sdncFailure() throws Exception {
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" SNDC Failure - UpdateNetworkInstanceInfra flow Started! ");
- System.out.println("----------------------------------------------------------");
-
- // setup simulators
-
- //MockSDNCAdapterBadAsynchronousResponse(); // 404
- mockSDNCAdapter("/SDNCAdapter", "SvcAction>query", 500, ""); // 500
- MockGetCloudRegion("RDM2WAGPLCP", 200, "CreateNetworkV2/cloudRegion25_AAIResponse_Success.xml");
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
- MockNodeQueryServiceInstanceById("f70e927b-6087-4974-9ef8-c5e4d5847ca4", "UpdateNetworkV2/updateNetwork_queryInstance_Success.xml");
-
- Map<String, String> variables = setupVariables2();
- WorkflowResponse workflowResponse = executeAsyncWorkflow(processEngineRule, "UpdateNetworkInstanceInfra", variables);
- waitForWorkflowToFinish(processEngineRule, workflowResponse.getProcessInstanceID());
-
- assertEquals("false", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_Success"));
- Assert.assertNotNull("UPDNETI_CompleteMsoProcessRequest - ", getVariable(processEngineRule, "UpdateNetworkInstanceInfra", "UPDNETI_CompleteMsoProcessRequest"));
-
- System.out.println("----------------------------------------------------------");
- System.out.println(" SNDC Failure - UpdateNetworkInstanceInfra flow Completed ");
- System.out.println("----------------------------------------------------------");
-
- }
-
- // *****************
- // Utility Section
- // *****************
-
- // Success Scenario
- private Map<String, String> setupVariables1() {
- Map<String, String> variables = new HashMap<String, String>();
- variables.put("bpmnRequest", getCreateNetworkRequest1());
- variables.put("mso-request-id", "testRequestId");
- variables.put("requestId", "testRequestId");
- variables.put("isBaseVfModule", "true");
- variables.put("recipeTimeout", "0");
- variables.put("requestAction", "CREATE");
- variables.put("serviceInstanceId", "f70e927b-6087-4974-9ef8-c5e4d5847ca4");
- variables.put("vnfId", "");
- variables.put("vfModuleId", "");
- variables.put("volumeGroupId", "");
- variables.put("networkId", "49c86598-f766-46f8-84f8-8d1c1b10f9b4");
- variables.put("serviceType", "vMOG");
- variables.put("vfModuleType", "");
- variables.put("networkType", "modelName");
- return variables;
-
- }
-
- public String getCreateNetworkRequest1() {
-
- String request =
- "{ \"requestDetails\": { " + '\n' +
- " \"modelInfo\": { " + '\n' +
- " \"modelType\": \"modelType\", " + '\n' +
- " \"modelId\": \"modelId\", " + '\n' +
- " \"modelNameVersionId\": \"modelNameVersionId\", " + '\n' +
- " \"modelName\": \"CONTRAIL_EXTERNAL\", " + '\n' +
- " \"modelVersion\": \"1\" " + '\n' +
- " }, " + '\n' +
- " \"cloudConfiguration\": { " + '\n' +
- " \"lcpCloudRegionId\": \"RDM2WAGPLCP\", " + '\n' +
- " \"tenantId\": \"88a6ca3ee0394ade9403f075db23167e\" " + '\n' +
- " }, " + '\n' +
- " \"requestInfo\": { " + '\n' +
- " \"instanceName\": \"MNS-25180-L-01-dmz_direct_net_1\", " + '\n' +
- " \"source\": \"VID\", " + '\n' +
- " \"callbackUrl\": \"\", " + '\n' +
- " \"suppressRollback\": \"true\" ," + '\n' +
- " \"productFamilyId\": \"a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb\" " + '\n' +
- " }, " + '\n' +
- " \"requestParameters\": { " + '\n' +
- " \"backoutOnFailure\": true, " + '\n' +
- " \"serviceId\": \"a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb\", " + '\n' +
- " \"userParams\": [] " + '\n' +
- " } " + '\n' +
- " } " + '\n' +
- "}";
-
- return request;
- }
-
- // Success Scenario 2
- private Map<String, String> setupVariables2() {
- Map<String, String> variables = new HashMap<String, String>();
- variables.put("bpmnRequest", getCreateNetworkRequest2());
- variables.put("mso-request-id", "testRequestId");
- variables.put("requestId", "testRequestId");
- variables.put("isBaseVfModule", "true");
- variables.put("recipeTimeout", "0");
- variables.put("requestAction", "UPDATE");
- variables.put("serviceInstanceId", "f70e927b-6087-4974-9ef8-c5e4d5847ca4");
- variables.put("vnfId", "");
- variables.put("vfModuleId", "");
- variables.put("volumeGroupId", "");
- variables.put("networkId", "49c86598-f766-46f8-84f8-8d1c1b10f9b4");
- variables.put("serviceType", "vMOG");
- variables.put("vfModuleType", "");
- variables.put("networkType", "modelName");
- return variables;
-
- }
-
- public String getCreateNetworkRequest2() {
-
- String request =
- "{ \"requestDetails\": { " + '\n' +
- " \"modelInfo\": { " + '\n' +
- " \"modelType\": \"modelType\", " + '\n' +
- " \"modelId\": \"modelId\", " + '\n' +
- " \"modelNameVersionId\": \"modelNameVersionId\", " + '\n' +
- " \"modelName\": \"CONTRAIL_EXTERNAL\", " + '\n' +
- " \"modelVersion\": \"1\" " + '\n' +
- " }, " + '\n' +
- " \"cloudConfiguration\": { " + '\n' +
- " \"lcpCloudRegionId\": \"RDM2WAGPLCP\", " + '\n' +
- " \"tenantId\": \"88a6ca3ee0394ade9403f075db23167e\" " + '\n' +
- " }, " + '\n' +
- " \"requestInfo\": { " + '\n' +
- " \"instanceName\": \"myOwn_Network\", " + '\n' +
- " \"source\": \"VID\", " + '\n' +
- " \"callbackUrl\": \"\", " + '\n' +
- " \"suppressRollback\": \"true\" ," + '\n' +
- " \"productFamilyId\": \"a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb\" " + '\n' +
- " }, " + '\n' +
- " \"requestParameters\": { " + '\n' +
- " \"backoutOnFailure\": true, " + '\n' +
- " \"serviceId\": \"a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb\", " + '\n' +
- " \"userParams\": [] " + '\n' +
- " } " + '\n' +
- " } " + '\n' +
- "}";
-
- return request;
-
- }
-
- /* Active Scenario
- private Map<String, String> setupVariablesActive() {
- Map<String, String> variables = new HashMap<String, String>();
- variables.put("mso-request-id", "testRequestId");
- variables.put("bpmnRequest", getCreateNetworkRequestActive());
- variables.put("requestId", "testRequestId");
- variables.put("isBaseVfModule", "true");
- variables.put("recipeTimeout", "0");
- variables.put("requestAction", "UPDATE");
- variables.put("serviceInstanceId", "f70e927b-6087-4974-9ef8-c5e4d5847ca4");
- variables.put("vnfId", "");
- variables.put("vfModuleId", "");
- variables.put("volumeGroupId", "");
- variables.put("networkId", "49c86598-f766-46f8-84f8-8d1c1b10f9b4");
- variables.put("serviceType", "vMOG");
- variables.put("vfModuleType", "");
- variables.put("networkType", "modelName");
- return variables;
-
- }
-
- public String getCreateNetworkRequestActive() {
-
- String request =
- "{ \"requestDetails\": { " + '\n' +
- " \"modelInfo\": { " + '\n' +
- " \"modelType\": \"modelType\", " + '\n' +
- " \"modelId\": \"modelId\", " + '\n' +
- " \"modelNameVersionId\": \"modelNameVersionId\", " + '\n' +
- " \"modelName\": \"CONTRAIL_EXTERNAL\", " + '\n' +
- " \"modelVersion\": \"1\" " + '\n' +
- " }, " + '\n' +
- " \"cloudConfiguration\": { " + '\n' +
- " \"lcpCloudRegionId\": \"RDM2WAGPLCP\", " + '\n' +
- " \"tenantId\": \"88a6ca3ee0394ade9403f075db23167e\" " + '\n' +
- " }, " + '\n' +
- " \"requestInfo\": { " + '\n' +
- " \"instanceName\": \"MNS-25180-L-01-dmz_direct_net_2\", " + '\n' +
- " \"source\": \"VID\", " + '\n' +
- " \"callbackUrl\": \"\", " + '\n' +
- " \"suppressRollback\": \"true\" ," + '\n' +
- " \"productFamilyId\": \"a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb\" " + '\n' +
- " }, " + '\n' +
- " \"requestParameters\": { " + '\n' +
- " \"userParams\": [] " + '\n' +
- " } " + '\n' +
- " } " + '\n' +
- "}";
-
- return request;
-
- } */
-
- // Missing Name Scenario
- private Map<String, String> setupVariablesMissingNetworkId() {
- Map<String, String> variables = new HashMap<String, String>();
- variables.put("mso-request-id", "88f65519-9a38-4c4b-8445-9eb4a5a5af56");
- variables.put("bpmnRequest", getCreateNetworkRequestNetworkId());
- variables.put("requestId", "testRequestId");
- variables.put("isBaseVfModule", "true");
- variables.put("recipeTimeout", "0");
- variables.put("requestAction", "UPDATE");
- variables.put("serviceInstanceId", "f70e927b-6087-4974-9ef8-c5e4d5847ca4");
- variables.put("vnfId", "");
- variables.put("vfModuleId", "");
- variables.put("volumeGroupId", "");
- //variables.put("networkId", "49c86598-f766-46f8-84f8-8d1c1b10f9b4"); // missing, ok
- variables.put("serviceType", "vMOG");
- variables.put("vfModuleType", "");
- variables.put("networkType", "modelName");
-
- return variables;
-
- }
-
- public String getCreateNetworkRequestNetworkId() {
-
- String request =
- "{ \"requestDetails\": { " + '\n' +
- " \"modelInfo\": { " + '\n' +
- " \"modelType\": \"modelType\", " + '\n' +
- " \"modelId\": \"modelId\", " + '\n' +
- " \"modelNameVersionId\": \"modelNameVersionId\", " + '\n' +
- " \"modelName\": \"CONTRAIL_EXTERNAL\", " + '\n' +
- " \"modelVersion\": \"1\" " + '\n' +
- " }, " + '\n' +
- " \"cloudConfiguration\": { " + '\n' +
- " \"lcpCloudRegionId\": \"RDM2WAGPLCP\", " + '\n' +
- " \"tenantId\": \"88a6ca3ee0394ade9403f075db23167e\" " + '\n' +
- " }, " + '\n' +
- " \"requestInfo\": { " + '\n' +
- " \"source\": \"VID\", " + '\n' +
- " \"callbackUrl\": \"\", " + '\n' +
- " \"suppressRollback\": \"true\" ," + '\n' +
- " \"productFamilyId\": \"a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb\" " + '\n' +
- " }, " + '\n' +
- " \"requestParameters\": { " + '\n' +
- " \"userParams\": [] " + '\n' +
- " } " + '\n' +
- " } " + '\n' +
- "}";
-
- return request;
-
- }
-
- // SDNC Rollback Scenario
- private Map<String, String> setupVariablesSDNCRollback() {
- Map<String, String> variables = new HashMap<String, String>();
- variables.put("mso-request-id", "testRequestId");
- variables.put("bpmnRequest", getCreateNetworkRequestSDNCRollback());
- variables.put("requestId", "testRequestId");
- variables.put("isBaseVfModule", "true");
- variables.put("recipeTimeout", "0");
- variables.put("requestAction", "UPDATE");
- variables.put("serviceInstanceId", "f70e927b-6087-4974-9ef8-c5e4d5847ca4");
- variables.put("vnfId", "");
- variables.put("vfModuleId", "");
- variables.put("volumeGroupId", "");
- variables.put("networkId", "49c86598-f766-46f8-84f8-8d1c1b10f9b4");
- variables.put("serviceType", "vMOG");
- variables.put("vfModuleType", "");
- variables.put("networkType", "modelName");
- return variables;
-
- }
-
- public String getCreateNetworkRequestSDNCRollback() {
-
- String request =
- "{ \"requestDetails\": { " + '\n' +
- " \"modelInfo\": { " + '\n' +
- " \"modelType\": \"modelType\", " + '\n' +
- " \"modelId\": \"modelId\", " + '\n' +
- " \"modelNameVersionId\": \"modelNameVersionId\", " + '\n' +
- " \"modelName\": \"CONTRAIL_EXTERNAL\", " + '\n' +
- " \"modelVersion\": \"1\" " + '\n' +
- " }, " + '\n' +
- " \"cloudConfiguration\": { " + '\n' +
- " \"lcpCloudRegionId\": \"RDM2WAGPLCP\", " + '\n' +
- " \"tenantId\": \"88a6ca3ee0394ade9403f075db23167e\" " + '\n' +
- " }, " + '\n' +
- " \"requestInfo\": { " + '\n' +
- " \"instanceName\": \"MNS-25180-L-01-dmz_direct_net_3\", " + '\n' +
- " \"source\": \"VID\", " + '\n' +
- " \"callbackUrl\": \"\", " + '\n' +
- " \"suppressRollback\": \"true\" ," + '\n' +
- " \"productFamilyId\": \"a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb\" " + '\n' +
- " }, " + '\n' +
- " \"requestParameters\": { " + '\n' +
- " \"userParams\": [] " + '\n' +
- " } " + '\n' +
- " } " + '\n' +
- "}";
-
-
- return request;
- }
-
-}
-/*-
- * ============LICENSE_START=======================================================
- * OPENECOMP - MSO
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-
-package org.openecomp.mso.bpmn.infrastructure;
-
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfById;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetVfModuleId;
-import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetVolumeGroupById;
-import static org.openecomp.mso.bpmn.mock.StubResponseDatabase.mockUpdateRequestDB;
-import static org.openecomp.mso.bpmn.mock.StubResponseVNFAdapter.mockPutVNFVolumeGroup;
-
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.UUID;
-
-import org.camunda.bpm.engine.test.Deployment;
-import org.junit.Test;
-import org.openecomp.mso.bpmn.common.WorkflowTest;
-import org.openecomp.mso.bpmn.common.workflow.service.WorkflowResponse;
-import org.openecomp.mso.bpmn.mock.FileUtil;
-
-/**
- * Unit test cases for UpdateVfModuleVolume.bpmn
- */
-public class UpdateVfModuleVolumeInfraV1Test extends WorkflowTest {
-
- private final CallbackSet callbacks = new CallbackSet();
-
- public UpdateVfModuleVolumeInfraV1Test() throws IOException {
- callbacks.put("volumeGroupUpdate", FileUtil.readResourceFile(
- "__files/VfModularity/VNFAdapterRestVolumeGroupCallback.xml"));
- }
-
- /**
- * Happy path scenario.
- *
- * @throws Exception
- */
- @Test
- @Deployment(resources = {
- "process/UpdateVfModuleVolumeInfraV1.bpmn",
- "subprocess/VnfAdapterRestV1.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/FalloutHandler.bpmn"
- })
- public void happyPath() throws Exception {
-
- logStart();
-
- MockGetGenericVnfById("/TEST-VNF-ID-0123", "CreateVfModuleVolumeInfraV1/GenericVnf.xml", 200);
- MockGetVolumeGroupById("mdt1", "78987", "UpdateVfModuleVolumeInfraV1/queryVolumeId_AAIResponse_Success.xml");
- MockGetVfModuleId("9e48f6ea-f786-46de-800a-d480e5ccc846", "6a1dc898-b590-47b9-bbf0-34424a7a2ec3/", "UpdateVfModuleVolumeInfraV1/vf_module_aai_response.xml", 200);
- mockPutVNFVolumeGroup("78987", 202);
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
-
- String businessKey = UUID.randomUUID().toString();
- String updaetVfModuleVolRequest =
- FileUtil.readResourceFile("__files/UpdateVfModuleVolumeInfraV1/updateVfModuleVolume_VID_request.json");
-
- Map<String, Object> testVariables = new HashMap<String, Object>();
- testVariables.put("requestId", "TEST-REQUEST-ID-0123");
- testVariables.put("serviceInstanceId", "test-service-instance-id");
- testVariables.put("volumeGroupId", "78987");
- testVariables.put("vnfId", "TEST-VNF-ID-0123");
- TestAsyncResponse asyncResponse = invokeAsyncProcess("UpdateVfModuleVolumeInfraV1", "v1", businessKey, updaetVfModuleVolRequest, testVariables);
- WorkflowResponse response = receiveResponse(businessKey, asyncResponse, 10000);
-
- String responseBody = response.getResponse();
- System.out.println("Workflow (Synch) Response:\n" + responseBody);
-
- injectVNFRestCallbacks(callbacks, "volumeGroupUpdate");
-
- waitForProcessEnd(businessKey, 10000);
- checkVariable(businessKey, "UpdateVfModuleVolumeSuccessIndicator", true);
-
- logEnd();
- }
-
- /**
- * VF Module Personal model id does not match request model invariant id
- * @throws Exception
- */
- @Test
- //@Ignore
- @Deployment(resources = {
- "process/UpdateVfModuleVolumeInfraV1.bpmn",
- "subprocess/VnfAdapterRestV1.bpmn",
- "subprocess/CompleteMsoProcess.bpmn",
- "subprocess/FalloutHandler.bpmn"
- })
- public void testPersonaModelIdNotMatch() throws Exception {
-
- logStart();
-
- MockGetVolumeGroupById("mdt1", "78987", "UpdateVfModuleVolumeInfraV1/queryVolumeId_AAIResponse_Success.xml");
- MockGetGenericVnfById("/TEST-VNF-ID-0123", "CreateVfModuleVolumeInfraV1/GenericVnf.xml", 200);
- MockGetVfModuleId("9e48f6ea-f786-46de-800a-d480e5ccc846", "6a1dc898-b590-47b9-bbf0-34424a7a2ec3/", "UpdateVfModuleVolumeInfraV1/vf_module_aai_response.xml", 200);
- mockPutVNFVolumeGroup("78987", 202);
- mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");
-
- String businessKey = UUID.randomUUID().toString();
- String updaetVfModuleVolRequest =
- FileUtil.readResourceFile("__files/UpdateVfModuleVolumeInfraV1/updateVfModuleVolume_VID_request_2.json");
-
- Map<String, Object> testVariables = new HashMap<String, Object>();
- testVariables.put("requestId", "TEST-REQUEST-ID-0123");
- testVariables.put("serviceInstanceId", "test-service-instance-id");
- testVariables.put("volumeGroupId", "78987");
- testVariables.put("vnfId", "TEST-VNF-ID-0123");
- TestAsyncResponse asyncResponse = invokeAsyncProcess("UpdateVfModuleVolumeInfraV1", "v1", businessKey, updaetVfModuleVolRequest, testVariables);
- WorkflowResponse response = receiveResponse(businessKey, asyncResponse, 10000);
-
- String responseBody = response.getResponse();
- System.out.println("Workflow (Synch) Response:\n" + responseBody);
-
- injectVNFRestCallbacks(callbacks, "volumeGroupUpdate");
-
- waitForProcessEnd(businessKey, 10000);
- checkVariable(businessKey, "UpdateVfModuleVolumeSuccessIndicator", true);
-
- logEnd();
- }
-}
+/*- \r
+ * ============LICENSE_START======================================================= \r
+ * OPENECOMP - MSO \r
+ * ================================================================================ \r
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. \r
+ * ================================================================================ \r
+ * Licensed under the Apache License, Version 2.0 (the "License"); \r
+ * you may not use this file except in compliance with the License. \r
+ * You may obtain a copy of the License at \r
+ * \r
+ * http://www.apache.org/licenses/LICENSE-2.0 \r
+ * \r
+ * Unless required by applicable law or agreed to in writing, software \r
+ * distributed under the License is distributed on an "AS IS" BASIS, \r
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. \r
+ * See the License for the specific language governing permissions and \r
+ * limitations under the License. \r
+ * ============LICENSE_END========================================================= \r
+ */ \r
+\r
+package org.openecomp.mso.bpmn.infrastructure;\r
+\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetGenericVnfById;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetVfModuleId;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseAAI.MockGetVolumeGroupById;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseDatabase.mockUpdateRequestDB;\r
+import static org.openecomp.mso.bpmn.mock.StubResponseVNFAdapter.mockPutVNFVolumeGroup;\r
+\r
+import java.io.IOException;\r
+import java.util.HashMap;\r
+import java.util.Map;\r
+import java.util.UUID;\r
+\r
+import org.camunda.bpm.engine.test.Deployment;\r
+import org.junit.Test;\r
+import org.openecomp.mso.bpmn.common.WorkflowTest;\r
+import org.openecomp.mso.bpmn.common.workflow.service.WorkflowResponse;\r
+import org.openecomp.mso.bpmn.mock.FileUtil;\r
+\r
+/**\r
+ * Unit test cases for UpdateVfModuleVolume.bpmn\r
+ */\r
+public class UpdateVfModuleVolumeInfraV1Test extends WorkflowTest {\r
+ \r
+ private final CallbackSet callbacks = new CallbackSet();\r
+\r
+ public UpdateVfModuleVolumeInfraV1Test() throws IOException {\r
+ callbacks.put("volumeGroupUpdate", FileUtil.readResourceFile(\r
+ "__files/VfModularity/VNFAdapterRestVolumeGroupCallback.xml"));\r
+ }\r
+\r
+ /**\r
+ * Happy path scenario.\r
+ * \r
+ * @throws Exception\r
+ */\r
+ @Test\r
+ @Deployment(resources = {\r
+ "process/UpdateVfModuleVolumeInfraV1.bpmn",\r
+ "subprocess/VnfAdapterRestV1.bpmn",\r
+ "subprocess/CompleteMsoProcess.bpmn",\r
+ "subprocess/GenericNotificationService.bpmn",\r
+ "subprocess/FalloutHandler.bpmn"\r
+ })\r
+ public void happyPath() throws Exception {\r
+\r
+ logStart();\r
+ \r
+ MockGetGenericVnfById("/TEST-VNF-ID-0123", "CreateVfModuleVolumeInfraV1/GenericVnf.xml", 200);\r
+ MockGetVolumeGroupById("mdt1", "78987", "UpdateVfModuleVolumeInfraV1/queryVolumeId_AAIResponse_Success.xml");\r
+ MockGetVfModuleId("9e48f6ea-f786-46de-800a-d480e5ccc846", "6a1dc898-b590-47b9-bbf0-34424a7a2ec3/", "UpdateVfModuleVolumeInfraV1/vf_module_aai_response.xml", 200);\r
+ mockPutVNFVolumeGroup("78987", 202);\r
+ mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");\r
+ \r
+ String businessKey = UUID.randomUUID().toString();\r
+ String updaetVfModuleVolRequest =\r
+ FileUtil.readResourceFile("__files/UpdateVfModuleVolumeInfraV1/updateVfModuleVolume_VID_request.json");\r
+ \r
+ Map<String, Object> testVariables = new HashMap<String, Object>();\r
+ testVariables.put("requestId", "TEST-REQUEST-ID-0123");\r
+ testVariables.put("serviceInstanceId", "test-service-instance-id");\r
+ testVariables.put("volumeGroupId", "78987");\r
+ testVariables.put("vnfId", "TEST-VNF-ID-0123");\r
+ TestAsyncResponse asyncResponse = invokeAsyncProcess("UpdateVfModuleVolumeInfraV1", "v1", businessKey, updaetVfModuleVolRequest, testVariables);\r
+ WorkflowResponse response = receiveResponse(businessKey, asyncResponse, 10000);\r
+\r
+ String responseBody = response.getResponse();\r
+ System.out.println("Workflow (Synch) Response:\n" + responseBody);\r
+ \r
+ injectVNFRestCallbacks(callbacks, "volumeGroupUpdate");\r
+ \r
+ waitForProcessEnd(businessKey, 10000);\r
+ checkVariable(businessKey, "UpdateVfModuleVolumeSuccessIndicator", true);\r
+ \r
+ logEnd();\r
+ }\r
+ \r
+ /**\r
+ * VF Module Personal model id does not match request model invariant id\r
+ * @throws Exception\r
+ */\r
+ @Test\r
+ //@Ignore\r
+ @Deployment(resources = {\r
+ "process/UpdateVfModuleVolumeInfraV1.bpmn",\r
+ "subprocess/VnfAdapterRestV1.bpmn",\r
+ "subprocess/CompleteMsoProcess.bpmn",\r
+ "subprocess/GenericNotificationService.bpmn",\r
+ "subprocess/FalloutHandler.bpmn"\r
+ })\r
+ public void testPersonaModelIdNotMatch() throws Exception {\r
+\r
+ logStart();\r
+ \r
+ MockGetVolumeGroupById("mdt1", "78987", "UpdateVfModuleVolumeInfraV1/queryVolumeId_AAIResponse_Success.xml");\r
+ MockGetGenericVnfById("/TEST-VNF-ID-0123", "CreateVfModuleVolumeInfraV1/GenericVnf.xml", 200);\r
+ MockGetVfModuleId("9e48f6ea-f786-46de-800a-d480e5ccc846", "6a1dc898-b590-47b9-bbf0-34424a7a2ec3/", "UpdateVfModuleVolumeInfraV1/vf_module_aai_response.xml", 200);\r
+ mockPutVNFVolumeGroup("78987", 202);\r
+ mockUpdateRequestDB(200, "Database/DBUpdateResponse.xml");\r
+ \r
+ String businessKey = UUID.randomUUID().toString();\r
+ String updaetVfModuleVolRequest =\r
+ FileUtil.readResourceFile("__files/UpdateVfModuleVolumeInfraV1/updateVfModuleVolume_VID_request_2.json");\r
+ \r
+ Map<String, Object> testVariables = new HashMap<String, Object>();\r
+ testVariables.put("requestId", "TEST-REQUEST-ID-0123");\r
+ testVariables.put("serviceInstanceId", "test-service-instance-id");\r
+ testVariables.put("volumeGroupId", "78987");\r
+ testVariables.put("vnfId", "TEST-VNF-ID-0123");\r
+ TestAsyncResponse asyncResponse = invokeAsyncProcess("UpdateVfModuleVolumeInfraV1", "v1", businessKey, updaetVfModuleVolRequest, testVariables);\r
+ WorkflowResponse response = receiveResponse(businessKey, asyncResponse, 10000);\r
+\r
+ String responseBody = response.getResponse();\r
+ System.out.println("Workflow (Synch) Response:\n" + responseBody);\r
+ \r
+ injectVNFRestCallbacks(callbacks, "volumeGroupUpdate");\r
+ \r
+ waitForProcessEnd(businessKey, 10000);\r
+ checkVariable(businessKey, "UpdateVfModuleVolumeSuccessIndicator", true);\r
+ \r
+ logEnd();\r
+ } \r
+}\r
--- /dev/null
+{\r
+"requestDetails": {\r
+"modelInfo": {\r
+"modelType": "vfModule",\r
+"modelInvariantId": "ff5256d2-5a33-55df-13ab-12abad84e7ff",\r
+"modelNameVersionId": "fe6478e5-ea33-3346-ac12-ab121484a3fe",\r
+"modelName": "STMTN5MMSC21-MMSC::model-1-0",\r
+"modelVersion": "1",\r
+"modelCustomizationUuid": "ee6478e5-ea33-3346-ac12-ab121484a3fe"\r
+},\r
+"subscriberInfo" : {\r
+"globalSubscriberId" : "MSO_1610_dev_id",\r
+"subscriberName" : "MSO_1610_dev_name"\r
+},\r
+"cloudConfiguration": {\r
+"lcpCloudRegionId": "MDTWNJ21",\r
+"tenantId": "fba1bd1e195a404cacb9ce17a9b2b421"\r
+},\r
+"requestInfo": {\r
+"instanceName": "PCRF::module-0-2",\r
+"source": "VID",\r
+"suppressRollback": true\r
+},\r
+"relatedInstanceList": [\r
+{\r
+"relatedInstance": {\r
+"instanceId": "17ef4658-bd1f-4ef0-9ca0-ea76e2bf122c",\r
+"instanceName": "MSOTESTVOL103a-vSAMP12_base_module-0_vol",\r
+"modelInfo": {\r
+"modelType": "volumeGroup",\r
+"modelInvariantId": "ff5256d2-5a33-55df-13ab-12abad84e7ff",\r
+"modelNameVersionId": "fe6478e5-ea33-3346-ac12-ab121484a3fe",\r
+"modelName": "vSAMP12..base..module-0",\r
+"modelVersion": "1"\r
+}\r
+}\r
+},\r
+{\r
+"relatedInstance": {\r
+"instanceId": "123456",\r
+"modelInfo": {\r
+"modelType": "service",\r
+"modelInvariantId": "ff3514e3-5a33-55df-13ab-12abad84e7ff",\r
+"modelNameVersionId": "fe6985cd-ea33-3346-ac12-ab121484a3fe",\r
+"modelName": "SERVICE_MODEL_NAME",\r
+"modelVersion": "1.0"\r
+}\r
+}\r
+},\r
+{\r
+"relatedInstance": {\r
+"instanceId": "skask",\r
+"instanceName": "skask-test",\r
+"modelInfo": {\r
+"modelType": "vnf",\r
+"modelInvariantId": "skask",\r
+"modelNameVersionId": "fe6478e4-ea33-3346-ac12-ab121484a3fe",\r
+"modelName": "vSAMP12",\r
+"modelVersion": "1.0",\r
+"modelCustomizationName": "vSAMP12 1"\r
+}\r
+}\r
+}\r
+],\r
+"requestParameters": {\r
+"usePreload": true,\r
+"userParams": {}\r
+}\r
+}
\ No newline at end of file
--- /dev/null
+{\r
+"requestDetails": {\r
+"modelInfo": {\r
+"modelType": "vfModule",\r
+"modelInvariantId": "ff5256d2-5a33-55df-13ab-12abad84e7ff",\r
+"modelNameVersionId": "fe6478e5-ea33-3346-ac12-ab121484a3fe",\r
+"modelName": "STMTN5MMSC21-MMSC::model-1-0",\r
+"modelVersion": "1",\r
+"modelCustomizationUuid": "ee6478e5-ea33-3346-ac12-ab121484a3fe"\r
+},\r
+"subscriberInfo" : {\r
+"globalSubscriberId" : "MSO_1610_dev_id",\r
+"subscriberName" : "MSO_1610_dev_name"\r
+},\r
+"cloudConfiguration": {\r
+"lcpCloudRegionId": "MDTWNJ21",\r
+"tenantId": "fba1bd1e195a404cacb9ce17a9b2b421"\r
+},\r
+"requestInfo": {\r
+"instanceName": "PCRF::module-0-2",\r
+"source": "VID",\r
+"suppressRollback": true\r
+},\r
+"relatedInstanceList": [\r
+{\r
+"relatedInstance": {\r
+"instanceId": "17ef4658-bd1f-4ef0-9ca0-ea76e2bf122c",\r
+"instanceName": "MSOTESTVOL103a-vSAMP12_base_module-0_vol",\r
+"modelInfo": {\r
+"modelType": "volumeGroup",\r
+"modelInvariantId": "ff5256d2-5a33-55df-13ab-12abad84e7ff",\r
+"modelNameVersionId": "fe6478e5-ea33-3346-ac12-ab121484a3fe",\r
+"modelName": "vSAMP12..base..module-0",\r
+"modelVersion": "1"\r
+}\r
+}\r
+},\r
+{\r
+"relatedInstance": {\r
+"instanceId": "123456",\r
+"modelInfo": {\r
+"modelType": "service",\r
+"modelInvariantId": "ff3514e3-5a33-55df-13ab-12abad84e7ff",\r
+"modelNameVersionId": "fe6985cd-ea33-3346-ac12-ab121484a3fe",\r
+"modelName": "SERVICE_MODEL_NAME",\r
+"modelVersion": "1.0"\r
+}\r
+}\r
+},\r
+{\r
+"relatedInstance": {\r
+"instanceId": "skask",\r
+"instanceName": "skask-test",\r
+"modelInfo": {\r
+"modelType": "vnf",\r
+"modelInvariantId": "skask",\r
+"modelNameVersionId": "fe6478e4-ea33-3346-ac12-ab121484a3fe",\r
+"modelName": "vSAMP12",\r
+"modelVersion": "1.0",\r
+"modelCustomizationName": "vSAMP12 1"\r
+}\r
+}\r
+}\r
+],\r
+"requestParameters": {\r
+"usePreload": false,\r
+"userParams" : [\r
+ {\r
+ "name" : "someUserParam",\r
+ "value" : "someValue"\r
+ },\r
+ { \r
+ "name": "sgi_protected_subnet_id", \r
+ "value": "thisissomefakevalue" \r
+ }\r
+]\r
+\r
+}\r
+}
\ No newline at end of file
--- /dev/null
+
+
+<ns2:updateRequestResponse xmlns:ns2="http://com.att.mso/requestsdb"
+ xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"/>
\ No newline at end of file
--- /dev/null
+<generic-vnf xmlns="http://com.att.aai.inventory/v7">\r
+ <vnf-id>12345678-f41f-4822-9323-b75962763d74</vnf-id>\r
+ <vnf-name>STMTN5MMSC20</vnf-name>\r
+ <vnf-type>pcrf-capacity</vnf-type>\r
+ <service-id>SDN-MOBILITY</service-id>\r
+ <equipment-role>vPCRF</equipment-role>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <in-maint>false</in-maint>\r
+ <is-closed-loop-disabled>false</is-closed-loop-disabled>\r
+ <model-invariant-id>introvert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+ <resource-version>0000020</resource-version>\r
+ <vf-modules>\r
+ <vf-module>\r
+ <vf-module-id>lukewarm</vf-module-id>\r
+ <vf-module-name>PCRF::module-0-0</vf-module-name>\r
+ <model-invariant-id>extrovert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+ <is-base-vf-module>true</is-base-vf-module>\r
+ <heat-stack-id>fastburn</heat-stack-id>\r
+ <module-index>2</module-index>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <resource-version>0000074</resource-version>\r
+ </vf-module>\r
+ <vf-module>\r
+ <vf-module-id>supercool</vf-module-id>\r
+ <vf-module-name>PCRF::module-1-0</vf-module-name>\r
+ <model-invariant-id>extrovert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+ <is-base-vf-module>false</is-base-vf-module> \r
+ <heat-stack-id>slowburn</heat-stack-id>\r
+ <module-index>0</module-index>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <resource-version>0000075</resource-version>\r
+ </vf-module>\r
+ <vf-module>\r
+ <vf-module-id>supercool</vf-module-id>\r
+ <vf-module-name>PCRF::module-1-0</vf-module-name>\r
+ <model-invariant-id>introvert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+ <is-base-vf-module>false</is-base-vf-module> \r
+ <heat-stack-id>slowburn</heat-stack-id>\r
+ <module-index>1</module-index>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <resource-version>0000075</resource-version>\r
+ </vf-module>\r
+ </vf-modules>\r
+ <relationship-list/>\r
+ <l-interfaces/>\r
+ <lag-interfaces/>\r
+</generic-vnf>\r
-<generic-vnf xmlns="http://org.openecomp.aai.inventory/v7">
- <vnf-id>skask</vnf-id>
- <vnf-name>STMTN5MMSC20</vnf-name>
- <vnf-type>pcrf-capacity</vnf-type>
- <service-id>SDN-MOBILITY</service-id>
- <equipment-role>vPCRF</equipment-role>
- <orchestration-status>pending-create</orchestration-status>
- <in-maint>false</in-maint>
- <is-closed-loop-disabled>false</is-closed-loop-disabled>
- <persona-model-id>introvert</persona-model-id>
- <persona-model-version>2.0</persona-model-version>
- <resource-version>0000020</resource-version>
- <vf-modules>
- <vf-module>
- <vf-module-id>lukewarm</vf-module-id>
- <vf-module-name>PCRF::module-0-0</vf-module-name>
- <persona-model-id>introvert</persona-model-id>
- <persona-model-version>2.0</persona-model-version>
- <is-base-vf-module>true</is-base-vf-module>
- <heat-stack-id>fastburn</heat-stack-id>
- <orchestration-status>pending-create</orchestration-status>
- <resource-version>0000074</resource-version>
- </vf-module>
- <vf-module>
- <vf-module-id>supercool</vf-module-id>
- <vf-module-name>PCRF::module-1-0</vf-module-name>
- <persona-model-id>extrovert</persona-model-id>
- <persona-model-version>2.0</persona-model-version>
- <is-base-vf-module>false</is-base-vf-module>
- <heat-stack-id>slowburn</heat-stack-id>
- <orchestration-status>pending-create</orchestration-status>
- <resource-version>0000075</resource-version>
- </vf-module>
- </vf-modules>
- <relationship-list/>
- <l-interfaces/>
- <lag-interfaces/>
-</generic-vnf>
+<generic-vnf xmlns="http://com.att.aai.inventory/v7">\r
+ <vnf-id>skask</vnf-id>\r
+ <vnf-name>STMTN5MMSC20</vnf-name>\r
+ <vnf-type>pcrf-capacity</vnf-type>\r
+ <service-id>SDN-MOBILITY</service-id>\r
+ <equipment-role>vPCRF</equipment-role>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <in-maint>false</in-maint>\r
+ <is-closed-loop-disabled>false</is-closed-loop-disabled>\r
+ <model-invariant-id>introvert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+ <resource-version>0000020</resource-version>\r
+ <vf-modules>\r
+ <vf-module>\r
+ <vf-module-id>lukewarm</vf-module-id>\r
+ <vf-module-name>PCRF::module-0-0</vf-module-name>\r
+ <model-invariant-id>introvert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+ <is-base-vf-module>true</is-base-vf-module>\r
+ <heat-stack-id>fastburn</heat-stack-id>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <resource-version>0000074</resource-version>\r
+ </vf-module>\r
+ <vf-module>\r
+ <vf-module-id>supercool</vf-module-id>\r
+ <vf-module-name>PCRF::module-1-0</vf-module-name>\r
+ <model-invariant-id>extrovert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+ <is-base-vf-module>false</is-base-vf-module>\r
+ <heat-stack-id>slowburn</heat-stack-id>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <resource-version>0000075</resource-version>\r
+ </vf-module>\r
+ </vf-modules>\r
+ <relationship-list/>\r
+ <l-interfaces/>\r
+ <lag-interfaces/>\r
+</generic-vnf>\r
--- /dev/null
+<output
+ xmlns="com:att:sdnctl:generic-resource">
+ <svc-request-id>094d311c-40bc-4ff1-9617-37c4226efcc3</svc-request-id>
+ <response-code>200</response-code>
+ <response-message></response-message>
+ <ack-final-indicator>Y</ack-final-indicator>
+ <service-response-information>
+ <instance-id>8462db9b-3e91-4e90-a2c8-6471313f87bf</instance-id>
+ <object-path>restconf/config/GENERIC-RESOURCE-API:services/service/8462db9b-3e91-4e90-a2c8-6471313f87bf/service-data/service-topology/</object-path>
+ </service-response-information>
+</output>
\ No newline at end of file
--- /dev/null
+<output xmlns="com:att:sdnctl:vnf">\r
+ <vnf-information>\r
+ <vnf-id>skask</vnf-id>\r
+ </vnf-information>\r
+ <response-code>200</response-code>\r
+ <svc-request-id>{{REQUEST-ID}}</svc-request-id>\r
+ <ack-final-indicator>Y</ack-final-indicator>\r
+ <service-information>\r
+ <subscriber-name>dontcare</subscriber-name>\r
+ <service-instance-id>0</service-instance-id>\r
+ <service-type>SDN-MOBILITY</service-type>\r
+ </service-information>\r
+</output>
\ No newline at end of file
--- /dev/null
+ <output xmlns="com:att:sdnctl:vnf">\r
+ <vnf-information>\r
+ <vnf-id>skask</vnf-id> \r
+ </vnf-information>\r
+ <response-code>200</response-code>\r
+ <svc-request-id>{{REQUEST-ID}}</svc-request-id>\r
+ <ack-final-indicator>Y</ack-final-indicator>\r
+ <service-information>\r
+ <subscriber-name>dontcare</subscriber-name>\r
+ <service-instance-id>0</service-instance-id>\r
+ <service-type>SDN-MOBILITY</service-type>\r
+ </service-information>\r
+ <instance-reference>\r
+ <object-path>restconf/SDNCObjectPath</object-path>\r
+ </instance-reference>\r
+ </output>
\ No newline at end of file
--- /dev/null
+ <output xmlns="com:att:sdnctl:vnf">\r
+ <vnf-information>\r
+ <vnf-id>skask</vnf-id>\r
+ </vnf-information>\r
+ <response-code>200</response-code>\r
+ <svc-request-id>{{REQUEST-ID}}</svc-request-id>\r
+ <ack-final-indicator>Y</ack-final-indicator>\r
+ <service-information>\r
+ <subscriber-name>dontcare</subscriber-name>\r
+ <service-instance-id>0</service-instance-id>\r
+ <service-type>SDN-MOBILITY</service-type>\r
+ </service-information>\r
+ </output>
\ No newline at end of file
--- /dev/null
+<output xmlns="com:att:sdnctl:vnf">\r
+<vnf-list xmlns="com:att:sdnctl:vnf">\r
+ <vnf-id>bd1b3789-6474-4935-94b2-90b656e035d0</vnf-id>\r
+ <service-data>\r
+ <vnf-id>bd1b3789-6474-4935-94b2-90b656e035d0</vnf-id>\r
+ <sdnc-request-header>\r
+ <svc-request-id>9ddf628a-9eca-430e-8974-22d520a31be1</svc-request-id>\r
+ <svc-action>assign</svc-action>\r
+ <svc-notification-url>https://msojra.infra.aic.att.net:8443/adapters/rest/SDNCNotify</svc-notification-url>\r
+ </sdnc-request-header>\r
+ <service-information>\r
+ <subscriber-name>notsurewecare</subscriber-name>\r
+ <service-instance-id>bd1b3789-6474-4935-94b2-90b656e035d0</service-instance-id>\r
+ <service-type>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-type>\r
+ <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
+ </service-information>\r
+ <oper-status>\r
+ <order-status>PendingCreate</order-status>\r
+ </oper-status>\r
+ <vnf-request-information>\r
+ <aic-cloud-region>VNN1CA52LCP</aic-cloud-region>\r
+ <vnf-name>skask</vnf-name>\r
+ <generic-vnf-id>afd0f02a-1ddb-43bb-aded-5113e46e82ae</generic-vnf-id>\r
+ <generic-vnf-type>ZVNN1MOGX01-SVC/ZVNN1MOGX01 - VF AUG 1 1</generic-vnf-type>\r
+ <generic-vnf-name>ZVNN1MOGX01</generic-vnf-name>\r
+ <tenant>33d209df14ac4c08ad60747185d2f3e0</tenant>\r
+ <vnf-id>bd1b3789-6474-4935-94b2-90b656e035d0</vnf-id>\r
+ <vnf-type>ZVNN1MOGX01 - VF AUG 1::module-0</vnf-type>\r
+ </vnf-request-information>\r
+ <vnf-topology-information>\r
+ <vnf-assignments>\r
+ <vnf-networks>\r
+ <network-role>mog_exn</network-role>\r
+ <network-id>03dbd833-785c-40c0-bf32-37594b5334bc</network-id>\r
+ <network-name>MNS-25180-P-VNNYCA01_exn_protected_net_1</network-name>\r
+ <contrail-network-fqdn/>\r
+ <subnet-id/>\r
+ <neutron-id>6f82d234-41a4-48e9-a9e8-415667a72929</neutron-id>\r
+ <sriov-vlan-filter-list>\r
+ <sriov-vlan-filter>filter1</sriov-vlan-filter>\r
+ </sriov-vlan-filter-list>\r
+ <sriov-vlan-filter-list>\r
+ <sriov-vlan-filter>filter2</sriov-vlan-filter> \r
+ </sriov-vlan-filter-list>\r
+ </vnf-networks>\r
+ <vnf-networks>\r
+ <network-role>mog_oam</network-role>\r
+ <network-id>3f181cde-9380-4c20-9d3a-e1a4ee74f994</network-id>\r
+ <network-name>MNS-25180-P-VNNYCA01_oam_protected_net_1</network-name>\r
+ <contrail-network-fqdn/>\r
+ <subnet-id/>\r
+ <neutron-id>713b6770-13fa-4949-8dbb-a1288c5e5932</neutron-id>\r
+ </vnf-networks>\r
+ <vnf-networks>\r
+ <network-role>mog_cor_B</network-role>\r
+ <network-id>821a550a-3f50-4725-995b-f212d5caec7c</network-id>\r
+ <network-name>MNS-25180-P-VNNYCA01_cor_direct_net_1</network-name>\r
+ <contrail-network-fqdn/>\r
+ <subnet-id/>\r
+ <neutron-id>18926e56-12b6-4a4d-98b6-37e0c05626ee</neutron-id>\r
+ </vnf-networks>\r
+ <vnf-networks>\r
+ <network-role>mog_cor_A</network-role>\r
+ <network-id>3dabf5c0-cffb-420c-8960-8499c74eb25f</network-id>\r
+ <network-name>MNS-25180-P-VNNYCA01_cor_direct_net_2</network-name>\r
+ <contrail-network-fqdn/>\r
+ <subnet-id/>\r
+ <neutron-id>35530b29-a4de-48ff-a014-111110ccc652</neutron-id>\r
+ </vnf-networks>\r
+ <vnf-networks>\r
+ <network-role>mog_gn</network-role>\r
+ <network-id>3ce97321-6e7f-49af-bd12-f833e377c310</network-id>\r
+ <network-name>MNS-25180-P-VNNYCA01_gn_direct_net_1</network-name>\r
+ <contrail-network-fqdn/>\r
+ <subnet-id/>\r
+ <neutron-id>32bfdd2c-28e1-4895-87a6-373bf12c3129</neutron-id>\r
+ </vnf-networks>\r
+ <vnf-networks>\r
+ <network-role>mog_dmz</network-role>\r
+ <network-id>d43ca910-02a5-47dc-8510-100a68a3c9e0</network-id>\r
+ <network-name>MNS-25180-P-VNNYCA01_dmz_protected_net_1</network-name>\r
+ <contrail-network-fqdn/>\r
+ <subnet-id/>\r
+ <neutron-id>cb9500fb-943f-412e-aea6-458711564a75</neutron-id>\r
+ </vnf-networks>\r
+ <availability-zones>\r
+ <availability-zone>nova</availability-zone>\r
+ </availability-zones>\r
+ <vnf-vms>\r
+ <vm-type>ps</vm-type>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MPS001</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MPS002</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MPS003</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MPS004</vm-name>\r
+ </vm-names>\r
+ <vm-count>4</vm-count>\r
+ <vm-networks>\r
+ <network-role>mog_cor_B</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.36.251</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.252</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.253</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.254</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ </vm-networks>\r
+ </vnf-vms>\r
+ <vnf-vms>\r
+ <vm-type>cm</vm-type>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MCM001</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01OAM002</vm-name>\r
+ </vm-names>\r
+ <vm-count>1</vm-count>\r
+ <vm-networks>\r
+ <network-role>mog_cor_B</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.36.249</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.250</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ </vm-networks>\r
+ <vm-networks>\r
+ <network-role>mog_oam</network-role>\r
+ <network-ips>\r
+ <ip-address>107.239.167.250</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.239.167.251</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ </vm-networks>\r
+ </vnf-vms>\r
+ <vnf-vms>\r
+ <vm-type>oam</vm-type>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01OAM001</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01OAM002</vm-name>\r
+ </vm-names>\r
+ <vm-count>2</vm-count>\r
+ <vm-networks>\r
+ <network-role>mog_oam</network-role>\r
+ <network-ips>\r
+ <ip-address>107.239.167.252</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.239.167.251</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ </vm-networks>\r
+ <vm-networks>\r
+ <network-role>mog_cor_B</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.36.249</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.250</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ </vm-networks>\r
+ </vnf-vms>\r
+ <vnf-vms>\r
+ <vm-type>pd</vm-type>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MPD001</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MPD002</vm-name>\r
+ </vm-names>\r
+ <vm-count>2</vm-count>\r
+ <vm-networks>\r
+ <network-role>mog_dmz</network-role>\r
+ <network-ips>\r
+ <ip-address>107.225.25.253</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.225.25.254</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ <floating-ip>107.225.254.253</floating-ip>\r
+ </vm-networks>\r
+ <vm-networks>\r
+ <network-role>mog_oam</network-role>\r
+ <network-ips>\r
+ <ip-address>107.239.167.254</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.239.167.253</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ <floating-ip>107.239.167.249</floating-ip>\r
+ </vm-networks>\r
+ <vm-networks>\r
+ <network-role>mog_exn</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.46.253</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.46.254</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ <floating-ip>107.224.46.252</floating-ip>\r
+ </vm-networks>\r
+ <vm-networks>\r
+ <network-role>mog_cor_B</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.36.247</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.248</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ <floating-ip>107.224.41.252</floating-ip>\r
+ </vm-networks>\r
+ <vm-networks>\r
+ <network-role>mog_gn</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.41.253</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.41.254</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ <floating-ip>107.224.41.252</floating-ip>\r
+ </vm-networks>\r
+ <vm-networks>\r
+ <network-role>mog_cor_A</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.38.253</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.38.254</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ </vm-networks>\r
+ </vnf-vms>\r
+ <vnf-vms>\r
+ <vm-type>sm</vm-type>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MSM001</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MSM002</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MSM003</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MSM004</vm-name>\r
+ </vm-names>\r
+ <vm-count>4</vm-count>\r
+ <vm-networks>\r
+ <network-role>mog_cor_B</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.36.243</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.244</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.245</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.246</ip-address>\r
+ </network-ips>\r
+ <use-dhcp>N</use-dhcp>\r
+ </vm-networks>\r
+ </vnf-vms>\r
+ </vnf-assignments>\r
+ <vnf-topology-identifier>\r
+ <vnf-name>ZVNNMOGX01_base</vnf-name>\r
+ <service-type>SDN-MOBILITY</service-type>\r
+ <vnf-type>ZVNN1MOGX01 - VF AUG 1::module-0</vnf-type>\r
+ <generic-vnf-type>ZVNN1MOGX01-SVC/ZVNN1MOGX01 - VF AUG 1 1</generic-vnf-type>\r
+ <generic-vnf-name>ZVNN1MOGX01</generic-vnf-name>\r
+ </vnf-topology-identifier>\r
+ </vnf-topology-information>\r
+ <request-information>\r
+ <request-id>9ddf628a-9eca-430e-8974-22d520a31be1</request-id>\r
+ <notification-url/>\r
+ <source>PORTAL</source>\r
+ <request-action>VNFActivateRequest</request-action>\r
+ </request-information>\r
+ </service-data>\r
+ <service-status>\r
+ <response-code>200</response-code>\r
+ <final-indicator>Y</final-indicator>\r
+ <request-status>synccomplete</request-status>\r
+ <response-timestamp>2016-08-05T16:15:19.398Z</response-timestamp>\r
+ <rpc-name>vnf-topology-operation</rpc-name>\r
+ <vnfsdn-action>VNFActivateRequest</vnfsdn-action>\r
+ <rpc-action>assign</rpc-action>\r
+ </service-status>\r
+</vnf-list>\r
+\r
+</output>\r
--- /dev/null
+<output xmlns="com:att:sdnctl:vnf">\r
+ <vnf-list xmlns="com:att:sdnctl:vnf">\r
+ <vnf-id>28455973-1ee5-4ad1-8d35-c4732679743a</vnf-id>\r
+ <service-status>\r
+ <response-code>200</response-code>\r
+ <final-indicator>Y</final-indicator>\r
+ <request-status>synccomplete</request-status>\r
+ <response-timestamp>2016-06-08T19:44:59.138Z</response-timestamp>\r
+ <rpc-name>vnf-topology-operation</rpc-name>\r
+ <vnfsdn-action>VNFActivateRequest</vnfsdn-action>\r
+ <rpc-action>assign</rpc-action>\r
+ </service-status>\r
+ <service-data>\r
+ <vnf-id>28455973-1ee5-4ad1-8d35-c4732679743</vnf-id>\r
+ <service-information>\r
+ <subscriber-name>notsurewecare</subscriber-name>\r
+ <service-instance-id>28455973-1ee5-4ad1-8d35-c4732679743a</service-instance-id>\r
+ <service-type>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-type>\r
+ <service-id>a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb</service-id>\r
+ </service-information>\r
+ <sdnc-request-header>\r
+ <svc-request-id>5e168556-a5c6-4813-bff3-cc03007afbbc</svc-request-id>\r
+ <svc-notification-url>http://mtanjv9moja01-eth1-0.aic.cip.att.com:8080/adapters/rest/SDNCNotify</svc-notification-url>\r
+ <svc-action>assign</svc-action>\r
+ </sdnc-request-header>\r
+ <vnf-request-information>\r
+ <aic-cloud-region>AAIAIC25</aic-cloud-region>\r
+ <vnf-name>MSOTEST06-vSAMP3::base::module-0</vnf-name>\r
+ <generic-vnf-id>91ad7ab0-9ffd-471d-971c-3eb913a2cc75</generic-vnf-id>\r
+ <generic-vnf-type>Test/vSAMP3 1</generic-vnf-type>\r
+ <generic-vnf-name>MSOTEST06</generic-vnf-name>\r
+ <tenant>4ae1d3446a4c48b2bec44b6cfba06d68</tenant>\r
+ <vnf-id>28455973-1ee5-4ad1-8d35-c4732679743a</vnf-id>\r
+ <vnf-type>vSAMP3::base::module-0</vnf-type>\r
+ </vnf-request-information>\r
+ <oper-status>\r
+ <order-status>PendingCreate</order-status> \r
+ </oper-status>\r
+ <vnf-topology-information>\r
+ <vnf-parameters>\r
+ <vnf-parameter-name>image</vnf-parameter-name>\r
+ <vnf-parameter-value>Ubuntu_Perf</vnf-parameter-value>\r
+ </vnf-parameters>\r
+ <vnf-parameters>\r
+ <vnf-parameter-name>flavor</vnf-parameter-name>\r
+ <vnf-parameter-value>m1.small</vnf-parameter-value>\r
+ </vnf-parameters>\r
+ <vnf-assignments>\r
+ <vnf-networks>\r
+ <network-role>int_imbl</network-role>\r
+ <network-id>680b7453-0ec4-4d96-b355-280d981d418f</network-id>\r
+ <network-name>Nimbus-25193-T-Willows2_int_imbl_net_1</network-name>\r
+ <contrail-network-fqdn>default-domain:Nimbus-25193-T-Willows2:Nimbus-25193-T-Willows2_int_imbl_net_1</contrail-network-fqdn>\r
+ <subnet-id></subnet-id>\r
+ <ipv6-subnet-id>775607fb-e16a-45ef-94a7-82fba0d16eec</ipv6-subnet-id>\r
+ <neutron-id>640d07fb-e16a-45ef-94a7-82fba0d169bf</neutron-id>\r
+ <sriov-vlan-filter-list>\r
+ <sriov-vlan-filter>filter1</sriov-vlan-filter>\r
+ </sriov-vlan-filter-list>\r
+ <sriov-vlan-filter-list>\r
+ <sriov-vlan-filter>filter2</sriov-vlan-filter> \r
+ </sriov-vlan-filter-list>\r
+ </vnf-networks>\r
+ <vnf-networks>\r
+ <network-role>sgi_protected</network-role>\r
+ <network-id>f9039ce9-e3cf-4716-b2d1-ec7912178ea4</network-id>\r
+ <network-name>Nimbus-25193-T-Willows2_sgi_protected_net_1</network-name>\r
+ <contrail-network-fqdn>default-domain:Nimbus-25193-T-Willows2:Nimbus-25193-T-Willows2_sgi_protected_net_1</contrail-network-fqdn>\r
+ <subnet-id>b9999ce9-e3cf-4716-b2d1-ec791217678c</subnet-id>\r
+ <ipv6-subnet-id></ipv6-subnet-id>\r
+ <neutron-id>bf11bba8-b971-4ab5-8281-215b3fedcd3c</neutron-id>\r
+ </vnf-networks>\r
+ <vnf-vms>\r
+ <vm-type>cm</vm-type>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01MCM001</vm-name>\r
+ </vm-names>\r
+ <vm-names>\r
+ <vm-name>ZVNN1MOGX01OAM002</vm-name>\r
+ </vm-names>\r
+ <vm-count>1</vm-count>\r
+ <vm-networks>\r
+ <network-role>mog_cor_B</network-role>\r
+ <network-ips>\r
+ <ip-address>107.224.36.249</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.224.36.250</ip-address>\r
+ </network-ips>\r
+ <network-ips-v6>\r
+ <ip-address-ipv6>2606:ae00:2e01:800::67</ip-address-ipv6>\r
+ </network-ips-v6>\r
+ <use-dhcp>N</use-dhcp>\r
+ <floating-ip>107.224.41.252</floating-ip>\r
+ <floating-ip-v6>2001:1890:1001:2B32::29:C</floating-ip-v6>\r
+ </vm-networks>\r
+ <vm-networks>\r
+ <network-role>mog_oam</network-role>\r
+ <network-ips>\r
+ <ip-address>107.239.167.250</ip-address>\r
+ </network-ips>\r
+ <network-ips>\r
+ <ip-address>107.239.167.251</ip-address>\r
+ </network-ips>\r
+ <network-ips-v6>\r
+ <ip-address-ipv6>aa::aa::aa::aa::aa::aa</ip-address-ipv6> \r
+ </network-ips-v6>\r
+ <network-ips-v6>\r
+ <ip-address-ipv6>bb::bb::bb::bb::bb::bb</ip-address-ipv6>\r
+ </network-ips-v6>\r
+ <interface-route-prefixes> \r
+ <interface-route-prefix-cidr>1.2.3.4/26</interface-route-prefix-cidr>\r
+ </interface-route-prefixes>\r
+ <interface-route-prefixes> \r
+ <interface-route-prefix-cidr>2002::/64</interface-route-prefix-cidr>\r
+ </interface-route-prefixes>\r
+ <use-dhcp>N</use-dhcp>\r
+ <floating-ip-v6>1111:1890:1001:2B32::29:D</floating-ip-v6>\r
+ </vm-networks>\r
+ </vnf-vms>\r
+ <availability-zones>\r
+ <availability-zone>nova</availability-zone>\r
+ </availability-zones>\r
+ </vnf-assignments>\r
+ <vnf-topology-identifier>\r
+ <vnf-name>MSOTEST06-vSAMP3::base::module-0</vnf-name>\r
+ <service-type>SDN-MOBILITY</service-type>\r
+ <vnf-type>vSAMP3::base::module-0</vnf-type>\r
+ <generic-vnf-type>Test/vSAMP3 1</generic-vnf-type>\r
+ <generic-vnf-name>MSOTEST06</generic-vnf-name>\r
+ </vnf-topology-identifier> \r
+ </vnf-topology-information>\r
+ <request-information>\r
+ <request-id>5e168556-a5c6-4813-bff3-cc03007afbbc</request-id>\r
+ <notification-url></notification-url>\r
+ <source>SoapUI-bns-vf-base-vSAMP3-9001</source>\r
+ <request-action>VNFActivateRequest</request-action> \r
+ </request-information>\r
+ </service-data>\r
+</vnf-list>\r
+</output>\r
--- /dev/null
+<createVfModuleResponse>\r
+ <vnfId>skask</vnfId>\r
+ <vfModuleId>supercool</vfModuleId>\r
+ <vfModuleStackId>slowburn</vfModuleStackId>\r
+ <vfModuleCreated>true</vfModuleCreated>\r
+ <vfModuleOutputs>\r
+ <entry>\r
+ <key>key1</key>\r
+ <value>value1</value>\r
+ </entry>\r
+ <entry>\r
+ <key>key2</key>\r
+ <value>value2</value>\r
+ </entry>\r
+ <entry>\r
+<key>server1_private_ip</key>\r
+<value>192.168.28.3</value>\r
+</entry>\r
+<entry>\r
+<key>contrail-service-instance-fqdn</key>\r
+<value>default-domain:MSOTest:MsoNW-RA</value>\r
+</entry>\r
+<entry>\r
+<key>policyKey1_contrail_network_policy_fqdn</key>\r
+<value>MSOTest:DefaultPolicyFQDN1</value>\r
+</entry>\r
+<entry>\r
+<key>policyKey2_contrail_network_policy_fqdn</key>\r
+<value>MSOTest:DefaultPolicyFQDN2</value>\r
+</entry>\r
+<entry>\r
+<key>oam_management_v6_address</key>\r
+<value>2000:abc:bce:1111</value>\r
+</entry>\r
+<entry>\r
+<key>oam_management_v4_address</key>\r
+<value>127.0.0.1</value>\r
+</entry>\r
+ </vfModuleOutputs>\r
+ <rollback> <!-- JC's doc has "vfModuleRollback" -->\r
+ <vnfId>skask</vnfId>\r
+ <vfModuleId>supercool</vfModuleId>\r
+ <vfModuleStackId>slowburn</vfModuleStackId>\r
+ <vfModuleCreated>true</vfModuleCreated>\r
+ <tenantId>tenantId</tenantId>\r
+ <cloudSiteId>cloudSiteId</cloudSiteId>\r
+ <msoRequest>\r
+ <requestId>requestId</requestId>\r
+ <serviceInstanceId>serviceInstanceId</serviceInstanceId>\r
+ </msoRequest>\r
+ <messageId>{{MESSAGE-ID}}</messageId> <!-- JC's doc does not have this -->\r
+ </rollback>\r
+ <messageId>{{MESSAGE-ID}}</messageId>\r
+</createVfModuleResponse>\r
+\r
--- /dev/null
+<updateVfModuleResponse>\r
+ <vnfId>skask</vnfId>\r
+ <vfModuleId>supercool</vfModuleId>\r
+ <vfModuleStackId>slowburn</vfModuleStackId>\r
+ <vfModuleOutputs>\r
+ <entry>\r
+ <key>key1</key>\r
+ <value>value1</value>\r
+ </entry>\r
+ <entry>\r
+ <key>key2</key>\r
+ <value>value2</value>\r
+ </entry>\r
+ </vfModuleOutputs>\r
+ <messageId>{{MESSAGE-ID}}</messageId>\r
+</updateVfModuleResponse>\r
--- /dev/null
+<updateVolumeGroupResponse>\r
+ <volumeGroupId>78987</volumeGroupId>\r
+ <volumeGroupStackId>slowburn</volumeGroupStackId>\r
+ <vfModuleOutputs>\r
+ <entry>\r
+ <key>key1</key>\r
+ <value>value1</value>\r
+ </entry>\r
+ <entry>\r
+ <key>key2</key>\r
+ <value>value2</value>\r
+ </entry>\r
+ </vfModuleOutputs>\r
+ <messageId>{{MESSAGE-ID}}</messageId>\r
+</updateVolumeGroupResponse>\r
--- /dev/null
+<vf-module xmlns="http://com.att.aai.inventory/v7">\r
+ <vf-module-id>lukewarm</vf-module-id>\r
+ <vf-module-name>PCRF::module-1</vf-module-name>\r
+ <heat-stack-id>slowburn</heat-stack-id>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <is-base-vf-module>true</is-base-vf-module>\r
+ <resource-version>330-90</resource-version>\r
+ <model-invariant-id>introvert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+</vf-module>
\ No newline at end of file
-<vf-module xmlns="http://org.openecomp.aai.inventory/v7">
- <vf-module-id>b37d96db-7d2c-47ce-bf61-a6c7b82fe161</vf-module-id>
- <vf-module-name>PCRF::module-0-2</vf-module-name>
- <persona-model-id>00000000-0000-0000-0000-000000000000</persona-model-id>
- <persona-model-version>1.0</persona-model-version>
- <is-base-vf-module>false</is-base-vf-module>
- <orchestration-status>pending-create</orchestration-status>
- <resource-version>330-90</resource-version>
+<vf-module xmlns="http://com.att.aai.inventory/v7">\r
+ <vf-module-id>b37d96db-7d2c-47ce-bf61-a6c7b82fe161</vf-module-id>\r
+ <vf-module-name>PCRF::module-0-2</vf-module-name>\r
+ <model-invariant-id>00000000-0000-0000-0000-000000000000</model-invariant-id>\r
+ <model-version-id>1.0</model-version-id>\r
+ <is-base-vf-module>false</is-base-vf-module>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <resource-version>330-90</resource-version>\r
</vf-module>
\ No newline at end of file
-<vf-module xmlns="http://org.openecomp.aai.inventory/v7">
- <vf-module-id>supercool</vf-module-id>
- <vf-module-name>PCRF::module-2</vf-module-name>
- <heat-stack-id>fastburn</heat-stack-id>
- <orchestration-status>pending-create</orchestration-status>
- <is-base-vf-module>false</is-base-vf-module>
- <resource-version>330-89</resource-version>
- <persona-model-id>introvert</persona-model-id>
- <persona-model-version>2.0</persona-model-version>
- <relationship-list>
- <relationship>
- <related-to>volume-group</related-to>
- <relationship-data>
- <relationship-key>cloud-region.cloud-owner</relationship-key>
- <relationship-value>att-aic</relationship-value>
- </relationship-data>
- <relationship-data>
- <relationship-key>cloud-region.cloud-region-id</relationship-key>
- <relationship-value>pdk1</relationship-value>
- </relationship-data>
- <relationship-data>
- <relationship-key>volume-group.volume-group-id</relationship-key>
- <relationship-value>78987</relationship-value>
- </relationship-data>
- </relationship>
- </relationship-list>
+<vf-module xmlns="http://com.att.aai.inventory/v7">\r
+ <vf-module-id>supercool</vf-module-id>\r
+ <vf-module-name>PCRF::module-2</vf-module-name>\r
+ <heat-stack-id>fastburn</heat-stack-id>\r
+ <orchestration-status>pending-create</orchestration-status>\r
+ <is-base-vf-module>false</is-base-vf-module>\r
+ <resource-version>330-89</resource-version>\r
+ <model-invariant-id>introvert</model-invariant-id>\r
+ <model-version-id>2.0</model-version-id>\r
+ <relationship-list>\r
+ <relationship>\r
+ <related-to>volume-group</related-to>\r
+ <relationship-data>\r
+ <relationship-key>cloud-region.cloud-owner</relationship-key>\r
+ <relationship-value>att-aic</relationship-value>\r
+ </relationship-data>\r
+ <relationship-data>\r
+ <relationship-key>cloud-region.cloud-region-id</relationship-key>\r
+ <relationship-value>pdk1</relationship-value>\r
+ </relationship-data>\r
+ <relationship-data>\r
+ <relationship-key>volume-group.volume-group-id</relationship-key>\r
+ <relationship-value>78987</relationship-value>\r
+ </relationship-data>\r
+ </relationship>\r
+ </relationship-list>\r
</vf-module>
\ No newline at end of file
mso.msoKey=07a7159d3bf51a0e53be7a8f89699be7\r
\r
mso.adapters.completemsoprocess.endpoint=http://localhost:28090/CompleteMsoProcess\r
-\r
+mso.workflow.message.endpoint=http://localhost:8080/mso/WorkflowMessage\r
+mso.catalog.db.endpoint=http://localhost:8090\r
mso.adapters.db.endpoint=http://localhost:28090/dbadapters/RequestsDbAdapter\r
mso.adapters.db.auth=757A94191D685FD2092AC1490730A4FC\r
\r
mso.sdnc.firewall.yang.model.version=2015-05-15\r
mso.sdnc.password=3141634BF7E070AA289CF2892C986C0B\r
mso.sdnc.timeout.firewall.minutes=20\r
+mso.callbackRetryAttempts=5\r
mso.sdnc.timeout=PT10S\r
mso.sdnc.timeout.ucpe.async.hours=120\r
mso.sdnc.timeout.ucpe.async.minutes=5\r
# Example to override default version for a resource:\r
#mso.workflow.default.aai.vce.version=6\r
#mso.workflow.default.aai.v6.vce.uri=/aai/v6/network/vces/vce\r
-\r
+mso.workflow.global.default.aai.namespace=http://org.openecomp.aai.inventory/\r
mso.workflow.global.default.aai.version=8\r
mso.workflow.default.aai.cloud-region.version=9\r
mso.workflow.default.aai.generic-vnf.version=9\r
import static com.github.tomakehurst.wiremock.client.WireMock.containing;\r
import static com.github.tomakehurst.wiremock.client.WireMock.delete;\r
import static com.github.tomakehurst.wiremock.client.WireMock.get;\r
+import static com.github.tomakehurst.wiremock.client.WireMock.post;\r
import static com.github.tomakehurst.wiremock.client.WireMock.patch;\r
import static com.github.tomakehurst.wiremock.client.WireMock.put;\r
import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;\r
.withStatus(200)));\r
}\r
\r
+ /////////////\r
+ \r
+ public static void MockVNFAdapterRestVfModule() {\r
+ stubFor(put(urlEqualTo("/vnfs/v1/vnfs/skask/vf-modules/supercool"))\r
+ .willReturn(aResponse()\r
+ .withStatus(202)\r
+ .withHeader("Content-Type", "application/xml")));\r
+ stubFor(post(urlMatching("/vnfs/v1/vnfs/.*/vf-modules"))\r
+ .willReturn(aResponse()\r
+ .withStatus(202)\r
+ .withHeader("Content-Type", "application/xml")));\r
+ stubFor(post(urlEqualTo("/vnfs/v1/vnfs/skask/vf-modules"))\r
+ .willReturn(aResponse()\r
+ .withStatus(202)\r
+ .withHeader("Content-Type", "application/xml")));\r
+ stubFor(put(urlEqualTo("/vnfs/v1/volume-groups/78987"))\r
+ .willReturn(aResponse()\r
+ .withStatus(202)\r
+ .withHeader("Content-Type", "application/xml")));\r
+ }\r
+ \r
+ public static void MockDBUpdateVfModule(){\r
+ stubFor(post(urlEqualTo("/dbadapters/RequestsDbAdapter"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/DBUpdateResponse.xml")));\r
+ }\r
+ \r
+ // start of mocks used locally and by other VF Module unit tests\r
+ public static void MockSDNCAdapterVfModule() {\r
+ // simplified the implementation to return "success" for all requests\r
+ stubFor(post(urlEqualTo("/SDNCAdapter"))\r
+// .withRequestBody(containing("SvcInstanceId><"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/StandardSDNCSynchResponse.xml")));\r
+\r
+ }\r
+ \r
+ // start of mocks used locally and by other VF Module unit tests\r
+ public static void MockAAIVfModule() {\r
+ stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/supercool"))\r
+ .atPriority(1)\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/VfModule-supercool.xml"))); \r
+ stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/lukewarm"))\r
+ .atPriority(2)\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/VfModule-lukewarm.xml")));\r
+ stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/.*"))\r
+ .atPriority(5)\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/VfModule-new.xml")));\r
+ stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask[?]depth=1"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/GenericVnf.xml")));\r
+ stubFor(patch(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/supercool"))\r
+// .withRequestBody(containing("PCRF"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)));\r
+ stubFor(patch(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/.*"))\r
+// .withRequestBody(containing("PCRF"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)));\r
+ // HTTP PUT stub still used by CreateAAIvfModuleVolumeGroup\r
+ stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/.*"))\r
+ .withRequestBody(containing("PCRF"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)));\r
+ // HTTP PUT stub still used by DoCreateVfModuleTest\r
+ stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/.*"))\r
+ .withRequestBody(containing("MODULELABEL"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)));\r
+ stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/volume-groups/volume-group[?]volume-group-id=78987"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/ConfirmVolumeGroupTenantResponse.xml")));\r
+ stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/volume-groups/volume-group[?]volume-group-id=78987"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/ConfirmVolumeGroupTenantResponse.xml")));\r
+ stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/MDTWNJ21/volume-groups/volume-group/78987"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/VolumeGroup.xml")));\r
+ stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/AAIAIC25/volume-groups/volume-group/78987"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/VolumeGroup.xml")));\r
+ stubFor(delete(urlMatching("/aai/v[0-9]+/cloud-infrastructure/volume-groups/volume-group/78987[?]resource-version=0000020"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("DeleteCinderVolumeV1/DeleteVolumeId_AAIResponse_Success.xml")));\r
+ stubFor(put(urlMatching("/aai/v[0-9]+/network/network-policies/network-policy/.*"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)\r
+ .withHeader("Content-Type", "text/xml")\r
+ .withBodyFile("VfModularity/AddNetworkPolicy_AAIResponse_Success.xml")));\r
+ stubFor(patch(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/NEWvBNGModuleId"))\r
+ .withRequestBody(containing("NEWvBNGModuleId"))\r
+ .willReturn(aResponse()\r
+ .withStatus(200)));\r
+ }\r
+\r
+ \r
+ \r
+ //////////////\r
\r
/**\r
* Cloud infrastructure below\r
.withStatus(returnCode)));\r
}\r
\r
+ public static void MockAAIVfModuleBadPatch(String endpoint, int statusCode) {\r
+ stubFor(patch(urlMatching(endpoint))\r
+ .willReturn(aResponse()\r
+ .withStatus(statusCode)));\r
+ }\r
+ \r
//// Deprecated Stubs below - to be deleted once unit test that reference them are refactored to use common ones above ////\r
@Deprecated\r
public static void MockGetVceById(){\r
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
import org.apache.http.Header;
import org.apache.http.HttpResponse;
-import org.apache.http.message.BasicHeader;
import org.apache.http.util.EntityUtils;
/**
* An immutable class that encapsulates an API response.
- *
+ *
* @version 1.0
* @since 1.0
*/
public class APIResponse {
private final int statusCode;
private final byte[] responseBody;
- private final BasicHeader[] headers;
+ private final HttpHeader[] headers;
/**
* Internal method used to create http headers using the specified
* @param httpResponse used to create headers
* @return http headers
*/
- private static BasicHeader[] buildHeaders(final HttpResponse httpResponse) {
+ private static HttpHeader[] buildHeaders(final HttpResponse httpResponse) {
final Header[] headers = httpResponse.getAllHeaders();
- BasicHeader[] httpHeaders = new BasicHeader[headers.length];
+ HttpHeader[] httpHeaders = new HttpHeader[headers.length];
for (int i = 0; i < headers.length; ++i) {
final Header header = headers[i];
final String name = header.getName();
- final String value = header.getValue();
- final BasicHeader httpHeader = new BasicHeader(name, value);
+ final String value = header.getValue();
+ final HttpHeader httpHeader = new HttpHeader(name, value);
httpHeaders[i] = httpHeader;
- }
+ }
return httpHeaders;
}
/**
* Gets the http status code returned by the api server.
* <p>
- * For example, status code 200 represents 'OK.'
+ * For example, status code 200 represents 'OK.'
*
* @return status code
*/
/**
* Gets a list of all the headers returned by the API response.
*
- * @return an array of all the BasicHeaders
+ * @return an array of all the HttpHeaders
*/
- public BasicHeader[] getAllHeaders() {
+ public HttpHeader[] getAllHeaders() {
// avoid exposing internals, create copy
return Arrays.copyOf(this.headers, this.headers.length);
}
public String getFirstHeader(String name) {
- for (BasicHeader header : headers) {
+ for (HttpHeader header : headers) {
if (header.getName().equals(name)) {
return header.getValue();
}
--- /dev/null
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.rest;
+
+/**
+ * An immutable class used to wrap an http header.
+ *
+ * @version 1.0
+ * @since 1.0
+ */
+public class HttpHeader {
+ private final String name;
+ private final String value;
+
+ /**
+ * Create an http header using the specified name and value
+ *
+ * @param name name of http header
+ * @param value value of http header
+ */
+ public HttpHeader(final String name, final String value) {
+ if (name == null) {
+ throw new IllegalArgumentException("Name may not be null.");
+ }
+
+ this.name = name;
+ this.value = value;
+ }
+
+ /**
+ * Gets the header name.
+ *
+ * @return header name
+ */
+ public String getName() {
+ return this.name;
+ }
+
+ /**
+ * Gets the header value.
+ *
+ * @return header value
+ */
+ public String getValue() {
+ return this.value;
+ }
+}
import org.apache.http.entity.ByteArrayEntity;
import org.apache.http.entity.StringEntity;
import org.apache.http.impl.EnglishReasonPhraseCatalog;
-import org.apache.http.message.BasicHeader;
import org.apache.http.message.BasicHttpResponse;
import org.apache.http.message.BasicStatusLine;
import org.evosuite.runtime.EvoRunner;
BasicHttpResponse basicHttpResponse0 = new BasicHttpResponse((ProtocolVersion) null, 0, "");
basicHttpResponse0.addHeader("", "");
APIResponse aPIResponse0 = new APIResponse((HttpResponse) basicHttpResponse0);
- BasicHeader[] httpHeaderArray0 = aPIResponse0.getAllHeaders();
+ HttpHeader[] httpHeaderArray0 = aPIResponse0.getAllHeaders();
assertNotNull(httpHeaderArray0);
}
public void test11() throws Throwable {
BasicHttpResponse basicHttpResponse0 = new BasicHttpResponse((ProtocolVersion) null, 1471, "0fVXWr>");
APIResponse aPIResponse0 = new APIResponse((HttpResponse) basicHttpResponse0);
- BasicHeader[] httpHeaderArray0 = aPIResponse0.getAllHeaders();
+ HttpHeader[] httpHeaderArray0 = aPIResponse0.getAllHeaders();
assertNotNull(httpHeaderArray0);
}
aPIResponse0.getResponseBodyAsString();
basicHttpResponse0.getStatusLine();
aPIResponse0.getStatusCode();
- BasicHeader[] httpHeaderArray0 = new BasicHeader[2];
- BasicHeader httpHeader0 = mock(BasicHeader.class, new ViolatedAssumptionAnswer());
+ HttpHeader[] httpHeaderArray0 = new HttpHeader[2];
+ HttpHeader httpHeader0 = mock(HttpHeader.class, new ViolatedAssumptionAnswer());
doReturn((String) null).when(httpHeader0).getName();
httpHeaderArray0[0] = httpHeader0;
- BasicHeader httpHeader1 = mock(BasicHeader.class, new ViolatedAssumptionAnswer());
+ HttpHeader httpHeader1 = mock(HttpHeader.class, new ViolatedAssumptionAnswer());
httpHeaderArray0[1] = httpHeader1;
PrivateAccess.setVariable((Class<APIResponse>) APIResponse.class, aPIResponse0, "headers", (Object) httpHeaderArray0);
// Undeclared exception!
--- /dev/null
+/*
+ * This file was automatically generated by EvoSuite
+ * Mon Nov 14 11:47:07 GMT 2016
+ */
+
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.rest;
+
+import org.junit.Test;
+import static org.junit.Assert.*;
+import static org.evosuite.runtime.EvoAssertions.*;
+
+import org.evosuite.runtime.EvoRunner;
+import org.evosuite.runtime.EvoRunnerParameters;
+import org.evosuite.runtime.PrivateAccess;
+import org.junit.runner.RunWith;
+
+@RunWith(EvoRunner.class) @EvoRunnerParameters(mockJVMNonDeterminism = true, useVFS = true, useVNET = true, resetStaticState = true, useJEE = true)
+public class HttpHeaderESTest extends HttpHeaderESTestscaffolding {
+
+ @Test(timeout = 4000)
+ public void test0() throws Throwable {
+ HttpHeader httpHeader0 = new HttpHeader("Fw", "WD#>QF/v6_|_A");
+ String string0 = httpHeader0.getValue();
+ assertEquals("WD#>QF/v6_|_A", string0);
+ assertEquals("Fw", httpHeader0.getName());
+ }
+
+ @Test(timeout = 4000)
+ public void test1() throws Throwable {
+ HttpHeader httpHeader0 = new HttpHeader("", "");
+ String string0 = httpHeader0.getValue();
+ assertEquals("", string0);
+ }
+
+ @Test(timeout = 4000)
+ public void test2() throws Throwable {
+ HttpHeader httpHeader0 = new HttpHeader("Nae may no be null.", "Nae may no be null.");
+ PrivateAccess.setVariable((Class<HttpHeader>) HttpHeader.class, httpHeader0, "name", (Object) null);
+ String string0 = httpHeader0.getName();
+ assertNull(string0);
+ }
+
+ @Test(timeout = 4000)
+ public void test3() throws Throwable {
+ HttpHeader httpHeader0 = new HttpHeader("", "EIqJp");
+ String string0 = httpHeader0.getName();
+ assertEquals("EIqJp", httpHeader0.getValue());
+ assertEquals("", string0);
+ }
+
+ @Test(timeout = 4000)
+ public void test4() throws Throwable {
+ HttpHeader httpHeader0 = null;
+ try {
+ httpHeader0 = new HttpHeader((String) null, (String) null);
+ fail("Expecting exception: IllegalArgumentException");
+
+ } catch(IllegalArgumentException e) {
+ //
+ // Name may not be null.
+ //
+ verifyException("org.openecomp.mso.rest.HttpHeader", e);
+ }
+ }
+
+ @Test(timeout = 4000)
+ public void test5() throws Throwable {
+ HttpHeader httpHeader0 = new HttpHeader("Nae may no be null.", "Nae may no be null.");
+ String string0 = httpHeader0.getName();
+ assertEquals("Nae may no be null.", string0);
+ }
+
+ @Test(timeout = 4000)
+ public void test6() throws Throwable {
+ HttpHeader httpHeader0 = new HttpHeader("|SJ`pSz:BCB1o8~", (String) null);
+ String string0 = httpHeader0.getValue();
+ assertNull(string0);
+ }
+}
--- /dev/null
+/**
+ * Scaffolding file used to store all the setups needed to run
+ * tests automatically generated by EvoSuite
+ * Mon Nov 14 11:47:07 GMT 2016
+ */
+
+/*-
+ * ============LICENSE_START=======================================================
+ * OPENECOMP - MSO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.openecomp.mso.rest;
+
+import org.evosuite.runtime.annotation.EvoSuiteClassExclude;
+import org.junit.BeforeClass;
+import org.junit.Before;
+import org.junit.After;
+import org.junit.AfterClass;
+import org.evosuite.runtime.sandbox.Sandbox;
+
+@EvoSuiteClassExclude
+public class HttpHeaderESTestscaffolding {
+
+ @org.junit.Rule
+ public org.evosuite.runtime.vnet.NonFunctionalRequirementRule nfr = new org.evosuite.runtime.vnet.NonFunctionalRequirementRule();
+
+ private static final java.util.Properties defaultProperties = (java.util.Properties) java.lang.System.getProperties().clone();
+
+ private org.evosuite.runtime.thread.ThreadStopper threadStopper = new org.evosuite.runtime.thread.ThreadStopper (org.evosuite.runtime.thread.KillSwitchHandler.getInstance(), 3000);
+
+ @BeforeClass
+ public static void initEvoSuiteFramework() {
+ org.evosuite.runtime.RuntimeSettings.className = "org.openecomp.mso.rest.HttpHeader";
+ org.evosuite.runtime.GuiSupport.initialize();
+ org.evosuite.runtime.RuntimeSettings.maxNumberOfThreads = 100;
+ org.evosuite.runtime.RuntimeSettings.maxNumberOfIterationsPerLoop = 10000;
+ org.evosuite.runtime.RuntimeSettings.mockSystemIn = true;
+ org.evosuite.runtime.RuntimeSettings.sandboxMode = org.evosuite.runtime.sandbox.Sandbox.SandboxMode.RECOMMENDED;
+ org.evosuite.runtime.sandbox.Sandbox.initializeSecurityManagerForSUT();
+ org.evosuite.runtime.classhandling.JDKClassResetter.init();
+ initializeClasses();
+ org.evosuite.runtime.Runtime.getInstance().resetRuntime();
+ }
+
+ @AfterClass
+ public static void clearEvoSuiteFramework(){
+ Sandbox.resetDefaultSecurityManager();
+ java.lang.System.setProperties((java.util.Properties) defaultProperties.clone());
+ }
+
+ @Before
+ public void initTestCase(){
+ threadStopper.storeCurrentThreads();
+ threadStopper.startRecordingTime();
+ org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().initHandler();
+ org.evosuite.runtime.sandbox.Sandbox.goingToExecuteSUTCode();
+
+ org.evosuite.runtime.GuiSupport.setHeadless();
+ org.evosuite.runtime.Runtime.getInstance().resetRuntime();
+ org.evosuite.runtime.agent.InstrumentingAgent.activate();
+ }
+
+ @After
+ public void doneWithTestCase(){
+ threadStopper.killAndJoinClientThreads();
+ org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().safeExecuteAddedHooks();
+ org.evosuite.runtime.classhandling.JDKClassResetter.reset();
+ resetClasses();
+ org.evosuite.runtime.sandbox.Sandbox.doneWithExecutingSUTCode();
+ org.evosuite.runtime.agent.InstrumentingAgent.deactivate();
+ org.evosuite.runtime.GuiSupport.restoreHeadlessMode();
+ }
+
+
+ private static void initializeClasses() {
+ org.evosuite.runtime.classhandling.ClassStateSupport.initializeClasses(HttpHeaderESTestscaffolding.class.getClassLoader() ,
+ "org.openecomp.mso.rest.HttpHeader"
+ );
+ }
+
+ private static void resetClasses() {
+ }
+}
-/*-
- * ============LICENSE_START=======================================================
- * OPENECOMP - MSO
- * ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-
-package org.openecomp.mso.logger;
-
-
-import com.att.eelf.i18n.EELFResolvableErrorEnum;
-import com.att.eelf.i18n.EELFResourceManager;
-
-public enum MessageEnum implements EELFResolvableErrorEnum{
- // Api Handler Messages
- APIH_REQUEST_NULL,
- APIH_QUERY_FOUND,
- APIH_QUERY_NOT_FOUND,
- APIH_QUERY_PARAM_WRONG,
- APIH_DB_ACCESS_EXC,
- APIH_DB_ACCESS_EXC_REASON,
- APIH_VALIDATION_ERROR,
- APIH_REQUEST_VALIDATION_ERROR,
- APIH_SERVICE_VALIDATION_ERROR,
- APIH_GENERAL_EXCEPTION_ARG,
- APIH_GENERAL_EXCEPTION,
- APIH_GENERAL_WARNING,
- APIH_AUDIT_EXEC,
- APIH_GENERAL_METRICS,
- APIH_DUPLICATE_CHECK_EXC,
- APIH_DUPLICATE_FOUND,
- APIH_BAD_ORDER,
- APIH_DB_ATTRIBUTE_NOT_FOUND,
- APIH_BPEL_COMMUNICATE_ERROR,
- APIH_BPEL_RESPONSE_ERROR,
- APIH_WARP_REQUEST,
- APIH_ERROR_FROM_BPEL_SERVER,
- APIH_DB_INSERT_EXC,
- APIH_DB_UPDATE_EXC,
- APIH_NO_PROPERTIES,
- APIH_PROPERTY_LOAD_SUC,
- APIH_LOAD_PROPERTIES_FAIL,
- APIH_SDNC_COMMUNICATE_ERROR,
- APIH_SDNC_RESPONSE_ERROR,
- APIH_CANNOT_READ_SCHEMA,
- APIH_HEALTH_CHECK_EXCEPTION,
- APIH_REQUEST_VALIDATION_ERROR_REASON,
- APIH_JAXB_MARSH_ERROR,
- APIH_JAXB_UNMARSH_ERROR,
- APIH_VNFREQUEST_VALIDATION_ERROR,
- APIH_DOM2STR_ERROR,
- APIH_READ_VNFOUTPUT_CLOB_EXCEPTION,
- APIH_DUPLICATE_CHECK_EXC_ATT,
- APIH_GENERATED_REQUEST_ID,
- APIH_GENERATED_SERVICE_INSTANCE_ID,
- APIH_REPLACE_REQUEST_ID,
- // Resource Adapter Messages
- RA_GENERAL_EXCEPTION_ARG,
- RA_GENERAL_EXCEPTION,
- RA_GENERAL_WARNING,
- RA_MISSING_PARAM,
- RA_AUDIT_EXEC,
- RA_GENERAL_METRICS,
- RA_CREATE_STACK_TIMEOUT,
- RA_DELETE_STACK_TIMEOUT,
- RA_UPDATE_STACK_TIMEOUT,
- RA_CONNECTION_EXCEPTION,
- RA_PARSING_ERROR,
- RA_PROPERTIES_NOT_FOUND,
- RA_LOAD_PROPERTIES_SUC,
- RA_NETWORK_ALREADY_EXIST,
- RA_UPDATE_NETWORK_ERR,
- RA_CREATE_STACK_ERR,
- RA_UPDATE_STACK_ERR,
- RA_CREATE_TENANT_ERR,
- RA_NETWORK_NOT_FOUND,
- RA_NETWORK_ORCHE_MODE_NOT_SUPPORT,
- RA_CREATE_NETWORK_EXC,
- RA_PARAM_NOT_FOUND,
- RA_CONFIG_EXC,
- RA_UNKOWN_PARAM,
- RA_VLAN_PARSE,
- RA_DELETE_NETWORK_EXC,
- RA_ROLLBACK_NULL,
- RA_TENANT_NOT_FOUND,
- RA_QUERY_NETWORK_EXC,
- RA_CREATE_NETWORK_NOTIF_EXC,
- RA_ASYNC_ROLLBACK,
- RA_WSDL_NOT_FOUND,
- RA_WSDL_URL_CONVENTION_EXC,
- RA_INIT_NOTIF_EXC,
- RA_SET_CALLBACK_AUTH_EXC,
- RA_FAULT_INFO_EXC,
- RA_MARSHING_ERROR,
- RA_PARSING_REQUEST_ERROR,
- RA_SEND_REQUEST_SDNC,
- RA_RESPONSE_FROM_SDNC,
- RA_EXCEPTION_COMMUNICATE_SDNC,
- RA_EVALUATE_XPATH_ERROR,
- RA_ANALYZE_ERROR_EXC,
- RA_ERROR_GET_RESPONSE_SDNC,
- RA_CALLBACK_BPEL,
- RA_INIT_CALLBACK_WSDL_ERR,
- RA_CALLBACK_BPEL_EXC,
- RA_CALLBACK_BPEL_COMPLETE,
- RA_SDNC_MISS_CONFIG_PARAM,
- RA_SDNC_INVALID_CONFIG,
- RA_PRINT_URL,
- RA_ERROR_CREATE_SDNC_REQUEST,
- RA_ERROR_CREATE_SDNC_RESPONSE,
- RA_ERROR_CONVERT_XML2STR,
- RA_RECEIVE_SDNC_NOTIF,
- RA_INIT_SDNC_ADAPTER,
- RA_SEND_REQUEST_APPC_ERR,
- RA_SEND_REQUEST_SDNC_ERR,
- RA_RECEIVE_BPEL_REQUEST,
- RA_TENANT_ALREADY_EXIST,
- RA_UPDATE_TENANT_ERR,
- RA_DELETE_TEMAMT_ERR,
- RA_ROLLBACK_TENANT_ERR,
- RA_QUERY_VNF_ERR,
- RA_VNF_ALREADY_EXIST,
- RA_VNF_UNKNOWN_PARAM,
- RA_VNF_EXTRA_PARAM,
- RA_CREATE_VNF_ERR,
- RA_VNF_NOT_EXIST,
- RA_UPDATE_VNF_ERR,
- RA_DELETE_VNF_ERR,
- RA_ASYNC_CREATE_VNF,
- RA_SEND_VNF_NOTIF_ERR,
- RA_ASYNC_CREATE_VNF_COMPLETE,
- RA_ASYNC_UPDATE_VNF,
- RA_ASYNC_UPDATE_VNF_COMPLETE,
- RA_ASYNC_QUERY_VNF,
- RA_ASYNC_QUERY_VNF_COMPLETE,
- RA_ASYNC_DELETE_VNF,
- RA_ASYNC_DELETE_VNF_COMPLETE,
- RA_ASYNC_ROLLBACK_VNF,
- RA_ASYNC_ROLLBACK_VNF_COMPLETE,
- RA_ROLLBACK_VNF_ERR,
- RA_DB_INVALID_STATUS,
- RA_CANT_UPDATE_REQUEST,
- RA_DB_REQUEST_NOT_EXIST,
- RA_CONFIG_NOT_FOUND,
- RA_CONFIG_LOAD,
- RA_RECEIVE_WORKFLOW_MESSAGE,
- // BPEL engine Messages
- BPMN_GENERAL_INFO,
- BPMN_GENERAL_EXCEPTION_ARG,
- BPMN_GENERAL_EXCEPTION,
- BPMN_GENERAL_WARNING,
- BPMN_AUDIT_EXEC,
- BPMN_GENERAL_METRICS,
- BPMN_URN_MAPPING_FAIL,
- BPMN_VARIABLE_NULL,
- BPMN_SDNC_CALLBACK_EXCEPTION,
- // ASDC Messages
- ASDC_GENERAL_EXCEPTION_ARG,
- ASDC_GENERAL_EXCEPTION,
- ASDC_GENERAL_WARNING,
- ASDC_AUDIT_EXEC,
- ASDC_GENERAL_METRICS,
- ASDC_CREATE_SERVICE,
- ASDC_ARTIFACT_ALREADY_DEPLOYED,
- ASDC_CREATE_ARTIFACT,
- ASDC_ARTIFACT_INSTALL_EXC,
- ASDC_ARTIFACT_ALREADY_DEPLOYED_DETAIL,
- ASDC_ARTIFACT_NOT_DEPLOYED_DETAIL,
- ASDC_ARTIFACT_CHECK_EXC,
- ASDC_INIT_ASDC_CLIENT_EXC,
- ASDC_INIT_ASDC_CLIENT_SUC,
- ASDC_LOAD_ASDC_CLIENT_EXC,
- ASDC_SINGLETON_CHECKT_EXC,
- ASDC_SHUTDOWN_ASDC_CLIENT_EXC,
- ASDC_CHECK_HEAT_TEMPLATE,
- ASDC_START_INSTALL_ARTIFACT,
- ASDC_ARTIFACT_TYPE_NOT_SUPPORT,
- ASDC_ARTIFACT_ALREADY_EXIST,
- ASDC_ARTIFACT_DOWNLOAD_SUC,
- ASDC_ARTIFACT_DOWNLOAD_FAIL,
- ASDC_START_DEPLOY_ARTIFACT,
- ASDC_SEND_NOTIF_ASDC,
- ASDC_SEND_NOTIF_ASDC_EXEC,
- ASDC_RECEIVE_CALLBACK_NOTIF,
- ASDC_RECEIVE_SERVICE_NOTIF,
- ASDC_ARTIFACT_NULL,
- ASDC_SERVICE_NOT_SUPPORT,
- ASDC_ARTIFACT_DEPLOY_SUC,
- ASDC_PROPERTIES_NOT_FOUND,
- // Default Messages, in case Log catalog is not defined
- GENERAL_EXCEPTION_ARG,
- GENERAL_EXCEPTION,
- GENERAL_WARNING,
- AUDIT_EXEC,
- GENERAL_METRICS,
- LOGGER_SETUP,
- LOGGER_NOT_FOUND,
- LOGGER_UPDATE_SUC,
- LOGGER_UPDATE_DEBUG,
- LOGGER_UPDATE_DEBUG_SUC,
- LOAD_PROPERTIES_SUC,
- NO_PROPERTIES,
- MADATORY_PARAM_MISSING,
- LOAD_PROPERTIES_FAIL,
- INIT_LOGGER,
- INIT_LOGGER_FAIL,
- JAXB_EXCEPTION,
- IDENTITY_SERVICE_NOT_FOUND;
-
- static {
- EELFResourceManager.loadMessageBundle("GenericMessages");
- EELFResourceManager.loadMessageBundle("ApiHandler");
- EELFResourceManager.loadMessageBundle("BPMN");
- EELFResourceManager.loadMessageBundle("ResourceAdapter");
- EELFResourceManager.loadMessageBundle("ASDC");
- }
-}
+/*-\r
+ * ============LICENSE_START=======================================================\r
+ * OPENECOMP - MSO\r
+ * ================================================================================\r
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.\r
+ * ================================================================================\r
+ * Licensed under the Apache License, Version 2.0 (the "License");\r
+ * you may not use this file except in compliance with the License.\r
+ * You may obtain a copy of the License at\r
+ *\r
+ * http://www.apache.org/licenses/LICENSE-2.0\r
+ *\r
+ * Unless required by applicable law or agreed to in writing, software\r
+ * distributed under the License is distributed on an "AS IS" BASIS,\r
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+ * See the License for the specific language governing permissions and\r
+ * limitations under the License.\r
+ * ============LICENSE_END=========================================================\r
+ */\r
+\r
+package org.openecomp.mso.logger;\r
+\r
+\r
+import com.att.eelf.i18n.EELFResolvableErrorEnum;\r
+import com.att.eelf.i18n.EELFResourceManager;\r
+\r
+public enum MessageEnum implements EELFResolvableErrorEnum{\r
+ // Api Handler Messages\r
+ APIH_REQUEST_NULL,\r
+ APIH_QUERY_FOUND,\r
+ APIH_QUERY_NOT_FOUND,\r
+ APIH_QUERY_PARAM_WRONG,\r
+ APIH_DB_ACCESS_EXC,\r
+ APIH_DB_ACCESS_EXC_REASON,\r
+ APIH_VALIDATION_ERROR,\r
+ APIH_REQUEST_VALIDATION_ERROR,\r
+ APIH_SERVICE_VALIDATION_ERROR,\r
+ APIH_GENERAL_EXCEPTION_ARG,\r
+ APIH_GENERAL_EXCEPTION,\r
+ APIH_GENERAL_WARNING,\r
+ APIH_AUDIT_EXEC,\r
+ APIH_GENERAL_METRICS,\r
+ APIH_DUPLICATE_CHECK_EXC,\r
+ APIH_DUPLICATE_FOUND,\r
+ APIH_BAD_ORDER,\r
+ APIH_DB_ATTRIBUTE_NOT_FOUND,\r
+ APIH_BPEL_COMMUNICATE_ERROR,\r
+ APIH_BPEL_RESPONSE_ERROR,\r
+ APIH_WARP_REQUEST,\r
+ APIH_ERROR_FROM_BPEL_SERVER,\r
+ APIH_DB_INSERT_EXC,\r
+ APIH_DB_UPDATE_EXC,\r
+ APIH_NO_PROPERTIES,\r
+ APIH_PROPERTY_LOAD_SUC,\r
+ APIH_LOAD_PROPERTIES_FAIL,\r
+ APIH_SDNC_COMMUNICATE_ERROR,\r
+ APIH_SDNC_RESPONSE_ERROR,\r
+ APIH_CANNOT_READ_SCHEMA,\r
+ APIH_HEALTH_CHECK_EXCEPTION,\r
+ APIH_REQUEST_VALIDATION_ERROR_REASON,\r
+ APIH_JAXB_MARSH_ERROR,\r
+ APIH_JAXB_UNMARSH_ERROR,\r
+ APIH_VNFREQUEST_VALIDATION_ERROR,\r
+ APIH_DOM2STR_ERROR,\r
+ APIH_READ_VNFOUTPUT_CLOB_EXCEPTION,\r
+ APIH_DUPLICATE_CHECK_EXC_ATT,\r
+ APIH_GENERATED_REQUEST_ID,\r
+ APIH_GENERATED_SERVICE_INSTANCE_ID,\r
+ APIH_REPLACE_REQUEST_ID,\r
+ // Resource Adapter Messages\r
+ RA_GENERAL_EXCEPTION_ARG,\r
+ RA_GENERAL_EXCEPTION,\r
+ RA_GENERAL_WARNING,\r
+ RA_MISSING_PARAM,\r
+ RA_AUDIT_EXEC,\r
+ RA_GENERAL_METRICS,\r
+ RA_CREATE_STACK_TIMEOUT,\r
+ RA_DELETE_STACK_TIMEOUT,\r
+ RA_UPDATE_STACK_TIMEOUT,\r
+ RA_CONNECTION_EXCEPTION,\r
+ RA_PARSING_ERROR,\r
+ RA_PROPERTIES_NOT_FOUND,\r
+ RA_LOAD_PROPERTIES_SUC,\r
+ RA_NETWORK_ALREADY_EXIST,\r
+ RA_UPDATE_NETWORK_ERR,\r
+ RA_CREATE_STACK_ERR,\r
+ RA_UPDATE_STACK_ERR,\r
+ RA_CREATE_TENANT_ERR,\r
+ RA_NETWORK_NOT_FOUND,\r
+ RA_NETWORK_ORCHE_MODE_NOT_SUPPORT,\r
+ RA_CREATE_NETWORK_EXC,\r
+ RA_PARAM_NOT_FOUND,\r
+ RA_CONFIG_EXC,\r
+ RA_UNKOWN_PARAM,\r
+ RA_VLAN_PARSE,\r
+ RA_DELETE_NETWORK_EXC,\r
+ RA_ROLLBACK_NULL,\r
+ RA_TENANT_NOT_FOUND,\r
+ RA_QUERY_NETWORK_EXC,\r
+ RA_CREATE_NETWORK_NOTIF_EXC,\r
+ RA_ASYNC_ROLLBACK,\r
+ RA_WSDL_NOT_FOUND,\r
+ RA_WSDL_URL_CONVENTION_EXC,\r
+ RA_INIT_NOTIF_EXC,\r
+ RA_SET_CALLBACK_AUTH_EXC,\r
+ RA_FAULT_INFO_EXC,\r
+ RA_MARSHING_ERROR,\r
+ RA_PARSING_REQUEST_ERROR,\r
+ RA_SEND_REQUEST_SDNC,\r
+ RA_RESPONSE_FROM_SDNC,\r
+ RA_EXCEPTION_COMMUNICATE_SDNC,\r
+ RA_EVALUATE_XPATH_ERROR,\r
+ RA_ANALYZE_ERROR_EXC,\r
+ RA_ERROR_GET_RESPONSE_SDNC,\r
+ RA_CALLBACK_BPEL,\r
+ RA_INIT_CALLBACK_WSDL_ERR,\r
+ RA_CALLBACK_BPEL_EXC,\r
+ RA_CALLBACK_BPEL_COMPLETE,\r
+ RA_SDNC_MISS_CONFIG_PARAM,\r
+ RA_SDNC_INVALID_CONFIG,\r
+ RA_PRINT_URL,\r
+ RA_ERROR_CREATE_SDNC_REQUEST,\r
+ RA_ERROR_CREATE_SDNC_RESPONSE,\r
+ RA_ERROR_CONVERT_XML2STR,\r
+ RA_RECEIVE_SDNC_NOTIF,\r
+ RA_INIT_SDNC_ADAPTER,\r
+ RA_SEND_REQUEST_APPC_ERR,\r
+ RA_SEND_REQUEST_SDNC_ERR,\r
+ RA_RECEIVE_BPEL_REQUEST,\r
+ RA_TENANT_ALREADY_EXIST,\r
+ RA_UPDATE_TENANT_ERR,\r
+ RA_DELETE_TEMAMT_ERR,\r
+ RA_ROLLBACK_TENANT_ERR,\r
+ RA_QUERY_VNF_ERR,\r
+ RA_VNF_ALREADY_EXIST,\r
+ RA_VNF_UNKNOWN_PARAM,\r
+ RA_VNF_EXTRA_PARAM,\r
+ RA_CREATE_VNF_ERR,\r
+ RA_VNF_NOT_EXIST,\r
+ RA_UPDATE_VNF_ERR,\r
+ RA_DELETE_VNF_ERR,\r
+ RA_ASYNC_CREATE_VNF,\r
+ RA_SEND_VNF_NOTIF_ERR,\r
+ RA_ASYNC_CREATE_VNF_COMPLETE,\r
+ RA_ASYNC_UPDATE_VNF,\r
+ RA_ASYNC_UPDATE_VNF_COMPLETE,\r
+ RA_ASYNC_QUERY_VNF,\r
+ RA_ASYNC_QUERY_VNF_COMPLETE,\r
+ RA_ASYNC_DELETE_VNF,\r
+ RA_ASYNC_DELETE_VNF_COMPLETE,\r
+ RA_ASYNC_ROLLBACK_VNF,\r
+ RA_ASYNC_ROLLBACK_VNF_COMPLETE,\r
+ RA_ROLLBACK_VNF_ERR,\r
+ RA_DB_INVALID_STATUS,\r
+ RA_CANT_UPDATE_REQUEST,\r
+ RA_DB_REQUEST_NOT_EXIST,\r
+ RA_CONFIG_NOT_FOUND,\r
+ RA_CONFIG_LOAD,\r
+ RA_RECEIVE_WORKFLOW_MESSAGE,\r
+ // BPEL engine Messages\r
+ BPMN_GENERAL_INFO,\r
+ BPMN_GENERAL_EXCEPTION_ARG,\r
+ BPMN_GENERAL_EXCEPTION,\r
+ BPMN_GENERAL_WARNING,\r
+ BPMN_AUDIT_EXEC,\r
+ BPMN_GENERAL_METRICS,\r
+ BPMN_URN_MAPPING_FAIL,\r
+ BPMN_VARIABLE_NULL,\r
+ BPMN_SDNC_CALLBACK_EXCEPTION,\r
+ BPMN_CALLBACK_EXCEPTION,\r
+ // ASDC Messages\r
+ ASDC_GENERAL_EXCEPTION_ARG,\r
+ ASDC_GENERAL_EXCEPTION,\r
+ ASDC_GENERAL_WARNING,\r
+ ASDC_AUDIT_EXEC,\r
+ ASDC_GENERAL_METRICS,\r
+ ASDC_CREATE_SERVICE,\r
+ ASDC_ARTIFACT_ALREADY_DEPLOYED,\r
+ ASDC_CREATE_ARTIFACT,\r
+ ASDC_ARTIFACT_INSTALL_EXC,\r
+ ASDC_ARTIFACT_ALREADY_DEPLOYED_DETAIL,\r
+ ASDC_ARTIFACT_NOT_DEPLOYED_DETAIL,\r
+ ASDC_ARTIFACT_CHECK_EXC,\r
+ ASDC_INIT_ASDC_CLIENT_EXC,\r
+ ASDC_INIT_ASDC_CLIENT_SUC,\r
+ ASDC_LOAD_ASDC_CLIENT_EXC,\r
+ ASDC_SINGLETON_CHECKT_EXC,\r
+ ASDC_SHUTDOWN_ASDC_CLIENT_EXC,\r
+ ASDC_CHECK_HEAT_TEMPLATE,\r
+ ASDC_START_INSTALL_ARTIFACT,\r
+ ASDC_ARTIFACT_TYPE_NOT_SUPPORT,\r
+ ASDC_ARTIFACT_ALREADY_EXIST,\r
+ ASDC_ARTIFACT_DOWNLOAD_SUC,\r
+ ASDC_ARTIFACT_DOWNLOAD_FAIL,\r
+ ASDC_START_DEPLOY_ARTIFACT,\r
+ ASDC_SEND_NOTIF_ASDC,\r
+ ASDC_SEND_NOTIF_ASDC_EXEC,\r
+ ASDC_RECEIVE_CALLBACK_NOTIF,\r
+ ASDC_RECEIVE_SERVICE_NOTIF,\r
+ ASDC_ARTIFACT_NULL,\r
+ ASDC_SERVICE_NOT_SUPPORT,\r
+ ASDC_ARTIFACT_DEPLOY_SUC,\r
+ ASDC_PROPERTIES_NOT_FOUND,\r
+ // Default Messages, in case Log catalog is not defined\r
+ GENERAL_EXCEPTION_ARG,\r
+ GENERAL_EXCEPTION,\r
+ GENERAL_WARNING,\r
+ AUDIT_EXEC,\r
+ GENERAL_METRICS,\r
+ LOGGER_SETUP,\r
+ LOGGER_NOT_FOUND,\r
+ LOGGER_UPDATE_SUC,\r
+ LOGGER_UPDATE_DEBUG,\r
+ LOGGER_UPDATE_DEBUG_SUC,\r
+ LOAD_PROPERTIES_SUC,\r
+ NO_PROPERTIES,\r
+ MADATORY_PARAM_MISSING,\r
+ LOAD_PROPERTIES_FAIL,\r
+ INIT_LOGGER,\r
+ INIT_LOGGER_FAIL,\r
+ JAXB_EXCEPTION,\r
+ IDENTITY_SERVICE_NOT_FOUND;\r
+\r
+ static {\r
+ EELFResourceManager.loadMessageBundle("GenericMessages");\r
+ EELFResourceManager.loadMessageBundle("ApiHandler");\r
+ EELFResourceManager.loadMessageBundle("BPMN");\r
+ EELFResourceManager.loadMessageBundle("ResourceAdapter");\r
+ EELFResourceManager.loadMessageBundle("ASDC");\r
+ }\r
+}\r
<?xml version="1.0" encoding="UTF-8"?>
-<con:soapui-project id="5e41efd3-b2b2-4507-a41a-02227bd51b8a" activeEnvironment="Default" name="HealthCheck" resourceRoot="" soapui-version="5.3.0" abortOnError="false" runType="SEQUENTIAL" xmlns:con="http://eviware.com/soapui/config"><con:settings/><con:interface xsi:type="con:RestService" id="c7309861-55a2-458f-9408-6ddee8ed79a7" wadlVersion="http://wadl.dev.java.net/2009/02" name="SetStatus" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://localhost:8080</con:endpoint></con:endpoints><con:resource name="SetStatus false infra" path="/ecomp/mso/infra/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false Infra" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 401 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>text/plain</con:mediaType><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true infra" path="/ecomp/mso/infra/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true infra" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>text/plain</con:mediaType><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false apih asdc" path="/asdc/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false apih asdc" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 401 403</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:domain/><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true apih asdc" path="/asdc/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true apih asdc" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 401 403</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/plain</con:mediaType><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false networks" path="/networks/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false networks" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true networks" path="/networks/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true networks" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false vnfs" path="/vnfs/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false vnfs" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true vnfs" path="/vnfs/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true vnfs" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:domain/><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false tenants" path="/tenants/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false tenants" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true tenants" path="/tenants/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true tenants" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false JRA" path="/adapters/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false JRA" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true JRA" path="/adapters/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true JRA" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 403</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>text/plain</con:mediaType><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="f1eae1f1-1a12-43a3-84ea-b966442eafb0" wadlVersion="http://wadl.dev.java.net/2009/02" name="GlobalHealthcheck" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://localhost:8080</con:endpoint></con:endpoints><con:resource name="Infra" path="/ecomp/mso/infra/globalhealthcheck" id="85e05d47-4f09-4925-ab77-63f8a1665c27"><con:settings/><con:parameters><con:parameter><con:name>enableBpmn</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="GlobalHC Infra" id="1b6937c7-9d88-43c6-99b6-9dca4e891d5c" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="42ea1c51-a0ca-445e-8f98-4af039a2b59c" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/globalhealthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enableBpmn" value="${#Project#enableBpmn}" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enableBpmn</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="JRA adapters" path="/adapters/rest/globalhealthcheck" id="cba118a2-5d68-47ab-9440-51920466fff0"><con:settings/><con:parameters><con:parameter><con:name>enableBpmn</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="GlobalHC adapters" id="52ffdb3c-6f8a-43b0-8a52-a2b603e3d9c5" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="b1109ecf-fd73-4a30-8c98-ac50a10e9cb7" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/globalhealthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enableBpmn" value="${#Project#enableBpmn}" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enableBpmn</con:entry></con:parameterOrder></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="4609f980-4202-4e50-b09f-abec5534dfa3" wadlVersion="http://wadl.dev.java.net/2009/02" name="SubModulesHealthcheck" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://${#Project#jrahost}</con:endpoint></con:endpoints><con:resource name="JRA networks" path="/networks/rest/healthcheck" id="61b35716-b06e-47ba-9567-7757980f1b5a"><con:settings/><con:parameters/><con:method name="LocalHC networks" id="48acb940-91ac-4b32-b32b-8808b552e059" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>500</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="a8aa066b-ad81-40bc-9976-de44fe3dcc0a" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/networks/admin/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="JRA adapters" path="/adapters/rest/healthcheck" id="fa70036c-7280-43c5-a26d-8e2d42584ee1"><con:settings/><con:parameters/><con:method name="LocalHC adapters" id="7587d026-ebda-4c13-80df-b5a26f322164" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="ea2c9416-63eb-4219-83fd-db0593bf63e3" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@bind_address"/><con:setting id="com.eviware.soapui.impl.support.AbstractHttpRequest@follow-redirects">true</con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="JRA vnfs" path="/vnfs/rest/healthcheck" id="ee547629-e2ac-4932-b582-9586c6a3f464"><con:settings/><con:parameters/><con:method name="LocalHC vnfs" id="285c0bac-3c68-4f07-b231-5bba3217b60a" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>500 404</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="f2effc08-5569-4e5b-a2e8-fa3bebc958b9" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/vnfs/rest/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="JRA tenants" path="/tenants/rest/healthcheck" id="796ada77-fce3-493d-b003-10d4c1ecc498"><con:settings/><con:parameters/><con:method name="LocalHC tenants" id="2f9ae7ac-c18d-48eb-a43c-8624d9475b7f" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="432c2172-deba-4173-a0af-0b6fccfd60dc" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/tenants/admin/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="APIH Infra" path="/ecomp/mso/infra/healthcheck" id="29001acb-f40a-4ed3-af96-0415649eeacf"><con:settings/><con:parameters/><con:method name="LocalHC infra" id="6d7685fa-354e-44c6-b512-0e802673d341" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>404</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="287d8590-e1da-49e5-afef-5f7191a55925" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="APIH asdc" path="/asdc/healthcheck" id="b79d1f28-0b27-4897-90a5-b17032d533da"><con:settings/><con:parameters/><con:method name="LocalHC asdc" id="f251569b-3e62-44c0-80c2-b806a0b2cda1" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="b0d9d540-073e-4d1d-ac19-32566206d0c6" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/asdc/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="Camunadalocal" path="/mso/healthcheck" id="6740d63f-f8ba-40d8-8397-c8d9135d241a"><con:settings/><con:parameters/><con:method name="CamundaLocal" id="a3ae9bf4-e129-4c12-a1ac-0f2fab31d509" method="GET"><con:description>not used in Arquilian as not same repo</con:description><con:settings/><con:parameters/><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>application/json</con:mediaType><con:status>500 503</con:status><con:params/><con:element xmlns:heal="localhost/mso/async/services/HealthCheck">heal:Fault</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>400 404 405</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>application/json</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:heal="localhost/mso/async/services/HealthCheck">heal:Response</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>404</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="b85f87ca-6c69-46be-aa1d-cd9f0b1ce48d" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#bpmnhost}</con:endpoint><con:request>{"variables":{}}</con:request><con:originalUri>localhost/mso/async/services/HealthCheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="APIH dbadapters" path="/dbadapters/healthcheck" id="c9adf66c-dbfa-4f87-ba07-be9799ed3ef7"><con:settings/><con:parameters/><con:method name="LocalHC apih dbadapters" id="602a2bad-4bac-4bdc-b64a-c6b0250997e7" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="91778949-a8b8-4211-be98-5dcb477512a8" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="Camunadalocal variables2" path="/mso/async/services/HealthCheck" id="6740d63f-f8ba-40d8-8397-c8d9135d241a"><con:settings/><con:parameters/><con:method name="CamundaLocal2" id="a3ae9bf4-e129-4c12-a1ac-0f2fab31d509" method="POST"><con:description>not used in Arquilian as not same repo</con:description><con:settings/><con:parameters/><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>application/json</con:mediaType><con:status>500 503</con:status><con:params/><con:element xmlns:heal="localhost/mso/async/services/HealthCheck">heal:Fault</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>400 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>application/json</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:heal="localhost/mso/async/services/HealthCheck">heal:Response</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="b85f87ca-6c69-46be-aa1d-cd9f0b1ce48d" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#bpmnhost}</con:endpoint><con:request>{"variables":{"requestId":{"value":"test","type":"String"}}}</con:request><con:originalUri>localhost/mso/async/services/HealthCheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="Camundalocal2" path="/mso/common/healthcheck" id="5300f433-6b32-447a-b0de-1d26353167d8"><con:settings/><con:parameters/><con:method name="Method 1" id="6fc76777-eeee-4126-bfd1-9da0eb5b7921" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="02e386ce-803e-4d34-b2fd-a694a2cb2fc2" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="bc7ec14b-913e-4b98-bdd2-772f5a98e77d" wadlVersion="http://wadl.dev.java.net/2009/02" name="GetStatus" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://192.168.126.130:8080</con:endpoint></con:endpoints><con:resource name="GetStatus DB Adapter" path="/dbadapters/RequestsDbAdapter" id="911c26b8-4b1d-49e3-b969-02de4c62bd3f"><con:settings/><con:parameters/><con:method name="GetStatus RequestsDbAdapter" id="4748011f-fcc6-4920-b1f2-1956b8cafa34" method="POST"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/xml;charset=ISO-8859-1</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">soapenv:Envelope</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/xml</con:mediaType><con:params/><con:element xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">soapenv:Envelope</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/xml;charset=ISO-8859-1</con:mediaType><con:status>500</con:status><con:params/><con:element xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">soapenv:Envelope</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>404</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="8fbeebe9-cdf0-4715-837c-16ae3cfdd5fb" mediaType="application/xml" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:req="http://org.openecomp.mso/requestsdb">
+<con:soapui-project id="5e41efd3-b2b2-4507-a41a-02227bd51b8a" activeEnvironment="Default" name="HealthCheck" resourceRoot="" soapui-version="5.2.1" abortOnError="false" runType="SEQUENTIAL" xmlns:con="http://eviware.com/soapui/config"><con:settings/><con:interface xsi:type="con:RestService" id="c7309861-55a2-458f-9408-6ddee8ed79a7" wadlVersion="http://wadl.dev.java.net/2009/02" name="SetStatus" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://localhost:8080</con:endpoint></con:endpoints><con:resource name="SetStatus false infra" path="/ecomp/mso/infra/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false Infra" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 401 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>text/plain</con:mediaType><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true infra" path="/ecomp/mso/infra/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true infra" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>text/plain</con:mediaType><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false apih asdc" path="/asdc/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false apih asdc" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 401 403</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:domain/><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true apih asdc" path="/asdc/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true apih asdc" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 401 403</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/plain</con:mediaType><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false networks" path="/networks/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false networks" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true networks" path="/networks/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true networks" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false vnfs" path="/vnfs/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false vnfs" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true vnfs" path="/vnfs/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true vnfs" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:domain/><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false tenants" path="/tenants/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false tenants" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true tenants" path="/tenants/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true tenants" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus false JRA" path="/adapters/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus false JRA" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="false" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SetStatus true JRA" path="/adapters/rest/setStatus/{siteName}" id="d03a4e5b-b5a2-4215-a37d-d5852a03e2e8"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value>true</con:value><con:style>QUERY</con:style><con:default>true</con:default><con:path xsi:nil="true"/><con:description xsi:nil="true"/></con:parameter><con:parameter><con:name>siteName</con:name><con:value>${#Project#sitename}</con:value><con:style>TEMPLATE</con:style><con:default>${#Project#sitename}</con:default></con:parameter></con:parameters><con:method name="SetStatus true JRA" id="5d87cc87-ef01-44e7-8e6f-e177e088a6fe" method="POST"><con:settings/><con:parameters/><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>405 404 403</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>text/plain</con:mediaType><con:status>500</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="e0314e05-9a73-4402-a404-3a1b0aa78232" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/setStatus</con:originalUri><con:credentials><con:username>${#Project#userlogin}</con:username><con:password>${#Project#userpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/><con:parameterOrder><con:entry>enable</con:entry><con:entry>siteName</con:entry></con:parameterOrder></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="f1eae1f1-1a12-43a3-84ea-b966442eafb0" wadlVersion="http://wadl.dev.java.net/2009/02" name="GlobalHealthcheck" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://localhost:8080</con:endpoint></con:endpoints><con:resource name="Infra" path="/ecomp/mso/infra/globalhealthcheck" id="85e05d47-4f09-4925-ab77-63f8a1665c27"><con:settings/><con:parameters><con:parameter><con:name>enableBpmn</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="GlobalHC Infra" id="1b6937c7-9d88-43c6-99b6-9dca4e891d5c" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="42ea1c51-a0ca-445e-8f98-4af039a2b59c" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/globalhealthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enableBpmn" value="${#Project#enableBpmn}" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enableBpmn</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="JRA adapters" path="/adapters/rest/globalhealthcheck" id="cba118a2-5d68-47ab-9440-51920466fff0"><con:settings/><con:parameters><con:parameter><con:name>enableBpmn</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="GlobalHC adapters" id="52ffdb3c-6f8a-43b0-8a52-a2b603e3d9c5" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="b1109ecf-fd73-4a30-8c98-ac50a10e9cb7" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/globalhealthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enableBpmn" value="${#Project#enableBpmn}" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enableBpmn</con:entry></con:parameterOrder></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="4609f980-4202-4e50-b09f-abec5534dfa3" wadlVersion="http://wadl.dev.java.net/2009/02" name="SubModulesHealthcheck" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://${#Project#jrahost}</con:endpoint></con:endpoints><con:resource name="JRA networks" path="/networks/rest/healthcheck" id="61b35716-b06e-47ba-9567-7757980f1b5a"><con:settings/><con:parameters/><con:method name="LocalHC networks" id="48acb940-91ac-4b32-b32b-8808b552e059" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>500</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="a8aa066b-ad81-40bc-9976-de44fe3dcc0a" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/networks/admin/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="JRA adapters" path="/adapters/rest/healthcheck" id="fa70036c-7280-43c5-a26d-8e2d42584ee1"><con:settings/><con:parameters/><con:method name="LocalHC adapters" id="7587d026-ebda-4c13-80df-b5a26f322164" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="ea2c9416-63eb-4219-83fd-db0593bf63e3" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@bind_address"/><con:setting id="com.eviware.soapui.impl.support.AbstractHttpRequest@follow-redirects">true</con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="JRA vnfs" path="/vnfs/rest/healthcheck" id="ee547629-e2ac-4932-b582-9586c6a3f464"><con:settings/><con:parameters/><con:method name="LocalHC vnfs" id="285c0bac-3c68-4f07-b231-5bba3217b60a" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>500 404</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="f2effc08-5569-4e5b-a2e8-fa3bebc958b9" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/vnfs/rest/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="JRA tenants" path="/tenants/rest/healthcheck" id="796ada77-fce3-493d-b003-10d4c1ecc498"><con:settings/><con:parameters/><con:method name="LocalHC tenants" id="2f9ae7ac-c18d-48eb-a43c-8624d9475b7f" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="432c2172-deba-4173-a0af-0b6fccfd60dc" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/tenants/admin/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="APIH Infra" path="/ecomp/mso/infra/healthcheck" id="29001acb-f40a-4ed3-af96-0415649eeacf"><con:settings/><con:parameters/><con:method name="LocalHC infra" id="6d7685fa-354e-44c6-b512-0e802673d341" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>404</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="287d8590-e1da-49e5-afef-5f7191a55925" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="APIH asdc" path="/asdc/healthcheck" id="b79d1f28-0b27-4897-90a5-b17032d533da"><con:settings/><con:parameters/><con:method name="LocalHC asdc" id="f251569b-3e62-44c0-80c2-b806a0b2cda1" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="b0d9d540-073e-4d1d-ac19-32566206d0c6" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/asdc/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="Camunadalocal" path="/mso/healthcheck" id="6740d63f-f8ba-40d8-8397-c8d9135d241a"><con:settings/><con:parameters/><con:method name="CamundaLocal" id="a3ae9bf4-e129-4c12-a1ac-0f2fab31d509" method="GET"><con:description>not used in Arquilian as not same repo</con:description><con:settings/><con:parameters/><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>application/json</con:mediaType><con:status>500 503</con:status><con:params/><con:element xmlns:heal="localhost/mso/async/services/HealthCheck">heal:Fault</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>400 404 405</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>application/json</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:heal="localhost/mso/async/services/HealthCheck">heal:Response</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>404</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="b85f87ca-6c69-46be-aa1d-cd9f0b1ce48d" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#bpmnhost}</con:endpoint><con:request>{"variables":{}}</con:request><con:originalUri>localhost/mso/async/services/HealthCheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="APIH dbadapters" path="/dbadapters/healthcheck" id="c9adf66c-dbfa-4f87-ba07-be9799ed3ef7"><con:settings/><con:parameters/><con:method name="LocalHC apih dbadapters" id="602a2bad-4bac-4bdc-b64a-c6b0250997e7" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="91778949-a8b8-4211-be98-5dcb477512a8" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/healthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="Camunadalocal variables2" path="/mso/async/services/HealthCheck" id="6740d63f-f8ba-40d8-8397-c8d9135d241a"><con:settings/><con:parameters/><con:method name="CamundaLocal2" id="a3ae9bf4-e129-4c12-a1ac-0f2fab31d509" method="POST"><con:description>not used in Arquilian as not same repo</con:description><con:settings/><con:parameters/><con:representation type="REQUEST"><con:mediaType>application/json</con:mediaType><con:params/></con:representation><con:representation type="FAULT"><con:mediaType>application/json</con:mediaType><con:status>500 503</con:status><con:params/><con:element xmlns:heal="localhost/mso/async/services/HealthCheck">heal:Fault</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>400 404</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>application/json</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:heal="localhost/mso/async/services/HealthCheck">heal:Response</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="b85f87ca-6c69-46be-aa1d-cd9f0b1ce48d" mediaType="application/json" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#bpmnhost}</con:endpoint><con:request>{"variables":{"requestId":{"value":"test","type":"String"}}}</con:request><con:originalUri>localhost/mso/async/services/HealthCheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="Camundalocal2" path="/mso/common/healthcheck" id="5300f433-6b32-447a-b0de-1d26353167d8"><con:settings/><con:parameters/><con:method name="Method 1" id="6fc76777-eeee-4126-bfd1-9da0eb5b7921" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="02e386ce-803e-4d34-b2fd-a694a2cb2fc2" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="bc7ec14b-913e-4b98-bdd2-772f5a98e77d" wadlVersion="http://wadl.dev.java.net/2009/02" name="GetStatus" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://192.168.126.130:8080</con:endpoint></con:endpoints><con:resource name="GetStatus DB Adapter" path="/dbadapters/RequestsDbAdapter" id="911c26b8-4b1d-49e3-b969-02de4c62bd3f"><con:settings/><con:parameters/><con:method name="GetStatus RequestsDbAdapter" id="4748011f-fcc6-4920-b1f2-1956b8cafa34" method="POST"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/xml;charset=ISO-8859-1</con:mediaType><con:status>200</con:status><con:params/><con:element xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">soapenv:Envelope</con:element></con:representation><con:representation type="REQUEST"><con:mediaType>application/xml</con:mediaType><con:params/><con:element xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">soapenv:Envelope</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/xml;charset=ISO-8859-1</con:mediaType><con:status>500</con:status><con:params/><con:element xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">soapenv:Envelope</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>404</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="8fbeebe9-cdf0-4715-837c-16ae3cfdd5fb" mediaType="application/xml" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:req="http://org.openecomp.mso/requestsdb">
<soapenv:Header/>
<soapenv:Body>
<req:getSiteStatus>
<siteName>${#Project#sitename}</siteName>
</req:getSiteStatus>
</soapenv:Body>
-</soapenv:Envelope>]]></con:request><con:originalUri>http://localhost/dbadapters/RequestsDbAdapter</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="045c84cd-4ad1-4f49-a187-7b4448b5cf97" wadlVersion="http://wadl.dev.java.net/2009/02" name="NodeHealthCheck" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://localhost:8080</con:endpoint></con:endpoints><con:resource name="NodehealthcheckJRA" path="/adapters/rest/nodehealthcheck" id="eb7dc74a-2b7f-4d1e-88f3-15987452e24d"><con:settings/><con:parameters/><con:method name="NodehealthcheckJRA" id="67871396-2679-4871-bbe4-2e2b63ed4180" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="00db386c-942d-4286-853f-01e279f6c2cb" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/nodehealthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="NodehealthcheckAPIH-Infra" path="/ecomp/mso/infra/nodehealthcheck" id="eb7dc74a-2b7f-4d1e-88f3-15987452e24d"><con:settings/><con:parameters/><con:method name="NodehealthcheckAPIH-Infra" id="67871396-2679-4871-bbe4-2e2b63ed4180" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="00db386c-942d-4286-853f-01e279f6c2cb" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/nodehealthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="NodehealthcheckBPMN" path="/mso/nodehealthcheck" id="30a0b380-93d5-4611-896a-1afe2150434a"><con:settings/><con:parameters/><con:method name="Method 1" id="e8a46161-d0f0-4afa-ac17-705694845302" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="2259e1c1-003d-485f-b424-925d1ee65f01" mediaType="application/json"><con:settings/><con:endpoint>http://localhost:8080</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="0da04960-3bf4-4066-9ec2-d35d2d3c8c4d" wadlVersion="http://wadl.dev.java.net/2009/02" name="Logging" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints/><con:resource name="NetworkAdapter" path="/networks/rest/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="TenantAdapter" path="/tenants/rest/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="VNFAdapter" path="/vnfs/rest/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SDNCAdapter" path="/adapters/rest/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="APIH Infra" path="/ecomp/mso/infra/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="ASDC" path="/asdc/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="RequestDBAdapter" path="/dbadapters/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource></con:interface><con:testSuite id="bcee4cc9-9c4e-4eeb-a520-9a3c73458e1f" name="Healthcheck TestSuite"><con:settings/><con:runType>SEQUENTIAL</con:runType><con:testCase id="9b4e70e4-1cd1-4152-89e9-18e8a0225108" failOnError="true" failTestCaseOnErrors="true" keepSession="false" maxResults="0" name="TestCaseHC" searchProperties="true"><con:settings/><con:testStep type="restrequest" name="GetStatus RequestsDbAdapter - Request 1" id="b3161fab-24b4-442d-b662-49bdc46f697b"><con:settings/><con:config service="GetStatus" resourcePath="/dbadapters/RequestsDbAdapter" methodName="GetStatus RequestsDbAdapter" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="GetStatus RequestsDbAdapter - Request 1" id="8fbeebe9-cdf0-4715-837c-16ae3cfdd5fb" mediaType="application/xml" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:req="http://org.openecomp.mso/requestsdb">
+</soapenv:Envelope>]]></con:request><con:originalUri>http://localhost/dbadapters/RequestsDbAdapter</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="045c84cd-4ad1-4f49-a187-7b4448b5cf97" wadlVersion="http://wadl.dev.java.net/2009/02" name="NodeHealthCheck" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints><con:endpoint>http://localhost:8080</con:endpoint></con:endpoints><con:resource name="NodehealthcheckJRA" path="/adapters/rest/nodehealthcheck" id="eb7dc74a-2b7f-4d1e-88f3-15987452e24d"><con:settings/><con:parameters/><con:method name="NodehealthcheckJRA" id="67871396-2679-4871-bbe4-2e2b63ed4180" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="00db386c-942d-4286-853f-01e279f6c2cb" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/nodehealthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="NodehealthcheckAPIH-Infra" path="/ecomp/mso/infra/nodehealthcheck" id="eb7dc74a-2b7f-4d1e-88f3-15987452e24d"><con:settings/><con:parameters/><con:method name="NodehealthcheckAPIH-Infra" id="67871396-2679-4871-bbe4-2e2b63ed4180" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html;charset=utf-8</con:mediaType><con:status>401</con:status><con:params/><con:element>html</con:element></con:representation><con:representation type="FAULT"><con:mediaType>text/html</con:mediaType><con:status>503</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="00db386c-942d-4286-853f-01e279f6c2cb" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/nodehealthcheck</con:originalUri><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource><con:resource name="NodehealthcheckBPMN" path="/mso/nodehealthcheck" id="30a0b380-93d5-4611-896a-1afe2150434a"><con:settings/><con:parameters/><con:method name="Method 1" id="e8a46161-d0f0-4afa-ac17-705694845302" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType xsi:nil="true"/><con:status>0</con:status><con:params/><con:element>data</con:element></con:representation><con:representation type="RESPONSE"><con:mediaType>text/html</con:mediaType><con:status>200</con:status><con:params/><con:element>html</con:element></con:representation><con:request name="Request 1" id="2259e1c1-003d-485f-b424-925d1ee65f01" mediaType="application/json"><con:settings/><con:endpoint>http://localhost:8080</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:request></con:method></con:resource></con:interface><con:interface xsi:type="con:RestService" id="0da04960-3bf4-4066-9ec2-d35d2d3c8c4d" wadlVersion="http://wadl.dev.java.net/2009/02" name="Logging" type="rest" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart=""/><con:endpoints/><con:resource name="NetworkAdapter" path="/networks/rest/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="TenantAdapter" path="/tenants/rest/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:representation type="RESPONSE"><con:mediaType>text/plain</con:mediaType><con:status>200</con:status><con:params/><con:element>data</con:element></con:representation><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="VNFAdapter" path="/vnfs/rest/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="SDNCAdapter" path="/adapters/rest/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="APIH Infra" path="/ecomp/mso/infra/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="ASDC" path="/asdc/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="RequestDBAdapter" path="/dbadapters/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource><con:resource name="BPMN" path="/mso/logging/debug" id="957cb67e-9f74-40ef-bbc6-bfee1ef3c1d7"><con:settings/><con:parameters><con:parameter><con:name>enable</con:name><con:value/><con:style>QUERY</con:style><con:default/><con:description xsi:nil="true"/></con:parameter></con:parameters><con:method name="Debug 1" id="41e16995-0c45-4156-91b3-5fec12bb5aa8" method="GET"><con:settings/><con:parameters/><con:request name="Request 1" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#bpmnhost}</con:endpoint><con:request/><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:request></con:method></con:resource></con:interface><con:testSuite id="bcee4cc9-9c4e-4eeb-a520-9a3c73458e1f" name="Healthcheck TestSuite"><con:settings/><con:runType>SEQUENTIAL</con:runType><con:testCase id="9b4e70e4-1cd1-4152-89e9-18e8a0225108" failOnError="true" failTestCaseOnErrors="true" keepSession="false" maxResults="0" name="TestCaseHC" searchProperties="true"><con:settings/><con:testStep type="restrequest" name="Enable RequestDBAdapter debug logs" id="e83f44c7-1cd6-4c9f-9afd-fb91faf7cf41"><con:settings/><con:config service="Logging" resourcePath="/dbadapters/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable RequestDBAdapter debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/dbadapters/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="2e5b9577-aa74-43c7-9440-eb00314d091c" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable ASDC debug logs" id="d938876a-34c6-4de9-89dc-55a63e710c18"><con:settings/><con:config service="Logging" resourcePath="/asdc/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable ASDC debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/asdc/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="62995dde-fa57-409d-8480-befef3f6ff70" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable NetworkAdapter debug logs" id="64f3deb6-2675-4eb8-8600-9ed2be76acc3"><con:settings/><con:config service="Logging" methodName="Debug 1" resourcePath="/networks/rest/logging/debug" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable NetworkAdapter debug logs" id="ba42db46-5a97-48d1-a88c-bab5a11313ae" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/networks/rest/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="1f209f2c-b621-4168-bca4-cbe4b5da4c7e" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable TenantAdapter debug logs" id="a0ec3eda-28c1-43c1-9737-70a1b355874c"><con:settings/><con:config service="Logging" methodName="Debug 1" resourcePath="/tenants/rest/logging/debug" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable TenantAdapter debug logs" id="a97a886d-002c-4431-bf33-c7ab1d31e881" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/tenantss/rest/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="d984f832-9790-496a-911e-57e3d1780969" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable VNF Adapter debug logs" id="6153b51b-165a-4406-ab7e-e1f32ede7d75"><con:settings/><con:config service="Logging" resourcePath="/vnfs/rest/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable VNF Adapter debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/vnfs/rest/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="bdd35643-b216-4200-8f07-45fc8b0ad304" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable SDNC Adapter debug logs" id="69f77bce-b9e1-4462-b7e3-0a8620eafddc"><con:settings/><con:config service="Logging" resourcePath="/adapters/rest/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable SDNC Adapter debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="f4db96ec-603d-4c1c-897f-2a76e2948637" name="Valid HTTP Status Codes"><con:configuration><codes>200
+</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable APIH Infra debug logs" id="99d0ad17-f116-4506-82ab-7f8a60924fb6"><con:settings/><con:config service="Logging" resourcePath="/ecomp/mso/infra/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable APIH Infra debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="df4e7c2f-384d-47d3-a772-309d8a7d6dd5" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable BPMN debug logs" id="57b545f9-8eb8-45f4-8c91-8b8ce8866e62"><con:settings/><con:config service="Logging" resourcePath="/mso/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable BPMN debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="df4e7c2f-384d-47d3-a772-309d8a7d6dd5" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="GetStatus RequestsDbAdapter - Request 1" id="b3161fab-24b4-442d-b662-49bdc46f697b"><con:settings/><con:config service="GetStatus" resourcePath="/dbadapters/RequestsDbAdapter" methodName="GetStatus RequestsDbAdapter" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="GetStatus RequestsDbAdapter - Request 1" id="8fbeebe9-cdf0-4715-837c-16ae3cfdd5fb" mediaType="application/xml" postQueryString="false"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:req="http://org.openecomp.mso/requestsdb">
<soapenv:Header/>
<soapenv:Body>
<req:getSiteStatus>
<siteName>${#Project#sitename}</siteName>
</req:getSiteStatus>
</soapenv:Body>
-</soapenv:Envelope>]]></con:request><con:originalUri>http://localhost/dbadapters/RequestsDbAdapter</con:originalUri><con:assertion type="Simple Contains" id="98f1d604-1865-45ac-ae71-3d94000738f3" name="Contains"><con:configuration><token><return>true</return></token><ignoreCase>false</ignoreCase><useRegEx>false</useRegEx></con:configuration></con:assertion><con:credentials><con:username>${#Project#dbadapteruser}</con:username><con:password>${#Project#dbadapterpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="NodehealthcheckAPIH - Request 1 2" id="afd352c1-685b-4bd3-be41-72ba3f3e2885"><con:settings/><con:config service="NodeHealthCheck" resourcePath="/ecomp/mso/infra/nodehealthcheck" methodName="NodehealthcheckAPIH-Infra" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="NodehealthcheckAPIH - Request 1 2" id="00db386c-942d-4286-853f-01e279f6c2cb" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/nodehealthcheck</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="222b1461-2b33-4951-9c5d-87a850dc1971" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="GlobalHC adapters - Request 1 3" id="0e877ae9-1d63-486c-8530-fc99e5416ac6"><con:settings/><con:config service="GlobalHealthcheck" resourcePath="/adapters/rest/globalhealthcheck" methodName="GlobalHC adapters" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="GlobalHC adapters - Request 1 3" id="b1109ecf-fd73-4a30-8c98-ac50a10e9cb7" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/globalhealthcheck</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="96e389cc-3e30-4ec0-b9bd-5eda145f6bbb" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enableBpmn" value="${#Project#enableBpmn}" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enableBpmn</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="LocalHC tenants - Request 1 2" id="c87beffd-7f8b-408d-9275-5876f5eb5dd4"><con:settings/><con:config service="SubModulesHealthcheck" resourcePath="/tenants/rest/healthcheck" methodName="LocalHC tenants" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="LocalHC tenants - Request 1 2" id="432c2172-deba-4173-a0af-0b6fccfd60dc" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/tenants/admin/healthcheck</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="99a55011-59f5-4693-9b9f-5c0400172b8e" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="LocalHC asdc - Request 1 2" id="5ea8229f-7cb6-4660-8b84-b9930822934a"><con:settings/><con:config service="SubModulesHealthcheck" resourcePath="/asdc/healthcheck" methodName="LocalHC asdc" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="LocalHC asdc - Request 1 2" id="b0d9d540-073e-4d1d-ac19-32566206d0c6" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/asdc/healthcheck</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="eb5af8a7-1730-4b42-a604-10172a4a10ac" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable NetworkAdapter debug logs" id="64f3deb6-2675-4eb8-8600-9ed2be76acc3"><con:settings/><con:config service="Logging" methodName="Debug 1" resourcePath="/networks/rest/logging/debug" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable debug logs" id="ba42db46-5a97-48d1-a88c-bab5a11313ae" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/networks/rest/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="1f209f2c-b621-4168-bca4-cbe4b5da4c7e" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable TenantAdapter debug logs" id="a0ec3eda-28c1-43c1-9737-70a1b355874c"><con:settings/><con:config service="Logging" methodName="Debug 1" resourcePath="/tenants/rest/logging/debug" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable TenantAdapter debug logs" id="a97a886d-002c-4431-bf33-c7ab1d31e881" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/tenantss/rest/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="d984f832-9790-496a-911e-57e3d1780969" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable VNF Adapter debug logs" id="6153b51b-165a-4406-ab7e-e1f32ede7d75"><con:settings/><con:config service="Logging" resourcePath="/vnfs/rest/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable VNF Adapter debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/vnfs/rest/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="bdd35643-b216-4200-8f07-45fc8b0ad304" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable SDNC Adapter debug logs" id="69f77bce-b9e1-4462-b7e3-0a8620eafddc"><con:settings/><con:config service="Logging" resourcePath="/adapters/rest/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable SDNC Adapter debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="f4db96ec-603d-4c1c-897f-2a76e2948637" name="Valid HTTP Status Codes"><con:configuration><codes>200
-</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable APIH Infra debug logs" id="99d0ad17-f116-4506-82ab-7f8a60924fb6"><con:settings/><con:config service="Logging" resourcePath="/ecomp/mso/infra/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable APIH Infra debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/ecomp/mso/infra/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="df4e7c2f-384d-47d3-a772-309d8a7d6dd5" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable ASDC debug logs" id="d938876a-34c6-4de9-89dc-55a63e710c18"><con:settings/><con:config service="Logging" resourcePath="/asdc/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable ASDC debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/asdc/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="62995dde-fa57-409d-8480-befef3f6ff70" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="Enable RequestDBAdapter debug logs" id="e83f44c7-1cd6-4c9f-9afd-fb91faf7cf41"><con:settings/><con:config service="Logging" resourcePath="/dbadapters/logging/debug" methodName="Debug 1" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="Enable RequestDBAdapter debug logs" id="8d1e6e96-d9d6-4166-bd74-ac7e9266db16" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/dbadapters/logging/debug</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="2e5b9577-aa74-43c7-9440-eb00314d091c" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:username>${#Project#msoclient}</con:username><con:password>${#Project#msoclientpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enable" value="true" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enable</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:properties/></con:testCase><con:properties/></con:testSuite><con:properties><con:property><con:name>apihhost</con:name><con:value>localhost:8080</con:value></con:property><con:property><con:name>jrahost</con:name><con:value>localhost:8080</con:value></con:property><con:property><con:name>userlogin</con:name><con:value>sitecontrol</con:value></con:property><con:property><con:name>userpassword</con:name><con:value>Domain2.0!</con:value></con:property><con:property><con:name>bpmnhost</con:name><con:value>localhost:8080</con:value></con:property><con:property><con:name>sitename</con:name><con:value>mso-docker</con:value></con:property><con:property><con:name>enableBpmn</con:name><con:value/></con:property><con:property><con:name>dbadapteruser</con:name><con:value>BPELClient</con:value></con:property><con:property><con:name>dbadapterpassword</con:name><con:value>password1$</con:value></con:property><con:property><con:name>msoclient</con:name><con:value>MSOClient</con:value></con:property><con:property><con:name>msoclientpassword</con:name><con:value>password1$</con:value></con:property></con:properties><con:wssContainer/><con:oAuth2ProfileContainer/><con:oAuth1ProfileContainer/><con:sensitiveInformation/></con:soapui-project>
\ No newline at end of file
+</soapenv:Envelope>]]></con:request><con:originalUri>http://localhost/dbadapters/RequestsDbAdapter</con:originalUri><con:assertion type="Simple Contains" id="98f1d604-1865-45ac-ae71-3d94000738f3" name="Contains"><con:configuration><token><return>true</return></token><ignoreCase>false</ignoreCase><useRegEx>false</useRegEx></con:configuration></con:assertion><con:credentials><con:username>${#Project#dbadapteruser}</con:username><con:password>${#Project#dbadapterpassword}</con:password><con:selectedAuthProfile>Basic</con:selectedAuthProfile><con:addedBasicAuthenticationTypes>Basic</con:addedBasicAuthenticationTypes><con:authType>Global HTTP Settings</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="NodehealthcheckAPIH - Request 1 2" id="afd352c1-685b-4bd3-be41-72ba3f3e2885"><con:settings/><con:config service="NodeHealthCheck" resourcePath="/ecomp/mso/infra/nodehealthcheck" methodName="NodehealthcheckAPIH-Infra" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="NodehealthcheckAPIH - Request 1 2" id="00db386c-942d-4286-853f-01e279f6c2cb" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/nodehealthcheck</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="222b1461-2b33-4951-9c5d-87a850dc1971" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="GlobalHC adapters - Request 1 3" id="0e877ae9-1d63-486c-8530-fc99e5416ac6"><con:settings/><con:config service="GlobalHealthcheck" resourcePath="/adapters/rest/globalhealthcheck" methodName="GlobalHC adapters" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="GlobalHC adapters - Request 1 3" id="b1109ecf-fd73-4a30-8c98-ac50a10e9cb7" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/adapters/rest/globalhealthcheck</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="96e389cc-3e30-4ec0-b9bd-5eda145f6bbb" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters><entry key="enableBpmn" value="${#Project#enableBpmn}" xmlns="http://eviware.com/soapui/config"/></con:parameters><con:parameterOrder><con:entry>enableBpmn</con:entry></con:parameterOrder></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="LocalHC tenants - Request 1 2" id="c87beffd-7f8b-408d-9275-5876f5eb5dd4"><con:settings/><con:config service="SubModulesHealthcheck" resourcePath="/tenants/rest/healthcheck" methodName="LocalHC tenants" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="LocalHC tenants - Request 1 2" id="432c2172-deba-4173-a0af-0b6fccfd60dc" mediaType="application/json"><con:settings/><con:endpoint>http://${#Project#jrahost}</con:endpoint><con:request/><con:originalUri>http://localhost/tenants/admin/healthcheck</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="99a55011-59f5-4693-9b9f-5c0400172b8e" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:restRequest></con:config></con:testStep><con:testStep type="restrequest" name="LocalHC asdc - Request 1 2" id="5ea8229f-7cb6-4660-8b84-b9930822934a"><con:settings/><con:config service="SubModulesHealthcheck" resourcePath="/asdc/healthcheck" methodName="LocalHC asdc" xsi:type="con:RestRequestStep" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:restRequest name="LocalHC asdc - Request 1 2" id="b0d9d540-073e-4d1d-ac19-32566206d0c6" mediaType="application/json"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:endpoint>http://${#Project#apihhost}</con:endpoint><con:request/><con:originalUri>http://localhost/asdc/healthcheck</con:originalUri><con:assertion type="Valid HTTP Status Codes" id="eb5af8a7-1730-4b42-a604-10172a4a10ac" name="Valid HTTP Status Codes"><con:configuration><codes>200</codes></con:configuration></con:assertion><con:credentials><con:authType>No Authorization</con:authType></con:credentials><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:parameters/></con:restRequest></con:config></con:testStep><con:properties/></con:testCase><con:properties/></con:testSuite><con:properties><con:property><con:name>apihhost</con:name><con:value>localhost:8080</con:value></con:property><con:property><con:name>jrahost</con:name><con:value>localhost:8080</con:value></con:property><con:property><con:name>userlogin</con:name><con:value>sitecontrol</con:value></con:property><con:property><con:name>userpassword</con:name><con:value>Domain2.0!</con:value></con:property><con:property><con:name>bpmnhost</con:name><con:value>localhost:8080</con:value></con:property><con:property><con:name>sitename</con:name><con:value>mso-docker</con:value></con:property><con:property><con:name>enableBpmn</con:name><con:value/></con:property><con:property><con:name>dbadapteruser</con:name><con:value>BPELClient</con:value></con:property><con:property><con:name>dbadapterpassword</con:name><con:value>password1$</con:value></con:property><con:property><con:name>msoclient</con:name><con:value>MSOClient</con:value></con:property><con:property><con:name>msoclientpassword</con:name><con:value>password1$</con:value></con:property></con:properties><con:wssContainer/><con:oAuth2ProfileContainer/><con:oAuth1ProfileContainer/><con:sensitiveInformation/></con:soapui-project>
\ No newline at end of file
UNLOCK TABLES;
INSERT INTO service (id, SERVICE_NAME, VERSION_STR, DESCRIPTION, SERVICE_NAME_VERSION_ID) VALUES ('4', 'VID_DEFAULT', '1.0', 'Default service for VID to use for infra APIH orchestration', 'MANUAL_RECORD');
-INSERT INTO service_recipe (SERVICE_ID, ACTION, VERSION_STR, DESCRIPTION, ORCHESTRATION_URI, RECIPE_TIMEOUT) VALUES ('4', 'createInstance', '1', 'VID_DEFAULT recipe to create service-instance if no custom BPMN flow is found', '/mso/async/services/CreateServiceInstance', '180');
-INSERT INTO service_recipe (SERVICE_ID, ACTION, VERSION_STR, DESCRIPTION, ORCHESTRATION_URI, RECIPE_TIMEOUT) VALUES ('4', 'deleteInstance', '1', 'VID_DEFAULT recipe to delete service-instance if no custom BPMN flow is found', '/mso/async/services/DelServiceInstance', '180');
+INSERT INTO service_recipe (SERVICE_ID, ACTION, VERSION_STR, DESCRIPTION, ORCHESTRATION_URI, RECIPE_TIMEOUT) VALUES ('4', 'createInstance', '1', 'VID_DEFAULT recipe to create service-instance if no custom BPMN flow is found', '/mso/async/services/CreateGenericALaCarteServiceInstance', '180');
+INSERT INTO service_recipe (SERVICE_ID, ACTION, VERSION_STR, DESCRIPTION, ORCHESTRATION_URI, RECIPE_TIMEOUT) VALUES ('4', 'deleteInstance', '1', 'VID_DEFAULT recipe to delete service-instance if no custom BPMN flow is found', '/mso/async/services/DeleteGenericALaCarteServiceInstance', '180');
INSERT INTO vnf_recipe (VNF_TYPE, ACTION, VERSION_STR, DESCRIPTION, ORCHESTRATION_URI, RECIPE_TIMEOUT) VALUES ('VID_DEFAULT', 'createInstance', '1', 'VID_DEFAULT recipe to create VNF if no custom BPMN flow is found', '/mso/async/services/CreateVnfInfra', '180');
INSERT INTO vnf_recipe (VNF_TYPE, ACTION, VERSION_STR, DESCRIPTION, ORCHESTRATION_URI, RECIPE_TIMEOUT) VALUES ('VID_DEFAULT', 'deleteInstance', '1', 'VID_DEFAULT recipe to delete VNF if no custom BPMN flow is found', '/mso/async/services/DeleteVnfInfra', '180');
INSERT INTO vnf_components_recipe (VNF_TYPE, VNF_COMPONENT_TYPE, ACTION, VERSION, DESCRIPTION, ORCHESTRATION_URI, RECIPE_TIMEOUT, VF_MODULE_ID) VALUES (NULL, 'volumeGroup', 'createInstance', '1', 'VID_DEFAULT recipe to create volume-group if no custom BPMN flow is found', '/mso/async/services/CreateVfModuleVolumeInfraV1', '180', 'VID_DEFAULT');