Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
-
None
Description
A defect in the following part of the ACO#doAttainState means that an asynchronous exception occurring in a state change method is lost and not propagated back via the future returned to the caller.
final SettableFuture<Void> returnVal = SettableFuture.create(); final ChildCounter counter = new ChildCounter(new Runnable() { @Override public void run() { try { ### If future returned by attainState contains an exception, it is lost. returnVal future completes normally regardless.. attainState().addListener(new Runnable() { @Override public void run() { returnVal.set(null); } }, getTaskExecutor().getExecutor()); } catch(RuntimeException e) { try { exceptionHandler.handleException(e, AbstractConfiguredObject.this); returnVal.set(null); } catch(Throwable t) { returnVal.setException(t); } } } });