Tascalate Concurrent 0.9.1
This release REPLACES 0.9.0 - the previous one is broken due to severe error in Promises.retry functionality as well as due to breaking changes in Promises.atLeast that should be done in major (0.x) release.
The changes are:
- Critical fix:
Promises.retryfunctionality now restored (was endless loop if retry fails for the given attempts count) - Critical fix: wrappers of
CompletableFuturenow overridesthenCompose[Async](fn)behavior for cancellation -- now the Promise returned from fn is cancelled as well (same as withCompletableTask). - Critical incompatible change:
Promises.atLeastandPromises.atLeastStrictnow returns only successfully completed promises, same asPromises.allandPromises.any[Strict]. If you need to check positions of successfully completed promises please use new methods:Promises.atLeastOrderedandPromises.atLeastOrderedStrict. Both returns list ofj.u.Optional,nullat corresponding position means thatCompletionStagewas settled with an error, non-nullOptionalcorresponds to result (emptyOptionalmeans that original result wasnull). - Get rid of sneaky-throwing exceptions in timeouts handling and for
AsyncCompletions. Generally,AsyncCompletionsnow works likeCompletableFuture.join()for theIterator / Streamof promises. - Variants of
Promises.any[Strict]andPromises.atLeast[Strict]that acceptsj.u.Mapparameter now returns no more elements than it was requested. - Added
RetryCallable.of/RetryRunnable.ofmethods to simplify conversions ofCallable / Runnable - Added
DelayPolicy.withCustomizerto let insert custom implementations ofDelayPolicywrappers in chained fashion. - Added
DependentPromise.as_with more specific function arg type; - Simplified
RetryContextinternals AggregatingPromisenow cancels remaining promises before firing events - to release resources before using results of theAggregatingPromiseitself; also this class is optimized for several usage scenarios.RetryPolicy.exceptionClassRetryableis overridable now;