summaryrefslogtreecommitdiffstats
path: root/examples/examples-servlet
diff options
context:
space:
mode:
authora.sreekumar <ajith.sreekumar@bell.ca>2021-01-25 11:03:42 +0000
committera.sreekumar <ajith.sreekumar@bell.ca>2021-01-28 13:14:51 +0000
commit658e67bc821a3bc55f2c6d877e7e0baa21427333 (patch)
tree5ab53c6026317858aec8b61bf0aec37459247cf5 /examples/examples-servlet
parent84f92b44e70ce27bb4213da677d50ac91169432c (diff)
Improve handling of multiple policy in APEX PDP
Change-Id: Ic4adf5bd8876dc31fc93993298e90389baaa2c39 Issue-ID: POLICY-2883 Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
Diffstat (limited to 'examples/examples-servlet')
-rw-r--r--examples/examples-servlet/src/main/java/org/onap/policy/apex/examples/servlet/ApexServletListener.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/examples/examples-servlet/src/main/java/org/onap/policy/apex/examples/servlet/ApexServletListener.java b/examples/examples-servlet/src/main/java/org/onap/policy/apex/examples/servlet/ApexServletListener.java
index 80ef7354b..3375ff869 100644
--- a/examples/examples-servlet/src/main/java/org/onap/policy/apex/examples/servlet/ApexServletListener.java
+++ b/examples/examples-servlet/src/main/java/org/onap/policy/apex/examples/servlet/ApexServletListener.java
@@ -1,6 +1,7 @@
/*-
* ============LICENSE_START=======================================================
* Copyright (C) 2018 Ericsson. All rights reserved.
+ * Modifications Copyright (C) 2021 Bell Canada. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -75,7 +76,11 @@ public class ApexServletListener implements ServletContextListener {
}
// Initialize apex
- apexMain = new ApexMain(argsList.toArray(new String[argsList.size()]));
+ try {
+ apexMain = new ApexMain(argsList.toArray(new String[argsList.size()]));
+ } catch (ApexException e) {
+ LOGGER.error("Apex Engine initialization failed", e);
+ }
}