diff options
author | sebdet <sebastien.determe@intl.att.com> | 2020-04-17 15:28:06 +0200 |
---|---|---|
committer | sebdet <sebastien.determe@intl.att.com> | 2020-04-20 11:42:11 +0200 |
commit | e79544b8d495cab881f6de3808e6337a2b37e461 (patch) | |
tree | e0db387835582e92d9d242fad8cd249381be3535 /src/main/resources/clds/camel/rest | |
parent | df68db271f23561671a59b1678c39b8ee54cd8e4 (diff) |
Fix the get status
The policy status goes to unknown because the status code returned is not good in some cases (failure with dcae comm)
Issue-ID: CLAMP-827
Signed-off-by: sebdet <sebastien.determe@intl.att.com>
Change-Id: Iae189f62b4c7061949ffd4c842465bf5e379b669
Diffstat (limited to 'src/main/resources/clds/camel/rest')
-rw-r--r-- | src/main/resources/clds/camel/rest/clamp-api-v2.xml | 21 |
1 files changed, 8 insertions, 13 deletions
diff --git a/src/main/resources/clds/camel/rest/clamp-api-v2.xml b/src/main/resources/clds/camel/rest/clamp-api-v2.xml index fc7dbd492..879c9b707 100644 --- a/src/main/resources/clds/camel/rest/clamp-api-v2.xml +++ b/src/main/resources/clds/camel/rest/clamp-api-v2.xml @@ -697,16 +697,14 @@ <to uri="direct:load-loop" /> <to uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('GET STATUS request','INFO',${exchangeProperty[loopObject]})" /> - <doTry> - <to uri="direct:update-policy-status-for-loop" /> - <to uri="direct:update-dcae-status-for-loop" /> - <to uri="direct:update-loop-state" /> + <to uri="direct:update-policy-status-for-loop" /> + <to uri="direct:update-dcae-status-for-loop" /> + <to uri="direct:update-loop-state" /> - <to + <to uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('GET STATUS request successfully executed','INFO',${exchangeProperty[loopObject]})" /> - <to + <to uri="bean:org.onap.clamp.flow.log.FlowLogOperation?method=endLog()" /> - </doTry> <doCatch> <exception>java.lang.Exception</exception> <handled> @@ -718,17 +716,14 @@ message="GET STATUS request FAILED for loop: ${header.loopName}, ${exception.stacktrace}" /> <to uri="bean:org.onap.clamp.loop.log.LoopLogService?method=addLog('GET STATUS request failed, Error reported: ${exception} - Body: ${exception.responseBody}','ERROR',${exchangeProperty[loopObject]})" /> - <setHeader headerName="CamelHttpResponseCode"> - <constant>500</constant> - </setHeader> - <setBody> - <simple>GET STATUS request FAILED</simple> - </setBody> </doCatch> <doFinally> <setBody> <simple>${exchangeProperty[loopObject]}</simple> </setBody> + <setHeader headerName="CamelHttpResponseCode"> + <constant>200</constant> + </setHeader> </doFinally> </doTry> </route> |