commit | 212995442cc8b4b5b2c12b95cf4d6eaac345c223 | [log] [tgz] |
---|---|---|
author | Pamela Dragosh <pdragosh@research.att.com> | Mon Feb 11 13:24:29 2019 +0000 |
committer | Gerrit Code Review <gerrit@onap.org> | Mon Feb 11 13:24:29 2019 +0000 |
tree | 4a4573b1d991d6fcb369234cc99c6ac8bea8c2d8 | |
parent | 7f1be8710503b4c34a49c96be8a6818757499bd6 [diff] | |
parent | cc4897a71480906b33e1c27d1b48b5a9017f86aa [diff] |
Merge "Return true only if thread has been really started"
diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedBusTopicSource.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedBusTopicSource.java index 4cc8fbb..83f3760 100644 --- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedBusTopicSource.java +++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/SingleThreadedBusTopicSource.java
@@ -172,6 +172,7 @@ this.busPollerThread = makePollerThread(); this.busPollerThread.setName(this.getTopicCommInfrastructure() + "-source-" + this.getTopic()); busPollerThread.start(); + return true; } catch (Exception e) { logger.warn("{}: cannot start because of {}", this, e.getMessage(), e); throw new IllegalStateException(e); @@ -179,7 +180,7 @@ } } - return this.alive; + return false; } /**