summaryrefslogtreecommitdiffstats
path: root/src/main/resources/clds/camel/routes/dcae-flows.xml
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/resources/clds/camel/routes/dcae-flows.xml')
-rw-r--r--src/main/resources/clds/camel/routes/dcae-flows.xml51
1 files changed, 23 insertions, 28 deletions
diff --git a/src/main/resources/clds/camel/routes/dcae-flows.xml b/src/main/resources/clds/camel/routes/dcae-flows.xml
index 395077a8e..469358190 100644
--- a/src/main/resources/clds/camel/routes/dcae-flows.xml
+++ b/src/main/resources/clds/camel/routes/dcae-flows.xml
@@ -2,19 +2,16 @@
<route id="deploy-loop">
<from uri="direct:deploy-loop" />
<doTry>
- <log
- loggingLevel="INFO"
+ <log loggingLevel="INFO"
message="Deploying the loop: ${exchangeProperty[loopObject].getName()}" />
<to
uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=invokeLog('DCAE', 'Deploying the loop')" />
<setBody>
- <method
- ref="org.onap.clamp.loop.components.external.DcaeComponent"
+ <method ref="org.onap.clamp.loop.components.external.DcaeComponent"
method="getDeployPayload(${exchangeProperty[loopObject]})" />
</setBody>
<setProperty propertyName="dcaeDeploymentId">
- <method
- ref="org.onap.clamp.loop.components.external.DcaeComponent"
+ <method ref="org.onap.clamp.loop.components.external.DcaeComponent"
method="generateDeploymentId()" />
</setProperty>
<setHeader headerName="CamelHttpMethod">
@@ -35,20 +32,17 @@
<simple>${exchangeProperty[X-ONAP-PartnerName]}
</simple>
</setHeader>
- <log
- loggingLevel="INFO"
+ <log loggingLevel="INFO"
message="Endpoint to deploy loop: {{clamp.config.dcae.deployment.url}}/dcae-deployments/${exchangeProperty[dcaeDeploymentId]}"></log>
<toD
uri="{{clamp.config.dcae.deployment.url}}/dcae-deployments/${exchangeProperty[dcaeDeploymentId]}?bridgeEndpoint=true&amp;useSystemProperties=true&amp;mapHttpMessageHeaders=false&amp;throwExceptionOnFailure=${exchangeProperty[raiseHttpExceptionFlag]}&amp;authUsername={{clamp.config.dcae.deployment.userName}}&amp;authPassword={{clamp.config.dcae.deployment.password}}&amp;connectionTimeToLive=5000&amp;httpClient.connectTimeout=10000&amp;httpClient.socketTimeout=300000&amp;authenticationPreemptive=true&amp;connectionClose=true" />
<convertBodyTo type="java.lang.String" />
<setProperty propertyName="dcaeResponse">
- <method
- ref="org.onap.clamp.loop.components.external.DcaeComponent"
+ <method ref="org.onap.clamp.loop.components.external.DcaeComponent"
method="convertDcaeResponse(${body})" />
</setProperty>
<setProperty propertyName="dcaeStatusUrl">
- <method
- ref="org.onap.clamp.loop.components.external.DcaeComponent"
+ <method ref="org.onap.clamp.loop.components.external.DcaeComponent"
method="getStatusUrl(${exchangeProperty[dcaeResponse]})" />
</setProperty>
<to
@@ -63,6 +57,9 @@
StatusUrl:${exchangeProperty[dcaeStatusUrl]})
</simple>
</setProperty>
+ <setProperty propertyName="logComponent">
+ <simple>DCAE</simple>
+ </setProperty>
<to uri="direct:dump-loop-log-http-response" />
</doFinally>
</doTry>
@@ -70,8 +67,7 @@
<route id="undeploy-loop">
<from uri="direct:undeploy-loop" />
- <log
- loggingLevel="INFO"
+ <log loggingLevel="INFO"
message="Undeploying the loop: ${exchangeProperty[loopObject].getName()} : ${exchangeProperty[loopObject].getDcaeDeploymentId()}" />
<to
uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=invokeLog('DCAE', 'Undeploying the loop')" />
@@ -82,8 +78,7 @@
</simple>
<doTry>
<setBody>
- <method
- ref="org.onap.clamp.loop.components.external.DcaeComponent"
+ <method ref="org.onap.clamp.loop.components.external.DcaeComponent"
method="getUndeployPayload(${exchangeProperty[loopObject]})" />
</setBody>
<setHeader headerName="CamelHttpMethod">
@@ -105,20 +100,17 @@
<simple>${exchangeProperty[X-ONAP-PartnerName]}
</simple>
</setHeader>
- <log
- loggingLevel="INFO"
+ <log loggingLevel="INFO"
message="Endpoint to undeploy loop: {{clamp.config.dcae.deployment.url}}/dcae-deployments/${exchangeProperty[loopObject].getDcaeDeploymentId()}"></log>
<toD
uri="{{clamp.config.dcae.deployment.url}}/dcae-deployments/${exchangeProperty[loopObject].getDcaeDeploymentId()}?bridgeEndpoint=true&amp;useSystemProperties=true&amp;mapHttpMessageHeaders=false&amp;throwExceptionOnFailure=${exchangeProperty[raiseHttpExceptionFlag]}&amp;authUsername={{clamp.config.dcae.deployment.userName}}&amp;authPassword={{clamp.config.dcae.deployment.password}}&amp;connectionTimeToLive=5000&amp;httpClient.connectTimeout=10000&amp;httpClient.socketTimeout=300000&amp;authenticationPreemptive=true&amp;connectionClose=true" />
<convertBodyTo type="java.lang.String" />
<setProperty propertyName="dcaeResponse">
- <method
- ref="org.onap.clamp.loop.components.external.DcaeComponent"
+ <method ref="org.onap.clamp.loop.components.external.DcaeComponent"
method="convertDcaeResponse(${body})" />
</setProperty>
<setProperty propertyName="dcaeStatusUrl">
- <method
- ref="org.onap.clamp.loop.components.external.DcaeComponent"
+ <method ref="org.onap.clamp.loop.components.external.DcaeComponent"
method="getStatusUrl(${exchangeProperty[dcaeResponse]})" />
</setProperty>
<to
@@ -130,13 +122,15 @@
<setProperty propertyName="logMessage">
<simple>UNDEPLOY loop status</simple>
</setProperty>
+ <setProperty propertyName="logComponent">
+ <simple>DCAE</simple>
+ </setProperty>
<to uri="direct:dump-loop-log-http-response" />
</doFinally>
</doTry>
</when>
<otherwise>
- <log
- loggingLevel="WARNING"
+ <log loggingLevel="WARNING"
message="Cannot Undeploy for the loop: ${exchangeProperty[loopObject].getName()}, the Deployment ID does not exist !" />
<to
uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('Cannot Undeploy for the loop: ${exchangeProperty[loopObject].getName()}, the Deployment ID does not exist !','WARNING',${exchangeProperty[loopObject]})" />
@@ -146,8 +140,7 @@
</route>
<route id="get-dcae-deployment-status">
<from uri="direct:get-dcae-deployment-status" />
- <log
- loggingLevel="INFO"
+ <log loggingLevel="INFO"
message="Getting DCAE deployment status for loop: ${exchangeProperty[loopObject].getName()}" />
<to
uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=invokeLog('DCAE', 'Getting Deployment status')" />
@@ -167,8 +160,7 @@
<simple>${exchangeProperty[X-ONAP-PartnerName]}
</simple>
</setHeader>
- <log
- loggingLevel="INFO"
+ <log loggingLevel="INFO"
message="Endpoint to query Closed Loop status: ${exchangeProperty[loopObject].getDcaeDeploymentStatusUrl()}"></log>
<toD
uri="${exchangeProperty[loopObject].getDcaeDeploymentStatusUrl()}?bridgeEndpoint=true&amp;useSystemProperties=true&amp;throwExceptionOnFailure=${exchangeProperty[raiseHttpExceptionFlag]}&amp;authMethod=Basic&amp;authUsername={{clamp.config.dcae.deployment.userName}}&amp;authPassword={{clamp.config.dcae.deployment.password}}&amp;connectionTimeToLive=5000&amp;httpClient.connectTimeout=10000&amp;httpClient.socketTimeout=30000&amp;authenticationPreemptive=true&amp;connectionClose=true" />
@@ -179,6 +171,9 @@
<setProperty propertyName="logMessage">
<simple>DCAE deployment status</simple>
</setProperty>
+ <setProperty propertyName="logComponent">
+ <simple>DCAE</simple>
+ </setProperty>
<to uri="direct:dump-loop-log-http-response" />
</doFinally>
</doTry>