blob: cf99625eebe2e057bffe051d878510c15adf74eb [file] [log] [blame]
sebdet74303b72019-10-08 17:53:08 +02001<rests xmlns="http://camel.apache.org/schema/spring">
2 <rest>
3 <get
4 uri="/v2/loop/getAllNames"
5 outType="java.lang.String[]"
6 produces="application/json">
7 <route>
8 <removeHeaders pattern="*" />
9 <doTry>
10 <to
11 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET ALL Loop')" />
12 <to
13 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','read')" />
14 <to
15 uri="bean:org.onap.clamp.loop.LoopController?method=getLoopNames()" />
16 <to
17 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
18 <doCatch>
19 <exception>java.lang.Exception</exception>
20 <handled>
21 <constant>false</constant>
22 </handled>
23 <to
24 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
25 </doCatch>
26 </doTry>
27 </route>
28 </get>
29 <get
30 uri="/v2/loop/{loopName}"
31 outType="org.onap.clamp.loop.Loop"
32 produces="application/json">
33 <route>
34 <removeHeaders
35 pattern="*"
36 excludePattern="loopName" />
37 <doTry>
38 <to
39 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET Loop')" />
40 <to
41 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','read')" />
42 <to
43 uri="bean:org.onap.clamp.loop.LoopController?method=getLoop(${header.loopName})" />
44 <to
45 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
46 <doCatch>
47 <exception>java.lang.Exception</exception>
48 <handled>
49 <constant>false</constant>
50 </handled>
51 <to
52 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
53 </doCatch>
54 </doTry>
55 </route>
56 </get>
57 <get
58 uri="/v2/loop/svgRepresentation/{loopName}"
59 outType="java.lang.String"
60 produces="application/xml">
61 <route>
62 <removeHeaders
63 pattern="*"
64 excludePattern="loopName" />
65 <doTry>
66 <to
67 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Get SVG Representation')" />
68 <to
69 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','read')" />
70 <to
71 uri="bean:org.onap.clamp.loop.LoopController?method=getSvgRepresentation(${header.loopName})" />
72 <to
73 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
74 <doCatch>
75 <exception>java.lang.Exception</exception>
76 <handled>
77 <constant>false</constant>
78 </handled>
79 <to
80 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
81 </doCatch>
82 </doTry>
83 </route>
84 </get>
85
86 <post
87 uri="/v2/loop/updateGlobalProperties/{loopName}"
88 type="com.google.gson.JsonObject"
89 consumes="application/json"
90 outType="org.onap.clamp.loop.Loop"
91 produces="application/json">
92 <route>
93 <removeHeaders
94 pattern="*"
95 excludePattern="loopName" />
96 <doTry>
97 <to
98 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Update the global properties')" />
99 <to
100 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
101 <setHeader headerName="GlobalPropertiesJson">
102 <simple>${body}</simple>
103 </setHeader>
104 <to uri="direct:load-loop" />
105 <to
106 uri="bean:org.onap.clamp.loop.LoopController?method=updateGlobalPropertiesJson(${header.loopName},${header.GlobalPropertiesJson})" />
107 <to
108 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Global Properties UPDATED','INFO',${exchangeProperty[loopObject]})" />
109 <to
110 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
111 <doCatch>
112 <exception>java.lang.Exception</exception>
113 <handled>
114 <constant>false</constant>
115 </handled>
116 <to
117 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
118 </doCatch>
119 </doTry>
120 </route>
121 </post>
122 <post
123 uri="/v2/loop/updateOperationalPolicies/{loopName}"
124 type="com.google.gson.JsonArray"
125 consumes="application/json"
126 outType="org.onap.clamp.loop.Loop"
127 produces="application/json">
128 <route>
129 <removeHeaders
130 pattern="*"
131 excludePattern="loopName" />
132 <doTry>
133 <to
134 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Update operational policies')" />
135 <to
136 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
137 <setHeader headerName="OperationalPoliciesArray">
138 <simple>${body}</simple>
139 </setHeader>
140 <to uri="direct:load-loop" />
141 <to
142 uri="bean:org.onap.clamp.loop.LoopController?method=updateOperationalPolicies(${header.loopName},${header.OperationalPoliciesArray})" />
143 <to
144 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Operational and Guard policies UPDATED','INFO',${exchangeProperty[loopObject]})" />
145 <to
146 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
147 <doCatch>
148 <exception>java.lang.Exception</exception>
149 <handled>
150 <constant>false</constant>
151 </handled>
152 <to
153 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
154 </doCatch>
155 </doTry>
156 </route>
157 </post>
158 <post
159 uri="/v2/loop/updateMicroservicePolicy/{loopName}"
160 type="org.onap.clamp.policy.microservice.MicroServicePolicy"
161 consumes="application/json"
162 outType="org.onap.clamp.policy.microservice.MicroServicePolicy"
163 produces="application/json">
164 <route>
165 <removeHeaders
166 pattern="*"
167 excludePattern="loopName" />
168 <doTry>
169 <to
170 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Update Microservice policies')" />
171 <to
172 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
173 <setProperty propertyName="MicroServicePolicyObject">
174 <simple>${body}</simple>
175 </setProperty>
176
177 <to uri="direct:load-loop" />
178 <to
179 uri="bean:org.onap.clamp.loop.LoopController?method=updateMicroservicePolicy(${header.loopName},${exchangeProperty[MicroServicePolicyObject]})" />
180 <to
181 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Micro Service policies UPDATED','INFO',${exchangeProperty[loopObject]})" />
182 <to
183 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
184 <doCatch>
185 <exception>java.lang.Exception</exception>
186 <handled>
187 <constant>false</constant>
188 </handled>
189 <to
190 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
191 </doCatch>
192 </doTry>
193 </route>
194 </post>
195 <put
196 uri="/v2/loop/deploy/{loopName}"
197 outType="org.onap.clamp.loop.Loop"
198 produces="application/json">
199 <route>
200 <removeHeaders
201 pattern="*"
202 excludePattern="loopName" />
203 <doTry>
204 <log
205 loggingLevel="INFO"
206 message="DCAE DEPLOY request for loop: ${header.loopName}" />
207 <to
208 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'DCAE DEPLOY request')" />
209 <to
210 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
211 <to uri="direct:load-loop" />
212 <to
213 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DCAE DEPLOY request','INFO',${exchangeProperty[loopObject]})" />
214
215 <to uri="direct:deploy-loop" />
216
217 <log
218 loggingLevel="INFO"
219 message="DEPLOY request successfully executed for loop: ${header.loopName}" />
220 <to
221 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DEPLOY request successfully executed','INFO',${exchangeProperty[loopObject]})" />
222 <to
223 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
224 <doCatch>
225 <exception>java.lang.Exception</exception>
226 <handled>
227 <constant>false</constant>
228 </handled>
229 <to
230 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
231 <log
232 loggingLevel="ERROR"
233 message="DEPLOY request failed for loop: ${header.loopName}" />
234 <to
235 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DEPLOY request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
236 </doCatch>
237 </doTry>
238 </route>
239 </put>
240 <put
241 uri="/v2/loop/undeploy/{loopName}"
242 outType="org.onap.clamp.loop.Loop"
243 produces="application/json">
244 <route>
245 <removeHeaders
246 pattern="*"
247 excludePattern="loopName" />
248 <doTry>
249 <log
250 loggingLevel="INFO"
251 message="DCAE UNDEPLOY request for loop: ${header.loopName}" />
252 <to
253 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'DCAE UNDEPLOY request')" />
254 <to
255 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
256 <to uri="direct:load-loop" />
257 <to
258 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DCAE UNDEPLOY request','INFO',${exchangeProperty[loopObject]})" />
259 <to uri="direct:undeploy-loop" />
260
261 <log
262 loggingLevel="INFO"
263 message="UNDEPLOY request successfully executed for loop: ${header.loopName}" />
264 <to
265 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('UNDEPLOY request successfully executed','INFO',${exchangeProperty[loopObject]})" />
266 <to
267 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
268 <doCatch>
269 <exception>java.lang.Exception</exception>
270 <handled>
271 <constant>false</constant>
272 </handled>
273 <to
274 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
275 <log
276 loggingLevel="ERROR"
277 message="UNDEPLOY request failed for loop: ${header.loopName}" />
278 <to
279 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('UNDEPLOY request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
280 </doCatch>
281 </doTry>
282 </route>
283 </put>
284 <put
285 uri="/v2/loop/stop/{loopName}"
286 outType="org.onap.clamp.loop.Loop"
287 produces="application/json">
288 <route>
289 <removeHeaders
290 pattern="*"
291 excludePattern="loopName" />
292 <doTry>
293 <log
294 loggingLevel="INFO"
295 message="STOP request for loop: ${header.loopName}" />
296 <to
297 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*,'STOP request')" />
298 <to
299 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
300 <to uri="direct:load-loop" />
301 <to
302 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('STOP request','INFO',${exchangeProperty[loopObject]})" />
303
304 <to uri="direct:remove-all-policy-from-active-pdp-group" />
305 <log
306 loggingLevel="INFO"
307 message="STOP request successfully executed for loop: ${header.loopName}" />
308 <to
309 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('STOP request successfully executed','INFO',${exchangeProperty[loopObject]})" />
310 <to
311 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
312 <doCatch>
313 <exception>java.lang.Exception</exception>
314 <handled>
315 <constant>false</constant>
316 </handled>
317 <to
318 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
319 <log
320 loggingLevel="ERROR"
321 message="STOP request failed for loop: $${header.loopName}" />
322 <to
323 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('STOP request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
324 </doCatch>
325 </doTry>
326 </route>
327 </put>
328 <put
329 uri="/v2/loop/restart/{loopName}"
330 outType="org.onap.clamp.loop.Loop"
331 produces="application/json">
332 <route>
333 <removeHeaders
334 pattern="*"
335 excludePattern="loopName" />
336 <doTry>
337 <log
338 loggingLevel="INFO"
339 message="RESTART request for loop: ${header.loopName}" />
340 <to
341 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*,'RESTART request')" />
342 <to
343 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
344 <to uri="direct:load-loop" />
345
346 <to
347 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('RESTART request','INFO',${exchangeProperty[loopObject]})" />
348
349 <to uri="direct:add-all-to-active-pdp-group" />
350 <log
351 loggingLevel="INFO"
352 message="RESTART request successfully executed for loop: ${header.loopName}" />
353 <to
354 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('RESTART request successfully executed','INFO',${exchangeProperty[loopObject]})" />
355 <to
356 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
357 <doCatch>
358 <exception>java.lang.Exception</exception>
359 <handled>
360 <constant>false</constant>
361 </handled>
362 <to
363 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
364 <log
365 loggingLevel="ERROR"
366 message="RESTART request failed for loop: ${header.loopName}" />
367 <to
368 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('RESTART request failed, Error reported: ${exception} - Body: ${exception.responseBody}','INFO',${exchangeProperty[loopObject]})" />
369 </doCatch>
370 </doTry>
371 </route>
372 </put>
373 <put
374 uri="/v2/loop/submit/{loopName}"
375 outType="org.onap.clamp.loop.Loop"
376 produces="application/json">
377 <route>
378 <removeHeaders
379 pattern="*"
380 excludePattern="loopName" />
381 <doTry>
382 <log
383 loggingLevel="INFO"
384 message="POLICY SUBMIT request for loop: ${header.loopName}" />
385 <to
386 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'POLICY SUBMIT request')" />
387 <to
388 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
389 <to uri="direct:load-loop" />
390 <to
391 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('POLICY SUBMIT request','INFO',${exchangeProperty[loopObject]})" />
392 <setProperty propertyName="raiseHttpExceptionFlag">
393 <simple resultType="java.lang.Boolean">false</simple>
394 </setProperty>
395 <to uri="direct:remove-all-policy-from-active-pdp-group" />
396 <log
397 loggingLevel="INFO"
398 message="Processing all MICRO-SERVICES policies defined in loop ${exchangeProperty[loopObject].getName()}" />
399 <split>
400 <simple>${exchangeProperty[loopObject].getMicroServicePolicies()}
401 </simple>
402 <setProperty propertyName="microServicePolicy">
403 <simple>${body}</simple>
404 </setProperty>
405 <log
406 loggingLevel="INFO"
407 message="Processing Micro Service Policy: ${exchangeProperty[microServicePolicy].getName()}" />
408 <setProperty propertyName="raiseHttpExceptionFlag">
409 <simple resultType="java.lang.Boolean">false</simple>
410 </setProperty>
411 <to uri="direct:delete-micro-service-policy" />
412 <to uri="direct:create-micro-service-policy" />
413 </split>
414 <log
415 loggingLevel="INFO"
416 message="Processing all OPERATIONAL policies defined in loop ${exchangeProperty[loopObject].getName()}" />
417 <split>
418 <simple>${exchangeProperty[loopObject].getOperationalPolicies()}
419 </simple>
420 <setProperty propertyName="operationalPolicy">
421 <simple>${body}</simple>
422 </setProperty>
423 <log
424 loggingLevel="INFO"
425 message="Processing Operational Policy: ${exchangeProperty[operationalPolicy].getName()}" />
426 <setProperty propertyName="raiseHttpExceptionFlag">
427 <simple resultType="java.lang.Boolean">false</simple>
428 </setProperty>
429
430 <to uri="direct:delete-operational-policy" />
431 <to uri="direct:create-operational-policy" />
432
433 <log
434 loggingLevel="INFO"
435 message="Processing all GUARD policies defined in loop ${exchangeProperty[loopObject].getName()}" />
436 <split>
437 <simple>${exchangeProperty[operationalPolicy].createGuardPolicyPayloads().entrySet()}
438 </simple>
439 <setProperty propertyName="guardPolicy">
440 <simple>${body}</simple>
441 </setProperty>
442 <log
443 loggingLevel="INFO"
444 message="Processing Guard Policy: ${exchangeProperty[guardPolicy].getKey()}" />
445
446 <setProperty propertyName="raiseHttpExceptionFlag">
447 <simple resultType="java.lang.Boolean">false</simple>
448 </setProperty>
449 <to uri="direct:delete-guard-policy" />
450 <to uri="direct:create-guard-policy" />
451 </split>
452 </split>
453
454 <delay>
455 <constant>3000</constant>
456 </delay>
457
458 <to uri="direct:add-all-to-active-pdp-group" />
459
460 <log
461 loggingLevel="INFO"
462 message="SUBMIT request successfully executed for loop: ${header.loopName}" />
463 <to
464 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('SUBMIT request successfully executed','INFO',${exchangeProperty[loopObject]})" />
465 <to
466 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
467 <doCatch>
468 <exception>java.lang.Exception</exception>
469 <handled>
470 <constant>false</constant>
471 </handled>
472 <to
473 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
474 <log
475 loggingLevel="ERROR"
476 message="SUBMIT request failed for loop: ${header.loopName}" />
477 <to
478 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('SUBMIT request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
479 </doCatch>
480 </doTry>
481 </route>
482 </put>
483 <put uri="/v2/loop/delete/{loopName}">
484 <route>
485 <removeHeaders
486 pattern="*"
487 excludePattern="loopName" />
488 <doTry>
489 <log
490 loggingLevel="INFO"
491 message="DELETE request for loop: ${header.loopName}" />
492 <to
493 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*,'DELETE request')" />
494 <to
495 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
496 <to uri="direct:load-loop" />
497 <to
498 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DELETE request','INFO',${exchangeProperty[loopObject]})" />
499 <to uri="direct:undeploy-loop" />
500 <to uri="direct:remove-all-policy-from-active-pdp-group" />
501 <split>
502 <simple>${exchangeProperty[loopObject].getMicroServicePolicies()}
503 </simple>
504 <setProperty propertyName="microServicePolicy">
505 <simple>${body}</simple>
506 </setProperty>
507 <log
508 loggingLevel="INFO"
509 message="Processing Micro Service Policy: ${exchangeProperty[microServicePolicy].getName()}" />
510 <to uri="direct:delete-micro-service-policy" />
511 </split>
512
513 <log
514 loggingLevel="INFO"
515 message="Processing all OPERATIONAL policies defined in loop ${exchangeProperty[loopObject].getName()}" />
516 <split>
517 <simple>${exchangeProperty[loopObject].getOperationalPolicies()}
518 </simple>
519 <setProperty propertyName="operationalPolicy">
520 <simple>${body}</simple>
521 </setProperty>
522 <log
523 loggingLevel="INFO"
524 message="Processing Operational Policy: ${exchangeProperty[operationalPolicy].getName()}" />
525 <to uri="direct:delete-operational-policy" />
526 <log
527 loggingLevel="INFO"
528 message="Processing all GUARD policies defined in loop ${exchangeProperty[loopObject].getName()}" />
529 <split>
530 <simple>${exchangeProperty[operationalPolicy].createGuardPolicyPayloads().entrySet()}
531 </simple>
532 <setProperty propertyName="guardPolicy">
533 <simple>${body}</simple>
534 </setProperty>
535 <log
536 loggingLevel="INFO"
537 message="Processing Guard Policy: ${exchangeProperty[guardPolicy].getKey()}" />
538 <to uri="direct:delete-guard-policy" />
539 </split>
540 </split>
541 <to
542 uri="bean:org.onap.clamp.loop.log.LoopService?method=deleteLoop(${header.loopName})" />
543 <log
544 loggingLevel="INFO"
545 message="DELETE request successfully executed for loop: ${header.loopName}" />
546 <to
547 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DELETE request successfully executed','INFO',${exchangeProperty[loopObject]})" />
548 <to
549 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
550 <doCatch>
551 <exception>java.lang.Exception</exception>
552 <handled>
553 <constant>false</constant>
554 </handled>
555 <to
556 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
557 <log
558 loggingLevel="ERROR"
559 message="DELETE request failed for loop: ${header.loopName}" />
560 <to
561 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DELETE request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
562 </doCatch>
563 </doTry>
564 </route>
565 </put>
566 <get
567 uri="/v2/loop/getstatus/{loopName}"
568 outType="org.onap.clamp.loop.Loop"
569 produces="application/json">
570 <route>
571 <removeHeaders
572 pattern="*"
573 excludePattern="loopName" />
574 <doTry>
575 <log
576 loggingLevel="INFO"
577 message="GET STATUS request for loop: ${header.loopName}" />
578 <to
579 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET STATUS request')" />
580 <to
581 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','read')" />
582 <to uri="direct:load-loop" />
583 <to
584 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('GET STATUS request','INFO',${exchangeProperty[loopObject]})" />
585 <doTry>
586 <to uri="direct:update-policy-status-for-loop" />
587 <to uri="direct:update-dcae-status-for-loop" />
588 <to uri="direct:update-loop-state" />
589
590 <to
591 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Get Status request successfully executed','INFO',${exchangeProperty[loopObject]})" />
592 <to
593 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
594 </doTry>
595 <doCatch>
596 <exception>java.lang.Exception</exception>
597 <handled>
598 <constant>false</constant>
599 </handled>
600 <to
601 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
602 <log
603 loggingLevel="ERROR"
604 message="Get Status request failed for loop: ${header.loopName}" />
605 <to
606 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Get Status request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
607 </doCatch>
608 <doFinally>
609 <setBody>
610 <simple>${exchangeProperty[loopObject]}</simple>
611 </setBody>
612 </doFinally>
613 </doTry>
614 </route>
615 </get>
616 </rest>
617</rests>