Consistent MonoToListenableFutureAdapter.cancel()

Issue: SPR-17336
This commit is contained in:
Rossen Stoyanchev
2018-10-09 14:55:04 -04:00
parent 29ff8a8d12
commit bef22ec9b5
2 changed files with 74 additions and 1 deletions

View File

@@ -89,7 +89,8 @@ abstract class AbstractMonoToListenableFutureAdapter<S, T> implements Listenable
return false;
}
this.monoProcessor.cancel();
return true;
// isCancelled may still return false, if mono completed before the cancel
return this.monoProcessor.isCancelled();
}
@Override