diff options
author | rameshiyer27 <ramesh.murugan.iyer@est.tech> | 2023-07-18 13:43:11 +0100 |
---|---|---|
committer | Ramesh Murugan Iyer <ramesh.murugan.iyer@est.tech> | 2023-07-24 09:29:45 +0000 |
commit | 0d650c2322f2136b26bfd3cf02a5bbb97847842a (patch) | |
tree | 89b1e7924a3a538385f5a9fdfa60af3230570f2f /runtime-acm/src/main/java | |
parent | 358a9a59e491ad5f7f6d51b42136835d1b5e6e95 (diff) |
Fix State change result of AC instances after timeout
If the AC operation succeeds/failed after timeout, the latest results were not updated in the database.
Issue-ID: POLICY-4769
Signed-off-by: zrrmmua <ramesh.murugan.iyer@est.tech>
Change-Id: Id849a79847f85aa96ae36cd614d045e180731ebf
(cherry picked from commit a78d8dbecaca562d900858321e70c2a9fa064ec7)
Diffstat (limited to 'runtime-acm/src/main/java')
-rw-r--r-- | runtime-acm/src/main/java/org/onap/policy/clamp/acm/runtime/supervision/SupervisionAcHandler.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/runtime-acm/src/main/java/org/onap/policy/clamp/acm/runtime/supervision/SupervisionAcHandler.java b/runtime-acm/src/main/java/org/onap/policy/clamp/acm/runtime/supervision/SupervisionAcHandler.java index 5a2079b0d..df5d0ff0e 100644 --- a/runtime-acm/src/main/java/org/onap/policy/clamp/acm/runtime/supervision/SupervisionAcHandler.java +++ b/runtime-acm/src/main/java/org/onap/policy/clamp/acm/runtime/supervision/SupervisionAcHandler.java @@ -248,10 +248,9 @@ public class SupervisionAcHandler { Set<Map.Entry<UUID, AcElementDeployAck>> automationCompositionResultSet, StateChangeResult stateChangeResult) { var updated = false; - var elementInErrors = StateChangeResult.FAILED.equals(stateChangeResult); boolean inProgress = !StateChangeResult.FAILED.equals(automationComposition.getStateChangeResult()); - if (elementInErrors && inProgress) { - automationComposition.setStateChangeResult(StateChangeResult.FAILED); + if (inProgress) { + automationComposition.setStateChangeResult(stateChangeResult); } for (var acElementAck : automationCompositionResultSet) { |