aboutsummaryrefslogtreecommitdiffstats
path: root/platform-logic/vnfapi/src/main/xml/VNF-API_vnf-topology-automated-assign-vfmodule.xml
blob: 7ce6b2d230fbf7a89c873228be90653a0ef577c6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
<service-logic xmlns='http://www.onap.org/sdnc/svclogic' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='VNF-API' version='${project.version}'><method rpc='vnf-topology-automated-assign-vfmodule' mode='sync'>
<block atomic="true"><switch test='`$vnf-topology-operation-input.request-information.request-action`'>
<outcome value='VNFActivateRequest'>
<block>
</block></outcome><outcome value='Other'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="If svc-action is 'assign' then request-action must be 'VNFActivateRequest'" />
</return></outcome></switch><get-resource plugin='org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource' resource='SQL'
  key='SELECT * from VF_MODULE_MODEL WHERE customization_uuid = $vnf-topology-operation-input.vnf-request-information.model-customization-uuid'
  pfx='db.vf-module-model'>

<outcome value='failure'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="Error reading VF_MODULE_MODEL table" />
</return></outcome><outcome value='not-found'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="404" />
    <parameter name="error-message" value="`'No model found for VF module customization UUID ' + $vnf-topology-operation-input.vnf-request-information.model-customization-uuid`" />
</return></outcome></get-resource><get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" 
		resource="cloud-region" 
		key="cloud-region.cloud-owner = 'CloudOwner' AND 
		     cloud-region.cloud-region-id = $vnf-topology-operation-input.vnf-request-information.aic-cloud-region"
        pfx='aai.cloud-region' local-only='false' >

<outcome value='not-found'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="404" />
    <parameter name="error-message" value="`'aic-cloud-region,'+ $vnf-topology-operation-input.vnf-request-information.aic-cloud-region + ' not found in AAI'`" />
</return></outcome><outcome value='failure'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="Error retrieving cloud region from AAI" />
</return></outcome></get-resource><set>
	<parameter name="service-data.vnf-id" value="`$vnf-topology-operation-input.vnf-request-information.vnf-id`"/>
	<parameter name="service-data.service-information.service-instance-id" value="`$vnf-topology-operation-input.service-information.service-instance-id`"/>
	<parameter name="service-data.service-information.service-type" value="`$vnf-topology-operation-input.service-information.service-type`"/>
</set><set>
	<parameter name="service-data." value="vnf-topology-operation-input." /></set><for index='idx' start='0' end='`$aai.cloud-region.relationship-list.relationship_length`' >
<switch test='`$aai.cloud-region.relationship-list.relationship[$idx].related-to`'>
<outcome value='complex'>
<block atomic="true"><execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'>
   <parameter name='ctx_memory_result_key' value='aai-uid-split' />
   <parameter name='original_string' value='`$aai.cloud-region.relationship-list.relationship[$idx].related-link`' />
   <parameter name='regex' value='/' />
</execute><set>
<parameter name='tmp.aic-clli' value='`$aai-uid-split[$aai-uid-split_length - 1]`' />
</set><break/></block></outcome></switch></for><block>
<switch test='`$aai.cloud-region.availability-zones.availability-zone_length`'>
<outcome value=''><set>
<parameter name='aai.cloud-region.availability-zones.availability-zone_length' value='0' />
</set></outcome></switch><for index='az-index' start='0' end='`$aai.cloud-region.availability-zones.availability-zone_length`' >
<block atomic="true"><set>
<parameter name='tmp.vnf-topology.vnf-assignments.availability-zones[$az-index].availability-zone'
  value='`$aai.cloud-region.availability-zones.availability-zone[$az-index].availability-zone-name`' />
</set></block></for></block><get-resource plugin='org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource' resource='SQL'
  key='SELECT * from VF_MODULE_TO_VFC_MAPPING WHERE vf_module_customization_uuid = $vnf-topology-operation-input.vnf-request-information.model-customization-uuid'
  pfx='db.vf-module-to-vfc-mapping[]'>

<outcome value='failure'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="Error reading VF_MODULE_TO_VFC_MAPPING table" />
</return></outcome><outcome value='not-found'>
<set>
<parameter name='db.vf-module-to-vfc-mapping_length' value='0' />
</set></outcome></get-resource><set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms_length'
  value='`$db.vf-module-to-vfc-mapping_length`' />
