1 <rests xmlns="http://camel.apache.org/schema/spring">
3 <get uri="/v2/loop/getAllNames" outType="java.lang.String[]"
4 produces="application/json">
6 <removeHeaders pattern="*" />
9 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET ALL Loop')" />
11 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','read')" />
13 uri="bean:org.onap.clamp.loop.LoopController?method=getLoopNames()" />
15 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
17 <exception>java.lang.Exception</exception>
19 <constant>false</constant>
22 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
27 <get uri="/v2/loop/{loopName}" outType="org.onap.clamp.loop.Loop"
28 produces="application/json">
30 <removeHeaders pattern="*" excludePattern="loopName" />
33 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET Loop')" />
35 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','read')" />
37 uri="bean:org.onap.clamp.loop.LoopController?method=getLoop(${header.loopName})" />
39 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
41 <exception>java.lang.Exception</exception>
43 <constant>false</constant>
46 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
51 <get uri="/v2/loop/svgRepresentation/{loopName}"
52 outType="java.lang.String" produces="application/xml">
54 <removeHeaders pattern="*" excludePattern="loopName" />
57 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Get SVG Representation')" />
59 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','read')" />
61 uri="bean:org.onap.clamp.loop.LoopController?method=getSvgRepresentation(${header.loopName})" />
63 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
65 <exception>java.lang.Exception</exception>
67 <constant>false</constant>
70 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
76 <post uri="/v2/loop/updateGlobalProperties/{loopName}"
77 type="com.google.gson.JsonObject" consumes="application/json"
78 outType="org.onap.clamp.loop.Loop" produces="application/json">
80 <removeHeaders pattern="*" excludePattern="loopName" />
83 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Update the global properties')" />
85 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
86 <setHeader headerName="GlobalPropertiesJson">
87 <simple>${body}</simple>
89 <to uri="direct:load-loop" />
91 uri="bean:org.onap.clamp.loop.LoopController?method=updateGlobalPropertiesJson(${header.loopName},${header.GlobalPropertiesJson})" />
93 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Global Properties UPDATED','INFO',${exchangeProperty[loopObject]})" />
95 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
97 <exception>java.lang.Exception</exception>
99 <constant>false</constant>
102 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
107 <post uri="/v2/loop/updateOperationalPolicies/{loopName}"
108 type="com.google.gson.JsonArray" consumes="application/json"
109 outType="org.onap.clamp.loop.Loop" produces="application/json">
111 <removeHeaders pattern="*" excludePattern="loopName" />
114 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Update operational policies')" />
116 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
117 <setHeader headerName="OperationalPoliciesArray">
118 <simple>${body}</simple>
120 <to uri="direct:load-loop" />
122 uri="bean:org.onap.clamp.loop.LoopController?method=updateOperationalPolicies(${header.loopName},${header.OperationalPoliciesArray})" />
124 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Operational and Guard policies UPDATED','INFO',${exchangeProperty[loopObject]})" />
126 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
128 <exception>java.lang.Exception</exception>
130 <constant>false</constant>
133 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
138 <post uri="/v2/loop/updateMicroservicePolicy/{loopName}"
139 type="org.onap.clamp.policy.microservice.MicroServicePolicy"
140 consumes="application/json"
141 outType="org.onap.clamp.policy.microservice.MicroServicePolicy"
142 produces="application/json">
144 <removeHeaders pattern="*" excludePattern="loopName" />
147 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Update Microservice policies')" />
149 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
150 <setProperty propertyName="MicroServicePolicyObject">
151 <simple>${body}</simple>
154 <to uri="direct:load-loop" />
156 uri="bean:org.onap.clamp.loop.LoopController?method=updateMicroservicePolicy(${header.loopName},${exchangeProperty[MicroServicePolicyObject]})" />
158 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Micro Service policies UPDATED','INFO',${exchangeProperty[loopObject]})" />
160 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
162 <exception>java.lang.Exception</exception>
164 <constant>false</constant>
167 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
172 <put uri="/v2/loop/deploy/{loopName}"
173 outType="org.onap.clamp.loop.Loop" produces="application/json">
175 <removeHeaders pattern="*" excludePattern="loopName" />
177 <log loggingLevel="INFO"
178 message="DCAE DEPLOY request for loop: ${header.loopName}" />
180 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'DCAE DEPLOY request')" />
182 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
183 <to uri="direct:load-loop" />
185 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DCAE DEPLOY request','INFO',${exchangeProperty[loopObject]})" />
187 <to uri="direct:deploy-loop" />
189 <log loggingLevel="INFO"
190 message="DEPLOY request successfully executed for loop: ${header.loopName}" />
192 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DEPLOY request successfully executed','INFO',${exchangeProperty[loopObject]})" />
194 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
196 <exception>java.lang.Exception</exception>
198 <constant>false</constant>
201 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
202 <log loggingLevel="ERROR"
203 message="DEPLOY request failed for loop: ${header.loopName}" />
205 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DEPLOY request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
210 <put uri="/v2/loop/refreshMicroServicePolicyJsonSchema/{loopName}/{microServicePolicyName}"
211 outType="org.onap.clamp.loop.Loop" produces="application/json">
213 <removeHeaders pattern="*" excludePattern="loopName|microServicePolicyName" />
215 <log loggingLevel="INFO"
216 message="Refresh Micro Service Policy UI for loop: ${header.loopName} and ${header.microServicePolicyName}" />
218 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'REFRESH Micro Service Policy UI request')" />
220 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
221 <to uri="direct:load-loop" />
223 uri="bean:org.onap.clamp.loop.LoopController?method=refreshMicroServicePolicyJsonRepresentation(${exchangeProperty[loopObject]},${header.microServicePolicyName}})" />
224 <log loggingLevel="INFO"
225 message="REFRESH Micro Service policy request successfully executed for loop: ${header.loopName}" />
227 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('REFRESH Micro Service policy request successfully executed','INFO',${exchangeProperty[loopObject]})" />
229 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
231 <exception>java.lang.Exception</exception>
233 <constant>false</constant>
236 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
237 <log loggingLevel="ERROR"
238 message="REFRESH Micro Service policy request failed for loop: ${header.loopName}" />
240 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('REFRESH Micro Service policy request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
245 <put uri="/v2/loop/refreshOperationalPolicyJsonSchema/{loopName}/{operationalPolicyName}"
246 outType="org.onap.clamp.loop.Loop" produces="application/json">
248 <removeHeaders pattern="*" excludePattern="loopName|operationalPolicyName" />
250 <log loggingLevel="INFO"
251 message="Refresh Operational Policy UI for loop: ${header.loopName} and ${header.operationalPolicyName}" />
253 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'REFRESH Operational Policy UI request')" />
255 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
256 <to uri="direct:load-loop" />
258 uri="bean:org.onap.clamp.loop.LoopController?method=refreshOperationalPolicyJsonRepresentation(${exchangeProperty[loopObject]},${header.operationalPolicyName}})" />
259 <log loggingLevel="INFO"
260 message="REFRESH operational policy request successfully executed for loop: ${header.loopName}" />
262 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('REFRESH operational policy request successfully executed','INFO',${exchangeProperty[loopObject]})" />
264 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
266 <exception>java.lang.Exception</exception>
268 <constant>false</constant>
271 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
272 <log loggingLevel="ERROR"
273 message="REFRESH operational policy request failed for loop: ${header.loopName}" />
275 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('REFRESH operational policy request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
280 <put uri="/v2/loop/undeploy/{loopName}"
281 outType="org.onap.clamp.loop.Loop" produces="application/json">
283 <removeHeaders pattern="*" excludePattern="loopName" />
285 <log loggingLevel="INFO"
286 message="DCAE UNDEPLOY request for loop: ${header.loopName}" />
288 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'DCAE UNDEPLOY request')" />
290 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
291 <to uri="direct:load-loop" />
293 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DCAE UNDEPLOY request','INFO',${exchangeProperty[loopObject]})" />
294 <to uri="direct:undeploy-loop" />
296 <log loggingLevel="INFO"
297 message="UNDEPLOY request successfully executed for loop: ${header.loopName}" />
299 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('UNDEPLOY request successfully executed','INFO',${exchangeProperty[loopObject]})" />
301 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
303 <exception>java.lang.Exception</exception>
305 <constant>false</constant>
308 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
309 <log loggingLevel="ERROR"
310 message="UNDEPLOY request failed for loop: ${header.loopName}" />
312 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('UNDEPLOY request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
317 <put uri="/v2/loop/stop/{loopName}"
318 outType="org.onap.clamp.loop.Loop" produces="application/json">
320 <removeHeaders pattern="*" excludePattern="loopName" />
322 <log loggingLevel="INFO"
323 message="STOP request for loop: ${header.loopName}" />
325 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*,'STOP request')" />
327 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
328 <to uri="direct:load-loop" />
330 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('STOP request','INFO',${exchangeProperty[loopObject]})" />
332 <to uri="direct:remove-all-policy-from-active-pdp-group" />
333 <log loggingLevel="INFO"
334 message="STOP request successfully executed for loop: ${header.loopName}" />
336 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('STOP request successfully executed','INFO',${exchangeProperty[loopObject]})" />
338 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
340 <exception>java.lang.Exception</exception>
342 <constant>false</constant>
345 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
346 <log loggingLevel="ERROR"
347 message="STOP request failed for loop: $${header.loopName}" />
349 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('STOP request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
354 <put uri="/v2/loop/restart/{loopName}"
355 outType="org.onap.clamp.loop.Loop" produces="application/json">
357 <removeHeaders pattern="*" excludePattern="loopName" />
359 <log loggingLevel="INFO"
360 message="RESTART request for loop: ${header.loopName}" />
362 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*,'RESTART request')" />
364 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
365 <to uri="direct:load-loop" />
368 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('RESTART request','INFO',${exchangeProperty[loopObject]})" />
370 <to uri="direct:add-all-to-active-pdp-group" />
371 <log loggingLevel="INFO"
372 message="RESTART request successfully executed for loop: ${header.loopName}" />
374 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('RESTART request successfully executed','INFO',${exchangeProperty[loopObject]})" />
376 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
378 <exception>java.lang.Exception</exception>
380 <constant>false</constant>
383 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
384 <log loggingLevel="ERROR"
385 message="RESTART request failed for loop: ${header.loopName}" />
387 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('RESTART request failed, Error reported: ${exception} - Body: ${exception.responseBody}','INFO',${exchangeProperty[loopObject]})" />
392 <put uri="/v2/loop/submit/{loopName}"
393 outType="org.onap.clamp.loop.Loop" produces="application/json">
395 <removeHeaders pattern="*" excludePattern="loopName" />
397 <log loggingLevel="INFO"
398 message="POLICY SUBMIT request for loop: ${header.loopName}" />
400 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'POLICY SUBMIT request')" />
402 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
403 <to uri="direct:load-loop" />
405 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('POLICY SUBMIT request','INFO',${exchangeProperty[loopObject]})" />
406 <setProperty propertyName="raiseHttpExceptionFlag">
407 <simple resultType="java.lang.Boolean">false</simple>
409 <to uri="direct:remove-all-policy-from-active-pdp-group" />
410 <log loggingLevel="INFO"
411 message="Processing all MICRO-SERVICES policies defined in loop ${exchangeProperty[loopObject].getName()}" />
413 <simple>${exchangeProperty[loopObject].getMicroServicePolicies()}
415 <setProperty propertyName="policy">
416 <simple>${body}</simple>
418 <log loggingLevel="INFO"
419 message="Processing Micro Service Policy: ${exchangeProperty[policy].getName()}" />
420 <setProperty propertyName="raiseHttpExceptionFlag">
421 <simple resultType="java.lang.Boolean">false</simple>
423 <to uri="direct:delete-policy" />
424 <to uri="direct:create-policy" />
426 <log loggingLevel="INFO"
427 message="Processing all OPERATIONAL policies defined in loop ${exchangeProperty[loopObject].getName()}" />
429 <simple>${exchangeProperty[loopObject].getOperationalPolicies()}
431 <setProperty propertyName="policy">
432 <simple>${body}</simple>
434 <log loggingLevel="INFO"
435 message="Processing Operational Policy: ${exchangeProperty[policy].getName()}" />
436 <setProperty propertyName="raiseHttpExceptionFlag">
437 <simple resultType="java.lang.Boolean">false</simple>
440 <to uri="direct:delete-policy" />
441 <to uri="direct:create-policy" />
444 <simple>${exchangeProperty['policy'].isLegacy()} == true
446 <log loggingLevel="INFO"
447 message="Processing all GUARD policies (LEGACY) defined in loop ${exchangeProperty[loopObject].getName()}" />
449 <simple>${exchangeProperty[operationalPolicy].createGuardPolicyPayloads().entrySet()}
451 <setProperty propertyName="guardPolicy">
452 <simple>${body}</simple>
454 <log loggingLevel="INFO"
455 message="Processing Guard Policy: ${exchangeProperty[guardPolicy].getKey()}" />
457 <setProperty propertyName="raiseHttpExceptionFlag">
458 <simple resultType="java.lang.Boolean">false</simple>
460 <to uri="direct:delete-guard-policy" />
461 <to uri="direct:create-guard-policy" />
468 <constant>3000</constant>
471 <to uri="direct:add-all-to-active-pdp-group" />
473 <log loggingLevel="INFO"
474 message="SUBMIT request successfully executed for loop: ${header.loopName}" />
476 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('SUBMIT request successfully executed','INFO',${exchangeProperty[loopObject]})" />
478 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
480 <exception>java.lang.Exception</exception>
482 <constant>false</constant>
485 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
486 <log loggingLevel="ERROR"
487 message="SUBMIT request failed for loop: ${header.loopName}" />
489 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('SUBMIT request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
494 <put uri="/v2/loop/delete/{loopName}">
496 <removeHeaders pattern="*" excludePattern="loopName" />
498 <log loggingLevel="INFO"
499 message="DELETE request for loop: ${header.loopName}" />
501 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*,'DELETE request')" />
503 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
504 <to uri="direct:load-loop" />
506 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DELETE request','INFO',${exchangeProperty[loopObject]})" />
507 <to uri="direct:undeploy-loop" />
508 <to uri="direct:remove-all-policy-from-active-pdp-group" />
510 <simple>${exchangeProperty[loopObject].getMicroServicePolicies()}
512 <setProperty propertyName="microServicePolicy">
513 <simple>${body}</simple>
515 <log loggingLevel="INFO"
516 message="Processing Micro Service Policy: ${exchangeProperty[microServicePolicy].getName()}" />
517 <to uri="direct:delete-micro-service-policy" />
520 <log loggingLevel="INFO"
521 message="Processing all OPERATIONAL policies defined in loop ${exchangeProperty[loopObject].getName()}" />
523 <simple>${exchangeProperty[loopObject].getOperationalPolicies()}
525 <setProperty propertyName="operationalPolicy">
526 <simple>${body}</simple>
528 <log loggingLevel="INFO"
529 message="Processing Operational Policy: ${exchangeProperty[operationalPolicy].getName()}" />
530 <to uri="direct:delete-operational-policy" />
531 <log loggingLevel="INFO"
532 message="Processing all GUARD policies defined in loop ${exchangeProperty[loopObject].getName()}" />
534 <simple>${exchangeProperty[operationalPolicy].createGuardPolicyPayloads().entrySet()}
536 <setProperty propertyName="guardPolicy">
537 <simple>${body}</simple>
539 <log loggingLevel="INFO"
540 message="Processing Guard Policy: ${exchangeProperty[guardPolicy].getKey()}" />
541 <to uri="direct:delete-guard-policy" />
545 uri="bean:org.onap.clamp.loop.log.LoopController?method=deleteLoop(${header.loopName})" />
546 <log loggingLevel="INFO"
547 message="DELETE request successfully executed for loop: ${header.loopName}" />
549 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DELETE request successfully executed','INFO',${exchangeProperty[loopObject]})" />
551 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
553 <exception>java.lang.Exception</exception>
555 <constant>false</constant>
558 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
559 <log loggingLevel="ERROR"
560 message="DELETE request failed for loop: ${header.loopName}" />
562 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('DELETE request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
567 <get uri="/v2/loop/getstatus/{loopName}"
568 outType="org.onap.clamp.loop.Loop" produces="application/json">
570 <removeHeaders pattern="*" excludePattern="loopName" />
572 <log loggingLevel="INFO"
573 message="GET STATUS request for loop: ${header.loopName}" />
575 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET STATUS request')" />
577 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','read')" />
578 <to uri="direct:load-loop" />
580 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('GET STATUS request','INFO',${exchangeProperty[loopObject]})" />
582 <to uri="direct:update-policy-status-for-loop" />
583 <to uri="direct:update-dcae-status-for-loop" />
584 <to uri="direct:update-loop-state" />
587 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Get Status request successfully executed','INFO',${exchangeProperty[loopObject]})" />
589 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
592 <exception>java.lang.Exception</exception>
594 <constant>false</constant>
597 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
598 <log loggingLevel="ERROR"
599 message="Get Status request failed for loop: ${header.loopName}" />
601 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Get Status request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" />
605 <simple>${exchangeProperty[loopObject]}</simple>
612 <put uri="/v2/loop/addOperationaPolicy/{loopName}/policyModel/{policyType}/{policyVersion}" outType="org.onap.clamp.loop.Loop" produces="application/json">
614 <removeHeaders pattern="*" excludePattern="loopName|policyType|policyVersion" />
617 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Add operational Policy')" />
619 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
620 <to uri="direct:load-loop" />
622 uri="bean:org.onap.clamp.loop.LoopController?method=addOperationalPolicy(${header.loopName},${header.policyType},${header.policyVersion})" />
624 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('ADD OperationalPolicy request successfully executed','INFO',${exchangeProperty[loopObject]})" />
626 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
628 <exception>java.lang.Exception</exception>
630 <constant>false</constant>
633 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
634 <log loggingLevel="ERROR"
635 message="ADD OperationalPolicy request failed for loop: ${header.loopName}" />
637 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('ADD OperationalPolicy request failed','ERROR',${exchangeProperty[loopObject]})" />
642 <put uri="/v2/loop/removeOperationaPolicy/{loopName}/policyModel/{policyType}/{policyVersion}" outType="org.onap.clamp.loop.Loop" produces="application/json">
644 <removeHeaders pattern="*" excludePattern="loopName|policyType|policyVersion" />
647 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'REMOVE operational Policy')" />
649 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
650 <to uri="direct:load-loop" />
652 uri="bean:org.onap.clamp.loop.LoopController?method=removeOperationalPolicy(${header.loopName},${header.policyType},${header.policyVersion})" />
654 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('REMOVE OperationalPolicy request successfully executed','INFO',${exchangeProperty[loopObject]})" />
656 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
658 <exception>java.lang.Exception</exception>
660 <constant>false</constant>
663 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
664 <log loggingLevel="ERROR"
665 message="REMOVE OperationalPolicy request failed for loop: ${header.loopName}" />
667 uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('REMOVE OperationalPolicy request failed','ERROR',${exchangeProperty[loopObject]})" />
673 uri="/v2/loop/create/{loopName}?templateName={templateName}"
674 outType="org.onap.clamp.loop.Loop" consumes="application/json"
675 produces="application/json">
679 excludePattern="loopName|templateName" />
682 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Create Loop')" />
684 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'cl','','update')" />
686 uri="bean:org.onap.clamp.loop.LoopController?method=createLoop(${header.loopName}, ${header.templateName})" />
688 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
690 <exception>java.lang.Exception</exception>
692 <constant>true</constant>
694 <setHeader headerName="CamelHttpResponseCode">
695 <constant>500</constant>
698 <simple>ERROR: ${exception.message}</simple>
701 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
706 <get uri="/v2/dictionary"
707 outType="org.onap.clamp.tosca.Dictionary" produces="application/json">
709 <removeHeaders pattern="*" />
712 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET ALL Dictionaries')" />
714 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','read')" />
716 uri="bean:org.onap.clamp.tosca.DictionaryService?method=getAllDictionaries()" />
718 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
720 <exception>java.lang.Exception</exception>
722 <constant>false</constant>
725 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
731 <get uri="/v2/dictionary/secondary/names"
732 outType="java.lang.String[]" produces="application/json">
734 <removeHeaders pattern="*" />
737 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET ALL Secondary Dictionary Level Names')" />
739 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','read')" />
741 uri="bean:org.onap.clamp.tosca.DictionaryService?method=getAllSecondaryLevelDictionaryNames()" />
743 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
745 <exception>java.lang.Exception</exception>
747 <constant>false</constant>
750 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
755 <get uri="/v2/dictionary/{dictionaryName}"
756 outType="org.onap.clamp.tosca.Dictionary" produces="application/json">
758 <removeHeaders pattern="*"
759 excludePattern="dictionaryName" />
762 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET ALL Dictionary Elements for a Dictionary Name')" />
764 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','read')" />
766 uri="bean:org.onap.clamp.tosca.DictionaryService?method=getDictionary(${header.dictionaryName})" />
768 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
770 <exception>java.lang.Exception</exception>
772 <constant>false</constant>
775 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
780 <put uri="/v2/dictionary" type="org.onap.clamp.tosca.Dictionary"
781 outType="org.onap.clamp.tosca.Dictionary" consumes="application/json"
782 produces="application/json">
786 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Add New or Update Dictionary')" />
788 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','update')" />
789 <setProperty propertyName="DictionaryObject">
790 <simple>${body}</simple>
793 uri="bean:org.onap.clamp.tosca.DictionaryService?method=saveOrUpdateDictionary(${exchangeProperty[DictionaryObject]})" />
795 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
797 <exception>java.lang.Exception</exception>
799 <constant>false</constant>
802 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
808 <put uri="/v2/dictionary/{name}"
809 type="org.onap.clamp.tosca.Dictionary"
810 outType="org.onap.clamp.tosca.Dictionary" consumes="application/json"
811 produces="application/json">
813 <removeHeaders pattern="*" excludePattern="name" />
816 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Add New or Update Dictionary Element')" />
818 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','update')" />
819 <setProperty propertyName="DictionaryObject">
820 <simple>${body}</simple>
823 uri="bean:org.onap.clamp.tosca.DictionaryService?method=saveOrUpdateDictionaryElement(${header.name}, ${exchangeProperty[DictionaryObject]})" />
825 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
827 <exception>java.lang.Exception</exception>
829 <constant>false</constant>
832 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
838 <delete uri="/v2/dictionary/{name}" produces="application/json">
840 <removeHeaders pattern="*" excludePattern="name" />
843 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Delete Dictionary')" />
845 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','update')" />
847 uri="bean:org.onap.clamp.tosca.DictionaryService?method=deleteDictionary(${header.name})" />
849 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
851 <exception>java.lang.Exception</exception>
853 <constant>false</constant>
856 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
862 <delete uri="/v2/dictionary/{name}/elements/{shortName}"
863 produces="application/json">
865 <removeHeaders pattern="*"
866 excludePattern="name|shortName" />
869 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Delete Dictionary Element')" />
871 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','update')" />
873 uri="bean:org.onap.clamp.tosca.DictionaryService?method=deleteDictionaryElement(${header.name}, ${header.shortName})" />
875 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
877 <exception>java.lang.Exception</exception>
879 <constant>false</constant>
882 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
888 <get uri="/v2/policyToscaModels"
889 outType="org.onap.clamp.loop.template.PolicyModel"
890 produces="application/json">
892 <removeHeaders pattern="*" />
895 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET ALL Tosca Policy Models')" />
897 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','read')" />
899 uri="bean:org.onap.clamp.loop.template.PolicyModelsService?method=getAllPolicyModels()" />
901 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
903 <exception>java.lang.Exception</exception>
905 <constant>true</constant>
907 <setHeader headerName="CamelHttpResponseCode">
908 <constant>500</constant>
911 <simple>ERROR: ${exception.message}</simple>
914 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
919 <get uri="/v2/policyToscaModels/{policyModelType}/{policyModelVersion}"
920 outType="org.onap.clamp.loop.template.PolicyModel"
921 produces="application/json">
923 <removeHeaders pattern="*"
924 excludePattern="policyModelType|policyModelVersion" />
927 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET Tosca Policy Model by Name/Version')" />
929 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','read')" />
931 uri="bean:org.onap.clamp.loop.template.PolicyModelsService?method=getPolicyModelByType(${header.policyModelType},${header.policyModelVersion})" />
933 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
935 <exception>java.lang.Exception</exception>
937 <constant>true</constant>
939 <setHeader headerName="CamelHttpResponseCode">
940 <constant>500</constant>
943 <simple>ERROR: ${exception.message}</simple>
946 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
951 <get uri="/v2/policyToscaModels/yaml/{policyModelType}/{policyModelVersion}"
952 outType="java.lang.String" produces="application/json">
954 <removeHeaders pattern="*"
955 excludePattern="policyModelType|policyModelVersion" />
958 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET Tosca Policy Model Yaml String by Name/Version')" />
960 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','read')" />
962 uri="bean:org.onap.clamp.loop.template.PolicyModelsService?method=getPolicyModelTosca(${header.policyModelType},${header.policyModelVersion})" />
964 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
966 <exception>java.lang.Exception</exception>
968 <constant>true</constant>
970 <setHeader headerName="CamelHttpResponseCode">
971 <constant>500</constant>
974 <simple>ERROR: ${exception.message}</simple>
977 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
983 <post uri="/v2/policyToscaModels"
984 type="java.lang.String"
985 outType="org.onap.clamp.loop.template.PolicyModel"
986 consumes="plain/text" produces="application/json">
988 <removeHeaders pattern="*"/>
991 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Upload New or Update Tosca Policy Model')" />
993 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','update')" />
994 <setProperty propertyName="PolicyModelTosca">
995 <simple>${body}</simple>
998 uri="bean:org.onap.clamp.loop.template.PolicyModelsService?method=createNewPolicyModelFromTosca(${exchangeProperty[PolicyModelTosca]})" />
1000 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
1002 <exception>java.lang.Exception</exception>
1004 <constant>true</constant>
1006 <setHeader headerName="CamelHttpResponseCode">
1007 <constant>404</constant>
1010 <simple>ERROR: ${exception.message}</simple>
1013 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
1018 <put uri="/v2/policyToscaModels/{policyModelType}/{policyModelVersion}"
1019 type="java.lang.String"
1020 outType="org.onap.clamp.loop.template.PolicyModel"
1021 consumes="plain/text" produces="application/json">
1023 <removeHeaders pattern="*"
1024 excludePattern="policyModelType|policyModelVersion" />
1027 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Upload New or Update Tosca Policy Model')" />
1029 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'tosca','','update')" />
1030 <setProperty propertyName="PolicyModelTosca">
1031 <simple>${body}</simple>
1034 uri="bean:org.onap.clamp.loop.template.PolicyModelsService?method=updatePolicyModelTosca(${header.policyModelType},${policyModelVersion},${exchangeProperty[PolicyModelTosca]})" />
1036 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
1038 <exception>java.lang.Exception</exception>
1040 <constant>true</constant>
1042 <setHeader headerName="CamelHttpResponseCode">
1043 <constant>404</constant>
1046 <simple>ERROR: ${exception.message}</simple>
1049 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
1055 <get uri="/v2/templates"
1056 outType="org.onap.clamp.loop.template.LoopTemplate"
1057 produces="application/json">
1059 <removeHeaders pattern="*" />
1062 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET ALL Templates')" />
1064 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'template','','read')" />
1066 uri="bean:org.onap.clamp.loop.template.LoopTemplatesService?method=getAllLoopTemplates()" />
1068 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
1070 <exception>java.lang.Exception</exception>
1072 <constant>true</constant>
1074 <setHeader headerName="CamelHttpResponseCode">
1075 <constant>500</constant>
1078 <simple>ERROR: ${exception.message}</simple>
1081 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
1086 <get uri="/v2/templates/{templateName}"
1087 outType="org.onap.clamp.loop.template.LoopTemplate"
1088 produces="application/json">
1090 <removeHeaders pattern="*"
1091 excludePattern="templateName" />
1094 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET a Template by NAME')" />
1096 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'template','','read')" />
1098 uri="bean:org.onap.clamp.loop.template.LoopTemplatesService?method=getLoopTemplate(${header.templateName})" />
1100 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
1102 <exception>java.lang.Exception</exception>
1104 <constant>true</constant>
1106 <setHeader headerName="CamelHttpResponseCode">
1107 <constant>500</constant>
1110 <simple>ERROR: ${exception.message}</simple>
1113 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
1118 <get uri="/v2/templates/names" outType="java.lang.String[]"
1119 produces="application/json">
1121 <removeHeaders pattern="*" />
1124 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'GET ALL Loop Template Names')" />
1126 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'template','','read')" />
1128 uri="bean:org.onap.clamp.loop.template.LoopTemplatesService?method=getLoopTemplateNames()" />
1130 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
1132 <exception>java.lang.Exception</exception>
1134 <constant>false</constant>
1137 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
1142 <get uri="/v2/templates/{templateName}/svgRepresentation"
1143 outType="java.lang.String" produces="application/xml">
1145 <removeHeaders pattern="*" excludePattern="templateName" />
1148 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=startLog(*, 'Get SVG Representation for Loop template')" />
1150 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=authorize(*,'template','','read')" />
1152 uri="bean:org.onap.clamp.loop.template.LoopTemplatesService?method=getSvgRepresentation(${header.templateName})" />
1154 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" />
1156 <exception>java.lang.Exception</exception>
1158 <constant>false</constant>
1161 uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=errorLog()" />
1166 <get uri="/v2/clampInformation" outType="org.onap.clamp.clds.model.ClampInformation"
1167 produces="application/json">
1169 uri="bean:org.onap.clamp.authorization.AuthorizationController?method=getClampInformation()" />