summaryrefslogtreecommitdiffstats
path: root/src/main/java/org
diff options
context:
space:
mode:
authorSébastien Determe <sebastien.determe@intl.att.com>2019-02-22 06:16:19 +0000
committerGerrit Code Review <gerrit@onap.org>2019-02-22 06:16:19 +0000
commit51544c9833da4d51ce18ddd01d0cb23c84de27dc (patch)
tree565bae5e18a10289c0599185a95b1c2b3ce597e2 /src/main/java/org
parentf08a27fede1086e17632dde816e0ae6214cab286 (diff)
parent9eb3c7a2fa4f6cace52d49a84123f370babaf57f (diff)
Merge "Allow only 1 Operational Policy"
Diffstat (limited to 'src/main/java/org')
-rw-r--r--src/main/java/org/onap/clamp/clds/service/CldsService.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/java/org/onap/clamp/clds/service/CldsService.java b/src/main/java/org/onap/clamp/clds/service/CldsService.java
index 42e9cf713..e3a379b36 100644
--- a/src/main/java/org/onap/clamp/clds/service/CldsService.java
+++ b/src/main/java/org/onap/clamp/clds/service/CldsService.java
@@ -394,11 +394,14 @@ public class CldsService extends SecureServiceBase {
errorMessage = e.getMessage();
}
- if (!errorMessage.isEmpty()) {
+ if (null == errorMessage || (null != errorMessage && !errorMessage.isEmpty())) {
CldsEvent.insEvent(cldsDao, model.getControlName(), getUserId(), actionCd, CldsEvent.ACTION_STATE_ERROR,
null);
// Need a refresh as new events have been inserted
model = CldsModel.retrieve(cldsDao, modelName, false);
+ if (null == errorMessage) {
+ errorMessage = "No response from Policy";
+ }
model.setErrorMessageForUi(errorMessage);
util.exiting(HttpStatus.INTERNAL_SERVER_ERROR.toString(), "putModelAndProcessAction failed", Level.INFO,
ONAPLogConstants.ResponseStatus.ERROR);