</set><for index='vm-type-index' start='0' end='`$db.vf-module-to-vfc-mapping_length`' >
<block atomic="true"><get-resource plugin='org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource' resource='SQL'
  key='SELECT * from VFC_MODEL WHERE customization_uuid = $db.vf-module-to-vfc-mapping[$vm-type-index].vfc-customization-uuid'
  pfx='db.vfc-model'>

<outcome value='failure'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="Error reading VFC_MODEL table" />
</return></outcome><outcome value='not-found'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="`'No entries found in VFC_MODEL table for customization UUID ' + $db.vf-module-to-vfc-mapping[$db-vm-index].vfc-customization-uuid`" />
</return></outcome></get-resource><switch test="$db.vfc-model.ecomp-generated-naming == 'Y'">
<outcome value='false'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="`'ECOMP generated naming is not Y for VFC customization UUID ' + $db.vf-module-to-vfc-mapping[$db-vm-index].vfc-customization-uuid`" />
</return></outcome></switch><set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-type'
   value='`$db.vf-module-to-vfc-mapping[$vm-type-index].vm-type`' />
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-count'
   value='`$db.vf-module-to-vfc-mapping[$vm-type-index].vm-count`' />

</set><for index='vm-index' start='0' end='`$db.vf-module-to-vfc-mapping[$vm-type-index].vm-count`' >
<block atomic="true"><set>
<parameter name='generate-unique-name-input.index-table-name' value='VM_NAME_INDEX' />
<parameter name='generate-unique-name-input.index-table-prefix-column' value='vm_name_prefix' />
<parameter name='generate-unique-name-input.name-table-type' value='VNFAPI_VM_INSTANCE' />
<parameter name='x' value="`$vnf-topology-operation-input.vnf-request-information.generic-vnf-name`" />
<parameter name='y' value="`$db.vfc-model.nfc-naming-code`" />
<parameter name='generate-unique-name-input.prefix' value="`$vnf-topology-operation-input.vnf-request-information.generic-vnf-name + $db.vfc-model.nfc-naming-code`" />
<parameter name='generate-unique-name-input.index-length' value='3' />
</set><call module='GENERIC-RESOURCE-API' rpc='generate-unique-name' mode='sync' >
<outcome value='failure'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="`$generate-unique-name-output.error-message`" />
</return></outcome><outcome value='success'>
<set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-names[$vm-index].vm-name' value='`$generate-unique-name-output.generated-name`' />
</set></outcome></call></block></for><set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-names_length'
  value='`$db.vf-module-to-vfc-mapping[$vm-type-index].vm-count`' />
</set><get-resource plugin='org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource' resource='SQL'
  key='SELECT * from VFC_TO_NETWORK_ROLE_MAPPING WHERE vfc_customization_uuid = $db.vf-module-to-vfc-mapping[$vm-type-index].vfc-customization-uuid'
  pfx='db.vfc-to-network-role-mapping[]'>

<outcome value='failure'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="Error reading VFC_TO_NETWORK_ROLE_MAPPING table" />
</return></outcome><outcome value='not-found'>
<set>
<parameter name='db.vfc-to-network-role-mapping_length' value='0' />
</set></outcome></get-resource><set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks_length' 
  value='`$db.vfc-to-network-role-mapping_length`' />
</set><set>
<parameter name='network-index' value='0' />
</set><for index='network-role-index' start='0' end='`$db.vfc-to-network-role-mapping_length`' >
<block atomic="true"><get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" 
		resource="l3-networks" 
		key="l3-network.network-role = $db.vfc-to-network-role-mapping[$network-role-index].network-role"
        pfx='aai.l3-network' local-only='false'
>
<!--
	AND l3-network.orchestration-status = 'active'
	AND cloud-region.cloud-region-id = $vnf-topology-operation-input.vnf-request-input.aic-cloud-region
	AND depth = 'ALL'"
