2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6 * Copyright (C) 2017 Huawei Technologies Co., Ltd. All rights reserved.
7 * ================================================================================
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 * ============LICENSE_END=========================================================
21 package org.openecomp.mso.bpmn.infrastructure.scripts;
23 import static org.apache.commons.lang3.StringUtils.*;
24 import groovy.xml.XmlUtil
27 import org.openecomp.mso.bpmn.core.domain.ServiceDecomposition
28 import org.openecomp.mso.bpmn.core.domain.ServiceInstance
29 import org.openecomp.mso.bpmn.core.domain.ModelInfo
30 import org.openecomp.mso.bpmn.core.json.JsonUtils
31 import org.openecomp.mso.bpmn.common.scripts.AaiUtil
32 import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
33 import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil
34 import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
35 import org.openecomp.mso.bpmn.common.scripts.CatalogDbUtils;
36 import org.openecomp.mso.bpmn.core.RollbackData
37 import org.openecomp.mso.bpmn.core.WorkflowException
38 import org.openecomp.mso.rest.APIResponse;
39 import org.openecomp.mso.rest.RESTClient
40 import org.openecomp.mso.rest.RESTConfig
42 import java.util.List;
43 import java.util.UUID;
45 import org.camunda.bpm.engine.delegate.BpmnError
46 import org.camunda.bpm.engine.runtime.Execution
47 import org.json.JSONObject;
48 import org.json.JSONArray;
49 import org.apache.commons.lang3.*
50 import org.apache.commons.codec.binary.Base64;
51 import org.springframework.web.util.UriUtils;
54 * This groovy class supports the <class>DoCreateServiceInstance.bpmn</class> process.
57 * @param - msoRequestId
58 * @param - globalSubscriberId
59 * @param - subscriptionServiceType
60 * @param - serviceInstanceId
61 * @param - serviceInstanceName - O
62 * @param - serviceModelInfo
63 * @param - productFamilyId
64 * @param - disableRollback
65 * @param - failExists - TODO
66 * @param - serviceInputParams (should contain aic_zone for serviceTypes TRANSPORT,ATM)
67 * @param - sdncVersion ("1610")
68 * @param - serviceDecomposition - Decomposition for R1710
69 * (if macro provides serviceDecompsition then serviceModelInfo, serviceInstanceId & serviceInstanceName will be ignored)
72 * @param - rollbackData (localRB->null)
73 * @param - rolledBack (no localRB->null, localRB F->false, localRB S->true)
74 * @param - WorkflowException
75 * @param - serviceInstanceName - (GET from AAI if null in input)
78 public class DoCreateE2EServiceInstance extends AbstractServiceTaskProcessor {
80 String Prefix="DCRESI_"
81 ExceptionUtil exceptionUtil = new ExceptionUtil()
82 JsonUtils jsonUtil = new JsonUtils()
83 CatalogDbUtils cutils = new CatalogDbUtils()
85 public void preProcessRequest (Execution execution) {
86 def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
88 utils.log("INFO"," ***** preProcessRequest *****", isDebugEnabled)
91 execution.setVariable("prefix", Prefix)
93 //requestDetails.subscriberInfo. for AAI GET & PUT & SDNC assignToplology
94 String globalSubscriberId = execution.getVariable("globalSubscriberId") //globalCustomerId
95 utils.log("INFO"," ***** globalSubscriberId *****" + globalSubscriberId, isDebugEnabled)
96 //requestDetails.requestParameters. for AAI PUT & SDNC assignTopology
97 String serviceType = execution.getVariable("serviceType")
98 utils.log("INFO"," ***** serviceType *****" + serviceType, isDebugEnabled)
99 //requestDetails.requestParameters. for SDNC assignTopology
100 String productFamilyId = execution.getVariable("productFamilyId") //AAI productFamilyId
102 if (isBlank(globalSubscriberId)) {
103 msg = "Input globalSubscriberId is null"
104 utils.log("INFO", msg, isDebugEnabled)
105 exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
108 if (isBlank(serviceType)) {
109 msg = "Input serviceType is null"
110 utils.log("INFO", msg, isDebugEnabled)
111 exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
114 if (productFamilyId == null) {
115 execution.setVariable("productFamilyId", "")
118 String sdncCallbackUrl = execution.getVariable('URN_mso_workflow_sdncadapter_callback')
119 if (isBlank(sdncCallbackUrl)) {
120 msg = "URN_mso_workflow_sdncadapter_callback is null"
121 utils.log("INFO", msg, isDebugEnabled)
122 exceptionUtil.buildAndThrowWorkflowException(execution, 500, msg)
124 execution.setVariable("sdncCallbackUrl", sdncCallbackUrl)
125 utils.log("INFO","SDNC Callback URL: " + sdncCallbackUrl, isDebugEnabled)
127 //requestDetails.modelInfo.for AAI PUT servieInstanceData
128 //requestDetails.requestInfo. for AAI GET/PUT serviceInstanceData
129 String serviceInstanceName = execution.getVariable("serviceInstanceName")
130 String serviceInstanceId = execution.getVariable("serviceInstanceId")
131 String uuiRequest = execution.getVariable("uuiRequest")
132 String modelInvariantUuid = jsonUtil.getJsonValue(uuiRequest, "service.serviceDefId")
133 String modelUuid = jsonUtil.getJsonValue(uuiRequest, "service.templateId")
134 String serviceModelName = jsonUtil.getJsonValue(uuiRequest, "service.parameters.templateName")
135 execution.setVariable("serviceModelName", serviceModelName)
136 //aai serviceType and Role can be setted as fixed value now.
137 String aaiServiceType = "E2E Service"
138 String aaiServiceRole = "E2E Service"
140 execution.setVariable("modelInvariantUuid", modelInvariantUuid)
141 execution.setVariable("modelUuid", modelUuid)
144 String oStatus = execution.getVariable("initialStatus") ?: ""
145 if ("TRANSPORT".equalsIgnoreCase(serviceType))
150 String statusLine = isBlank(oStatus) ? "" : "<orchestration-status>${oStatus}</orchestration-status>"
152 AaiUtil aaiUriUtil = new AaiUtil(this)
153 String aai_uri = aaiUriUtil.getBusinessCustomerUri(execution)
154 String namespace = aaiUriUtil.getNamespaceFromUri(aai_uri)
155 String serviceInstanceData =
156 """<service-instance xmlns=\"${namespace}\">
157 <service-instance-id>${serviceInstanceId}</service-instance-id>
158 <service-instance-name>${serviceInstanceName}</service-instance-name>
159 <service-type>${aaiServiceType}</service-type>
160 <service-role>${aaiServiceRole}</service-role>
162 <model-invariant-id>${modelInvariantUuid}</model-invariant-id>
163 <model-version-id>${modelUuid}</model-version-id>
164 </service-instance>""".trim()
165 execution.setVariable("serviceInstanceData", serviceInstanceData)
166 utils.logAudit(serviceInstanceData)
167 utils.log("INFO", " aai_uri " + aai_uri + " namespace:" + namespace, isDebugEnabled)
168 utils.log("INFO", " 'payload' to create Service Instance in AAI - " + "\n" + serviceInstanceData, isDebugEnabled)
170 } catch (BpmnError e) {
172 } catch (Exception ex){
173 msg = "Exception in preProcessRequest " + ex.getMessage()
174 utils.log("INFO", msg, isDebugEnabled)
175 exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
177 utils.log("INFO"," ***** Exit preProcessRequest *****", isDebugEnabled)
180 public void postProcessAAIGET(Execution execution) {
181 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
182 utils.log("INFO"," ***** postProcessAAIGET ***** ", isDebugEnabled)
186 String serviceInstanceName = execution.getVariable("serviceInstanceName")
187 boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
188 if(succInAAI != true){
189 utils.log("INFO","Error getting Service-instance from AAI", + serviceInstanceName, isDebugEnabled)
190 WorkflowException workflowException = execution.getVariable("WorkflowException")
191 utils.logAudit("workflowException: " + workflowException)
192 if(workflowException != null){
193 exceptionUtil.buildAndThrowWorkflowException(execution, workflowException.getErrorCode(), workflowException.getErrorMessage())
197 msg = "Failure in postProcessAAIGET GENGS_SuccessIndicator:" + succInAAI
198 utils.log("INFO", msg, isDebugEnabled)
199 exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)
204 boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
205 if(foundInAAI == true){
206 utils.log("INFO","Found Service-instance in AAI", isDebugEnabled)
207 msg = "ServiceInstance already exists in AAI:" + serviceInstanceName
208 utils.log("INFO", msg, isDebugEnabled)
209 exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)
212 } catch (BpmnError e) {
214 } catch (Exception ex) {
215 msg = "Exception in DoCreateServiceInstance.postProcessAAIGET. " + ex.getMessage()
216 utils.log("INFO", msg, isDebugEnabled)
217 exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
219 utils.log("INFO"," *** Exit postProcessAAIGET *** ", isDebugEnabled)
222 public void postProcessAAIPUT(Execution execution) {
223 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
224 utils.log("INFO"," ***** postProcessAAIPUT ***** ", isDebugEnabled)
227 String serviceInstanceId = execution.getVariable("serviceInstanceId")
228 boolean succInAAI = execution.getVariable("GENPS_SuccessIndicator")
229 if(succInAAI != true){
230 utils.log("INFO","Error putting Service-instance in AAI", + serviceInstanceId, isDebugEnabled)
231 WorkflowException workflowException = execution.getVariable("WorkflowException")
232 utils.logAudit("workflowException: " + workflowException)
233 if(workflowException != null){
234 exceptionUtil.buildAndThrowWorkflowException(execution, workflowException.getErrorCode(), workflowException.getErrorMessage())
239 //start rollback set up
240 RollbackData rollbackData = new RollbackData()
241 def disableRollback = execution.getVariable("disableRollback")
242 rollbackData.put("SERVICEINSTANCE", "disableRollback", disableRollback.toString())
243 rollbackData.put("SERVICEINSTANCE", "rollbackAAI", "true")
244 rollbackData.put("SERVICEINSTANCE", "serviceInstanceId", serviceInstanceId)
245 rollbackData.put("SERVICEINSTANCE", "subscriptionServiceType", execution.getVariable("subscriptionServiceType"))
246 rollbackData.put("SERVICEINSTANCE", "globalSubscriberId", execution.getVariable("globalSubscriberId"))
247 execution.setVariable("rollbackData", rollbackData)
250 } catch (BpmnError e) {
252 } catch (Exception ex) {
253 msg = "Exception in DoCreateServiceInstance.postProcessAAIDEL. " + ex.getMessage()
254 utils.log("INFO", msg, isDebugEnabled)
255 exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
257 utils.log("INFO"," *** Exit postProcessAAIPUT *** ", isDebugEnabled)
260 public void postProcessAAIGET2(Execution execution) {
261 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
262 utils.log("INFO"," ***** postProcessAAIGET2 ***** ", isDebugEnabled)
266 String serviceInstanceName = execution.getVariable("serviceInstanceName")
267 boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
268 if(succInAAI != true){
269 utils.log("INFO","Error getting Service-instance from AAI in postProcessAAIGET2", + serviceInstanceName, isDebugEnabled)
270 WorkflowException workflowException = execution.getVariable("WorkflowException")
271 utils.logAudit("workflowException: " + workflowException)
272 if(workflowException != null){
273 exceptionUtil.buildAndThrowWorkflowException(execution, workflowException.getErrorCode(), workflowException.getErrorMessage())
277 msg = "Failure in postProcessAAIGET2 GENGS_SuccessIndicator:" + succInAAI
278 utils.log("INFO", msg, isDebugEnabled)
279 exceptionUtil.buildAndThrowWorkflowException(execution, 2500, msg)
284 boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
285 if(foundInAAI == true){
286 String aaiService = execution.getVariable("GENGS_service")
287 if (!isBlank(aaiService) && (utils.nodeExists(aaiService, "service-instance-name"))) {
288 execution.setVariable("serviceInstanceName", utils.getNodeText1(aaiService, "service-instance-name"))
289 utils.log("INFO","Found Service-instance in AAI.serviceInstanceName:" + execution.getVariable("serviceInstanceName"), isDebugEnabled)
293 } catch (BpmnError e) {
295 } catch (Exception ex) {
296 msg = "Exception in DoCreateServiceInstance.postProcessAAIGET2 " + ex.getMessage()
297 utils.log("INFO", msg, isDebugEnabled)
298 exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
300 utils.log("INFO"," *** Exit postProcessAAIGET2 *** ", isDebugEnabled)
303 public void preProcessRollback (Execution execution) {
304 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
305 utils.log("INFO"," ***** preProcessRollback ***** ", isDebugEnabled)
308 Object workflowException = execution.getVariable("WorkflowException");
310 if (workflowException instanceof WorkflowException) {
311 utils.log("INFO", "Prev workflowException: " + workflowException.getErrorMessage(), isDebugEnabled)
312 execution.setVariable("prevWorkflowException", workflowException);
313 //execution.setVariable("WorkflowException", null);
315 } catch (BpmnError e) {
316 utils.log("INFO", "BPMN Error during preProcessRollback", isDebugEnabled)
317 } catch(Exception ex) {
318 String msg = "Exception in preProcessRollback. " + ex.getMessage()
319 utils.log("INFO", msg, isDebugEnabled)
321 utils.log("INFO"," *** Exit preProcessRollback *** ", isDebugEnabled)
324 public void postProcessRollback (Execution execution) {
325 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
326 utils.log("INFO"," ***** postProcessRollback ***** ", isDebugEnabled)
329 Object workflowException = execution.getVariable("prevWorkflowException");
330 if (workflowException instanceof WorkflowException) {
331 utils.log("INFO", "Setting prevException to WorkflowException: ", isDebugEnabled)
332 execution.setVariable("WorkflowException", workflowException);
334 execution.setVariable("rollbackData", null)
335 } catch (BpmnError b) {
336 utils.log("INFO", "BPMN Error during postProcessRollback", isDebugEnabled)
338 } catch(Exception ex) {
339 msg = "Exception in postProcessRollback. " + ex.getMessage()
340 utils.log("INFO", msg, isDebugEnabled)
342 utils.log("INFO"," *** Exit postProcessRollback *** ", isDebugEnabled)
345 public void preInitResourcesOperStatus(Execution execution){
346 def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
348 utils.log("INFO", " ======== STARTED preInitResourcesOperStatus Process ======== ", isDebugEnabled)
350 String serviceId = execution.getVariable("serviceInstanceId")
351 String operationId = execution.getVariable("operationId")
352 String operationType = execution.getVariable("operationType")
353 String resourceTemplateUUIDs = ""
354 String result = "processing"
355 String progress = "0"
357 String operationContent = "Prepare service creation"
358 utils.log("INFO", "Generated new operation for Service Instance serviceId:" + serviceId + " operationId:" + operationId + " operationType:" + operationType, isDebugEnabled)
359 serviceId = UriUtils.encode(serviceId,"UTF-8")
360 execution.setVariable("serviceInstanceId", serviceId)
361 execution.setVariable("operationId", operationId)
362 execution.setVariable("operationType", operationType)
363 String incomingRequest = execution.getVariable("uuiRequest")
364 String resourcesStr = jsonUtil.getJsonValue(incomingRequest, "service.parameters.resources")
365 List<String> resourceList = jsonUtil.StringArrayToList(execution, resourcesStr)
366 for(String resource : resourceList){
367 resourceTemplateUUIDs = resourceTemplateUUIDs + jsonUtil.getJsonValue(resource, "resourceId") + ":"
370 def dbAdapterEndpoint = "http://mso.mso.testlab.openecomp.org:8080/dbadapters/RequestsDbAdapter"
371 execution.setVariable("CVFMI_dbAdapterEndpoint", dbAdapterEndpoint)
372 utils.log("INFO", "DB Adapter Endpoint is: " + dbAdapterEndpoint, isDebugEnabled)
375 """<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
376 xmlns:ns="http://org.openecomp.mso/requestsdb">
379 <ns:initResourceOperationStatus xmlns:ns="http://org.openecomp.mso/requestsdb">
380 <serviceId>${serviceId}</serviceId>
381 <operationId>${operationId}</operationId>
382 <operationType>${operationType}</operationType>
383 <resourceTemplateUUIDs>${resourceTemplateUUIDs}</resourceTemplateUUIDs>
384 </ns:initResourceOperationStatus>
386 </soapenv:Envelope>"""
388 payload = utils.formatXml(payload)
389 execution.setVariable("CVFMI_initResOperStatusRequest", payload)
390 utils.log("INFO", "Outgoing initResourceOperationStatus: \n" + payload, isDebugEnabled)
391 utils.logAudit("CreateVfModuleInfra Outgoing initResourceOperationStatus Request: " + payload)
394 utils.log("ERROR", "Exception Occured Processing preInitResourcesOperStatus. Exception is:\n" + e, isDebugEnabled)
395 execution.setVariable("CVFMI_ErrorResponse", "Error Occurred during preInitResourcesOperStatus Method:\n" + e.getMessage())
397 utils.log("INFO", "======== COMPLETED preInitResourcesOperStatus Process ======== ", isDebugEnabled)
401 * prepare resource create request
403 public void preResourceRequest(execution){
404 String resourceType = execution.getVariable("resourceType")
405 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
406 String serviceInstanceName = execution.getVariable("serviceInstanceName")
407 String nsServiceName = resourceType + "_" + serviceInstanceName
408 execution.setVariable("nsServiceName", nsServiceName)
409 utils.log("INFO", "Prepare Resource Request nsServiceName:" + nsServiceName, isDebugEnabled)
410 String globalSubscriberId = execution.getVariable("globalSubscriberId")
411 String serviceType = execution.getVariable("serviceType")
412 String serviceId = execution.getVariable("serviceInstanceId")
413 execution.setVariable("serviceId", serviceId)
414 String operationId = execution.getVariable("operationId")
415 String incomingRequest = execution.getVariable("uuiRequest")
416 String resourcesStr = jsonUtil.getJsonValue(incomingRequest, "service.parameters.resources")
417 String nsServiceDescription = jsonUtil.getJsonValue(incomingRequest, "service.description")
418 execution.setVariable("nsServiceDescription", nsServiceDescription)
419 utils.log("INFO", "Prepare Resource Request nsServiceDescription:" + nsServiceDescription, isDebugEnabled)
420 List<String> resourceList = jsonUtil.StringArrayToList(execution, resourcesStr)
421 //reset the variables
422 execution.setVariable("resourceUUID", "")
423 execution.setVariable("resourceInvariantUUID", "")
424 execution.setVariable("resourceParameters", "")
425 for(String resource : resourceList){
426 String resourceName = jsonUtil.getJsonValue(resource, "resourceName")
427 if(StringUtils.containsIgnoreCase(resourceName, resourceType)){
428 String resourceUUID = jsonUtil.getJsonValue(resource, "resourceId")
429 String resourceInvariantUUID = jsonUtil.getJsonValue(resource, "resourceDefId")
430 String resourceParameters = jsonUtil.getJsonValue(resource, "nsParameters")
431 execution.setVariable("resourceUUID", resourceUUID)
432 execution.setVariable("resourceInvariantUUID", resourceInvariantUUID)
433 execution.setVariable("resourceParameters", resourceParameters)
434 utils.log("INFO", "Prepare Resource Request resourceType:" + resourceType, isDebugEnabled)
435 utils.log("INFO", "Prepare Resource Request resourceUUID:" + resourceUUID, isDebugEnabled)
436 utils.log("INFO", "Prepare Resource Request resourceParameters:" + resourceParameters, isDebugEnabled)
439 utils.log("INFO", "Prepare Controller Request finished", isDebugEnabled)
442 * sequence resource. we should analyze resource sequence from service template
443 * Here we make VF first, and then network for E2E service.
445 public void sequenceResoure(execution){
446 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
447 utils.log("INFO", "======== Start sequenceResoure Process ======== ", isDebugEnabled)
448 String serviceModelUUID = execution.getVariable("modelUuid")
449 JSONArray networks = cutils.getAllNetworksByServiceModelUuid(execution, serviceModelUUID)
450 utils.log("DEBUG", "obtained Network list: " + networks, isDebugEnabled)
451 if (networks == null) {
452 utils.log("INFO", "No matching networks in Catalog DB for serviceModelUUID=" + serviceModelUUID, isDebugEnabled)
454 String incomingRequest = execution.getVariable("uuiRequest")
455 String resourcesStr = jsonUtil.getJsonValue(incomingRequest, "service.parameters.resources")
456 List<String> resourceList = jsonUtil.StringArrayToList(execution, resourcesStr)
457 // Only one match herenetwork
458 List<String> nsResources = new ArrayList<String>()
459 List<String> wanResources = new ArrayList<String>()
460 List<String> resourceSequence = new ArrayList<String>()
461 for(String resource : resourceList){
462 String resourceName = jsonUtil.getJsonValue(resource, "resourceName")
463 String resourceUUID = jsonUtil.getJsonValue(resource, "resourceId")
465 boolean isNetwork = false;
466 if(networks != null){
467 for(int i = 0; i < networks.size(); i++){
468 String networkUUID = jsonUtil.getJsonValueForKey(networks.get(i), "modelVersionId")
469 if(StringUtils.equals(resourceUUID, networkUUID)){
476 wanResources.add(resourceName)
478 nsResources.add(resourceName)
481 resourceSequence.addAll(nsResources)
482 resourceSequence.addAll(wanResources)
483 String isContainsWanResource = wanResources.isEmpty() ? "false" : "true"
484 execution.setVariable("isContainsWanResource", isContainsWanResource)
485 execution.setVariable("currentResourceIndex", 0)
486 execution.setVariable("resourceSequence", resourceSequence)
487 utils.log("INFO", "resourceSequence: " + resourceSequence, isDebugEnabled)
488 execution.setVariable("wanResources", wanResources)
489 utils.log("INFO", "======== COMPLETED sequenceResoure Process ======== ", isDebugEnabled)
492 public void getCurrentResoure(execution){
493 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
494 utils.log("INFO", "======== Start getCurrentResoure Process ======== ", isDebugEnabled)
495 def currentIndex = execution.getVariable("currentResourceIndex")
496 List<String> resourceSequence = execution.getVariable("resourceSequence")
497 List<String> wanResources = execution.getVariable("wanResources")
498 String resourceName = resourceSequence.get(currentIndex)
499 execution.setVariable("resourceType",resourceName)
500 if(wanResources.contains(resourceName)){
501 execution.setVariable("controllerInfo", "SDN-C")
503 execution.setVariable("controllerInfo", "VF-C")
505 utils.log("INFO", "======== COMPLETED getCurrentResoure Process ======== ", isDebugEnabled)
511 public void parseNextResource(execution){
512 def isDebugEnabled=execution.getVariable("isDebugLogEnabled")
513 utils.log("INFO", "======== Start parseNextResource Process ======== ", isDebugEnabled)
514 def currentIndex = execution.getVariable("currentResourceIndex")
515 def nextIndex = currentIndex + 1
516 execution.setVariable("currentResourceIndex", nextIndex)
517 List<String> resourceSequence = execution.getVariable("resourceSequence")
518 if(nextIndex >= resourceSequence.size()){
519 execution.setVariable("allResourceFinished", "true")
521 execution.setVariable("allResourceFinished", "false")
523 utils.log("INFO", "======== COMPLETED parseNextResource Process ======== ", isDebugEnabled)
527 * post config request.
529 public void postConfigRequest(execution){