diff --git a/bpmn/MSOMockServer/.gitignore b/bpmn/MSOMockServer/.gitignore
new file mode 100644
index 0000000..f6c8fbc
--- /dev/null
+++ b/bpmn/MSOMockServer/.gitignore
@@ -0,0 +1,4 @@
+/bin
+/target
+/target
+/target
diff --git a/bpmn/MSOMockServer/WebContent/META-INF/MANIFEST.MF b/bpmn/MSOMockServer/WebContent/META-INF/MANIFEST.MF
new file mode 100644
index 0000000..254272e
--- /dev/null
+++ b/bpmn/MSOMockServer/WebContent/META-INF/MANIFEST.MF
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path: 
+
diff --git a/bpmn/MSOMockServer/WebContent/WEB-INF/web.xml b/bpmn/MSOMockServer/WebContent/WEB-INF/web.xml
new file mode 100644
index 0000000..1aa8cdb
--- /dev/null
+++ b/bpmn/MSOMockServer/WebContent/WEB-INF/web.xml
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app id="WebApp_ID" version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
+</web-app>
\ No newline at end of file
diff --git a/bpmn/MSOMockServer/pom.xml b/bpmn/MSOMockServer/pom.xml
new file mode 100644
index 0000000..500535d
--- /dev/null
+++ b/bpmn/MSOMockServer/pom.xml
@@ -0,0 +1,100 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+	<parent>
+        <groupId>org.openecomp.so</groupId>
+        <artifactId>bpmn</artifactId>
+		<version>1.1.0-SNAPSHOT</version>
+	</parent>
+	<modelVersion>4.0.0</modelVersion>
+	<groupId>org.openecomp.so</groupId>
+	<artifactId>MSOMockServer</artifactId>
+	<packaging>war</packaging>
+
+	<build>
+		<plugins>
+		
+			<plugin>
+				<groupId>org.apache.maven.plugins</groupId>
+				<artifactId>maven-war-plugin</artifactId>
+				<version>2.4</version>
+				<configuration>
+				    <attachClasses>true</attachClasses>
+					<archiveClasses>true</archiveClasses>				
+					<failOnMissingWebXml>false</failOnMissingWebXml>
+				</configuration>
+			</plugin>
+		</plugins>
+	</build>
+	<dependencies>
+	
+		<dependency>
+			<groupId>com.github.tomakehurst</groupId>
+			<artifactId>wiremock</artifactId>
+			<version>1.56</version>
+			<classifier>standalone</classifier>
+			<exclusions>
+				<exclusion>
+					<groupId>org.mortbay.jetty</groupId>
+					<artifactId>jetty</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>com.google.guava</groupId>
+					<artifactId>guava</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>com.fasterxml.jackson.core</groupId>
+					<artifactId>jackson-core</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>com.fasterxml.jackson.core</groupId>
+					<artifactId>jackson-annotations</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>com.fasterxml.jackson.core</groupId>
+					<artifactId>jackson-databind</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>org.apache.httpcomponents</groupId>
+					<artifactId>httpclient</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>org.skyscreamer</groupId>
+					<artifactId>jsonassert</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>xmlunit</groupId>
+					<artifactId>xmlunit</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>com.jayway.jsonpath</groupId>
+					<artifactId>json-path</artifactId>
+				</exclusion>
+				<exclusion>
+					<groupId>net.sf.jopt-simple</groupId>
+					<artifactId>jopt-simple</artifactId>
+				</exclusion>
+			</exclusions>
+		</dependency>
+		<dependency>
+            <groupId>org.openecomp.so</groupId>
+            <artifactId>common</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+		<dependency>
+			<groupId>javax.ws.rs</groupId>
+			<artifactId>javax.ws.rs-api</artifactId>
+			<version>2.0</version>
+		</dependency>
+		<dependency>
+		    <groupId>org.jboss.resteasy</groupId>
+		    <artifactId>resteasy-client</artifactId>
+		    <version>3.0.8.Final</version>
+			<exclusions>			
+				<exclusion>
+					<groupId>org.apache.httpcomponents</groupId> 				
+					<artifactId>httpclient</artifactId>
+				</exclusion>
+			</exclusions>	
+		</dependency>
+	</dependencies>
+</project>
\ No newline at end of file
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/FileUtil.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/FileUtil.java
new file mode 100644
index 0000000..2ebb44a
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/FileUtil.java
@@ -0,0 +1,80 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import java.io.IOException;
+import java.io.InputStream;
+import org.openecomp.mso.logger.MsoLogger;
+
+/**
+ * 
+ * File utility class.<br/>
+ * <p>
+ * </p>
+ * 
+ * @author
+ * @version     ONAP  Sep 15, 2017
+ */
+public class FileUtil {
+
+    private static final MsoLogger LOGGER = MsoLogger.getMsoLogger (MsoLogger.Catalog.RA);
+    
+    private FileUtil() {
+        /**
+         * Constructor.
+         */
+    }
+	/**
+	 * Read the specified resource file and return the contents as a String.
+	 * 
+	 * @param fileName Name of the resource file
+	 * @return the contents of the resource file as a String
+	 * @throws IOException if there is a problem reading the file
+	 */
+	public static String readResourceFile(String fileName) {
+		InputStream stream;
+		try {
+			stream = getResourceAsStream(fileName);
+			byte[] bytes;
+			bytes = new byte[stream.available()];
+			stream.read(bytes);
+			stream.close();
+			return new String(bytes);
+		} catch (IOException e) {
+		    LOGGER.debug("Exception:", e);
+			return "";
+		}
+	}
+	
+	/**
+	 * Get an InputStream for the resource specified.
+	 * 
+	 * @param resourceName Name of resource for which to get InputStream.
+	 * @return an InputStream for the resource specified.
+	 * @throws IOException If we can't get the InputStream for whatever reason.
+	 */
+	private static InputStream getResourceAsStream(String resourceName) throws IOException {
+		InputStream stream =
+				FileUtil.class.getClassLoader().getResourceAsStream(resourceName);
+		if (stream == null) {
+			throw new IOException("Can't access resource '" + resourceName + "'");
+		}
+		return stream;
+	}		
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/MockResource.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/MockResource.java
new file mode 100644
index 0000000..fc97e69
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/MockResource.java
@@ -0,0 +1,205 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import static com.github.tomakehurst.wiremock.core.WireMockConfiguration.wireMockConfig;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.ws.rs.GET;
+import javax.ws.rs.POST;
+import javax.ws.rs.Path;
+import javax.ws.rs.PathParam;
+import javax.ws.rs.Produces;
+import javax.ws.rs.core.Response;
+
+import com.github.tomakehurst.wiremock.WireMockServer;
+import com.github.tomakehurst.wiremock.client.WireMock;
+
+/**
+ * 
+ * Mock Resource which is used to start, stop the WireMock Server
+ * Also up to 50 mock properties can be added at run-time to change the properties used in transformers such as sdnc_delay in SDNCAdapterMockTransformer
+ * You can also selectively setup a stub (use reset before setting up), reset all stubs
+ */
+@Path("/server")
+public class MockResource {
+
+	private boolean started = false;
+	private final Integer defaultPort = 28090;
+	private WireMockServer wireMockServer = null;
+	private static Map<String,String> mockProperties = new HashMap<String,String>();
+
+	public static String getMockProperties(String key) {
+		return mockProperties.get(key);
+	}
+
+	private synchronized void initMockServer(int portNumber) {
+		String path = FileUtil.class.getClassLoader().getResource("__files/sdncSimResponse.xml").getFile();
+		path = path.substring(0,path.indexOf("__files/"));
+
+		wireMockServer = new WireMockServer(wireMockConfig().port(portNumber).extensions("org.openecomp.mso.bpmn.mock.SDNCAdapterMockTransformer")
+																			.extensions("org.openecomp.mso.bpmn.mock.SDNCAdapterNetworkTopologyMockTransformer")
+																			.extensions("org.openecomp.mso.bpmn.mock.VnfAdapterCreateMockTransformer")
+																			.extensions("org.openecomp.mso.bpmn.mock.VnfAdapterDeleteMockTransformer")
+																			.extensions("org.openecomp.mso.bpmn.mock.VnfAdapterUpdateMockTransformer")
+																			.extensions("org.openecomp.mso.bpmn.mock.VnfAdapterRollbackMockTransformer")
+																			.extensions("org.openecomp.mso.bpmn.mock.VnfAdapterQueryMockTransformer"));
+																			//.withRootDirectory(path));
+		//Mocks were failing - commenting out for now, both mock and transformers seem to work fine
+		WireMock.configureFor("localhost", portNumber);
+		wireMockServer.start();
+//		StubResponse.setupAllMocks();
+		started= true;
+	}
+
+	public static void main(String [] args) {
+		MockResource mockresource = new MockResource();
+		mockresource.start(28090);
+		mockresource.reset();
+//		mockresource.setupStub("MockCreateTenant");
+	}
+	
+	/**
+	 * Starts the wiremock server in default port
+	 * @return
+	 */
+	@GET
+	@Path("/start")
+	@Produces("application/json")
+	public Response start() {
+		return startMockServer(defaultPort);
+	}
+
+	private Response startMockServer(int port) {
+		if (!started) {
+			initMockServer(defaultPort);
+			System.out.println("Started Mock Server in port " + port);
+			return Response.status(200).entity("Started Mock Server in port " + port).build();
+		} else {
+			return Response.status(200).entity("Mock Server is already running").build();
+		}
+	}
+
+	/**
+	 * Starts the wiremock server in a different port
+	 * @param portNumber
+	 * @return
+	 */
+	@GET
+	@Path("/start/{portNumber}")
+	@Produces("application/json")
+	public Response start(@PathParam("portNumber") Integer portNumber) {
+		if (portNumber == null) portNumber = defaultPort;
+		return startMockServer(portNumber.intValue());
+	}
+
+
+	/**
+	 * Stop the wiremock server
+	 * @return
+	 */
+	@GET
+	@Path("/stop")
+	@Produces("application/json")
+	public synchronized Response stop() {
+		if (wireMockServer.isRunning()) {
+			wireMockServer.stop();
+			started = false;
+			return Response.status(200).entity("Stopped Mock Server in port ").build();
+		}
+		return Response.status(200).entity("Mock Server is not running").build();
+	}
+
+
+	/**
+	 * Return list of mock properties
+	 * @return
+	 */
+	@GET
+	@Path("/properties")
+	@Produces("application/json")
+	public Response getProperties() {
+		return Response.status(200).entity(mockProperties).build();
+	}
+
+	/**
+	 * Update a particular mock property at run-time
+	 * @param name
+	 * @param value
+	 * @return
+	 */
+	@POST
+	@Path("/properties/{name}/{value}")
+	public Response updateProperties(@PathParam("name") String name, @PathParam("value") String value) {
+		if (mockProperties.size() > 50) return Response.serverError().build();
+		mockProperties.put(name, value);
+		return Response.status(200).build();
+	}
+
+	/**
+	 * Reset all stubs
+	 * @return
+	 */
+	@GET
+	@Path("/reset")
+	@Produces("application/json")
+	public Response reset() {
+		WireMock.reset();
+		return Response.status(200).entity("Wiremock stubs are reset").build();
+	}
+
+	
+	/**
+	 * Setup a stub selectively
+	 * Prior to use, make sure that stub method is available in StubResponse class
+	 * @param methodName
+	 * @return
+	 */
+	
+	// commenting for now until we figure out a way to use new StubResponse classes to setupStubs
+//	@GET
+//	@Path("/stub/{methodName}")
+//	@Produces("application/json")
+//	public Response setupStub(@PathParam("methodName") String methodName) {
+//		
+//	    @SuppressWarnings("rawtypes")
+//		Class params[] = {};
+//	    Object paramsObj[] = {};
+//
+//	    try {
+//			Method thisMethod = StubResponse.class.getDeclaredMethod(methodName, params);
+//			try {
+//				thisMethod.invoke(StubResponse.class, paramsObj);
+//			} catch (IllegalAccessException | IllegalArgumentException
+//					| InvocationTargetException e) {
+//				return Response.status(200).entity("Error invoking " + methodName ).build();
+//			}
+//		} catch (NoSuchMethodException | SecurityException e) {
+//			return Response.status(200).entity("Stub " + methodName + " not found...").build();
+//		}		
+//		return Response.status(200).entity("Successfully invoked " + methodName).build();
+//	}
+	
+	
+	public static Map<String,String> getMockProperties(){
+		return mockProperties;
+	}
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/MockResourceApplication.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/MockResourceApplication.java
new file mode 100644
index 0000000..ebbfea5
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/MockResourceApplication.java
@@ -0,0 +1,50 @@
+/* 
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.ws.rs.ApplicationPath;
+import javax.ws.rs.core.Application;
+
+/**
+ * 
+ * JAX RS Application wiring for Mock Resource
+ */
+@ApplicationPath("/console")
+public class MockResourceApplication extends Application {
+
+	private Set<Object> singletons = new HashSet<Object>();
+	private Set<Class<?>> classes = new HashSet<Class<?>>();
+
+	public MockResourceApplication() {
+		singletons.add(new MockResource());
+	}
+
+	@Override
+	public Set<Class<?>> getClasses() {
+		return classes;
+	}
+
+	@Override
+	public Set<Object> getSingletons() {
+		return singletons;
+	}
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/SDNCAdapterMockTransformer.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/SDNCAdapterMockTransformer.java
new file mode 100644
index 0000000..9c4e793
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/SDNCAdapterMockTransformer.java
@@ -0,0 +1,140 @@
+/* 
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import org.jboss.resteasy.client.ClientRequest;
+import org.jboss.resteasy.client.ClientResponse;
+import org.openecomp.mso.logger.MsoLogger;
+
+import com.github.tomakehurst.wiremock.client.ResponseDefinitionBuilder;
+import com.github.tomakehurst.wiremock.common.FileSource;
+import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
+import com.github.tomakehurst.wiremock.http.Request;
+import com.github.tomakehurst.wiremock.http.ResponseDefinition;
+
+import org.openecomp.mso.logger.MsoLogger;
+/**
+ * 
+ * Simulates SDNC Adapter Callback response
+ *
+ */
+public class SDNCAdapterMockTransformer extends ResponseTransformer {
+
+	private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
+	private String callbackResponse;
+	private String requestId;
+	
+	public SDNCAdapterMockTransformer() {
+		callbackResponse = FileUtil.readResourceFile("__files/sdncSimResponse.xml");
+	}
+
+	public SDNCAdapterMockTransformer(String requestId) {
+		this.requestId = requestId;
+	}
+	
+	public String name() {
+		return "sdnc-adapter-transformer";
+	}
+
+	/**
+	 * Grab the incoming request xml,extract the request id and replace the stub response with the incoming request id
+	 * so that callback response can be correlated
+	 * 
+	 * Mock Resource can be used to add dynamic properties. If sdnc_delay is not in the list by default waits for 300ms before
+	 * the callback response is sent
+	 */
+	@Override
+	public ResponseDefinition transform(Request request, ResponseDefinition responseDefinition,
+			FileSource fileSource) {
+		String requestBody = request.getBodyAsString();
+		
+		String callbackUrl = requestBody.substring(requestBody.indexOf("<sdncadapter:CallbackUrl>")+25, requestBody.indexOf("</sdncadapter:CallbackUrl>"));
+		String requestId = requestBody.substring(requestBody.indexOf("<sdncadapter:RequestId>")+23, requestBody.indexOf("</sdncadapter:RequestId>"));
+
+		callbackResponse = FileUtil.readResourceFile("__files/" + responseDefinition.getBodyFileName());
+		System.out.println("callbackResponse:" + callbackResponse);
+		
+		if (this.requestId != null) {
+			callbackResponse = callbackResponse.replace(this.requestId, requestId);
+		} else {
+			callbackResponse = callbackResponse.replace("testRequestId", requestId);
+		}
+		
+
+		Object sdncDelay = MockResource.getMockProperties().get("sdnc_delay");
+		int delay = 300;
+		if (sdncDelay != null) {
+			delay = Integer.parseInt(sdncDelay.toString());
+		}
+		
+		//Kick off callback thread
+		System.out.println("callback Url:" + callbackUrl + ":delay:" + delay);
+		CallbackResponseThread calbackResponseThread = new CallbackResponseThread(callbackUrl,callbackResponse, delay);
+		calbackResponseThread.start();
+		
+		//return 200 OK with empty body
+		return ResponseDefinitionBuilder
+                .like(responseDefinition).but()
+                .withStatus(200).withBody("").withHeader("Content-Type", "text/xml")
+                .build();
+	}
+
+	@Override
+	public boolean applyGlobally() {
+	    return false;
+	}
+	
+	/**
+	 * 
+	 * Callback response thread which sends the callback response asynchronously
+	 *
+	 */
+	private class CallbackResponseThread extends Thread {
+		
+		private String callbackUrl;
+		private String payLoad;
+		private int delay;
+		
+		public CallbackResponseThread(String callbackUrl, String payLoad, int delay) {
+			this.callbackUrl = callbackUrl;
+			this.payLoad = payLoad;
+			this.delay = delay;
+		}
+		
+		public void run () {
+			try {
+				//Delay sending callback response
+				sleep(delay);
+			} catch (InterruptedException e1) {
+				LOGGER.debug("Exception :",e1);
+			}
+			LOGGER.debug("Sending callback response:" + callbackUrl);
+			ClientRequest request = new ClientRequest(callbackUrl);
+			request.body("text/xml", payLoad);
+			System.err.println(payLoad);
+			try {
+				ClientResponse result = request.post();
+				//System.err.println("Successfully posted callback:" + result.getStatus());
+			} catch (Exception e) {
+				LOGGER.debug("Exception :",e);
+			}
+		}
+		
+	}
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/SDNCAdapterNetworkTopologyMockTransformer.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/SDNCAdapterNetworkTopologyMockTransformer.java
new file mode 100644
index 0000000..e59e3b6
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/SDNCAdapterNetworkTopologyMockTransformer.java
@@ -0,0 +1,132 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import org.jboss.resteasy.client.ClientRequest;
+import org.jboss.resteasy.client.ClientResponse;
+
+import com.github.tomakehurst.wiremock.client.ResponseDefinitionBuilder;
+import com.github.tomakehurst.wiremock.common.FileSource;
+import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
+import com.github.tomakehurst.wiremock.http.Request;
+import com.github.tomakehurst.wiremock.http.ResponseDefinition;
+
+import org.openecomp.mso.logger.MsoLogger;
+
+public class SDNCAdapterNetworkTopologyMockTransformer extends ResponseTransformer {
+
+	private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
+	
+	private String callbackResponse;
+	private String requestId;
+	
+	public SDNCAdapterNetworkTopologyMockTransformer() {
+		callbackResponse = ""; // FileUtil.readResourceFile("__files/sdncDeleteNetworkTopologySimResponse.xml");
+	}
+
+	public SDNCAdapterNetworkTopologyMockTransformer(String requestId) {
+		this.requestId = requestId;
+	}
+	
+	public String name() {
+		return "network-topology-operation-transformer";
+	}
+
+	@Override
+	public ResponseDefinition transform(Request request, ResponseDefinition responseDefinition, FileSource fileSource) {
+		String requestBody = request.getBodyAsString();
+		
+		String callbackUrl = requestBody.substring(requestBody.indexOf("<sdncadapter:CallbackUrl>")+25, requestBody.indexOf("</sdncadapter:CallbackUrl>"));
+		String requestId = requestBody.substring(requestBody.indexOf("<sdncadapter:RequestId>")+23, requestBody.indexOf("</sdncadapter:RequestId>"));
+		System.out.println("request callbackUrl : " + callbackUrl);
+		System.out.println("request requestId : " + requestId);
+		
+		System.out.println("file path/name : " + responseDefinition.getBodyFileName());
+		callbackResponse = FileUtil.readResourceFile("__files/" + responseDefinition.getBodyFileName());		
+		// extract Response responseRequestId
+		String responseRequestId = callbackResponse.substring(callbackResponse.indexOf("<RequestId>")+11, callbackResponse.indexOf("</RequestId>"));
+		System.out.println("response requestId: " + responseRequestId);		
+		System.out.println("callbackResponse (before): " + callbackResponse);
+		callbackResponse = callbackResponse.replace(responseRequestId, requestId);				
+		if (this.requestId != null) {
+			callbackResponse = callbackResponse.replace(this.requestId, requestId);
+		} else {
+			callbackResponse = callbackResponse.replace(responseRequestId, requestId);
+		}	
+		System.out.println("callbackResponse (after):" + callbackResponse);		
+
+		Object sdncDelay = MockResource.getMockProperties().get("sdnc_delay");
+		int delay = 300;
+		if (sdncDelay != null) {
+			delay = Integer.parseInt(sdncDelay.toString());
+		}
+		
+		//Kick off callback thread
+		System.out.println("(NetworkTopologyMockTransformer) callback Url:" + callbackUrl + ":delay:" + delay);
+		CallbackResponseThread calbackResponseThread = new CallbackResponseThread(callbackUrl,callbackResponse, delay);
+		calbackResponseThread.start();
+		
+		//return 200 OK with body
+		return ResponseDefinitionBuilder
+                .like(responseDefinition).but()
+                .withStatus(200).withBody(callbackResponse).withHeader("Content-Type", "text/xml")
+                .build();
+	}
+
+	@Override
+	public boolean applyGlobally() {
+	    return false;
+	}
+	
+	private class CallbackResponseThread extends Thread {
+		
+		private String callbackUrl;
+		private String payLoad;
+		private int delay;
+		
+		public CallbackResponseThread(String callbackUrl, String payLoad, int delay) {
+			this.callbackUrl = callbackUrl;
+			this.payLoad = payLoad;
+			this.delay = delay;
+		}
+		
+		public void run () {
+			try {
+				//Delay sending callback response
+				sleep(delay);
+			} catch (InterruptedException e1) {
+				// TODO Auto-generated catch block
+				LOGGER.debug("Exception :",e1);
+			}
+			LOGGER.debug("Sending callback response to url: " + callbackUrl);
+			ClientRequest request = new ClientRequest(callbackUrl);
+			request.body("text/xml", payLoad);
+			//System.err.println(payLoad);
+			try {
+				ClientResponse result = request.post();
+				LOGGER.debug("Successfully posted callback? Status: " + result.getStatus());
+			} catch (Exception e) {
+				// TODO Auto-generated catch block
+			    LOGGER.debug("catch error in - request.post() ");
+				LOGGER.debug("Exception :",e);
+			}
+		}
+		
+	}
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseAAI.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseAAI.java
new file mode 100644
index 0000000..32f2641
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseAAI.java
@@ -0,0 +1,1069 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
+import static com.github.tomakehurst.wiremock.client.WireMock.containing;
+import static com.github.tomakehurst.wiremock.client.WireMock.delete;
+import static com.github.tomakehurst.wiremock.client.WireMock.get;
+import static com.github.tomakehurst.wiremock.client.WireMock.post;
+import static com.github.tomakehurst.wiremock.client.WireMock.patch;
+import static com.github.tomakehurst.wiremock.client.WireMock.put;
+import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlMatching;
+
+
+/**
+ * Reusable Mock StubResponses for AAI Endpoints
+ *
+ */
+public class StubResponseAAI {
+
+	public static void setupAllMocks() {
+
+	}
+
+
+	/**
+	 * Tunnel-XConnect Mock Stub Response
+	 */
+	public static void MockPutTunnelXConnect(String globalCustId, String subscriptionType, String serviceInstanceId, String allottedResourceId, String tunnelId){
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId + "/allotted-resources/allotted-resource/" + allottedResourceId + "/tunnel-xconnects/tunnel-xconnect/" + tunnelId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+
+
+	/**
+	 * Allotted Resource Mock StubResponses below
+	 */
+	public static void MockGetAllottedResource(String globalCustId, String subscriptionType, String serviceInstanceId, String allottedResourceId, String responseFile) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId + "/allotted-resources/allotted-resource/" + allottedResourceId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockPutAllottedResource(String globalCustId, String subscriptionType, String serviceInstanceId, String allottedResourceId) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId + "/allotted-resources/allotted-resource/" + allottedResourceId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+
+	public static void MockPutAllottedResource_500(String globalCustId, String subscriptionType, String serviceInstanceId, String allottedResourceId) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId + "/allotted-resources/allotted-resource/" + allottedResourceId))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+	
+	public static void MockDeleteAllottedResource(String globalCustId, String subscriptionType, String serviceInstanceId, String allottedResourceId, String resourceVersion) {
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId + "/allotted-resources/allotted-resource/" + allottedResourceId + "[?]resource-version=" + resourceVersion))
+				.willReturn(aResponse()
+						.withStatus(204)));
+	}
+	
+	public static void MockPatchAllottedResource(String globalCustId, String subscriptionType, String serviceInstanceId, String allottedResourceId) {
+		stubFor(patch(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId + "/allotted-resources/allotted-resource/" + allottedResourceId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+
+	public static void MockQueryAllottedResourceById(String allottedResourceId, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/nodes-query[?]search-node-type=allotted-resource[&]filter=id:EQUALS:" + allottedResourceId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+
+	/**
+	 * Service Instance Mock StubResponses below
+	 */
+	public static void MockGetServiceInstance(String globalCustId, String subscriptionType, String serviceInstanceId, String responseFile) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockGetServiceInstance_404(String customer, String serviceSubscription, String serviceInstanceId){
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "/service-instances/service-instance/" + serviceInstanceId))
+						.willReturn(aResponse()
+						.withStatus(404)));
+	}
+
+	public static void MockGetServiceInstance_500(String customer, String serviceSubscription, String serviceInstanceId){
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "/service-instances/service-instance/" + serviceInstanceId))
+						.willReturn(aResponse()
+						.withStatus(500)));
+	}
+
+	public static void MockGetServiceInstance_500(String customer, String serviceSubscription, String serviceInstanceId, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "/service-instances/service-instance/" + serviceInstanceId))
+						.willReturn(aResponse()
+						.withStatus(500)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockNodeQueryServiceInstanceByName(String serviceInstanceName, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/nodes-query[?]search-node-type=service-instance[&]filter=service-instance-name:EQUALS:" + serviceInstanceName))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockNodeQueryServiceInstanceByName_404(String serviceInstanceName){
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/nodes-query[?]search-node-type=service-instance&filter=service-instance-name:EQUALS:" + serviceInstanceName))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+
+	public static void MockNodeQueryServiceInstanceByName_500(String serviceInstanceName){
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/nodes-query[?]search-node-type=service-instance&filter=service-instance-name:EQUALS:" + serviceInstanceName))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+
+	public static void MockNodeQueryServiceInstanceById(String serviceInstanceId, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/nodes-query[?]search-node-type=service-instance[&]filter=service-instance-id:EQUALS:" + serviceInstanceId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockNodeQueryServiceInstanceById_404(String serviceInstanceId){
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/nodes-query[?]search-node-type=service-instance&filter=service-instance-id:EQUALS:" + serviceInstanceId))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+
+	public static void MockNodeQueryServiceInstanceById_500(String serviceInstanceId){
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/nodes-query[?]search-node-type=service-instance&filter=service-instance-id:EQUALS:" + serviceInstanceId))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+
+	public static void MockDeleteServiceInstance(String customer, String serviceSubscription, String serviceInstanceId, String resourceVersion){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "/service-instances/service-instance/" + serviceInstanceId + "[?]resource-version=" + resourceVersion))
+				  .willReturn(aResponse()
+				  .withStatus(204)));
+	}
+	
+	public static void MockGetServiceInstance(String customer, String serviceSubscription, String serviceInstanceId, String resourceVersion, int statusCode){
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "/service-instances/service-instance/" + serviceInstanceId + "[?]resource-version=" + resourceVersion))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)));
+	}
+	
+	public static void MockGetServiceInstance(String customer, String serviceSubscription, String resourceVersion, int statusCode){
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "[?]resource-version=" + resourceVersion))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "text/xml")));
+	}
+	
+	public static void MockDeleteServiceInstance(String customer, String serviceSubscription, String serviceInstanceId, String resourceVersion, int statusCode){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "/service-instances/service-instance/" + serviceInstanceId + "[?]resource-version=" + resourceVersion))
+				.willReturn(aResponse()
+						.withStatus(statusCode)));
+	}
+	
+	public static void MockDeleteServiceInstance(String customer, String serviceSubscription, String resourceVersion, int statusCode){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "[?]resource-version=" +1234))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)));
+	}
+
+	public static void MockDeleteServiceInstance_404(String customer, String serviceSubscription, String serviceInstanceId, String resourceVersion){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "/service-instances/service-instance/" + serviceInstanceId + "[?]resource-version=" + resourceVersion))
+				 .willReturn(aResponse()
+				  .withStatus(404)));
+	}
+
+	public static void MockDeleteServiceInstance_500(String customer, String serviceSubscription, String serviceInstanceId, String resourceVersion){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + customer + "/service-subscriptions/service-subscription/" + serviceSubscription + "/service-instances/service-instance/" + serviceInstanceId + "[?]resource-version=" + resourceVersion))
+				 .willReturn(aResponse()
+				  .withStatus(500)));
+	}
+
+	public static void MockPutServiceInstance(String globalCustId, String subscriptionType, String serviceInstanceId, String responseFile) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockPutServiceInstance_500(String globalCustId, String subscriptionType, String serviceInstanceId) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+
+	/**
+	 * Service-Subscription Mock StubResponses below
+	 */
+	public static void MockGetServiceSubscription(String globalCustId, String subscriptionType, String responseFile) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockDeleteServiceSubscription(String globalCustId, String subscriptionType, int statusCode) {
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType))
+				.willReturn(aResponse()
+						.withStatus(statusCode)));
+	}
+
+	public static void MockDeleteServiceInstanceId(String globalCustId, String subscriptionType, String serviceInstanceId) {
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType + "/service-instances/service-instance/" + serviceInstanceId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+
+	public static void MockPutServiceSubscription(String globalCustId, String subscriptionType) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+	
+	public static void MockGetServiceSubscription(String globalCustId, String subscriptionType, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId + "/service-subscriptions/service-subscription/" + subscriptionType))
+				.willReturn(aResponse()
+				.withStatus(statusCode)));
+	}
+
+	/**
+	 * Customer Mock StubResponses below
+	 */
+	public static void MockGetCustomer(String globalCustId, String responseFile) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockDeleteCustomer(String globalCustId) {
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+
+	public static void MockPutCustomer(String globalCustId) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+
+	public static void MockPutCustomer_500(String globalCustId) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/" + globalCustId))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+
+
+	/**
+	 * Generic-Vnf Mock StubResponses below
+	 */
+	
+	public static void MockGetGenericVnfById(String vnfId, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "[?]depth=1"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetGenericVnfById(String vnfId, String responseFile, int statusCode){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf" + vnfId))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetGenericVnfByIdWithPriority(String vnfId, int statusCode, String responseFile) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf" + vnfId))
+				.atPriority(1)
+				.willReturn(aResponse()
+					.withStatus(statusCode)
+					.withHeader("Content-Type", "text/xml")
+					.withBodyFile(responseFile)));	
+	}
+	
+	public static void MockGetGenericVnfByIdWithPriority(String vnfId, String vfModuleId, int statusCode, String responseFile, int priority) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "/vf-modules/vf-module/" + vfModuleId))
+				.atPriority(priority)
+				.willReturn(aResponse()
+					.withStatus(statusCode)
+					.withHeader("Content-Type", "text/xml")
+					.withBodyFile(responseFile)));	
+	}
+
+	public static void MockGetGenericVnfByIdWithDepth(String vnfId, int depth, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "[?]depth=" + depth))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetGenericVnfById_404(String vnfId){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+
+	public static void MockGetGenericVnfById_500(String vnfId){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+
+	public static void MockGetGenericVnfByName(String vnfName, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf[?]vnf-name=" + vnfName))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetGenericVnfByNameWithDepth(String vnfName, int depth, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf[?]vnf-name=" + vnfName + "[&]depth=" + depth))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockGetGenericVnfByName_404(String vnfName){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf[?]vnf-name=" + vnfName))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+
+	public static void MockDeleteGenericVnf(String vnfId, String resourceVersion){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "[?]resource-version=" + resourceVersion))
+				.willReturn(aResponse()
+						.withStatus(204)));
+	}
+
+	public static void MockDeleteGenericVnf(String vnfId, String resourceVersion, int statusCode){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "[?]resource-version=" + resourceVersion))
+				.willReturn(aResponse()
+						.withStatus(statusCode)));
+	}
+
+	public static void MockDeleteGenericVnf_500(String vnfId, String resourceVersion){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "[?]resource-version=" + resourceVersion))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+
+	public static void MockPutGenericVnf(String vnfId){
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+	
+	public static void MockPutGenericVnf(String vnfId, String requestBodyContaining, int statusCode) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf" + vnfId))
+				.withRequestBody(containing(requestBodyContaining))
+				.willReturn(aResponse()
+					.withStatus(statusCode)));
+	}
+
+	public static void MockPutGenericVnf(String vnfId, int statusCode) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf" + vnfId))
+				.willReturn(aResponse()
+					.withStatus(statusCode)));
+	}
+	
+	public static void MockPutGenericVnf_Bad(String vnfId, int statusCode){
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId))
+				.willReturn(aResponse()
+						.withStatus(statusCode)));
+	}
+
+	public static void MockPatchGenericVnf(String vnfId){
+		stubFor(patch(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+	/**
+	 * Vce Mock StubResponses below
+	 */
+	public static void MockGetVceById(String vnfId, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/vces/vce/" + vnfId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockGetVceByName(String vnfName, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/vces/vce[?]vnf-name=" + vnfName))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockDeleteVce(String vnfId, String resourceVersion, int statusCode){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/vces/vce/" + vnfId + "[?]resource-version=" + resourceVersion))
+				.willReturn(aResponse()
+						.withStatus(statusCode)));
+	}
+
+	public static void MockPutVce(String vnfId){
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/vces/vce/" + vnfId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+	
+	public static void MockGetGenericVceByNameWithDepth(String vnfName, int depth, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/vces/vce[?]vnf-name=" + vnfName + "[&]depth=" + depth))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockGetVceGenericQuery(String serviceInstanceName, int depth, int statusCode, String responseFile){
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/generic-query[?]key=service-instance.service-instance-name:" + serviceInstanceName + "[&]start-node-type=service-instance[&]include=vce[&]depth=" + depth))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	/**
+	 * Tenant Mock StubResponses below
+	 */
+	public static void MockGetTenantGenericQuery(String customer, String serviceType, String responseFile) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/search/generic-query[?]key=customer.global-customer-id:" + customer + "&key=service-subscription.service-type:" + serviceType + "&start-node-type=service-subscription&include=tenant&include=service-subscription&depth=1"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void MockGetTenant(String tenantId, String responseFile) {
+		stubFor(get(urlEqualTo("/aai/v2/cloud-infrastructure/tenants/tenant/" + tenantId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+
+	/**
+	 * Network Mock StubResponses below
+	 */
+	public static void MockGetNetwork(String networkId, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/l3-networks/l3-network/" + networkId))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkByIdWithDepth(String networkId, String responseFile, String depth) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/l3-networks/l3-network/" + networkId + "[?]depth=" + depth))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkCloudRegion(String responseFile, String cloudRegion) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/"+cloudRegion))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkByName(String networkName, String responseFile) {
+		   stubFor(get(urlMatching("/aai/v[0-9]+/network/l3-networks/l3-network[?]network-name="+networkName))
+					.willReturn(aResponse()
+							.withStatus(200)
+							.withHeader("Content-Type", "text/xml")
+							.withBodyFile(responseFile)));
+	}
+
+	public static void MockGetNetworkByName_404(String responseFile, String networkName) {
+ 	stubFor(get(urlMatching("/aai/v[0-9]+/network/l3-networks/l3-network[?]network-name="+networkName))
+				.willReturn(aResponse()
+						.withStatus(404)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkCloudRegion_404(String cloudRegion) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/"+cloudRegion))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+
+	public static void MockPutNetwork(String networkId, int statusCode, String responseFile) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/l3-networks/l3-network/" + networkId))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockPutNetwork(String networkPolicyId, String responseFile, int statusCode) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/network-policies/network-policy/" + networkPolicyId))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkName(String networkPolicyName, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/l3-networks/l3-network[?]network-name=" + networkPolicyName))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+
+	public static void MockGetNetworkVpnBinding(String responseFile, String vpnBinding) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/vpn-bindings/vpn-binding/"+vpnBinding + "[?]depth=all"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}	
+	
+	public static void MockGetNetworkPolicy(String responseFile, String policy) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/network-policies/network-policy/"+policy + "[?]depth=all"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkVpnBinding(String networkBindingId, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/vpn-bindings/vpn-binding/" + networkBindingId))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkPolicy(String networkPolicy, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/network-policies/network-policy/" + networkPolicy))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkTableReference(String responseFile, String tableReference) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/route-table-references/route-table-reference/"+tableReference + "[?]depth=all"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockPutNetworkIdWithDepth(String responseFile, String networkId, String depth) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/l3-networks/l3-network/"+networkId+"[?]depth="+depth ))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkPolicyfqdn(String networkPolicy, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/network-policies/network-policy[?]network-policy-fqdn=" + networkPolicy))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetNetworkRouteTable(String networkRouteId, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/route-table-references/route-table-reference/" + networkRouteId))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockPatchVfModuleId(String vnfId, String vfModuleId) {
+		stubFor(patch(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "/vf-modules/vf-module/" + vfModuleId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+	
+	/////////////
+	
+	public static void MockVNFAdapterRestVfModule() {
+		stubFor(put(urlEqualTo("/vnfs/v1/vnfs/skask/vf-modules/supercool"))
+			.willReturn(aResponse()
+				.withStatus(202)
+				.withHeader("Content-Type", "application/xml")));
+		stubFor(post(urlMatching("/vnfs/v1/vnfs/.*/vf-modules"))
+				.willReturn(aResponse()
+					.withStatus(202)
+					.withHeader("Content-Type", "application/xml")));
+		stubFor(post(urlEqualTo("/vnfs/v1/vnfs/skask/vf-modules"))
+			.willReturn(aResponse()
+				.withStatus(202)
+				.withHeader("Content-Type", "application/xml")));
+		stubFor(put(urlEqualTo("/vnfs/v1/volume-groups/78987"))
+			.willReturn(aResponse()
+				.withStatus(202)
+				.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void MockDBUpdateVfModule(){
+		stubFor(post(urlEqualTo("/dbadapters/RequestsDbAdapter"))
+			.willReturn(aResponse()
+				.withStatus(200)
+			    .withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/DBUpdateResponse.xml")));
+	}
+	
+	// start of mocks used locally and by other VF Module unit tests
+	public static void MockSDNCAdapterVfModule() {
+		// simplified the implementation to return "success" for all requests
+		stubFor(post(urlEqualTo("/SDNCAdapter"))
+//			.withRequestBody(containing("SvcInstanceId><"))
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/StandardSDNCSynchResponse.xml")));
+
+	}
+	
+	// start of mocks used locally and by other VF Module unit tests
+	public static void MockAAIVfModule() {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/supercool"))
+			.atPriority(1)
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/VfModule-supercool.xml")));		
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/lukewarm"))
+			.atPriority(2)
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/VfModule-lukewarm.xml")));
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/.*"))
+			.atPriority(5)
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/VfModule-new.xml")));
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask[?]depth=1"))
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/GenericVnf.xml")));
+		stubFor(patch(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/supercool"))
+//			.withRequestBody(containing("PCRF"))
+			.willReturn(aResponse()
+				.withStatus(200)));
+		stubFor(patch(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/.*"))
+//				.withRequestBody(containing("PCRF"))
+				.willReturn(aResponse()
+					.withStatus(200)));
+		// HTTP PUT stub still used by CreateAAIvfModuleVolumeGroup
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/.*"))
+				.withRequestBody(containing("PCRF"))
+				.willReturn(aResponse()
+					.withStatus(200)));
+		// HTTP PUT stub still used by DoCreateVfModuleTest
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/.*"))
+				.withRequestBody(containing("MODULELABEL"))
+				.willReturn(aResponse()
+					.withStatus(200)));
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/volume-groups/volume-group[?]volume-group-id=78987"))
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/ConfirmVolumeGroupTenantResponse.xml")));
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/volume-groups/volume-group[?]volume-group-id=78987"))
+				.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/ConfirmVolumeGroupTenantResponse.xml")));
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/MDTWNJ21/volume-groups/volume-group/78987"))
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "text/xml")
+				.withBodyFile("VfModularity/VolumeGroup.xml")));
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/AAIAIC25/volume-groups/volume-group/78987"))
+				.willReturn(aResponse()
+					.withStatus(200)
+					.withHeader("Content-Type", "text/xml")
+					.withBodyFile("VfModularity/VolumeGroup.xml")));
+		stubFor(delete(urlMatching("/aai/v[0-9]+/cloud-infrastructure/volume-groups/volume-group/78987[?]resource-version=0000020"))
+			     .willReturn(aResponse()
+			     .withStatus(200)
+			     .withHeader("Content-Type", "text/xml")
+			     .withBodyFile("DeleteCinderVolumeV1/DeleteVolumeId_AAIResponse_Success.xml")));
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/network-policies/network-policy/.*"))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile("VfModularity/AddNetworkPolicy_AAIResponse_Success.xml")));
+		stubFor(patch(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/skask/vf-modules/vf-module/NEWvBNGModuleId"))
+				.withRequestBody(containing("NEWvBNGModuleId"))
+				.willReturn(aResponse()
+					.withStatus(200)));
+	}
+
+	
+	
+	//////////////
+
+	/**
+	 * Cloud infrastructure below
+	 */
+	
+	public static void MockGetCloudRegion(String cloudRegionId, int statusCode, String responseFile) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/" + cloudRegionId))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	/**
+	 * Volume Group StubResponse below
+	 */
+	public static void MockGetVolumeGroupById(String cloudRegionId, String volumeGroupId, String responseFile) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/" + cloudRegionId + "/volume-groups/volume-group/" + volumeGroupId))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockPutVolumeGroupById(String cloudRegionId, String volumeGroupId, String responseFile, int statusCode) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/" + cloudRegionId + "/volume-groups/volume-group/" + volumeGroupId))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetVolumeGroupByName(String cloudRegionId, String volumeGroupName, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/" + cloudRegionId + "/volume-groups[?]volume-group-name=" + volumeGroupName))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockDeleteVolumeGroupById(String cloudRegionId, String volumeGroupId, String resourceVersion, int statusCode) {
+		stubFor(delete(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/" + cloudRegionId + "/volume-groups/volume-group/" + volumeGroupId + "[?]resource-version=" + resourceVersion))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)));
+	}
+
+	public static void MockGetVolumeGroupByName_404(String cloudRegionId, String volumeGroupName) {
+		stubFor(get(urlMatching("/aai/v9/cloud-infrastructure/cloud-regions/cloud-region/att-aic/" + cloudRegionId + "/volume-groups[?]volume-group-name=" + volumeGroupName))
+				.willReturn(aResponse()
+				.withStatus(404)));
+	}
+	
+	public static void MockDeleteVolumeGroup(String cloudRegionId, String volumeGroupId, String resourceVersion) {
+		stubFor(delete(urlMatching("/aai/v[0-9]+/cloud-infrastructure/cloud-regions/cloud-region/att-aic/" + cloudRegionId + "/volume-groups/volume-group/" + volumeGroupId + "[?]resource-version=" + resourceVersion))
+				.willReturn(aResponse()
+				.withStatus(200)));
+	}
+	
+	/**
+	 * VF-Module StubResponse below
+	 * @param statusCode TODO
+	 */
+	public static void MockGetVfModuleId(String vnfId, String vfModuleId, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "/vf-modules/vf-module/" + vfModuleId))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetVfModuleByNameWithDepth(String vnfId, String vfModuleName, int depth, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "/vf-modules/vf-module[?]vf-module-name=" + vfModuleName + "[?]depth=" + depth))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetVfModuleIdNoResponse(String vnfId, String requestContaining, String vfModuleId) {
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "/vf-modules/vf-module/" + vfModuleId))
+				.withRequestBody(containing(requestContaining))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")));
+	}
+
+	public static void MockPutVfModuleIdNoResponse(String vnfId, String requestContaining, String vfModuleId) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId +"/vf-modules/vf-module/" +vfModuleId))
+				.withRequestBody(containing(requestContaining))
+				.willReturn(aResponse()
+					.withStatus(200)));
+	}
+	
+	public static void MockPutVfModuleId(String vnfId, String vfModuleId) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "/vf-modules/vf-module/" + vfModuleId))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+	
+	public static void MockPutVfModuleId(String vnfId, String vfModuleId, int returnCode) {
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "/vf-modules/vf-module/" + vfModuleId))
+				.willReturn(aResponse()
+						.withStatus(returnCode)));
+	}
+	
+	public static void MockDeleteVfModuleId(String vnfId, String vfModuleId, String resourceVersion, int returnCode) {
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/" + vnfId + "/vf-modules/vf-module/" + vfModuleId + "/[?]resource-version=" + resourceVersion))
+				.willReturn(aResponse()
+						.withStatus(returnCode)));
+	}
+
+	public static void MockAAIVfModuleBadPatch(String endpoint, int statusCode) {
+		stubFor(patch(urlMatching(endpoint))
+			.willReturn(aResponse()
+				.withStatus(statusCode)));
+	}
+	
+	/* AAI Pserver Queries */
+	public static void MockGetPserverByVnfId(String vnfId, String responseFile, int statusCode) {
+		stubFor(put(urlMatching("/v10/query.*"))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "application/json")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetGenericVnfsByVnfId(String vnfId, String responseFile, int statusCode) {
+		stubFor(get(urlMatching("/v10/network/generic-vnfs/.*"))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						.withHeader("Content-Type", "application/json; charset=utf-8")
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void MockSetInMaintFlagByVnfId(String vnfId, int statusCode) {
+		stubFor(patch(urlMatching("/v10/network/generic-vnfs/.*"))
+				.willReturn(aResponse()
+						.withStatus(statusCode)
+						));
+	}
+	
+	//// Deprecated Stubs below - to be deleted once unit test that reference them are refactored to use common ones above ////
+	@Deprecated
+	public static void MockGetVceById(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/vces/vce/testVnfId123?depth=1"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericFlows/getVceResponse.xml")));
+	}
+	@Deprecated
+	public static void MockGetVceByName(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/vces/vce[?]vnf-name=testVnfName123"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericFlows/getVceByNameResponse.xml")));
+	}
+	@Deprecated
+	public static void MockPutVce(){
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/vces/vce/testVnfId123"))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+	@Deprecated
+	public static void MockDeleteVce(){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/vces/vce/testVnfId123[?]resource-version=testReVer123"))
+				.willReturn(aResponse()
+						.withStatus(204)));
+	}
+	@Deprecated
+	public static void MockDeleteVce_404(){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/vces/vce/testVnfId123[?]resource-version=testReVer123"))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+
+	@Deprecated
+	public static void MockDeleteServiceSubscription(){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/business/customers/customer/1604-MVM-26/service-subscriptions/service-subscription/SDN-ETHERNET-INTERNET[?]resource-version=1234"))
+				  .willReturn(aResponse()
+				  .withStatus(204)));
+	}
+	@Deprecated
+	public static void MockGetServiceSubscription(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/1604-MVM-26/service-subscriptions/service-subscription/SDN-ETHERNET-INTERNET"))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile("GenericFlows/getServiceSubscription.xml")));
+	}
+	@Deprecated
+	public static void MockGetServiceSubscription_200Empty(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/1604-MVM-26/service-subscriptions/service-subscription/SDN-ETHERNET-INTERNET[?]resource-version=1234"))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBody(" ")));
+	}
+	@Deprecated
+	public static void MockGetServiceSubscription_404() {
+		stubFor(get(urlMatching("/aai/v[0-9]+/business/customers/customer/1604-MVM-26/service-subscriptions/service-subscription/SDN-ETHERNET-INTERNET"))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+	@Deprecated
+	public static void MockGENPSIPutServiceInstance(){
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/1604-MVM-26/service-subscriptions/service-subscription/SDN-ETHERNET-INTERNET/service-instances/service-instance/MIS%252F1604%252F0026%252FSW_INTERNET"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericPutServiceInstance/GenericPutServiceInstance_PutServiceInstance_AAIResponse_Success.xml")));
+	}
+
+	@Deprecated
+	public static void MockGENPSIPutServiceSubscription(){
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/1604-MVM-26/service-subscriptions/service-subscription/SDN-ETHERNET-INTERNET"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericPutServiceInstance/GenericPutServiceInstance_PutServiceInstance_AAIResponse_Success.xml")));
+	}
+	@Deprecated
+	public static void MockGENPSIPutServiceInstance_get500(){
+		stubFor(put(urlMatching("/aai/v[0-9]+/business/customers/customer/1604-MVM-26/service-subscriptions/service-subscription/SDN-ETHERNET-INTERNET/service-instances/service-instance/MIS%252F1604%252F0026%252FSW_INTERNET"))
+				.willReturn(aResponse()
+						.withStatus(500)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericPutServiceInstance/aaiFault.xml")));
+	}
+
+	@Deprecated
+	public static void MockGetGenericVnfById(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericFlows/getGenericVnfByNameResponse.xml")));
+	}
+	@Deprecated
+	public static void MockGetGenericVnfById_404(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123"))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+	@Deprecated
+	public static void MockGetGenericVnfByName(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf[?]vnf-name=testVnfName123"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericFlows/getGenericVnfResponse.xml")));
+	}
+	@Deprecated
+	public static void MockGetGenericVnfByName_hasRelationships(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf[?]vnf-name=testVnfName123"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericFlows/getGenericVnfResponse_hasRelationships.xml")));
+	}
+	@Deprecated
+	public static void MockGetGenericVnfById_hasRelationships(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withBodyFile("GenericFlows/getGenericVnfResponse_hasRelationships.xml")));
+	}
+	@Deprecated
+	public static void MockGetGenericVnfById_500(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123"))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+	@Deprecated
+	public static void MockGetGenericVnfByName_404(){
+		stubFor(get(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf[?]vnf-name=testVnfName123"))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+	@Deprecated
+	public static void MockPutGenericVnf(){
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123"))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+	@Deprecated
+	public static void MockPutGenericVnf_400(){
+		stubFor(put(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123"))
+				.willReturn(aResponse()
+						.withStatus(400)));
+	}
+	@Deprecated
+	public static void MockDeleteGenericVnf(){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123[?]resource-version=testReVer123"))
+				.willReturn(aResponse()
+						.withStatus(204)));
+	}
+	@Deprecated
+	public static void MockDeleteGenericVnf_404(){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123[?]resource-version=testReVer123"))
+				.willReturn(aResponse()
+						.withStatus(404)));
+	}
+	@Deprecated
+	public static void MockDeleteGenericVnf_500(){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123[?]resource-version=testReVer123"))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+	@Deprecated
+	public static void MockDeleteGenericVnf_412(){
+		stubFor(delete(urlMatching("/aai/v[0-9]+/network/generic-vnfs/generic-vnf/testVnfId123[[?]]resource-version=testReVer123"))
+				.willReturn(aResponse()
+						.withStatus(412)));
+	}
+
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseDatabase.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseDatabase.java
new file mode 100644
index 0000000..c9f64d9
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseDatabase.java
@@ -0,0 +1,102 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
+import static com.github.tomakehurst.wiremock.client.WireMock.post;
+import static com.github.tomakehurst.wiremock.client.WireMock.get;
+import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
+
+/**
+ * Stub response class for Database stubs
+ * including database adapter, catalog db,
+ * and other databases.
+ */
+public class StubResponseDatabase {
+
+	public static void setupAllMocks() {
+
+	}
+
+	public static void MockUpdateRequestDB(String fileName){
+		stubFor(post(urlEqualTo("/dbadapters/RequestsDbAdapter"))
+				.willReturn(aResponse()
+				.withStatus(200)
+			    .withHeader("Content-Type", "text/xml")
+				.withBodyFile(fileName)));
+	}	
+	
+	public static void mockUpdateRequestDB(int statusCode, String reponseFile) {
+		stubFor(post(urlEqualTo("/dbadapters/RequestsDbAdapter"))
+				.willReturn(aResponse()
+				.withStatus(statusCode)
+			    .withHeader("Content-Type", "text/xml")
+				.withBodyFile(reponseFile)));
+	}
+
+	public static void MockGetAllottedResourcesByModelInvariantId(String modelInvariantId, String responseFile){
+		stubFor(get(urlEqualTo("/v1/serviceAllottedResources?serviceModelInvariantUuid=" + modelInvariantId))
+				.willReturn(aResponse()
+				.withStatus(200)
+			    .withHeader("Content-Type", "application/json")
+				.withBodyFile(responseFile)));
+	}
+
+	public static void MockGetAllottedResourcesByModelInvariantId_500(String modelInvariantId, String responseFile){
+		stubFor(get(urlEqualTo("/v1/serviceAllottedResources?serviceModelInvariantUuid=" + modelInvariantId))
+				.willReturn(aResponse()
+				.withStatus(500)));
+	}
+	
+	public static void MockGetVnfCatalogDataCustomizationUuid(String vnfModelCustomizationUuid,  String responseFile){
+		stubFor(get(urlEqualTo("/v2/serviceVnfs?vnfModelCustomizationUuid=" + vnfModelCustomizationUuid))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "application/json")
+				  .withBodyFile(responseFile)));
+	}
+
+	public static void MockGetVfModuleByModelNameCatalogData(String vfModuleModelName, String responseFile){
+		stubFor(get(urlEqualTo("/v2/vfModules?vfModuleModelName=" + vfModuleModelName))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "application/json")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetServiceResourcesCatalogData(String serviceModelInvariantUuid, String serviceModelVersion, String responseFile){
+		stubFor(get(urlEqualTo("/v2/serviceResources?serviceModelInvariantUuid=" + serviceModelInvariantUuid + 
+				"&serviceModelVersion=" + serviceModelVersion))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "application/json")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockGetServiceResourcesCatalogData(String serviceModelInvariantUuid, String responseFile){
+		stubFor(get(urlEqualTo("/v2/serviceResources?serviceModelInvariantUuid=" + serviceModelInvariantUuid))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "application/json")
+				  .withBodyFile(responseFile)));
+	}	
+	
+
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseNetworkAdapter.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseNetworkAdapter.java
new file mode 100644
index 0000000..8baeb1b
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseNetworkAdapter.java
@@ -0,0 +1,113 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
+import static com.github.tomakehurst.wiremock.client.WireMock.containing;
+import static com.github.tomakehurst.wiremock.client.WireMock.post;
+import static com.github.tomakehurst.wiremock.client.WireMock.put;
+import static com.github.tomakehurst.wiremock.client.WireMock.delete;
+import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
+
+/**
+ * Please describe the StubResponseNetwork.java class
+ *
+ */
+public class StubResponseNetworkAdapter {
+
+	private static final String EOL = "\n";
+
+	public static void setupAllMocks() {
+
+	}
+
+
+	public static void MockNetworkAdapter() {
+		stubFor(post(urlEqualTo("/networks/NetworkAdapter"))
+			.willReturn(aResponse()
+			.withStatus(200)));
+	}
+
+	public static void MockNetworkAdapter(String response) {
+		stubFor(post(urlEqualTo("/networks/NetworkAdapter"))
+			.willReturn(aResponse()
+			.withStatus(200)
+			.withHeader("Content-Type", "text/xml")
+			.withBodyFile(response)));
+	}
+
+	public static void MockNetworkAdapter_500() {
+		stubFor(post(urlEqualTo("/networks/NetworkAdapter"))
+			.willReturn(aResponse()
+			.withStatus(500)));
+	}
+
+	public static void MockNetworkAdapterPost(String responseFile, String requestContaining) {
+		stubFor(post(urlEqualTo("/networks/NetworkAdapter"))
+			.withRequestBody(containing(requestContaining))				
+			.willReturn(aResponse()
+			.withStatus(200)
+			.withHeader("Content-Type", "text/xml")
+			.withBodyFile(responseFile)));
+	}	
+	
+	public static void MockNetworkAdapter(String networkId, int statusCode, String responseFile) {
+		stubFor(delete(urlEqualTo("/networks/NetworkAdapter/" + networkId))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "application/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockNetworkAdapterContainingRequest(String requestContaining, int statusCode, String responseFile) {
+		stubFor(post(urlEqualTo("/networks/NetworkAdapter"))
+				  .withRequestBody(containing(requestContaining))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockPutNetworkAdapter(String networkId, String requestContaining, int statusCode, String responseFile) {
+		stubFor(put(urlEqualTo("/networks/NetworkAdapter/" + networkId))
+				  .withRequestBody(containing(requestContaining))
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void MockNetworkAdapterRestRollbackDelete(String responseFile, String networkId) {
+		stubFor(delete(urlEqualTo("/networks/NetworkAdapter/"+networkId+"/rollback"))
+			.willReturn(aResponse()
+			.withStatus(200)
+			.withHeader("Content-Type", "text/xml")
+			.withBodyFile(responseFile)));
+	}	
+
+	public static void MockNetworkAdapterRestPut(String responseFile, String networkId) {
+		stubFor(put(urlEqualTo("/networks/NetworkAdapter/"+networkId))
+			.willReturn(aResponse()
+			.withStatus(200)
+			.withHeader("Content-Type", "text/xml")
+			.withBodyFile(responseFile)));
+	}		
+	
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponsePolicy.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponsePolicy.java
new file mode 100644
index 0000000..38b81c5
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponsePolicy.java
@@ -0,0 +1,94 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
+import static com.github.tomakehurst.wiremock.client.WireMock.containing;
+import static com.github.tomakehurst.wiremock.client.WireMock.delete;
+import static com.github.tomakehurst.wiremock.client.WireMock.get;
+import static com.github.tomakehurst.wiremock.client.WireMock.post;
+import static com.github.tomakehurst.wiremock.client.WireMock.patch;
+import static com.github.tomakehurst.wiremock.client.WireMock.put;
+import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlMatching;
+
+/**
+ * Reusable Mock StubResponses for Policy
+ *
+ */
+public class StubResponsePolicy {
+
+	public static void setupAllMocks() {
+
+	}
+
+	// start of Policy mocks
+	public static void MockPolicyAbort() {		
+		stubFor(post(urlEqualTo("/pdp/api/getDecision"))
+			.withRequestBody(containing("BB1"))
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "application/json")
+				.withBodyFile("policyAbortResponse.json")));
+		
+		stubFor(post(urlEqualTo("/pdp/api/getDecision"))
+				.withRequestBody(containing("UPDVnfI"))
+				.willReturn(aResponse()
+					.withStatus(200)
+					.withHeader("Content-Type", "application/json")
+					.withBodyFile("policyAbortResponse.json")));
+		
+		stubFor(post(urlEqualTo("/pdp/api/getDecision"))
+				.withRequestBody(containing("RPLVnfI"))
+				.willReturn(aResponse()
+					.withStatus(200)
+					.withHeader("Content-Type", "application/json")
+					.withBodyFile("policyAbortResponse.json")));
+
+
+	}
+	
+	public static void MockPolicySkip() {		
+		stubFor(post(urlEqualTo("/pdp/api/getDecision"))
+			.withRequestBody(containing("BB1"))
+			.willReturn(aResponse()
+				.withStatus(200)
+				.withHeader("Content-Type", "application/json")
+				.withBodyFile("Policy/policySkipResponse.json")));
+		
+		stubFor(post(urlEqualTo("/pdp/api/getDecision"))
+				.withRequestBody(containing("UPDVnfI"))
+				.willReturn(aResponse()
+					.withStatus(200)
+					.withHeader("Content-Type", "application/json")
+					.withBodyFile("Policy/policySkipResponse.json")));
+		
+		stubFor(post(urlEqualTo("/pdp/api/getDecision"))
+				.withRequestBody(containing("RPLVnfI"))
+				.willReturn(aResponse()
+					.withStatus(200)
+					.withHeader("Content-Type", "application/json")
+					.withBodyFile("Policy/policySkipResponse.json")));
+
+
+	}
+	
+	
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseSDNCAdapter.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseSDNCAdapter.java
new file mode 100644
index 0000000..f41d6d7
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseSDNCAdapter.java
@@ -0,0 +1,146 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
+import static com.github.tomakehurst.wiremock.client.WireMock.containing;
+import static com.github.tomakehurst.wiremock.client.WireMock.post;
+import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
+
+/**
+ * Please describe the StubResponseSDNC.java class
+ */
+public class StubResponseSDNCAdapter {
+
+	public static void setupAllMocks() {
+
+	}
+
+	public static void mockSDNCAdapter_500() {
+		stubFor(post(urlEqualTo("/SDNCAdapter"))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}		
+	
+	public static void mockSDNCAdapter_500(String requestContaining) {
+		stubFor(post(urlEqualTo("/SDNCAdapter"))
+		  .withRequestBody(containing(requestContaining))
+		  .willReturn(aResponse()
+		  .withStatus(500)));
+	}		
+	
+	public static void mockSDNCAdapter(int statusCode) {
+		stubFor(post(urlEqualTo("/SDNCAdapter"))
+				.willReturn(aResponse()
+						.withStatus(statusCode)));
+	}
+	
+	public static void mockSDNCAdapter(String endpoint, int statusCode, String responseFile) {
+		stubFor(post(urlEqualTo(endpoint))	
+				  .willReturn(aResponse()
+				  .withStatus(statusCode)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+
+	public static void mockSDNCAdapter(String responseFile) {
+		stubFor(post(urlEqualTo("/SDNCAdapter"))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+	
+	public static void mockSDNCAdapter(String endpoint, String requestContaining, int statusCode, String responseFile) {
+		stubFor(post(urlEqualTo(endpoint))
+				.withRequestBody(containing(requestContaining))
+				.willReturn(aResponse()
+					.withStatus(statusCode)
+					.withHeader("Content-Type", "text/xml")
+					.withBodyFile(responseFile)));
+	}
+
+	public static void mockSDNCAdapterSimulator(String responseFile) {
+		MockResource mockResource = new MockResource();
+		mockResource.updateProperties("sdnc_delay", "300");
+		stubFor(post(urlEqualTo("/SDNCAdapter"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "application/soap+xml")
+						.withTransformers("sdnc-adapter-transformer")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void mockSDNCAdapterSimulator(String responseFile, String requestContaining) {
+		MockResource mockResource = new MockResource();
+		mockResource.updateProperties("sdnc_delay", "300");
+		stubFor(post(urlEqualTo("/SDNCAdapter"))
+				.withRequestBody(containing(requestContaining))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "application/soap+xml")
+						.withTransformers("sdnc-adapter-transformer")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void mockSDNCAdapterRest() {
+		stubFor(post(urlEqualTo("/SDNCAdapter/v1/sdnc/services"))
+				.willReturn(aResponse()
+						.withStatus(202)
+						.withHeader("Content-Type", "application/json")));
+	}
+
+	public static void mockSDNCAdapterRest_500() {
+		stubFor(post(urlEqualTo("/SDNCAdapter/v1/sdnc/services"))
+				.willReturn(aResponse()
+						.withStatus(500)
+						.withHeader("Content-Type", "application/json")));
+	}
+
+	public static void mockSDNCAdapterRest(String requestContaining) {
+		stubFor(post(urlEqualTo("/SDNCAdapter/v1/sdnc/services"))
+				.withRequestBody(containing(requestContaining))
+				.willReturn(aResponse()
+						.withStatus(202)
+						.withHeader("Content-Type", "application/json")));
+	}
+
+	public static void mockSDNCAdapterRest_500(String requestContaining) {
+		stubFor(post(urlEqualTo("/SDNCAdapter/v1/sdnc/services"))
+				.withRequestBody(containing(requestContaining))
+				.willReturn(aResponse()
+						.withStatus(500)
+						.withHeader("Content-Type", "application/json")));
+	}
+
+	public static void mockSDNCAdapterTopology(String responseFile, String requestContaining) {
+		MockResource mockResource = new MockResource();
+		mockResource.updateProperties("sdnc_delay", "300");		
+		stubFor(post(urlEqualTo("/SDNCAdapter"))
+				.withRequestBody(containing(requestContaining))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "text/xml")
+						.withTransformers("network-topology-operation-transformer")
+						.withBodyFile(responseFile)));
+	}
+
+	
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseSNIRO.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseSNIRO.java
new file mode 100644
index 0000000..a8f4db8
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseSNIRO.java
@@ -0,0 +1,69 @@
+/*
+ * ============LICENSE_START=======================================================
+ * ONAP - SO
+ * ================================================================================
+ * 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=========================================================
+ */
+
+/*
+ * © 2014 AT&T Intellectual Property. All rights reserved. Used under license from AT&T Intellectual Property.
+ */
+package org.openecomp.mso.bpmn.mock;
+
+import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
+import static com.github.tomakehurst.wiremock.client.WireMock.post;
+import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
+
+/**
+ * Please describe the StubResponseSNIRO.java class
+ *
+ * @author cb645j
+ */
+public class StubResponseSNIRO {
+
+	public static void setupAllMocks() {
+
+	}
+
+	public static void mockSNIRO() {
+		stubFor(post(urlEqualTo("/sniro/api/v2/placement"))
+				.willReturn(aResponse()
+						.withStatus(202)
+						.withHeader("Content-Type", "application/json")));
+	}
+
+	public static void mockSNIRO(String responseFile) {
+		stubFor(post(urlEqualTo("/sniro/api/v2/placement"))
+				.willReturn(aResponse()
+						.withStatus(202)
+						.withHeader("Content-Type", "application/json")
+						.withBodyFile(responseFile)));
+	}
+
+	public static void mockSNIRO_400() {
+		stubFor(post(urlEqualTo("/sniro/api/v2/placement"))
+				.willReturn(aResponse()
+						.withStatus(400)
+						.withHeader("Content-Type", "application/json")));
+	}
+
+	public static void mockSNIRO_500() {
+		stubFor(post(urlEqualTo("/sniro/api/v2/placement"))
+				.willReturn(aResponse()
+						.withStatus(500)
+						.withHeader("Content-Type", "application/json")));
+	}
+
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseVNFAdapter.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseVNFAdapter.java
new file mode 100644
index 0000000..b4aca50
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/StubResponseVNFAdapter.java
@@ -0,0 +1,158 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
+import static com.github.tomakehurst.wiremock.client.WireMock.containing;
+import static com.github.tomakehurst.wiremock.client.WireMock.delete;
+import static com.github.tomakehurst.wiremock.client.WireMock.post;
+import static com.github.tomakehurst.wiremock.client.WireMock.put;
+import static com.github.tomakehurst.wiremock.client.WireMock.stubFor;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
+import static com.github.tomakehurst.wiremock.client.WireMock.urlMatching;
+
+/**
+ * Please describe the StubResponseVNF.java class
+ */
+public class StubResponseVNFAdapter {
+
+	public static void mockVNFAdapter() {
+		stubFor(post(urlEqualTo("/vnfs/VnfAdapterAsync"))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+
+	public static void mockVNFAdapter(String responseFile) {
+		stubFor(post(urlEqualTo("/vnfs/VnfAdapterAsync"))
+				  .willReturn(aResponse()
+				  .withStatus(200)
+				  .withHeader("Content-Type", "text/xml")
+				  .withBodyFile(responseFile)));
+	}
+
+	public static void mockVNFAdapter_500() {
+		stubFor(post(urlEqualTo("/vnfs/VnfAdapterAsync"))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+
+	public static void mockVNFAdapterTransformer(String transformer, String responseFile) {
+		MockResource mockResource = new MockResource();
+		mockResource.updateProperties("vnf_delay", "300");
+		stubFor(post(urlEqualTo("/vnfs/VnfAdapterAsync"))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "application/soap+xml")
+						.withTransformers(transformer)
+						.withBodyFile(responseFile)));
+	}
+
+	public static void mockVNFAdapterTransformer(String transformer, String responseFile, String requestContaining) {
+		MockResource mockResource = new MockResource();
+		mockResource.updateProperties("vnf_delay", "300");
+		stubFor(post(urlEqualTo("/vnfs/VnfAdapterAsync"))
+				.withRequestBody(containing(requestContaining))
+				.willReturn(aResponse()
+						.withStatus(200)
+						.withHeader("Content-Type", "application/soap+xml")
+						.withTransformers(transformer)
+						.withBodyFile(responseFile)));
+	}
+	
+	public static void mockVNFPost(String vfModuleId, int statusCode, String vnfId) {
+		stubFor(post(urlEqualTo("/vnfs/v1/vnfs/" + vnfId + "/vf-modules" + vfModuleId))
+				.willReturn(aResponse()
+				.withStatus(statusCode)
+				.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void mockVNFPut(String vfModuleId, int statusCode) {
+		stubFor(put(urlEqualTo("/vnfs/v1/vnfs/vnfId/vf-modules" + vfModuleId))
+				.willReturn(aResponse()
+				.withStatus(statusCode)
+				.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void mockVNFPut(String vnfId, String vfModuleId, int statusCode) {
+		stubFor(put(urlEqualTo("/vnfs/v1/vnfs/" + vnfId + "/vf-modules" + vfModuleId))
+				.willReturn(aResponse()
+				.withStatus(statusCode)
+				.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void mockVNFDelete(String vnfId, String vfModuleId, int statusCode) {
+		stubFor(delete(urlEqualTo("/vnfs/v1/vnfs/" + vnfId + "/vf-modules" + vfModuleId))
+				.willReturn(aResponse()
+				.withStatus(statusCode)
+				.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void mockVNFRollbackDelete(String vfModuleId, int statusCode) {
+		stubFor(delete(urlEqualTo("/vnfs/v1/vnfs/vnfId/vf-modules" + vfModuleId + "/rollback"))
+				.willReturn(aResponse()
+				.withStatus(statusCode)
+				.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void mockPutVNFVolumeGroup(String volumeGroupId, int statusCode) {
+		stubFor(put(urlEqualTo("/vnfs/v1/volume-groups/" + volumeGroupId))
+				.willReturn(aResponse()
+					.withStatus(statusCode)
+					.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void mockPutVNFVolumeGroupRollback(String volumeGroupId, int statusCode) {
+		stubFor(delete(urlMatching("/vnfs/v1/volume-groups/" + volumeGroupId + "/rollback"))
+				.willReturn(aResponse()
+				.withStatus(statusCode)
+				.withHeader("Content-Type", "application/xml")));
+	}
+	public static void mockPostVNFVolumeGroup(int statusCode) {
+		stubFor(post(urlEqualTo("/vnfs/v1/volume-groups"))
+				.willReturn(aResponse()
+					.withStatus(statusCode)
+					.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void mockVNFAdapterRest(String vnfId) {
+		stubFor(post(urlEqualTo("/vnfs/v1/vnfs/" + vnfId + "/vf-modules"))
+				.willReturn(aResponse()
+						.withStatus(200)));
+	}
+
+	public static void mockVNFAdapterRest_500(String vnfId) {
+		stubFor(post(urlEqualTo("/vnfs/v1/vnfs/" + vnfId + "/vf-modules"))
+				.willReturn(aResponse()
+						.withStatus(500)));
+	}
+	
+	public static void mockVfModuleDelete(String volumeGroupId) {
+		stubFor(delete(urlMatching("/vnfs/v1/volume-groups/"+ volumeGroupId))
+				.willReturn(aResponse()
+				.withStatus(202)
+				.withHeader("Content-Type", "application/xml")));
+	}
+	
+	public static void mockVfModuleDelete(String volumeGroupId, int statusCode) {
+		stubFor(delete(urlMatching("/vnfs/v1/volume-groups/78987"))
+				.willReturn(aResponse()
+				.withStatus(statusCode)
+				.withHeader("Content-Type", "application/xml")));
+	}
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterCreateMockTransformer.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterCreateMockTransformer.java
new file mode 100644
index 0000000..23921da
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterCreateMockTransformer.java
@@ -0,0 +1,148 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import javax.xml.ws.Endpoint;
+
+import org.jboss.resteasy.client.ClientRequest;
+import org.jboss.resteasy.client.ClientResponse;
+import org.openecomp.mso.logger.MsoLogger;
+
+import com.github.tomakehurst.wiremock.client.ResponseDefinitionBuilder;
+import com.github.tomakehurst.wiremock.common.FileSource;
+import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
+import com.github.tomakehurst.wiremock.http.Request;
+import com.github.tomakehurst.wiremock.http.ResponseDefinition;
+
+import org.openecomp.mso.logger.MsoLogger;
+/**
+ * Please describe the VnfAdapterCreateMockTransformer.java class
+ *
+ */
+public class VnfAdapterCreateMockTransformer extends ResponseTransformer {
+
+	private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
+	
+	private String notifyCallbackResponse;
+	private String ackResponse;
+
+	public VnfAdapterCreateMockTransformer() {
+		notifyCallbackResponse = FileUtil.readResourceFile("__files/vnfAdapterMocks/vnfCreateSimResponse.xml"); // default response
+	}
+
+	@Override
+	public String name() {
+		return "vnf-adapter-create-transformer";
+	}
+
+	@Override
+	public ResponseDefinition transform(Request request, ResponseDefinition responseDefinition,
+			FileSource fileSource) {
+
+		String requestBody = request.getBodyAsString();
+
+		String notficationUrl = requestBody.substring(requestBody.indexOf("<notificationUrl>")+17, requestBody.indexOf("</notificationUrl>"));
+		String messageId = requestBody.substring(requestBody.indexOf("<messageId>")+11, requestBody.indexOf("</messageId>"));
+		String responseMessageId = "";
+		String updatedResponse = "";
+
+		try {
+			// try supplied response file (if any)
+			System.out.println(" Supplied fileName: " + responseDefinition.getBodyFileName());
+		    ackResponse = FileUtil.readResourceFile("__files/" + responseDefinition.getBodyFileName());
+			notifyCallbackResponse = ackResponse;
+			responseMessageId = ackResponse.substring(ackResponse.indexOf("<messageId>")+11, ackResponse.indexOf("</messageId>"));
+		    updatedResponse = ackResponse.replace(responseMessageId, messageId);
+		} catch (Exception ex) {
+			LOGGER.debug("Exception :",ex);
+			System.out.println(" ******* Use default response file in '__files/vnfAdapterMocks/vnfCreateSimResponse.xml'");
+		    responseMessageId = notifyCallbackResponse.substring(notifyCallbackResponse.indexOf("<messageId>")+11, notifyCallbackResponse.indexOf("</messageId>"));
+			updatedResponse = notifyCallbackResponse.replace(responseMessageId, messageId);
+		}
+
+		System.out.println("response (mock) messageId       : " + responseMessageId);
+		System.out.println("request  (replacement) messageId: " + messageId);
+
+		System.out.println("vnf Response (before):" + notifyCallbackResponse);
+		System.out.println("vnf Response (after):" + updatedResponse);
+
+		Object vnfDelay = MockResource.getMockProperties().get("vnf_delay");
+		int delay = 300;
+		if (vnfDelay != null) {
+			delay = Integer.parseInt(vnfDelay.toString());
+		}
+
+		//Kick off callback thread
+		System.out.println("VnfAdapterCreateMockTransformer notficationUrl: " + notficationUrl + ":delay: " + delay);
+		CallbackResponseThread callbackResponseThread = new CallbackResponseThread(notficationUrl,updatedResponse, delay);
+		callbackResponseThread.start();
+
+		return ResponseDefinitionBuilder
+		           .like(responseDefinition).but()
+		           .withStatus(200).withBody(updatedResponse).withHeader("Content-Type", "text/xml")
+		           .build();
+
+	}
+
+	@Override
+	public boolean applyGlobally() {
+	    return false;
+	}
+
+	private class CallbackResponseThread extends Thread {
+
+		private String callbackUrl;
+		private String payLoad;
+		private int delay;
+
+		public CallbackResponseThread(String callbackUrl, String payLoad, int delay) {
+			this.callbackUrl = callbackUrl;
+			this.payLoad = payLoad;
+			this.delay = delay;
+		}
+
+		@SuppressWarnings("deprecation")
+		public void run () {
+			try {
+				//Delay sending callback response
+				sleep(delay);
+			} catch (InterruptedException e1) {
+				// TODO Auto-generated catch block
+				LOGGER.debug("Exception :",e1);
+			}
+			LOGGER.debug("Sending callback response to url: " + callbackUrl);
+			ClientRequest request = new ClientRequest(callbackUrl);
+			request.body("text/xml", payLoad);
+			//System.out.println("payLoad: " + payLoad);
+
+			try {
+				ClientResponse result = request.post();
+				LOGGER.debug("Successfully posted callback? Status: " + result.getStatus());
+				//System.err.println("Successfully posted callback:" + result.getStatus());
+			} catch (Exception e) {
+				// TODO Auto-generated catch block
+			    LOGGER.debug("catch error in - request.post() ");
+				LOGGER.debug("Exception :",e);
+			}
+		}
+
+	}
+
+
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterDeleteMockTransformer.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterDeleteMockTransformer.java
new file mode 100644
index 0000000..ee6972e
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterDeleteMockTransformer.java
@@ -0,0 +1,143 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import org.jboss.resteasy.client.ClientRequest;
+import org.jboss.resteasy.client.ClientResponse;
+import org.openecomp.mso.logger.MsoLogger;
+
+import com.github.tomakehurst.wiremock.client.ResponseDefinitionBuilder;
+import com.github.tomakehurst.wiremock.common.FileSource;
+import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
+import com.github.tomakehurst.wiremock.http.Request;
+import com.github.tomakehurst.wiremock.http.ResponseDefinition;
+/**
+ * Please describe the VnfAdapterCreateMockTransformer.java class
+ *
+ */
+public class VnfAdapterDeleteMockTransformer extends ResponseTransformer {
+
+	private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
+
+	private String notifyCallbackResponse;
+	private String ackResponse;
+
+	public VnfAdapterDeleteMockTransformer() {
+		notifyCallbackResponse = FileUtil.readResourceFile("__files/vnfAdapterMocks/vnfDeleteSimResponse.xml");
+	}
+
+	@Override
+	public String name() {
+		return "vnf-adapter-delete-transformer";
+	}
+
+	@Override
+	public ResponseDefinition transform(Request request, ResponseDefinition responseDefinition,
+			FileSource fileSource) {
+
+		// System.err.println("notifyCallbackResponse:" + notifyCallbackResponse);
+
+		String requestBody = request.getBodyAsString();
+
+		String notficationUrl = requestBody.substring(requestBody.indexOf("<notificationUrl>")+17, requestBody.indexOf("</notificationUrl>"));
+		String messageId = requestBody.substring(requestBody.indexOf("<messageId>")+11, requestBody.indexOf("</messageId>"));
+		String responseMessageId = "";
+		String updatedResponse = "";
+
+		try {
+			// try supplied response file (if any)
+			System.out.println(" Supplied fileName: " + responseDefinition.getBodyFileName());
+		    ackResponse = FileUtil.readResourceFile("__files/" + responseDefinition.getBodyFileName());
+			notifyCallbackResponse = ackResponse;
+			responseMessageId = ackResponse.substring(ackResponse.indexOf("<messageId>")+11, ackResponse.indexOf("</messageId>"));
+		    updatedResponse = ackResponse.replace(responseMessageId, messageId);
+		} catch (Exception ex) {
+			LOGGER.debug("Exception :",ex);
+			System.out.println(" ******* Use default response file in '__files/vnfAdapterMocks/vnfDeleteSimResponse.xml'");
+		    responseMessageId = notifyCallbackResponse.substring(notifyCallbackResponse.indexOf("<messageId>")+11, notifyCallbackResponse.indexOf("</messageId>"));
+			updatedResponse = notifyCallbackResponse.replace(responseMessageId, messageId);
+		}
+
+		System.out.println("response (mock) messageId       : " + responseMessageId);
+		System.out.println("request  (replacement) messageId: " + messageId);
+
+		System.out.println("vnf Response (before):" + notifyCallbackResponse);
+		System.out.println("vnf Response (after):" + updatedResponse);
+
+		Object vnfDelay = MockResource.getMockProperties().get("vnf_delay");
+		int delay = 300;
+		if (vnfDelay != null) {
+			delay = Integer.parseInt(vnfDelay.toString());
+		}
+
+		//Kick off callback thread
+		System.out.println("VnfAdapterDeleteMockTransformer notficationUrl: " + notficationUrl + ":delay: " + delay);
+		CallbackResponseThread callbackResponseThread = new CallbackResponseThread(notficationUrl,updatedResponse, delay);
+		callbackResponseThread.start();
+
+		return ResponseDefinitionBuilder
+		           .like(responseDefinition).but()
+		           .withStatus(200).withBody(updatedResponse).withHeader("Content-Type", "text/xml")
+		           .build();
+
+	}
+
+	@Override
+	public boolean applyGlobally() {
+	    return false;
+	}
+
+	private class CallbackResponseThread extends Thread {
+
+		private String callbackUrl;
+		private String payLoad;
+		private int delay;
+
+		public CallbackResponseThread(String callbackUrl, String payLoad, int delay) {
+			this.callbackUrl = callbackUrl;
+			this.payLoad = payLoad;
+			this.delay = delay;
+		}
+
+		@SuppressWarnings("deprecation")
+		public void run () {
+			try {
+				//Delay sending callback response
+				sleep(delay);
+			} catch (InterruptedException e1) {
+				// TODO Auto-generated catch block
+				LOGGER.debug("Exception :",e1);
+			}
+			System.out.println("Sending callback response to url: " + callbackUrl);
+			ClientRequest request = new ClientRequest(callbackUrl);
+			request.body("text/xml", payLoad);
+			//System.err.println(payLoad);
+			try {
+				ClientResponse result = request.post();
+				System.out.println("Successfully posted callback? Status: " + result.getStatus());
+				//System.err.println("Successfully posted callback:" + result.getStatus());
+			} catch (Exception e) {
+				// TODO Auto-generated catch block
+				System.out.println("catch error in - request.post() ");
+				LOGGER.debug("Exception :",e);
+			}
+		}
+
+	}
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterQueryMockTransformer.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterQueryMockTransformer.java
new file mode 100644
index 0000000..1582071
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterQueryMockTransformer.java
@@ -0,0 +1,161 @@
+/* 
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+
+import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
+
+import org.jboss.resteasy.client.ClientRequest;
+import org.jboss.resteasy.client.ClientResponse;
+import org.openecomp.mso.logger.MsoLogger;
+
+import com.github.tomakehurst.wiremock.client.ResponseDefinitionBuilder;
+import com.github.tomakehurst.wiremock.common.FileSource;
+import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
+import com.github.tomakehurst.wiremock.http.Request;
+import com.github.tomakehurst.wiremock.http.ResponseDefinition;
+
+import org.openecomp.mso.logger.MsoLogger;
+/**
+ * Please describe the VnfAdapterQueryMockTransformer.java class
+ *
+ */
+
+
+public class VnfAdapterQueryMockTransformer extends ResponseTransformer{
+	
+	private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
+	
+	private String notifyCallbackResponse;
+	private String ackResponse;
+	private String messageId;
+
+	public VnfAdapterQueryMockTransformer() {
+		notifyCallbackResponse = FileUtil.readResourceFile("__files/vnfAdapterMocks/vnfQuerySimResponse.xml");
+	}
+	
+	public VnfAdapterQueryMockTransformer(String messageId) {
+		this.messageId = messageId;
+	}
+
+	@Override
+	public String name() {
+		return "vnf-adapter-query-transformer";
+	}
+	
+	@Override
+	public ResponseDefinition transform(Request request, ResponseDefinition responseDefinition,
+			FileSource fileSource) {
+
+		String requestBody = request.getBodyAsString();
+
+		String notficationUrl = requestBody.substring(requestBody.indexOf("<notificationUrl>")+17, requestBody.indexOf("</notificationUrl>"));
+		String messageId = requestBody.substring(requestBody.indexOf("<messageId>")+11, requestBody.indexOf("</messageId>"));
+	//	String updatedResponse = notifyCallbackResponse.replace("b1a82ce6-7f5c-45fd-9273-acaf88fc2137", messageId);
+	
+		String responseMessageId = "";
+		String updatedResponse = "";
+		
+	//	if (ackResponse == null) {
+			//System.err.println("file:" + responseDefinition.getBodyFileName());
+		//	ackResponse = FileUtil.readResourceFile("__files/" + responseDefinition.getBodyFileName());
+		//}
+
+		
+		try {
+			// try supplied response file (if any)
+			System.out.println(" Supplied fileName: " + responseDefinition.getBodyFileName());
+		    ackResponse = FileUtil.readResourceFile("__files/" + responseDefinition.getBodyFileName());
+			notifyCallbackResponse = ackResponse;
+			responseMessageId = ackResponse.substring(ackResponse.indexOf("<messageId>")+11, ackResponse.indexOf("</messageId>"));
+		    updatedResponse = ackResponse.replace(responseMessageId, messageId); 
+		} catch (Exception ex) {
+			LOGGER.debug("Exception :",ex);
+			System.out.println(" ******* Use default response file in '__files/vnfAdapterMocks/vnfQuerySimResponse.xml'");
+		    responseMessageId = notifyCallbackResponse.substring(notifyCallbackResponse.indexOf("<messageId>")+11, notifyCallbackResponse.indexOf("</messageId>"));
+			updatedResponse = notifyCallbackResponse.replace(responseMessageId, messageId);
+		}
+		
+		System.out.println("response (mock) messageId       : " + responseMessageId);		
+		System.out.println("request  (replacement) messageId: " + messageId);
+		
+		System.out.println("vnf Response (before):" + notifyCallbackResponse);
+		System.out.println("vnf Response (after):" + updatedResponse);
+		
+		
+		Object vnfDelay = MockResource.getMockProperties().get("vnf_delay");
+		int delay = 300;
+		if (vnfDelay != null) {
+			delay = Integer.parseInt(vnfDelay.toString());
+		}
+
+		//Kick off callback thread
+		
+		//System.out.println("notficationUrl" + notficationUrl);
+		//System.out.println("updatedResponse" + updatedResponse);
+		System.out.println("VnfAdapterQueryMockTransformer notficationUrl: " + notficationUrl + ":delay: " + delay);
+		CallbackResponseThread callbackResponseThread = new CallbackResponseThread(notficationUrl,updatedResponse, delay);
+		System.out.println("Inside Callback" );
+		callbackResponseThread.start();
+
+				return ResponseDefinitionBuilder
+		             .like(responseDefinition).but()
+		             .withStatus(200).withBody(updatedResponse).withHeader("Content-Type", "text/xml")
+		             .build();
+	}
+
+	@Override
+	public boolean applyGlobally() {
+	    return false;
+	}
+
+	private class CallbackResponseThread extends Thread {
+
+		private String callbackUrl;
+		private String payLoad;
+		private int delay;
+
+		public CallbackResponseThread(String callbackUrl, String payLoad, int delay) {
+			this.callbackUrl = callbackUrl;
+			this.payLoad = payLoad;
+			this.delay = delay;
+		}
+
+		public void run () {
+			try {
+				//Delay sending callback response
+				sleep(delay);
+			} catch (InterruptedException e1) {
+				LOGGER.debug("Exception :",e1);
+			}
+			ClientRequest request = new ClientRequest(callbackUrl);
+			request.body("text/xml", payLoad);
+			//System.err.println(payLoad);
+			try {
+				ClientResponse result = request.post();
+				//System.err.println("Successfully posted callback:" + result.getStatus());
+			} catch (Exception e) {
+				LOGGER.debug("Exception :",e);
+			}
+		}
+
+	}
+
+
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterRollbackMockTransformer.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterRollbackMockTransformer.java
new file mode 100644
index 0000000..186fd35
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterRollbackMockTransformer.java
@@ -0,0 +1,144 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * 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.mock;
+
+import org.jboss.resteasy.client.ClientRequest;
+import org.jboss.resteasy.client.ClientResponse;
+
+import com.github.tomakehurst.wiremock.client.ResponseDefinitionBuilder;
+import com.github.tomakehurst.wiremock.common.FileSource;
+import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
+import com.github.tomakehurst.wiremock.http.Request;
+import com.github.tomakehurst.wiremock.http.ResponseDefinition;
+
+import org.openecomp.mso.logger.MsoLogger;
+/**
+ * Please describe the VnfAdapterCreateMockTransformer.java class
+ *
+ */
+public class VnfAdapterRollbackMockTransformer extends ResponseTransformer {
+
+	private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
+
+	private String notifyCallbackResponse;
+	private String ackResponse;
+	private String messageId;
+
+	public VnfAdapterRollbackMockTransformer() {
+		notifyCallbackResponse = FileUtil.readResourceFile("__files/vnfAdapterMocks/vnfRollbackSimResponse.xml");
+	}
+	
+	public VnfAdapterRollbackMockTransformer(String messageId) {
+		this.messageId = messageId;
+	}
+
+	@Override
+	public String name() {
+		return "vnf-adapter-rollback-transformer";
+	}
+
+	@Override
+	public ResponseDefinition transform(Request request, ResponseDefinition responseDefinition,
+			FileSource fileSource) {
+
+		String requestBody = request.getBodyAsString();
+
+		String notficationUrl = requestBody.substring(requestBody.indexOf("<notificationUrl>")+17, requestBody.indexOf("</notificationUrl>"));
+		String messageId = requestBody.substring(requestBody.indexOf("<messageId>")+11, requestBody.indexOf("</messageId>"));
+		String responseMessageId = "";
+		String updatedResponse = "";
+		
+		try {
+			// try supplied response file (if any)
+			System.out.println(" Supplied fileName: " + responseDefinition.getBodyFileName());
+		    ackResponse = FileUtil.readResourceFile("__files/" + responseDefinition.getBodyFileName());
+			notifyCallbackResponse = ackResponse;
+			responseMessageId = ackResponse.substring(ackResponse.indexOf("<messageId>")+11, ackResponse.indexOf("</messageId>"));
+		    updatedResponse = ackResponse.replace(responseMessageId, messageId); 
+		} catch (Exception ex) {
+			LOGGER.debug("Exception :",ex);
+			System.out.println(" ******* Use default response file in '__files/vnfAdapterMocks/vnfRollbackSimResponse.xml'");
+		    responseMessageId = notifyCallbackResponse.substring(notifyCallbackResponse.indexOf("<messageId>")+11, notifyCallbackResponse.indexOf("</messageId>"));
+			updatedResponse = notifyCallbackResponse.replace(responseMessageId, messageId);
+		}
+		
+		System.out.println("response (mock) messageId       : " + responseMessageId);		
+		System.out.println("request  (replacement) messageId: " + messageId);
+		
+		System.out.println("vnf Response (before):" + notifyCallbackResponse);
+		System.out.println("vnf Response (after):" + updatedResponse);
+
+		Object vnfDelay = MockResource.getMockProperties().get("vnf_delay");
+		int delay = 300;
+		if (vnfDelay != null) {
+			delay = Integer.parseInt(vnfDelay.toString());
+		}
+
+		//Kick off callback thread
+		System.out.println("VnfAdapterRollbackMockTransformer notficationUrl: " + notficationUrl + ":delay: " + delay);		
+		CallbackResponseThread callbackResponseThread = new CallbackResponseThread(notficationUrl,updatedResponse, delay);
+		callbackResponseThread.start();
+
+		return ResponseDefinitionBuilder
+		           .like(responseDefinition).but()
+		           .withStatus(200).withBody(updatedResponse).withHeader("Content-Type", "text/xml")
+		           .build();
+		
+	}
+
+	@Override
+	public boolean applyGlobally() {
+	    return false;
+	}
+
+	private class CallbackResponseThread extends Thread {
+
+		private String callbackUrl;
+		private String payLoad;
+		private int delay;
+
+		public CallbackResponseThread(String callbackUrl, String payLoad, int delay) {
+			this.callbackUrl = callbackUrl;
+			this.payLoad = payLoad;
+			this.delay = delay;
+		}
+
+		public void run () {
+			try {
+				//Delay sending callback response
+				sleep(delay);
+			} catch (InterruptedException e1) {
+				LOGGER.debug("Exception :",e1);
+			}
+			System.out.println("Sending callback response to url: " + callbackUrl);
+			ClientRequest request = new ClientRequest(callbackUrl);
+			request.body("text/xml", payLoad);
+			//System.err.println(payLoad);
+			try {
+				ClientResponse result = request.post();
+				System.out.println("Successfully posted callback? Status: " + result.getStatus());
+				//System.err.println("Successfully posted callback:" + result.getStatus());
+			} catch (Exception e) {
+				System.out.println("catch error in - request.post() ");				
+				LOGGER.debug("Exception :",e);
+			}
+		}
+
+	}
+}
diff --git a/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterUpdateMockTransformer.java b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterUpdateMockTransformer.java
new file mode 100644
index 0000000..7808b47
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/java/org/openecomp/mso/bpmn/mock/VnfAdapterUpdateMockTransformer.java
@@ -0,0 +1,149 @@
+/*
+ * ============LICENSE_START======================================================= 
+ * ONAP - SO 
+ * ================================================================================ 
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2017 Huawei Technologies Co., Ltd. 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.mock;
+
+import org.jboss.resteasy.client.ClientRequest;
+import org.jboss.resteasy.client.ClientResponse;
+import org.openecomp.mso.logger.MsoLogger;
+
+import com.github.tomakehurst.wiremock.client.ResponseDefinitionBuilder;
+import com.github.tomakehurst.wiremock.common.FileSource;
+import com.github.tomakehurst.wiremock.extension.ResponseTransformer;
+import com.github.tomakehurst.wiremock.http.Request;
+import com.github.tomakehurst.wiremock.http.ResponseDefinition;
+
+import org.openecomp.mso.logger.MsoLogger;
+/**
+ * Please describe the VnfAdapterUpdateMockTransformer.java class
+ *
+ */
+public class VnfAdapterUpdateMockTransformer extends ResponseTransformer {
+
+	private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
+	
+	private String notifyCallbackResponse;
+	private String requestId;
+	private String ackResponse;
+
+	public VnfAdapterUpdateMockTransformer() {
+		notifyCallbackResponse = FileUtil.readResourceFile("vnfAdapter/vnfUpdateSimResponse.xml");
+	}
+
+	public VnfAdapterUpdateMockTransformer(String requestId) {
+		this.requestId = requestId;
+	}
+
+
+	public String name() {
+		return "vnf-adapter-update-transformer";
+	}
+
+	@Override
+	public ResponseDefinition transform(Request request, ResponseDefinition responseDefinition,
+			FileSource fileSource) {
+
+		String requestBody = request.getBodyAsString();
+
+		String notficationUrl = requestBody.substring(requestBody.indexOf("<notificationUrl>")+17, requestBody.indexOf("</notificationUrl>"));
+		String messageId = requestBody.substring(requestBody.indexOf("<messageId>")+11, requestBody.indexOf("</messageId>"));
+		String responseMessageId = "";
+		String updatedResponse = "";
+		
+		try {
+			// try supplied response file (if any)
+			System.out.println(" Supplied fileName: " + responseDefinition.getBodyFileName());
+		    ackResponse = FileUtil.readResourceFile("__files/" + responseDefinition.getBodyFileName());
+			notifyCallbackResponse = ackResponse;
+			responseMessageId = ackResponse.substring(ackResponse.indexOf("<messageId>")+11, ackResponse.indexOf("</messageId>"));
+		    updatedResponse = ackResponse.replace(responseMessageId, messageId); 
+		} catch (Exception ex) {
+			LOGGER.debug("Exception :",ex);
+			System.out.println(" ******* Use default response file in 'vnfAdapter/vnfUpdateSimResponse.xml'");
+		    responseMessageId = notifyCallbackResponse.substring(notifyCallbackResponse.indexOf("<messageId>")+11, notifyCallbackResponse.indexOf("</messageId>"));
+			updatedResponse = notifyCallbackResponse.replace(responseMessageId, messageId);
+		}
+		
+		System.out.println("response (mock) messageId       : " + responseMessageId);		
+		System.out.println("request  (replacement) messageId: " + messageId);
+		
+		System.out.println("vnf Response (before):" + notifyCallbackResponse);
+		System.out.println("vnf Response (after):" + updatedResponse);
+		
+		Object vnfDelay = MockResource.getMockProperties().get("vnf_delay");
+		int delay = 300;
+		if (vnfDelay != null) {
+			delay = Integer.parseInt(vnfDelay.toString());
+		}
+
+		//Kick off callback thread
+		System.out.println("VnfAdapterUpdateMockTransformer notficationUrl: " + notficationUrl + ":delay: " + delay);		
+		CallbackResponseThread callbackResponseThread = new CallbackResponseThread(notficationUrl,updatedResponse, delay);
+		callbackResponseThread.start();
+
+		return ResponseDefinitionBuilder
+		           .like(responseDefinition).but()
+		           .withStatus(200).withBody(updatedResponse).withHeader("Content-Type", "text/xml")
+		           .build();
+
+	}
+
+	@Override
+	public boolean applyGlobally() {
+	    return false;
+	}
+
+	private class CallbackResponseThread extends Thread {
+
+		private String callbackUrl;
+		private String payLoad;
+		private int delay;
+
+		public CallbackResponseThread(String callbackUrl, String payLoad, int delay) {
+			this.callbackUrl = callbackUrl;
+			this.payLoad = payLoad;
+			this.delay = delay;
+		}
+
+		public void run () {
+			try {
+				//Delay sending callback response
+				sleep(delay);
+			} catch (InterruptedException e1) {
+				LOGGER.debug("Exception :", e1);
+			}
+			System.out.println("Sending callback response to url: " + callbackUrl);			
+			ClientRequest request = new ClientRequest(callbackUrl);
+			request.body("text/xml", payLoad);
+			//System.err.println(payLoad);
+			try {
+				ClientResponse result = request.post();
+				System.out.println("Successfully posted callback? Status: " + result.getStatus());				
+				//System.err.println("Successfully posted callback:" + result.getStatus());
+			} catch (Exception e) {
+				System.out.println("catch error in - request.post() ");
+				LOGGER.debug("Exception :",e);
+			}
+		}
+
+	}
+}
+
diff --git a/bpmn/MSOMockServer/src/main/resources/__files/sdncSimResponse.xml b/bpmn/MSOMockServer/src/main/resources/__files/sdncSimResponse.xml
new file mode 100644
index 0000000..bef293d
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/resources/__files/sdncSimResponse.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
+	xmlns:v1="http://domain2.openecomp.org/workflow/sdnc/adapter/schema/v1">
+	<soapenv:Header />
+	<soapenv:Body>
+			<SDNCAdapterCallbackRequest
+				xmlns="http://domain2.openecomp.org/workflow/sdnc/adapter/schema/v1">
+				<CallbackHeader>
+					<RequestId>d325c9a7-84c0-4081-b979-9cc773a0976d</RequestId>
+					<ResponseCode>200</ResponseCode>
+					<ResponseMessage>OK</ResponseMessage>
+				</CallbackHeader>
+				<RequestData xsi:type="xs:string" xmlns:xs="http://www.w3.org/2001/XMLSchema"
+					xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">&lt;layer3-service-list
+					xmlns="com:att:sdnctl:l3api"&gt;&lt;service-instance-id&gt;0XX/VXXX/003717//Shakeout&lt;/service-instance-id&gt;&lt;service-status&gt;&lt;rpc-name&gt;svc-topology-operation&lt;/rpc-name&gt;&lt;rpc-action&gt;delete&lt;/rpc-action&gt;&lt;request-status&gt;synccomplete&lt;/request-status&gt;&lt;final-indicator&gt;Y&lt;/final-indicator&gt;&lt;l3sdn-action&gt;DisconnectLayer3ServiceRequest&lt;/l3sdn-action&gt;&lt;response-timestamp&gt;2015-10-22T02:11:52.010Z&lt;/response-timestamp&gt;&lt;/service-status&gt;&lt;service-data&gt;&lt;svc-config-additional-data/&gt;&lt;/service-data&gt;&lt;/layer3-service-list&gt;
+				</RequestData>
+			</SDNCAdapterCallbackRequest>
+	</soapenv:Body>
+</soapenv:Envelope>
diff --git a/bpmn/MSOMockServer/src/main/webapp/WEB-INF/jboss-web.xml b/bpmn/MSOMockServer/src/main/webapp/WEB-INF/jboss-web.xml
new file mode 100644
index 0000000..cca27bb
--- /dev/null
+++ b/bpmn/MSOMockServer/src/main/webapp/WEB-INF/jboss-web.xml
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>  
+<!DOCTYPE jboss-web PUBLIC "-//JBoss//DTD Web Application 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-web_5_0.dtd">
+<jboss-web>
+  <security-domain>other</security-domain>
+  <context-root>/msomock</context-root>
+</jboss-web>  
\ No newline at end of file
diff --git a/bpmn/MSOURN-plugin/build.properties b/bpmn/MSOURN-plugin/build.properties
deleted file mode 100644
index 7e5fb9f..0000000
--- a/bpmn/MSOURN-plugin/build.properties
+++ /dev/null
@@ -1,7 +0,0 @@
-# Copy this file to 'build.properties' and modify it to match your system
-# Alternatively, you can also copy it to '${user.home}/.camunda/build.properties'
-# to have a central configuration that works with all camunda BPM projects
-
-# Defines the deployment folder in a camunda BPM installation (backslashes need to be escaped or replaced by forward slashes).
-#deploy.jboss.dir=C:/camunda/camunda-bpm-jboss-7.3.0/server/jboss-as-${jboss-version}/standalone/deployments
-deploy.jboss.dir=C:/D2/jboss-ee/server/jboss-as-7.2.0.Final/standalone/deployments
\ No newline at end of file
diff --git a/bpmn/MSOURN-plugin/build.xml b/bpmn/MSOURN-plugin/build.xml
deleted file mode 100644
index f2dbc55..0000000
--- a/bpmn/MSOURN-plugin/build.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="urnMap-plugin" default="deploy.jboss">
-
-	<property file="build.properties" />
-	<property file="${user.home}/.camunda/build.properties" />
-	<property name="target.dir" value="target" />
-
-	<condition property="mvn.executable" value="mvn.bat" else="mvn">
-		<os family="windows"/>
-	</condition>
-
-	<target name="deploy.jboss" depends="package.mvn, install.cockpit.plugin" description="Copies the cockit plugin to the deployment directory defined in '${basedir}/build.properties' or '${user.home}/.camunda/build.properties'" />
-
-	<target name="deploy.tomcat" depends="package.mvn" description="Copies the cockpit plugin to the deployment directory defined in '${basedir}/build.properties' or '${user.home}/.camunda/build.properties'">
-		<fail unless="deploy.tomcat.dir" message="No deployment folder has been configured. Please copy the file '${basedir}/build.properties.example' to '${basedir}/build.properties' or '${user.home}/.camunda/build.properties' and change it according to your environment." />
-		<copy file="${target.dir}/${ant.project.name}.jar" todir="${deploy.tomcat.dir}/camunda/WEB-INF/lib" />
-		<touch file="${deploy.tomcat.dir}/camunda/WEB-INF/web.xml"/>
-	</target>
-
-	<target name="package.mvn">
-		<exec executable="${mvn.executable}" dir="." failonerror="true">
-			<env key="MAVEN_OPTS" value="-Xmx1024m -Xms512m -DskipTests=true -Dmaven.test.skip=true" />
-			<arg line="clean package" />
-		</exec>
-	</target>
-
-	<target name="install.cockpit.plugin">
-		<fail unless="deploy.jboss.dir" message="No deployment folder has been configured. Please copy the file '${basedir}/build.properties.example' to '${basedir}/build.properties' or '${user.home}/.camunda/build.properties' and change it according to your environment." />
-		<path id="cockpit.file.id"> 
-			<fileset dir="${deploy.jboss.dir}"> 
-				<include name="camunda-webapp-*.war"/> 
-			</fileset> 
-		</path> 
-		<property name="cockpit.file" refid="cockpit.file.id"/> 
-		<war destfile="${cockpit.file}" update="true">
-			<zipfileset file="${target.dir}/${ant.project.name}.jar" fullpath="WEB-INF/lib/${ant.project.name}.jar" />
-		</war>
-	</target>
-
-	<target name="undeploy.jboss" description="Deletes the cockpit plugin from the deployment directory defined in '${basedir}/build.properties' or '${user.home}/.camunda/build.properties'">
-		<path id="cockpit.file.id"> 
-			<fileset dir="${deploy.jboss.dir}"> 
-				<include name="camunda-webapp-*.war"/> 
-			</fileset> 
-		</path> 
-		<property name="cockpit.file" refid="cockpit.file.id"/>
-		<basename property="cockpit.filename" file="${cockpit.file}"/>
-		<move file="${cockpit.file}" todir="${java.io.tmpdir}"/>
-		<zip destfile="${cockpit.file}">
-			<zipfileset src="${java.io.tmpdir}/${cockpit.filename}">
-				<exclude name="WEB-INF/lib/${ant.project.name}.jar"/>
-			</zipfileset>
-		</zip>
-	</target>
-
-	<target name="undeploy.tomcat" description="Deletes the cockpit plugin from the deployment directory defined in '${basedir}/build.properties' or '${user.home}/.camunda/build.properties'">
-		<delete file="${deploy.tomcat.dir}/camunda/WEB-INF/lib/${ant.project.name}.jar" />
-	</target>
-
-</project>
diff --git a/bpmn/MSOURN-plugin/pom.xml b/bpmn/MSOURN-plugin/pom.xml
deleted file mode 100644
index 40dcd1f..0000000
--- a/bpmn/MSOURN-plugin/pom.xml
+++ /dev/null
@@ -1,65 +0,0 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-	<modelVersion>4.0.0</modelVersion>
-
-	<parent>
-		<groupId>org.openecomp.so</groupId>
-		<artifactId>bpmn</artifactId>
-		<version>1.1.0-SNAPSHOT</version>
-	</parent>
-
-	<groupId>org.openecomp.so</groupId>
-	<artifactId>cockpit-urnmap-plugin</artifactId>
-
-	<packaging>jar</packaging>
-
-	<name>MSO URN Mapping Cockpit Plugin</name>
-
-	<dependencies>
-		<dependency>
-		    <groupId>org.camunda.bpm.webapp</groupId>
-            <artifactId>camunda-webapp</artifactId>
-            <classifier>classes</classifier>
-            <version>${camunda.version}</version>
-			<exclusions>
-				<exclusion>
-					<groupId>commons-fileupload</groupId>
-					<artifactId>commons-fileupload</artifactId>
-				</exclusion>
-			</exclusions>
-		</dependency>
-		<dependency>
-			<groupId>commons-fileupload</groupId>
-			<artifactId>commons-fileupload</artifactId>
-			<version>1.3.2</version>
-		</dependency>
-		<dependency>
-			<groupId>javax.ws.rs</groupId>
-			<artifactId>javax.ws.rs-api</artifactId>
-			<version>2.0</version>
-		</dependency>
-		<!--  TODO Upate it to ee version -->
-		<dependency>
-			<groupId>org.camunda.bpm</groupId>
-			<artifactId>camunda-engine</artifactId>
-			<version>${camunda.version}</version>
-		</dependency>
-		<dependency>
-			<groupId>com.h2database</groupId>
-			<artifactId>h2</artifactId>
-			<scope>test</scope>
-		</dependency>
-		<dependency>
-			<groupId>javax.servlet</groupId>
-			<artifactId>javax.servlet-api</artifactId>
-			<version>3.0.1</version>
-			<scope>provided</scope>
-		</dependency>
-		<dependency>
-			<groupId>org.openecomp.so</groupId>
-			<artifactId>common</artifactId>
-			<version>${project.version}</version>
-			<scope>compile</scope>
-		</dependency>
-	</dependencies>
-</project>
diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/URNMapPlugin.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/URNMapPlugin.java
deleted file mode 100644
index 4f6ead0..0000000
--- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/URNMapPlugin.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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.camunda.bpmn.plugin.urnmap;
-
-import java.util.Arrays;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import org.camunda.bpm.cockpit.plugin.spi.impl.AbstractCockpitPlugin;
-import org.openecomp.camunda.bpmn.plugin.urnmap.resources.URNMapPluginRootResource;
-
- 
-
-public class URNMapPlugin  extends AbstractCockpitPlugin{
-	public static final String ID = "urnMap-plugin";
-	  
-	  @Override
-	  public String getId() {
-	    return ID;
-	  }
-
-	  @Override
-	  public Set<Class<?>> getResourceClasses() {
-	    Set<Class<?>> classes = new HashSet<>();
-
-	    classes.add(URNMapPluginRootResource.class);
-
-	    return classes;
-	  }
-
-	  @Override
-	  public List<String> getMappingFiles() {
-		  return Arrays.asList("org/openecomp/camunda/bpm/plugin/urnmap/queries/urnMap.xml");
-	  }
-}
diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/MyBatisExtendedSessionFactory.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/MyBatisExtendedSessionFactory.java
deleted file mode 100644
index 60d6566..0000000
--- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/MyBatisExtendedSessionFactory.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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.camunda.bpmn.plugin.urnmap.db;
-
-import org.camunda.bpm.engine.ProcessEngineConfiguration;
-import org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl;
-import org.camunda.bpm.engine.impl.cfg.StandaloneProcessEngineConfiguration;
-import org.camunda.bpm.engine.impl.interceptor.CommandContextInterceptor;
-import org.camunda.bpm.engine.impl.interceptor.CommandInterceptor;
-import org.camunda.bpm.engine.impl.interceptor.LogInterceptor;
-import org.camunda.bpm.engine.impl.util.ReflectUtil;
-
-import java.io.InputStream;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
-
-public class MyBatisExtendedSessionFactory extends StandaloneProcessEngineConfiguration {
-
-  private String resourceName;
-
-  @Override
-  protected void init() {
-    throw new IllegalArgumentException(
-            "Normal 'init' on process engine only used for extended MyBatis mappings is not allowed, please use 'initFromProcessEngineConfiguration'. You cannot construct a process engine with this configuration.");
-  }
-
-  /**
-   * initialize the {@link ProcessEngineConfiguration} from an existing one,
-   * just using the database settings and initialize the database / MyBatis
-   * stuff.
-   */
-  public void initFromProcessEngineConfiguration(ProcessEngineConfigurationImpl processEngineConfiguration, String resourceName) {
-    this.resourceName = resourceName;
-
-    setDatabaseType(processEngineConfiguration.getDatabaseType());
-    setDataSource(processEngineConfiguration.getDataSource());
-    setDatabaseTablePrefix(processEngineConfiguration.getDatabaseTablePrefix());
-
-    initDataSource();
-    initCommandContextFactory();
-    initTransactionFactory();
-    initTransactionContextFactory();
-    initCommandExecutors();
-    initSqlSessionFactory();
-    initIncidentHandlers();
-    initIdentityProviderSessionFactory();
-    initSessionFactories();
-  }
-
-  /**
-   * In order to always open a new command context set the property
-   * "alwaysOpenNew" to true inside the CommandContextInterceptor.
-   *
-   * If you execute the custom queries inside the process engine
-   * (for example in a service task), you have to do this.
-   */
-  @Override
-  protected Collection<? extends CommandInterceptor> getDefaultCommandInterceptorsTxRequired() {
-    List<CommandInterceptor> defaultCommandInterceptorsTxRequired = new ArrayList<>();
-    defaultCommandInterceptorsTxRequired.add(new LogInterceptor());
-    defaultCommandInterceptorsTxRequired.add(new CommandContextInterceptor(commandContextFactory, this, true));
-    return defaultCommandInterceptorsTxRequired;
-  }
-
-  @Override
-  protected InputStream getMyBatisXmlConfigurationSteam() {
-    return ReflectUtil.getResourceAsStream(resourceName);
-  }
-
-}
diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/MyBatisQueryCommandExecutor.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/MyBatisQueryCommandExecutor.java
deleted file mode 100644
index f81d8c6..0000000
--- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/MyBatisQueryCommandExecutor.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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.camunda.bpmn.plugin.urnmap.db;
-
-import org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl;
-import org.camunda.bpm.engine.impl.interceptor.Command;
-
-/**
- * Helper to initialize a minimized process engine which does all the transaction and MyBatis mapping stuff for us
- * and can be used to execute queries.
- */
-public class MyBatisQueryCommandExecutor {
-  
-  private MyBatisExtendedSessionFactory myBatisExtendedSessionFactory;
-
-  public MyBatisQueryCommandExecutor(ProcessEngineConfigurationImpl processEngineConfiguration, String mappingResourceName) {
-    myBatisExtendedSessionFactory = new MyBatisExtendedSessionFactory();
-    myBatisExtendedSessionFactory.initFromProcessEngineConfiguration(processEngineConfiguration, mappingResourceName);
-  }
-  
-  public <T> T executeQueryCommand(Command<T> command) {
-	return myBatisExtendedSessionFactory.getCommandExecutorTxRequired().execute(command);
-  }
-  
-  
-}
diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/URNData.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/URNData.java
deleted file mode 100644
index b2dcefb..0000000
--- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/URNData.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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.camunda.bpmn.plugin.urnmap.db;
-
-public class URNData {
-
-	  private String URNName;
-	  private String URNValue;
-	  private String Ver_;
-	public String getURNName() {
-		return URNName;
-	}
-	public void setURNName(String uRNName) {
-		URNName = uRNName;
-	}
-	public String getURNValue() {
-		return URNValue;
-	}
-	public void setURNValue(String uRNValue) {
-		URNValue = uRNValue;
-	}
-	public String getVer_() {
-		return Ver_;
-	}
-	public void setVer_(String ver_) {
-		Ver_ = ver_;
-	}
-	  
-}
diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/URNService.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/URNService.java
deleted file mode 100644
index 1eb0ba6..0000000
--- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/db/URNService.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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.camunda.bpmn.plugin.urnmap.db;
-
-import java.util.List;
-
-import org.camunda.bpm.engine.ProcessEngines;
-import org.camunda.bpm.engine.impl.ProcessEngineImpl;
-import org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl;
-import org.camunda.bpm.engine.impl.interceptor.Command;
-import org.camunda.bpm.engine.impl.interceptor.CommandContext;
-
-public class URNService {
-
-
-  public List<URNData> getProperties() {
-    ProcessEngineImpl processEngine = (ProcessEngineImpl) ProcessEngines.getDefaultProcessEngine();
-    ProcessEngineConfigurationImpl processEngineConfiguration = processEngine.getProcessEngineConfiguration();
-
-    MyBatisQueryCommandExecutor commandExecutor = new MyBatisQueryCommandExecutor(processEngineConfiguration, "mappings.xml");
-    return commandExecutor.executeQueryCommand(new Command<List<URNData>>() {
-
-      @SuppressWarnings("unchecked")
-      @Override
-      public List<URNData> execute(CommandContext commandContext) {
-        return (List<URNData>) commandContext.getDbSqlSession().selectList("retrieveUrnKeyValuePair", null);
-      }
-    });
-  }
-
-}
diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/ProcessInstanceResource.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/ProcessInstanceResource.java
deleted file mode 100644
index 484981c..0000000
--- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/ProcessInstanceResource.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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.camunda.bpmn.plugin.urnmap.resources;
-
-import java.util.List;
-import java.util.StringTokenizer;
-
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.PUT;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import org.camunda.bpm.cockpit.db.QueryParameters;
-import org.camunda.bpm.cockpit.plugin.resource.AbstractPluginResource;
-import org.openecomp.camunda.bpmn.plugin.urnmap.db.*;
-
-public class ProcessInstanceResource extends AbstractPluginResource {
-
-  private static final Logger log = LoggerFactory.getLogger(ProcessInstanceResource.class);
-
-  public ProcessInstanceResource(String engineName) {
-    super(engineName);
-  }
-
-  @GET
-  public List<URNData> getUrnDataMap() {    
-    List<URNData> list = getQueryService()
-            .executeQuery(
-                    "cockpit.urnMap.retrieveUrnKeyValuePair",
-                    new QueryParameters<URNData>());
-    
-    log.info("urnmap-plugin project - Results Retrieved: ");
-    log.info("URNName: " + "		" + "URNValue: " );
-    for(URNData d: list)
-    {
-    	log.info(  d.getURNName() + "		"  + d.getURNValue());
-    }
-   
-    return list;
-  }
-  
-  @PUT
-  //public void insertNewRow(String key, String value) 
-  public void insertNewRow(String temp) 
-   {  
- 	 log.info("AddNewRow: XXXXXXXXXXXXXXXXX ---> " + temp);
- 	 StringTokenizer st = new StringTokenizer(temp, "|");
- 	 String key = "";
- 	 String value = "";
- 	 
- 	 while(st.hasMoreTokens()) { 
- 		  key = st.nextToken(); 
- 		  value = st.nextToken(); 
- 		  log.info(key + "\t" + value); 
- 		 } 
-  			 
- 	  log.info("AddNewRow: XXXXXXXXXXXXXXXXX ---> key: " + key + " , Value: " + value);
- 	  URNData nRow = new URNData();
- 	  nRow.setVer_("1"); 	 
- 	  nRow.setURNName(key);
- 	  nRow.setURNValue(value);
- 	  
- 	 getQueryService().executeQuery("cockpit.urnMap.insertNewRow", nRow, URNData.class);
- 	 
- 	 log.info("AddNewRow: XXXXXX    END   XXXXXXXXXXX");
-   }
-  
-  @POST
-  public void getPersistData(URNData d) {  
-	  
-	  log.info("getPersistData:  UrnName: " + d.getURNName() + " , URNValue: " + d.getURNValue() );
-	    
- 	    	getQueryService().executeQuery("cockpit.urnMap.persistURNData", d, URNData.class);
-     
-	    	    
-	    log.info("XXXXXXXXXX - END - XXXXXXXXXXXXXXX");
-  	}
-}
diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/URNMapPluginRootResource.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/URNMapPluginRootResource.java
deleted file mode 100644
index e8e5e47..0000000
--- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/URNMapPluginRootResource.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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.camunda.bpmn.plugin.urnmap.resources;
-
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-
-import org.camunda.bpm.cockpit.plugin.resource.AbstractPluginRootResource;
-import org.openecomp.camunda.bpmn.plugin.urnmap.URNMapPlugin;
-
-@SuppressWarnings("deprecation")
-@Path("plugin/" + URNMapPlugin.ID)
-public class URNMapPluginRootResource extends AbstractPluginRootResource
-{
-	  public URNMapPluginRootResource() {
-		  	  super(URNMapPlugin.ID);
-	  }
-
-	  @Path("{engineName}/process-instance") 
-	  public URNResource getProcessInstanceResource(@PathParam("engineName") String engineName) {
-	    return subResource(new URNResource(engineName), engineName);
-	  }
-}
diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/URNResource.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/URNResource.java
deleted file mode 100644
index 938b9d3..0000000
--- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/URNResource.java
+++ /dev/null
@@ -1,239 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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.camunda.bpmn.plugin.urnmap.resources;
-/***
-import java.beans.Statement;
-import java.sql.DriverManager;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-*/
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.StringTokenizer;
-
-import javax.naming.Context;
-import javax.naming.InitialContext;
-import javax.sql.DataSource;
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.PUT;
-
-import org.camunda.bpm.cockpit.db.QueryParameters;
-import org.camunda.bpm.cockpit.plugin.resource.AbstractCockpitPluginResource;
-
-
-//import org.camunda.bpm.cockpit.plugin.resource.AbstractPluginResource;
-import org.openecomp.camunda.bpmn.plugin.urnmap.db.URNData;
-import org.openecomp.mso.logger.MsoLogger;
-
-
-//public class ProcessInstanceResource extends AbstractPluginResource {
-public class URNResource extends AbstractCockpitPluginResource{
-  public URNResource(String engineName) {
-    super(engineName);
-  }
-  
-  private Connection conn;
-  private static MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
-  @GET
-  public List<URNData> getUrnDataMap() 
-  {  
-	  List<URNData> list = new ArrayList();
-	  PreparedStatement psData = null;
-	  try {
-			
-		    conn = getDBConnection();
-			psData = conn
-						.prepareStatement("select * from MSO_URN_MAPPING order by NAME_");
-			    
-			    ResultSet r = psData.executeQuery();
-			    
-				while(r.next()) 
-				{
-					URNData d = new URNData();
-					d.setURNName(r.getString("NAME_"));
-					d.setURNValue(r.getString("VALUE_"));
-					d.setVer_( r.getString("REV_"));
-					
-					list.add(d);					
-				}
-				
-		} catch (Exception e) 
-		{
-			msoLogger.debug("Exception in getUrnDataMap ", e);			
-		} finally {
-			if(psData != null){
-				try {
-					psData.close();
-					conn.close();
-				} catch (SQLException e) {
-					msoLogger.debug("Exception while closing the PreparedStatement: ", e);
-				}
-			}
-			if(conn != null){
-				try {
-					conn.close();
-				} catch (SQLException e) {
-					msoLogger.debug("Exception while closing the connection: ", e);
-				}
-			}
-		}
-     
-    for(URNData d: list)
-    {
-    	msoLogger.debug(  d.getURNName() + "		"  + d.getURNValue());
-    	//msoLogger.debug("Started Executing " + getTaskName());
-    	msoLogger.debug("Started Executing " + d.getURNName() + " " + d.getURNValue());
-    }
-   
-    return list;
-  }
-  
-  public List<URNData> getUrnDataMapOLD() 
-  {  
-	  
-    List<URNData> list = getQueryService()
-            .executeQuery("cockpit.urnMap.retrieveUrnKeyValuePair", new QueryParameters<URNData>());
-    
-    msoLogger.debug("urnmap-plugin project - Results Retrieved: ");
-    msoLogger.debug("URNName: " + "		" + "URNValue: " );
-    
-    for(URNData d: list)
-    {
-    	msoLogger.debug( d.getURNName() + "		"  + d.getURNValue());
-    }
-   
-    return list;
-  }
-  
-  public Connection getDBConnection()
-  {
-	  try {
-			
-			if(conn == null)
-			{
-				Context ctx = new InitialContext();
-			    DataSource ds = (DataSource)ctx.lookup("java:jboss/datasources/ProcessEngine");//jboss
-		    	conn =			ds.getConnection();
-	 
-			}			 
-			
-		} catch (Exception e) 
-		{
-			msoLogger.debug("Exception in DBConnection ", e);
-		}
-	  
-	  return conn;
-  }
-  
-  @PUT
-  public void insertNewRow(String temp) 
-   {  
- 	 msoLogger.debug("AddNewRow: XXXXXXXXXXXXXXXXX ---> " + temp);
- 	 msoLogger.debug("AddNewRow: EngineName  ---> " + engineName);
- 	 
- 	 StringTokenizer st = new StringTokenizer(temp, "|");
- 	 String key_ = "";
- 	 String value_ = "";
- 	 
- 	 while(st.hasMoreTokens()) { 
- 		  key_ = st.nextToken(); 
- 		  value_ = st.nextToken(); 
- 		 msoLogger.debug(key_ + "\t" + value_); 
- 		 } 
-  			 
-       msoLogger.debug("AddNewRow: XXXXXXXXXXXXXXXXX ---> key: " + key_ + " , Value: " + value_);
- 	  final URNData nRow = new URNData();
- 	  nRow.setVer_("1");
- 	  PreparedStatement psData = null;
-	  
-		msoLogger.debug("----------- START ----------------------");
-		try {
-			
-  		    conn = getDBConnection();
-			psData = conn
-						.prepareStatement("Insert into MSO_URN_MAPPING values ('" + key_ + "', '" + value_  + "', '1')");
-			    
-			    psData.executeUpdate();		 
-			
-		} catch (Exception e) 
-		{
-			msoLogger.debug("Exception in insertNewRow ", e);
-		}finally {
-			if(psData != null){
-				try {
-					psData.close();
-					conn.close();
-				} catch (SQLException e) {
-					msoLogger.debug("Exception while closing the PreparedStatement: ", e);
-				}
-			}
-			if(conn != null){
-				try {
-					conn.close();
-				} catch (SQLException e) {
-					msoLogger.debug("Exception while closing the connection: ", e);
-				}
-			}
-		}
- 	// getQueryService().executeQuery("cockpit.urnMap.insertNewRow", nRow, URNData.class);
-   }
-  
-  @POST
-  public void getPersistData(URNData d) {  
-	  
-	    	//getQueryService().executeQuery("cockpit.urnMap.persistURNData", d, URNData.class);
- 	    PreparedStatement psData = null;
-	  try {
-			
-		    conn = getDBConnection();
-			psData = conn
-						.prepareStatement("UPDATE MSO_URN_MAPPING set VALUE_ ='"+ d.getURNValue() + "' WHERE NAME_='" + d.getURNName() + "'");
-			    
-			    psData.executeUpdate();
-			   
-		} catch (Exception e) 
-		{
-			msoLogger.debug("Exception in PersistData ", e);
-		}finally {
-			if(psData != null){
-				try {
-					psData.close();
-					conn.close();
-				} catch (SQLException e) {
-					msoLogger.debug("Exception while closing the PreparedStatement: ", e);
-				}
-			}
-			if(conn != null){
-				try {
-					conn.close();
-				} catch (SQLException e) {
-					msoLogger.debug("Exception while closing the connection: ", e);
-				}
-			}
-		}
-	 
-  	}
-}
diff --git a/bpmn/MSOURN-plugin/src/main/resources/META-INF/services/org.camunda.bpm.cockpit.plugin.spi.CockpitPlugin b/bpmn/MSOURN-plugin/src/main/resources/META-INF/services/org.camunda.bpm.cockpit.plugin.spi.CockpitPlugin
deleted file mode 100644
index 9a5055a..0000000
--- a/bpmn/MSOURN-plugin/src/main/resources/META-INF/services/org.camunda.bpm.cockpit.plugin.spi.CockpitPlugin
+++ /dev/null
@@ -1 +0,0 @@
-org.openecomp.camunda.bpm.plugin.urnmap.URNMapPlugin
\ No newline at end of file
diff --git a/bpmn/MSOURN-plugin/src/main/resources/mappings.xml b/bpmn/MSOURN-plugin/src/main/resources/mappings.xml
deleted file mode 100644
index c66704e..0000000
--- a/bpmn/MSOURN-plugin/src/main/resources/mappings.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-  ============LICENSE_START=======================================================
-  ECOMP 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=========================================================
-  -->
-
-
-<!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN" "http://mybatis.org/dtd/mybatis-3-config.dtd">
-
-<configuration>
-	<settings>
-		<setting name="lazyLoadingEnabled" value="false" />
-	</settings>
-	<mappers>
-        <mapper resource="org/openecomp/camunda/bpm/plugin/urnmap/queries/urnMap.xml" />
-	</mappers>
-</configuration>
diff --git a/bpmn/MSOURN-plugin/src/main/resources/org/openecomp/camunda/bpm/plugin/urnmap/queries/urnMap.xml b/bpmn/MSOURN-plugin/src/main/resources/org/openecomp/camunda/bpm/plugin/urnmap/queries/urnMap.xml
deleted file mode 100644
index d0b5861..0000000
--- a/bpmn/MSOURN-plugin/src/main/resources/org/openecomp/camunda/bpm/plugin/urnmap/queries/urnMap.xml
+++ /dev/null
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-  ============LICENSE_START=======================================================
-  ECOMP 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=========================================================
-  -->
-
-
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-
-<mapper namespace="cockpit.urnMap">
-  <resultMap id="urnDataMap" type="org.openecomp.camunda.bpm.plugin.urnmap.db.URNData">
-    <result property="URNName" column="URNNAME" jdbcType="VARCHAR"/>
-    <result property="URNValue" column="URNVALUE" jdbcType="VARCHAR" />
-  </resultMap>
-
-  <select id="retrieveUrnKeyValuePair" resultMap="urnDataMap">
-    select NAME_ URNName, VALUE_ URNValue from MSO_URN_MAPPING
-  </select>
-
-
-  <!-- INSERT cockpit.InsertURNData  keyProperty="NAME_" -->
-  <resultMap id="insertNewRow" type="org.openecomp.camunda.bpm.plugin.urnmap.db.URNData">
-    <result property="URNName" 	  column="NAME_" 	jdbcType="VARCHAR" />
-    <result property="URNValue"   column="VALUE_"   jdbcType="VARCHAR" />
-    <result property="1" 	      column="REV_" 	jdbcType="INTEGER"/>
-  </resultMap>
-  
-	<insert id="insertNewRow" parameterType="org.openecomp.camunda.bpm.plugin.urnmap.db.URNData">
-	    insert into MSO_URN_MAPPING (NAME_, VALUE_, REV_) 
-	    values (
-	    			#{URNName}, #{URNValue}, 1
-	          )
-	</insert>
-	
-<!-- UPDATE cockpit.InsertURNData -->
-  <resultMap id="saveURNMappingDataMap" type="org.openecomp.camunda.bpm.plugin.urnmap.db.URNData">
-    <result property="URNName" 	column="NAME_" 	jdbcType="VARCHAR" />
-    <result property="URNValue"   column="VALUE_" jdbcType="VARCHAR" />
-    <result property="1" 	    column="REV_" 	jdbcType="INTEGER"/>
-  </resultMap>
-  
-  <update id="persistURNData">
-  update  MSO_URN_MAPPING set
-    NAME_ = #{URNName},
-    VALUE_ = #{URNValue},
-    REV_ = 1
-    where NAME_=#{URNName}
-</update>
-</mapper>
diff --git a/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/app/dashboard.html b/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/app/dashboard.html
deleted file mode 100644
index cc794e5..0000000
--- a/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/app/dashboard.html
+++ /dev/null
@@ -1,63 +0,0 @@
-<!--
-  ============LICENSE_START=======================================================
-  ECOMP 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=========================================================
-  -->
-
-<div class="form-group container">  
-	<form novalidate="novalidate" class="simple-form" name="urnMapper"> 		  
-		<div class="panel panel-default">  
-			<div class="panel-heading" style="padding:3px;background:#871020 !important;color:#fff"> <h3 style="margin:1px" class="heading">Process Engine - URN Mapping</h3></div>
-			<div class="panel-body">
-				<div class="well">
-					<div class="input-group well" style="padding:5px">					
-						<input id="new_key" class="form-control input-md"  placeholder="New URN Key"   size="25" type="text"  name="URNName"  value="" ng-blur="enableAddRowBtn()">
-						<span class="input-group-btn" style="width:0px;"></span>
-						<input type="text" class="form-control input-md" size="55" style="margin-left:-1px" id="new_value" placeholder="New URN Value"  name="URNValue" />
-						<span class="input-group-btn" style="width:0px;"></span>				
-						<span class="input-group-btn">
-							<button class="btn btn-primary" type="button" id="addRow_BTN" data-ng-click="addNewRow(); setTimeout( retrieveData(), 1000);" disabled data-original-title="" title="">Add!</button>
-						</span>
-					</div>
-					<div>
-					  <table cellpadding="0" cellspacing="0" class="table responsive" widht="100%">
-						<tbody>        
-						  <tr data-ng-repeat="urnData in UrnDataMap">       
-							 <td>
-								<div class="input-group">
-								  <input id="{{ urnData.urnname }}_key" type="text"  style="border:0px solid #bfbfbf" size="25" class="form-control input-md" ng-blur="SaveRow( urnData )" value="{{ urnData.urnName }}" data-ng-model= "urnData.urnname" data-ng-change="enableButton(urnData)"/>
-								  <span class="input-group-btn" style="width:0px;"></span>
-								  <input id="{{ urnData.urnname }}_value" type="text" style="border:0px solid #dfdfdf;border-left:1px solid #bfbfbf" size="55" class="form-control input-md" ng-blur="SaveRow( urnData )" value="{{ urnData.urnvalue }}" data-ng-model="urnData.urnvalue" data-ng-change="enableButton(urnData)"/>
-								  <span class="input-group-btn">
-									<button disabled="true" class="btn btn-primary" type="button" id="btn_{{ urnData.urnname }}_key" data-ng-click="SaveRow( urnData ); setTimeout( retrieveData(), 1000);">
-										<span class="glyphicon glyphicon-floppy-disk"></span>
-									</button>
-								  </span>
-								</div><!-- /input-group -->
-							 </td>      
-							 <!-- 
-							<td><button id="btn_{{ urnData.urnname }}_key" data-ng-click="SaveRow( urnData )" disabled>SaveRecord</button> </td>
-							 -->
-						  </tr>       
-						</tbody>
-					  </table>	
-					</div>
-				</div>
-			</div>
-		</div>
-	</form>
-</div>
diff --git a/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/app/plugin.js b/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/app/plugin.js
deleted file mode 100644
index 702f6cd..0000000
--- a/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/app/plugin.js
+++ /dev/null
@@ -1,132 +0,0 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * 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=========================================================
- */
-
-define(['angular'], function(angular) {
-
-  var DashboardController = ["$scope", "$http", "Uri", function($scope, $http, Uri) {
-
-    $http.get(Uri.appUri("plugin://urnMap-plugin/:engine/process-instance"))
-      .success(function(data) {
-        $scope.UrnDataMap = data;
-      });
- 
-    //enable saveRow button
-    $scope.enableButton=function(urnData)
-    {
-       	document.getElementById("btn_" + urnData.urnname + "_key").disabled = false;
-    };
-    
-    $scope.enableAddRowBtn=function()
-    {
-     	if(document.getElementById("new_key").value.trim().length >0)
-    		 document.getElementById("addRow_BTN").disabled = false;
-    	else
-    		document.getElementById("addRow_BTN").disabled = true;
-    };
-    
-    
-    $scope.addNewRow = function() 
-    {
-    	var newKey = document.getElementById("new_key").value.trim();
-    	var newValue = document.getElementById("new_value").value.trim();
-    	var x;
-    	
-    	for (var i=0;i<$scope.UrnDataMap.length;i++)
-    	{
-     		var n = $scope.UrnDataMap[i].urnname.localeCompare(newKey);
-     		if(n == 0){
-    			x = "match";
-    		}
-    	}
-    	
-     	if(Boolean(x))
-    	{
-    		alert("URN Name already exists, please check the KEY!");
-    	}
-    	else
-    	{
-    		if(newKey.length >0 )
-    		{
-
-    			var temp = newKey + "|" + newValue;
-              	
-          		$http.put(Uri.appUri("plugin://urnMap-plugin/:engine/process-instance"), temp);
-         
-                document.getElementById("new_key").value = "";
-                document.getElementById("new_value").value = "";
-
-    		}
-    		
-     	}
-     	//this.enableAddRowBtn;
-     	document.getElementById("addRow_BTN").disabled = true;
-     	
-     $http.get(Uri.appUri("plugin://urnMap-plugin/:engine/process-instance"))
-        .success(function(data) {
-          $scope.UrnDataMap = data;
-        });
-        
-        
-      }
-    
-    $scope.retrieveData = function() {
-    	
-    	 $http.get(Uri.appUri("plugin://urnMap-plugin/:engine/process-instance"))
-         .success(function(data) {
-           $scope.UrnDataMap = data;
-         });
-    }
-    
-     $scope.SaveRow = function(user) 
-    {  	
-        $http.post(Uri.appUri("plugin://urnMap-plugin/:engine/process-instance"), user);
-                   
-      	document.getElementById("btn_" + user.urnname + "_key").disabled = true;
-        document.getElementById(user.urnname + "_status").style.display = "";
-        this.enableAddRowBtn;
-        
-        $http.get(Uri.appUri("plugin://urnMap-plugin/:engine/process-instance"))
-        .success(function(data) {
-          $scope.UrnDataMap = data;
-        });
-        
-        };
-  }];
-
-  var Configuration = ['ViewsProvider', function(ViewsProvider) {
-
-    ViewsProvider.registerDefaultView('cockpit.dashboard', {
-      id: 'process-definitions',
-      label: 'Deployed Processes',
-      url: 'plugin://urnMap-plugin/static/app/dashboard.html',
-      controller: DashboardController,
-       // make sure we have a higher priority than the default plugin
-      priority: 12
-    });
-  }];
-//START
-//END
-  
-  var ngModule = angular.module('cockpit.plugin.urnMap-plugin', []);
-
-  ngModule.config(Configuration);
-
-  return ngModule;
-});
diff --git a/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/info.txt b/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/info.txt
deleted file mode 100644
index 09b6262..0000000
--- a/bpmn/MSOURN-plugin/src/main/resources/plugin-webapp/urnMap-plugin/info.txt
+++ /dev/null
@@ -1 +0,0 @@
-# Client side assets of the urnMap-plugin
\ No newline at end of file
diff --git a/bpmn/pom.xml b/bpmn/pom.xml
index b878467..4f96cc1 100644
--- a/bpmn/pom.xml
+++ b/bpmn/pom.xml
@@ -31,11 +31,10 @@
 
   <modules>
     <module>MSOCoreBPMN</module>
-    <!--<module>MSOMockServer</module> -->
+    <module>MSOMockServer</module>
     <module>MSORESTClient</module>
     <module>MSOCommonBPMN</module>
     <module>MSOInfrastructureBPMN</module>
-    <module>MSOURN-plugin</module>
     <module>MSOCockpit</module>
   </modules>
 