-->
<outcome value='not-found'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="`'No active l3-network found in AAI with cloud_region_id '
          + $vnf-topology-operation-input.vnf-request-information.aic-cloud-region + ' and network_role '
          + $db.vf-network-role-mapping[$network-role-index].network-role`" />
</return></outcome><outcome value='failure'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="Error retrieving l3-network from AAI" />
</return></outcome></get-resource><set>
<parameter name='l3-network-id' value='-1' />
</set><block>
<for index='db-network-index' start='0' end='`$aai.l3-network.l3-network_length`' >
<switch test='`$aai.l3-network.l3-network[$db-network-index].orchestration-status`'>
<outcome value='Pending Create'>
<block>
</block></outcome><outcome value='Pending Delete'>
<block>
</block></outcome><outcome value='Other'>
<for silentFailure='true' index='db-rel-index' start='0' end='`$aai.l3-network.l3-network[$db-network-index].relationship-list.relationship_length`' >
<switch test='`$aai.l3-network.l3-network[$db-network-index].relationship-list.relationship[$db-rel-index].related-to`'>
<outcome value='cloud-region'>
<for silentFailure='true' index='db-data-index' start='0' end='`$aai.l3-network.l3-network[$db-network-index].relationship-list.relationship[$db-rel-index].relationship-data_length`' >
<switch test='`$aai.l3-network.l3-network[$db-network-index].relationship-list.relationship[$db-rel-index].relationship-data[$db-data-index].relationship-key`'>
<outcome value='cloud-region.cloud-region-id'>
<switch test='`$aai.l3-network.l3-network[$db-network-index].relationship-list.relationship[$db-rel-index].relationship-data[$db-data-index].relationship-value == $vnf-topology-operation-input.vnf-request-information.aic-cloud-region`'>
<outcome value='true'>
<block atomic="true"><set>
<parameter name='l3-network-id' value='`$aai.l3-network.l3-network[$db-network-index].network-id`' /></set><return status='failure'>
</return></block></outcome></switch></outcome></switch></for></outcome></switch></for></outcome></switch></for><return status='success'>

</return></block><switch test='`$l3-network-id`'>
<outcome value='-1'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="`'Unable to find l3-network in AAI for network role ' + $db.vf-network-role-mapping[$role-index].network-role`" />
</return></outcome></switch><set>
<parameter name="tmp.vnf-topology.vnf-assignments.vnf-networks[$network-index].network-name" 
	value="`$aai.l3-network.l3-network[$network-role-index].network-name`" />
<parameter name="tmp.vnf-topology.vnf-assignments.vnf-networks[$network-index].network-id" 
	value="`$aai.l3-network.l3-network[$network-role-index].network-id`" />
<parameter name="tmp.vnf-topology.vnf-assignments.vnf-networks[$network-index].neutron-id" 
	value="`$aai.l3-network.l3-network[$network-role-index].neutron-network-id`" />
<parameter name="tmp.vnf-topology.vnf-assignments.vnf-networks[$network-index].contrail-network-fqdn" 
	value="`$aai.l3-network.l3-network[$network-role-index].contrail-network-fqdn`" />
<parameter name="tmp.vnf-topology.vnf-assignments.vnf-networks[$network-index].network-role" 
	value="`$db.vfc-to-network-role-mapping[$network-role-index].network-role`" />
</set><set>
<parameter name='network-index' value='`$network-index + 1`' />
</set></block></for><set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-networks_length'
  value='`$network-index`' />
</set></block></for><for index='vm-type-index' start='0' end='`$tmp.vnf-topology.vnf-assignments.vnf-vms_length`' >
<for index='network-role-index' start='0' end='`$tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks_length`' >
<block atomic="true"><set>
<parameter name='vm-networks-index' value='-1' />

</set><switch test='`$db.vfc-to-network-role-mapping[$network-role-index].ipv4-ip-version`'>
<outcome value=''><set>
<parameter name='vm-networks-index' value='-1' />

</set></outcome><outcome value='ipv4'>
<block atomic="true"><set>
<parameter name='vm-networks-index' value='0' />
</set><set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].use-dhcp'
   value='`$db.vfc-to-network-role-mapping[$network-role-index].ipv4-use-dhcp`' />
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].ip-count'
   value='`$db.vfc-to-network-role-mapping[$network-role-index].ipv4-count`' /></set><set>
<parameter name='tmp.local.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].ip-version'
   value='ipv4' />   </set></block></outcome></switch><switch test='`$db.vfc-to-network-role-mapping[$network-role-index].ipv6-ip-version`'>
<outcome value=''><block>
</block></outcome><outcome value='ipv6'>
<block atomic="true"><set>
<parameter name='vm-networks-index' value='`$network-information-index + 1`' />
</set><set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].use-dhcp'
   value='`$db.vfc-to-network-role-mapping[$network-role-index].ipv6-use-dhcp`' />
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].ip-count'
   value='`$db.vfc-to-network-role-mapping[$network-role-index].ipv6-count`' /></set><set>
<parameter name='tmp.local.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].ip-version'
   value='ipv6' />
</set></block></outcome></switch><set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].network-role'
   value='`$db.vfc-to-network-role-mapping[$network-role-index].network-role`' /></set><switch test='`$vm-networks-index`'>
<outcome value='-1'><block>
</block></outcome><outcome value='Other'>
<set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks_length'
   value='`$vm-networks-index + 1`' />
</set></outcome></switch></block></for></for><for index='vm-type-index' start='0' end='`$tmp.vnf-topology.vnf-assignments.vnf-vms_length`' >
<for index='network-role-index' start='0' end='`$tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks_length`' >
<switch test='`$tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].use-dhcp`'>
<outcome value='N'>
<for index='ip-count-index' start='0' end='`$tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].ip-count`'><block atomic="true"><set>
<parameter name='generate-unique-name-input.index-table-name' value='EIPAM_CLIENT_KEY_INDEX' />
<parameter name='generate-unique-name-input.index-table-prefix-column' value='vnf_name_prefix' />
<parameter name='generate-unique-name-input.name-table-type' value='VNFAPI_CLIENT_KEY' />
<parameter name='generate-unique-name-input.prefix'
	value="`$vnf-topology-operation-input.vnf-request-information.vnf-name + ':' +
		$tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-type + ':' +
		$tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].network-role + ':'`" />
<parameter name='generate-unique-name-input.index-length' value='2' />

<!-- zrdm3mmex57_vlc:vlc:sctp_a:01 --></set><call module='GENERIC-RESOURCE-API' rpc='generate-unique-name' mode='sync' >
<outcome value='failure'>
<return status='failure'>
	<parameter name='ack-final' value='Y'/>
	<parameter name="error-code" value="500" />
    <parameter name="error-message" value="`$generate-unique-name-output.error-message`" />
</return></outcome></call><set>
<parameter name='tmp.aic-cloud-region'
   value='`$vnf-topology-operation-input.vnf-request-information.aic-cloud-region`' />
<parameter name='tmp.client-key'
   value='`$generate-unique-name-output.generated-name`' />
<parameter name='tmp.subnetpool-id'
   value='`$db.vfc-to-network-role-mapping[$network-role-index].extcp-subnetpool-id`' />
<parameter name='network-topology-operation-input.network-information.network-id' 
	value = 'NOT_APPLICABLE' />
<parameter name='service-data.service-information.service-type' 
	value = 'NOT_APPLICABLE' />
</set><call module='VNF-API' rpc='eipam-mobility-ip-assignment' mode='sync' ></call><execute plugin="com.att.sdnctl.sli.plugin.eipam.EIPAMPlugin" method="assignIPAddress"><outcome value='failure'><block atomic="true"><call module='VNF-API' rpc='rollback-eipam-ip-assignment' mode='sync' ></call><return status="failure">
	<parameter name="ack-final" value="Y" />
	<parameter name="error-code" value="500"/>
	<parameter name="error-message" value="An error occured while obtaining new address blocks from EIPAM." />
</return></block></outcome></execute><switch test='`$eipam-ip-block.plans_length`'>
<outcome value=''><block atomic="true"><call module='VNF-API' rpc='rollback-eipam-ip-assignment' mode='sync' ></call><return status="failure">
	<parameter name="ack-final" value="Y" />
	<parameter name="error-code" value="500"/>
	<parameter name="error-message" value="eipam-ip-block.plans[] is null." />
</return></block></outcome><outcome value='0'><block atomic="true"><call module='VNF-API' rpc='rollback-eipam-ip-assignment' mode='sync' ></call><return status="failure">
	<parameter name="ack-final" value="Y" />
	<parameter name="error-code" value="500"/>
	<parameter name="error-message" value="eipam-ip-block.plans[] is null." />
</return></block></outcome></switch><for index='plans-index' start='0' end='`$eipam-ip-block.plans_length`' >
<block atomic="true"><switch test='`$eipam-ip-block.plans[$plans-index].requests_length`'>
<outcome value=''><block atomic="true"><call module='VNF-API' rpc='rollback-eipam-ip-assignment' mode='sync' ></call><return status="failure">
	<parameter name="ack-final" value="Y" />
	<parameter name="error-code" value="500"/>
	<parameter name="error-message" value="`'eipam-ip-block.plans['+ $plans-index +'].requests[] is null.'`" />
</return></block></outcome><outcome value='0'><block atomic="true"><call module='VNF-API' rpc='rollback-eipam-ip-assignment' mode='sync' ></call><return status="failure">
	<parameter name="ack-final" value="Y" />
	<parameter name="error-code" value="500"/>
	<parameter name="error-message" value="`'eipam-ip-block.plans['+ $plans-index +'].requests[] is null.'`" />
</return></block></outcome></switch><for index='rqst-index' start='0' end='`$eipam-ip-block.plans[$plans-index].requests_length`' >
<switch test='`$eipam-ip-block.plans[$plans-index].address-family`'>
<outcome value='ipv4'>
<set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].network-ips[$ip-count-index].ip-address'
   value='`$eipam-ip-block.plans[$plans-index].requests[$rqst-index].ip-prefix`' /></set></outcome><outcome value='ipv6'>
<set>
<parameter name='tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-networks[$network-role-index].network-ips-v6[$ip-count-index].ip-address-ipv6'
   value='`$eipam-ip-block.plans[$plans-index].requests[$rqst-index].ip-prefix`' /></set></outcome></switch></for></block></for></block></for></outcome></switch></for></for><for index='vm-type-index' start='0' end='`$tmp.vnf-topology.vnf-assignments.vnf-vms_length`' >
<for index='vm-index' start='0' end='`$tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-count`' >
<block atomic="true"><delete plugin='org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource' resource='SQL'
  key='DELETE from VIPR_CONFIGURATION WHERE vnf_id = $service-data.vnf-id
     AND ecomp_service_instance_id = $vnf-topology-operation-input.service-information.service-instance-id
     AND vm_name = $tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-names[$vm-index].vm-name' ><outcome value='failure'>
<record plugin="org.onap.ccsdk.sli.core.sli.recording.Slf4jRecorder">
<parameter name="logger" value="message-log"/>
<parameter name="field1" value="__TIMESTAMP__"/>
<parameter name="field2" value="VNF-API.vnf-topology-automated-assign-vfmodule:REQID"/>
<parameter name="field3" value="`$vnf-topology-operation-input.sdnc-request-header.svc-request-id`"/>
<parameter name="field4" value="Failed to insert VIPR_CONFIGURATION record"/>
</record></outcome></delete><save plugin="org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource" resource="SQL"
	key="INSERT INTO VIPR_CONFIGURATION (vnf_id, 
		vnf_name, 
		ecomp_service_instance_id, 
		vm_name, 
		cloud_region_id, 
		cloud_owner) 
	VALUES ( $service-data.vnf-id , 
		$vnf-topology-operation-input.vnf-request-information.vnf-name , 
		$vnf-topology-operation-input.service-information.service-instance-id , 
		$tmp.vnf-topology.vnf-assignments.vnf-vms[$vm-type-index].vm-names[$vm-index]-vm-name , 
		$vnf-topology-operation.vnf-request-information.aic-cloud-region , 
		'CloudOwner')" ><outcome value='failure'>
<record plugin="org.onap.ccsdk.sli.core.sli.recording.Slf4jRecorder">
<parameter name="logger" value="message-log"/>
<parameter name="field1" value="__TIMESTAMP__"/>
<parameter name="field2" value="VNF-API.vnf-topology-automated-assign-vfmodule:REQID"/>
<parameter name="field3" value="`$vnf-topology-operation-input.sdnc-request-header.svc-request-id`"/>
<parameter name="field4" value="Failed to insert VIPR_CONFIGURATION record"/>
</record></outcome></save></block></for></for><set>
<parameter name='service-data.vnf-topology-information.' value='tmp.vnf-topology.' />
</set><execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='printContext' >
<parameter name='filename' value='/var/tmp/bgb-vnfapi-vfmodule.log' />
</execute></block></method></service-logic>