Increase coverage in artifact-handler-node package
[appc.git] / appc-inbound / appc-artifact-handler / provider / src / test / java / org / onap / appc / artifact / handler / node / ArtifactHandlerNodeTest.java
1 /*-
2  * ============LICENSE_START=======================================================
3  * ONAP : APPC
4  * ================================================================================
5  * Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved.
6  * ================================================================================
7  * Copyright (C) 2017 Amdocs
8  * ================================================================================
9  * Modifications Copyright (C) 2019 Ericsson
10  * =============================================================================
11  * Licensed under the Apache License, Version 2.0 (the "License");
12  * you may not use this file except in compliance with the License.
13  * You may obtain a copy of the License at
14  *
15  *      http://www.apache.org/licenses/LICENSE-2.0
16  *
17  * Unless required by applicable law or agreed to in writing, software
18  * distributed under the License is distributed on an "AS IS" BASIS,
19  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20  * See the License for the specific language governing permissions and
21  * limitations under the License.
22  *
23  * ============LICENSE_END=========================================================
24  */
25
26 package org.onap.appc.artifact.handler.node;
27
28 import org.apache.commons.io.IOUtils;
29 import org.json.JSONArray;
30 import org.json.JSONObject;
31 import org.junit.Before;
32 import org.junit.Ignore;
33 import org.junit.Rule;
34 import org.junit.Test;
35 import org.junit.rules.ExpectedException;
36 import org.junit.runner.RunWith;
37 import org.mockito.Mockito;
38 import org.onap.ccsdk.sli.core.sli.SvcLogicContext;
39 import org.onap.sdnc.config.params.transformer.tosca.ArtifactProcessorImpl;
40 import org.onap.sdnc.config.params.transformer.tosca.exceptions.ArtifactProcessorException;
41 import org.powermock.api.mockito.PowerMockito;
42 import org.powermock.core.classloader.annotations.PrepareForTest;
43 import org.powermock.modules.junit4.PowerMockRunner;
44 import org.powermock.reflect.Whitebox;
45 import org.onap.appc.artifact.handler.dbservices.DBService;
46 import org.onap.appc.artifact.handler.dbservices.MockDBService;
47 import org.onap.appc.artifact.handler.utils.SdcArtifactHandlerConstants;
48 import org.onap.appc.yang.YANGGenerator;
49 import org.onap.appc.yang.impl.YANGGeneratorFactory;
50 import org.onap.appc.artifact.handler.utils.ArtifactHandlerProviderUtilTest;
51 import java.util.Map;
52 import java.util.HashMap;
53 import java.io.IOException;
54 import java.nio.charset.Charset;
55
56 import static org.junit.Assert.assertEquals;
57 import static org.junit.Assert.assertFalse;
58 import static org.junit.Assert.assertNotNull;
59 import static org.junit.Assert.assertNull;
60 import static org.junit.Assert.assertTrue;
61
62 @RunWith(PowerMockRunner.class)
63 @PrepareForTest({DBService.class, YANGGeneratorFactory.class})
64 public class ArtifactHandlerNodeTest {
65
66     private ArtifactHandlerNode artifactHandlerNode;
67     private DBService dbServiceMock;
68
69     @Rule
70     public ExpectedException expectedEx = ExpectedException.none();
71
72     @Before
73     public void setUp() throws Exception {
74         artifactHandlerNode = Mockito.spy(new ArtifactHandlerNode());
75         PowerMockito.mockStatic(DBService.class);
76         dbServiceMock = Mockito.mock(DBService.class);
77         Mockito.doReturn("12345").when(dbServiceMock).getInternalVersionNumber(Mockito.any(), Mockito.anyString(), Mockito.anyString());
78         PowerMockito.when(DBService.initialise()).thenReturn(dbServiceMock);
79         PowerMockito.mockStatic(YANGGeneratorFactory.class);
80         YANGGenerator yangGeneratorMock = Mockito.mock(YANGGenerator.class);
81         PowerMockito.when(YANGGeneratorFactory.getYANGGenerator()).thenReturn(yangGeneratorMock);
82         ArtifactProcessorImpl artifactProcessorMock = Mockito.mock(ArtifactProcessorImpl.class);
83         Mockito.doReturn(artifactProcessorMock).when(artifactHandlerNode).getArtifactProcessorImpl();
84     }
85
86     @Test
87     public void testProcessArtifact() throws Exception {
88         SvcLogicContext ctx = new SvcLogicContext();
89         ctx.setAttribute("test", "test");
90         Map<String, String> inParams = new HashMap<>();
91         JSONObject postData = new JSONObject();
92         JSONObject input = new JSONObject();
93         inParams.put("response_prefix", "prefix");
94         JSONObject requestInfo = new JSONObject();
95         JSONObject documentInfo = getDocumentInfo("templates/reference_template");
96         documentInfo.put(SdcArtifactHandlerConstants.ARTIFACT_NAME, "reference_Junit.json");
97         requestInfo.put("RequestInfo", "testValue");
98         input.put(SdcArtifactHandlerConstants.DOCUMENT_PARAMETERS, documentInfo);
99         input.put(SdcArtifactHandlerConstants.REQUEST_INFORMATION, requestInfo);
100         postData.put("input", input);
101         inParams.put("postData", postData.toString());
102         artifactHandlerNode.processArtifact(inParams, ctx);
103         assertNull(ctx.getAttribute(SdcArtifactHandlerConstants.FILE_CATEGORY));
104     }
105
106     @Test
107     public void testPopulateProtocolReference() throws Exception {
108         ArtifactHandlerNode ah = new ArtifactHandlerNode();
109         String contentStr =
110                 "{\"action\": \"TestAction\",\"action-level\": \"vnf\",\"scope\": {\"vnf-type\": \"vDBE-I\",\"vnfc-type\": null},\"template\": \"N\",\"device-protocol\": \"REST\"}";
111         JSONObject content = new JSONObject(contentStr);
112         MockDBService dbService = MockDBService.initialise();
113         Whitebox.invokeMethod(ah, "populateProtocolReference", dbService, content);
114     }
115
116     @Test
117     public void testCleanVnfcInstance() throws Exception {
118         ArtifactHandlerNode ah = new ArtifactHandlerNode();
119         SvcLogicContext ctx = new SvcLogicContext();
120         Whitebox.invokeMethod(ah, "cleanVnfcInstance", ctx);
121         assertTrue(true);
122     }
123
124     @Test
125     public void testStoreUpdateSdcArtifacts() throws Exception {
126         ArtifactHandlerNode ah = new ArtifactHandlerNode();
127         String postDataStr =
128                 "{\"request-information\":{\"request-id\": \"12345\"},\"document-parameters\":{\"artifact-name\":\"testArtifact\",\"artifact-contents\":{\"content\":\"TestContent\"}}}";
129         JSONObject postData = new JSONObject(postDataStr);
130         expectedEx.expect(ArtifactHandlerInternalException.class);
131         Whitebox.invokeMethod(ah, "storeUpdateSdcArtifacts", postData);
132     }
133
134     @Test
135     public void testUpdateYangContents() throws Exception {
136         String artifactId = "1";
137         String yangContents = "SomeContent";
138         Whitebox.invokeMethod(artifactHandlerNode, "updateYangContents", artifactId, yangContents);
139         Mockito.verify(dbServiceMock).updateYangContents(Mockito.any(SvcLogicContext.class),
140                 Mockito.anyString(), Mockito.anyString());
141     }
142
143     @Test
144     public void testProcessVmList() throws Exception{
145         String contentStr = "{\r\n\t\"action\": \"ConfigScaleOut\",\r\n\t\"action-level\": \"VNF\",\r\n\t\"scope\": "
146                 + "{\r\n\t\t\"vnf-type\": \"ScaleOutVNF\",\r\n\t\t\"vnfc-type\": \"\"\r\n\t},\r\n\t\"template\": \"Y\",\r\n\t\"vm\": "
147                 + "[\r\n\t{ \r\n\t\t\"vm-instance\": 1,\r\n\t\t\"template-id\":\"id1\",\r\n\t\t\r\n\t\t\"vnfc\": [{\r\n\t\t\t\"vnfc-instance\": 1,\r\n\t\t\t\"vnfc-type\": \"t1\",\r\n\t\t\t\"vnfc-function-code\": "
148                 + "\"Testdbg\",\r\n\t\t\t\"group-notation-type\": \"GNType\",\r\n\t\t\t\"ipaddress-v4-oam-vip\": \"N\",\r\n\t\t\t\"group-notation-value\": "
149                 + "\"GNValue\"\r\n\t\t}]\r\n\t},\r\n\t{ \r\n\t\t\"vm-instance\": 1,\r\n\t\t\"template-id\":\"id2\",\r\n\t\t\r\n\t\t\"vnfc\": [{\r\n\t\t\t\"vnfc-instance\": 1,\r\n\t\t\t\"vnfc-type\": "
150                 + "\"t1\",\r\n\t\t\t\"vnfc-function-code\": \"Testdbg\",\r\n\t\t\t\"group-notation-type\": \"GNType\",\r\n\t\t\t\"ipaddress-v4-oam-vip\": \"N\",\r\n\t\t\t\"group-notation-value\": "
151                 + "\"GNValue\"\r\n\t\t},\r\n\t\t{\r\n\t\t\t\"vnfc-instance\": 2,\r\n\t\t\t\"vnfc-type\": \"t2\",\r\n\t\t\t\"vnfc-function-code\": \"Testdbg\",\r\n\t\t\t\"group-notation-type\": "
152                 + "\"GNType\",\r\n\t\t\t\"ipaddress-v4-oam-vip\": \"Y\",\r\n\t\t\t\"group-notation-value\": \"GNValue\"\r\n\t\t}]\r\n\t},\r\n\t{\r\n\t\t\"vm-instance\": 2,\r\n\t\t\"template-id\":\"id3\",\r\n\t\t\"vnfc\": "
153                 + "[{\r\n\t\t\t\"vnfc-instance\": 1,\r\n\t\t\t\"vnfc-type\": \"t3\",\r\n\t\t\t\"vnfc-function-code\": \"Testdbg\",\r\n\t\t\t\"group-notation-type\": "
154                 + "\"GNType\",\r\n\t\t\t\"ipaddress-v4-oam-vip\": \"Y\",\r\n\t\t\t\"group-notation-value\": \"GNValue\"\r\n\t\t}]\r\n\t}],\r\n\t\"device-protocol\": "
155                 + "\"TEST-PROTOCOL\",\r\n\t\"user-name\": \"Testnetconf\",\r\n\t\"port-number\": \"22\",\r\n\t\"artifact-list\": [{\r\n\t\t\"artifact-name\": \"Testv_template.json\",\r\n\t\t\"artifact-type\": "
156                 + "\"Testconfig_template\"\r\n\t},\r\n\t{\r\n\t\t\"artifact-name\": \"TESTv_parameter_definitions.json\",\r\n\t\t\"artifact-type\": \"Testparameter_definitions\"\r\n\t},\r\n\t{\r\n\t\t\"artifact-name\": "
157                 + "\"PD_JunitTESTv_parameter_yang.json\",\r\n\t\t\"artifact-type\": \"PD_definations\"\r\n\t}]\r\n}";
158         JSONObject content=new JSONObject(contentStr);
159         MockDBService dbService = MockDBService.initialise();
160         SvcLogicContext context = new SvcLogicContext();
161         artifactHandlerNode.processVmList(content, context, dbService);
162     }
163
164     @Test
165     public void testProcessConfigTypeActions() throws Exception{
166         String contentStr = "{\"action\": \"ConfigScaleOut\"}";
167         JSONObject content=new JSONObject(contentStr);
168         MockDBService dbService = MockDBService.initialise();
169         SvcLogicContext context = new SvcLogicContext();
170         context.setAttribute(SdcArtifactHandlerConstants.DEVICE_PROTOCOL,"Test");
171         artifactHandlerNode.processConfigTypeActions(content, dbService, context);
172     }
173
174     @Test
175     public void testProcessActionLists() throws Exception {
176         String contentStr = "{\r\n\t\"action\": \"HealthCheck\",\r\n\t\"action-level\": \"vm\",\r\n\t\"scope\":"
177                 + " {\r\n\t\t\"vnf-type\": \"vDBE-I\",\r\n\t\t\"vnfc-type\": null\r\n\t},\r\n\t\"template\": "
178                 + "\"N\",\r\n\t\"device-protocol\": \"REST\",\r\n\t\"vnfc-function-code-list\": [\"SSC\", \"MMSC\"]\r\n}";
179         JSONObject content = new JSONObject(contentStr);
180         JSONArray vmActionVnfcFunctionCodesList = new JSONArray();
181         JSONArray vnfActionList = new JSONArray();
182         JSONArray vfModuleActionList = new JSONArray();
183         JSONArray vnfcActionList = new JSONArray();
184         String[] actionLevels = { "vnf", "vm", "vf-module", "vnfc" };
185         for (String actionLevel : actionLevels) {
186             artifactHandlerNode.processActionLists(content, actionLevel, vnfcActionList, vfModuleActionList,
187                     vnfActionList, vmActionVnfcFunctionCodesList);
188         }
189     }
190
191     @Test
192     public void testIsCapabilityArtifactNeeded() throws Exception {
193         String scopeObjStr1= "{\"vnf-type\":\"someVnf\",\"vnfc-type\":\"somVnfc\"}";
194         String scopeObjStr2= "{\"vnf-type\":\"someVnf\",\"vnfc-type\":\"\"}";
195         JSONObject scope1 = new JSONObject(scopeObjStr1);
196         JSONObject scope2 = new JSONObject(scopeObjStr2);
197         SvcLogicContext context = new SvcLogicContext();
198         artifactHandlerNode.setVnfcTypeInformation(scope1, context);
199         assertFalse(artifactHandlerNode.isCapabilityArtifactNeeded(context));
200         artifactHandlerNode.setVnfcTypeInformation(scope2, context);
201         assertTrue(artifactHandlerNode.isCapabilityArtifactNeeded(context));
202     }
203
204     @Test
205     public void testProcessArtifactListsWithMultipleTemplates() throws Exception {
206         String contentStr = "{\r\n\t\t\"action\": \"ConfigScaleOut\",\r\n\t\t\"action-level\": \"vnf\",\r\n\t\t\"scope\": {\r\n\t\t\t\"vnf-type\": "
207                 + "\"vCfgSO-0405\",\r\n\t\t\t\"vnfc-type\": \"\"\r\n\t\t},\r\n\t\t\"template\": \"Y\",\r\n\t\t\"vm\": [{\r\n\t\t\t\"template-id\": "
208                 + "\"TID-0405-EZ\",\r\n\t\t\t\"vm-instance\": 1,\r\n\t\t\t\"vnfc\": [{\r\n\t\t\t\t\"vnfc-instance\": \"1\",\r\n\t\t\t\t\"vnfc-function-code\": "
209                 + "\"Cfg-ez\",\r\n\t\t\t\t\"ipaddress-v4-oam-vip\": \"Y\",\r\n\t\t\t\t\"group-notation-type\": \"first-vnfc-name\",\r\n\t\t\t\t\"group-notation-value\":"
210                 + " \"pair\",\r\n\t\t\t\t\"vnfc-type\": \"vCfg-0405-ez\"\r\n\t\t\t}]\r\n\t\t},\r\n\t\t{\r\n\t\t\t\"template-id\": "
211                 + "\"TID-0405-EZ\",\r\n\t\t\t\"vm-instance\": 2,\r\n\t\t\t\"vnfc\": [{\r\n\t\t\t\t\"vnfc-instance\": \"1\",\r\n\t\t\t\t\"vnfc-function-code\": "
212                 + "\"Cfg-ez\",\r\n\t\t\t\t\"ipaddress-v4-oam-vip\": \"Y\",\r\n\t\t\t\t\"group-notation-type\": \"first-vnfc-name\",\r\n\t\t\t\t\"group-notation-value\":"
213                 + " \"pair\",\r\n\t\t\t\t\"vnfc-type\": \"vCfg-0405-ez\"\r\n\t\t\t}]\r\n\t\t}],\r\n\t\t\"device-protocol\": \"ANSIBLE\",\r\n\t\t\"user-name\": \"root\","
214                 + "\r\n\t\t\"port-number\": \"22\",\r\n\t\t\"artifact-list\": [{\r\n\t\t\t\"artifact-name\": \"template_ConfigScaleOut_vCfgSO-0405_0.0.1V_TID-0405-EZ.json\","
215                 + "\r\n\t\t\t\"artifact-type\": \"config_template\"\r\n\t\t},\r\n\t\t{\r\n\t\t\t\"artifact-name\": \"pd_ConfigScaleOut_vCfgSO-0405_0.0.1V_TID-0405-EZ.yaml\","
216                 + "\r\n\t\t\t\"artifact-type\": \"parameter_definitions\"\r\n\t\t},\r\n\t\t{\r\n\t\t\t\"artifact-name\": "
217                 + "\"template_ConfigScaleOut_vCfgSO-0405_0.0.1V_TID-0405-EZ-2.json\",\r\n\t\t\t\"artifact-type\": \"config_template\"\r\n\t\t},\r\n\t\t{\r\n\t\t\t\"artifact-name\": "
218                 + "\"pd_ConfigScaleOut_vCfgSO-0405_0.0.1V_TID-0405-EZ-2.yaml\",\r\n\t\t\t\"artifact-type\": \"parameter_definitions\"\r\n\t\t}],\r\n\t\t\"template-id-list\":"
219                 + " [\"TID-0405-EZ\",\r\n\t\t\"TID-0405-EZ-2\"],\r\n\t\t\"scopeType\": \"vnf-type\"\r\n\t}";
220         JSONObject content = new JSONObject(contentStr);
221         MockDBService dbService = MockDBService.initialise();
222         SvcLogicContext context = new SvcLogicContext();
223         context.setAttribute("vnf-type", "someVnf");
224         context.setAttribute("action", "ConfigScaleOut");
225         artifactHandlerNode.processArtifactList(content, dbService, context, null);
226     }
227
228     @Test
229     public void testProcessArtifactListsWithVnfcTypeList() throws Exception {
230         String contentStr = "{\r\n\t\"action\": \"Configure\",\r\n\t\"action-level\": \"vnf\",\r\n\t\"scope\": {\r\n\t\t\"vnf-type\": "
231                 + "\"newtypeofvnf\",\r\n\t\t\"vnfc-type-list\": [\"vnfctype1\",\"vnfctype2\"]\r\n\t},\r\n\t\"template\": \"Y\",\r\n\t\"vm\":"
232                 + " [{\r\n\t\t\t\"vm-instance\": 1,\r\n\t\t\t\"template-id\": \"vnfctype1\",\r\n\t\t\t\"vnfc\": [{\r\n\t\t\t\t\"vnfc-instance\": "
233                 + "\"1\",\r\n\t\t\t\t\"vnfc-function-code\": \"fcx\",\r\n\t\t\t\t\"ipaddress-v4-oam-vip\": \"Y\",\r\n\t\t\t\t\"group-notation-type\": "
234                 + "\"first-vnfc-name\",\r\n\t\t\t\t\"group-notation-value\": \"pair\",\r\n\t\t\t\t\"vnfc-type\": \"vDBE\"\r\n\t\t\t}]\r\n\t\t},"
235                 + "\r\n\t\t{\r\n\t\t\t\"vm-instance\": 1,\r\n\t\t\t\"template-id\": \"vnfctype2\",\r\n\t\t\t\"vnfc\": [{\r\n\t\t\t\t\"vnfc-instance\": "
236                 + "\"1\",\r\n\t\t\t\t\"vnfc-function-code\": \"fcx\",\r\n\t\t\t\t\"ipaddress-v4-oam-vip\": \"Y\",\r\n\t\t\t\t\"group-notation-type\": "
237                 + "\"first-vnfc-name\",\r\n\t\t\t\t\"group-notation-value\": \"pair\",\r\n\t\t\t\t\"vnfc-type\": \"vDBE\"\r\n\t\t\t}]\r\n\t\t},"
238                 + "\r\n\t\t{\r\n\t\t\t\"vm-instance\": 2,\r\n\t\t\t\"template-id\": \"vnfctype2\",\r\n\t\t\t\"vnfc\": [{\r\n\t\t\t\t\"vnfc-instance\": "
239                 + "\"1\",\r\n\t\t\t\t\"vnfc-function-code\": \"fcx\",\r\n\t\t\t\t\"ipaddress-v4-oam-vip\": \"Y\",\r\n\t\t\t\t\"group-notation-type\": "
240                 + "\"first-vnfc-name\",\r\n\t\t\t\t\"group-notation-value\": \"pair\",\r\n\t\t\t\t\"vnfc-type\": \"vDBE\"\r\n\t\t\t}]\r\n\t\t}\r\n\t],"
241                 + "\r\n\t\"device-protocol\": \"NETCONF-XML\",\r\n\t\"user-name\": \"netconf\",\r\n\t\"port-number\": \"20\",\r\n\t\"artifact-list\": "
242                 + "[{\r\n\t\t\t\"artifact-name\": \"template_ConfigScaleOut_newtypeofvnf_0.0.1V_vnfctype1.xml\",\r\n\t\t\t\"artifact-type\": "
243                 + "\"config_template\"\r\n\t\t},\r\n\t\t{\r\n\t\t\t\"artifact-name\": \"pd_ConfigScaleOut_newtypeofvnf_0.0.1V_vnfctype1.yaml\","
244                 + "\r\n\t\t\t\"artifact-type\": \"parameter_definitions\"\r\n\t\t},\r\n\t\t{\r\n\t\t\t\"artifact-name\": "
245                 + "\"template_ConfigScaleOut_newtypeofvnf_0.0.1V_vnfctype2.xml\",\r\n\t\t\t\"artifact-type\": "
246                 + "\"config_template\"\r\n\t\t},\r\n\t\t{\r\n\t\t\t\"artifact-name\": \"pd_ConfigScaleOut_newtypeofvnf_0.0.1V_vnfctype2.yaml\","
247                 + "\r\n\t\t\t\"artifact-type\": \"parameter_definitions\"\r\n\t\t}\r\n\t],\r\n\t\"scopeType\": \"vnf-type\"\r\n}";
248         JSONObject content = new JSONObject(contentStr);
249         MockDBService dbService = MockDBService.initialise();
250         SvcLogicContext context = new SvcLogicContext();
251         context.setAttribute("vnf-type", "someVnf");
252         context.setAttribute("action", "Configure");
253         JSONObject scope = (JSONObject)content.get("scope");
254         JSONArray vnfcTypeList = artifactHandlerNode.setVnfcTypeInformation(scope, context);
255         artifactHandlerNode.processArtifactList(content, dbService, context, vnfcTypeList);
256         JSONArray vnfcLists = scope.getJSONArray("vnfc-type-list");        
257         assertEquals(vnfcLists.toString(), "[\"vnfctype1\",\"vnfctype2\"]");
258         assertEquals(context.getAttribute("vnfc-type"),"vnfctype2");
259         assertNotNull (vnfcTypeList);
260     }
261
262     @Test
263     public void testProcessArtifactPdArtifactName() throws IOException, ArtifactProcessorException {
264         SvcLogicContext ctx = new SvcLogicContext();
265         ctx.setAttribute("test", "test");
266         Map<String, String> inParams = new HashMap<>();
267         JSONObject postData = new JSONObject();
268         JSONObject input = new JSONObject();
269         inParams.put("response_prefix", "prefix");
270         JSONObject requestInfo = new JSONObject();
271         JSONObject documentInfo = getDocumentInfo("templates/pd_template");
272         documentInfo.put(SdcArtifactHandlerConstants.ARTIFACT_NAME, "pd_Junit.json");
273         requestInfo.put("RequestInfo", "testValue");
274         input.put(SdcArtifactHandlerConstants.DOCUMENT_PARAMETERS, documentInfo);
275         input.put(SdcArtifactHandlerConstants.REQUEST_INFORMATION, requestInfo);
276         postData.put("input", input);
277         inParams.put("postData", postData.toString());
278         artifactHandlerNode.processArtifact(inParams, ctx);
279         Mockito.verify(dbServiceMock, Mockito.times(2)).initialise();
280     }
281
282     private JSONObject getDocumentInfo(String filename) throws IOException {
283         JSONObject documentInfo = new JSONObject();
284         String artifactContent = IOUtils.toString(ArtifactHandlerProviderUtilTest.class.getClassLoader()
285                 .getResourceAsStream(filename), Charset.defaultCharset());
286         documentInfo.put(SdcArtifactHandlerConstants.ARTIFACT_CONTENTS, artifactContent);
287         documentInfo.put(SdcArtifactHandlerConstants.SERVICE_UUID, "12345");
288         documentInfo.put(SdcArtifactHandlerConstants.DISTRIBUTION_ID, "12345");
289         documentInfo.put(SdcArtifactHandlerConstants.SERVICE_NAME, "12345");
290         documentInfo.put(SdcArtifactHandlerConstants.SERVICE_DESCRIPTION, "12345");
291         documentInfo.put(SdcArtifactHandlerConstants.RESOURCE_UUID, "12345");        
292         documentInfo.put(SdcArtifactHandlerConstants.RESOURCE_INSTANCE_NAME, "12345");
293         documentInfo.put(SdcArtifactHandlerConstants.RESOURCE_VERSION, "12345");
294         documentInfo.put(SdcArtifactHandlerConstants.RESOURCE_TYPE, "12345");
295         documentInfo.put(SdcArtifactHandlerConstants.ARTIFACT_UUID, "12345");
296         documentInfo.put(SdcArtifactHandlerConstants.ARTIFACT_TYPE, "12345");
297         documentInfo.put(SdcArtifactHandlerConstants.ARTIFACT_VERSION, "12345");
298         documentInfo.put(SdcArtifactHandlerConstants.ARTIFACT_DESRIPTION, "12345");
299         return documentInfo;
300     }
301 }