Releases: threadly/threadly
7.0 Release
Enhancements:
- Support for JDK 17
- ListenableFutureTask and SettableListenableFuture were re-implemented to provide better compatibility and performance (#256)
Major API version change, breaking changes include:
- Minimum JVM version updated to 11
Deprecation's removed:
ListenableFutureTask
no longer supports a recurring or repeating mode of operation. Because of that theboolean
to define the mode is no longer accepted. If you previously were passing afalse
for this argument it can be simply removed. If recurring execution is needed this can be hacked in easily (and is done within the library in our compatibility layer).- One of
ConfigurableThreadFactory
's constructors has been removed, supplying an additionalnull
argument at the end will match 6.X's functionality. - The above constructor change also was done to
ThreadReferencingThreadFactory
. Supplying an additionalnull
argument at the end will match 6.X's functionality. SameThreadSubmitterExecutor
can no longer be constructed. Internal optimizations require the use ofSameThreadSubmitterExecutor.instance()
- In
Profiler
invocations ofdump
where specifying if individual threads should be included have been removed. Now an additional argument must be specified for the minimum number of times a stack had to be witnessed before it was reported, allowing an even more concise output. Specifying an argument of1
at the end will match 6.X's functionality. UnsafeAccess
was removed to comply with JDK 17 support
The above is summarized in our migration guide: https://github.com/threadly/threadly/wiki/Major-version-migration-guide#6x---7x
Feel free to join our Zulip chat or file an issue if you need help with migration
6.7 Release
6.7 Release is primarily focused around API changes in ListenableFutureTask
. In 7.0 the ability to have a recurring ListenableFutureTask
is removed. For that reason the constructor has been changed to no longer accept a boolean for this recurring state. Assuming a false
was previously provided this argument can now simply be removed.
6.6 Release
Changes included in this release:
- Added to
StatisticsUtils
getMax
andgetMin
implementations in order to find the extreme values in a collection ofNumber
's FutureUtils.makeFirstResultFuture
permutation added where errors are ignored.FutureUtils.makeResultListFuture
wont throw anIllegalStateException
if a dependent future is canceled. Because it needs the results (unless errors are ignored), this is still a fatal condition. However the resulting future will now indicate this state instead of having the Exception thrown.
6.5 Release
-
The constructor for
SameThreadSubmitterExecutor
has been deprecated. This was meant to be done earlier, insteadSameThreadSubmitterExecutor.instance()
should be used. -
ReschedulingOperation
performance improvements by to looping instead of immediately executing if it was signaled while running. This provides a couple improvements:- No need to incur the overhead of queuing and cross thread communication to execute immediately
- When a SameThreadSubmitterExecutor is used this will avoid a possible stack overflow
-
ConfigurableThreadFactory
now has the ability to add a listener to be provided threads as they are created. This can be useful for debugging or other monitoring code which needs to know about threads related to specific pools. Within the threadly libraryControlledThreadProfiler
is a perfect example of how this can be leveraged.
6.4 Release
This release includes:
- Bug fix to
OrderedExecutorLimiter
where canceledListenableFuture
's returned by it could result in aNullPointerException
when sorting the queue. - Implemented issue #270 so that idle ForkJoinPool threads are identified and summarized in output
6.3 Release
Improvements included in this release:
- New constructor in
Profiler
to control how the dump is produced for the ListenableFuture result in a timedstart
. This can be useful when using the timed start and needing to produce large dumps or otherwise concerned about the performance impacts. OrderedExecutorLimiter
was extended to allow the limits to be adjusted at runtime just like theExecutorLimiter
can. If you extendExecutorLimiter
in your application please read the commit notes: a21152e
6.2 Release
Improvements included in this release:
- Added
OrderedExecutorLimiter
. This limiter provides the first way to provide a task ordering besides FIFO. - Minor logic simplifications in workerIdle loop in PriorityScheduler with reduced burdens to check for pool shutdown (now deferring only to the max pool size).
- Fix for
SingleThreadScheduler.prestartExecutionThread
not blocking for the thread to start when invoked concurrently and another thread initiated the start. This is a very small window with no likely noticeable impact, but was still a simple fix.
6.1 Release
Features and improvements in this release:
- To improve safety and make debugging easier, flatMap will set a
NullPointerException
state if the mapper returns anull
future - In
Profiler
the output can be configured to omit stacks which were seen less than X times ListenableFuture
now has the ability to check for an error state without needing anExecutionException
: e55ad5b#diff-43daa81fc2a0173f30f7eee9cd8ea2daR65- The ability to check error conditions directly enabled a number of performance gains, including reduced GC and computation overheads when mapping futures.
6.0 Release (100th release)
6.0 API update release:
-
org.threadly.test.concurrent
package has been moved to a new artifact at the maven coordinatesorg.threadly:threadly-test:1.0
. -
BlockingQueueConsumer
was replaced with a potentially more performantPoller.consumeQueue
or a more direct replacementorg.threadly.concurrent.processing.BlockingQueueConsumer
-
CentralThreadlyPool.lowPriorityPool(boolean)
was replaced with eitherCentralThreadlyPool.lowPrioritySingleThreadPool()
orCentralThreadlyPool.lowPriorityPool()
-
DoNothingRunnable
can not be constructed, insteadDoNothingRunnable.instance()
should be used. -
RunnableCallableAdapter
can not be constructed, instead the static functionRunnableCallableAdapter.adapt
should be used. -
RunnableChain
was moved to the packageorg.threadly.concurrent.wrapper
-
AbstractFutureCallbackFailureHandler
was removed, instead useListenableFuture.failureCallback(Consumer)
-
AbstractFutureCallbackResultHandler
was removed, instead useListenableFuture.resultCallback(Consumer)
-
FutureCallbackExceptionHandlerAdapter
was removed, instead useListenableFuture.failureCallback(Consumer)
(which allows anExceptionHandler
to be passed in) -
FutureCallbackFailureHandler
was removed, instead useListenableFuture.failureCallback(Consumer)
-
FutureCallbackResultHandler
was removed, instead useListenableFuture.resultCallback(Consumer)
-
FutureUtils.scheduleWhileTaskResultNull
was removed, instead just implement a small Predicate with anull
check and useFutureUtils.scheduleWhile
-
Watchdog
was renamed and moved toorg.threadly.concurrent.future.watchdog.ConstantTimeWatchdog
-
WatchdogCache
was renamed and moved toorg.threadly.concurrent.future.watchdog.MixedTimeWatchdog
-
RunnableFutureCallbackAdapter
was removed without replacement (more precise and performant lambda options are used now) -
ListenableScheduledFuture
interface was removed without replacement -
ScheduledFutureDelegate
was removed without replacement -
StripedLock
was removed without replacement -
A variety of deprecated constructors were replaced, see 5.43 javadocs for details on how to migrate to a still supported constructor
We decided to keep this release smaller by limiting the scope to currently exclude:
-
A JVM upgrade will NOT be included, still allowing java 8 and newer.
-
Deeper API considerations previously planned for 6.0 are going to be pushed to potentially a 7.0 release.
5.43 Release
This is the last release before the 6.0 major version bump. This release includes:
- Added
CompletableFutureAdapter
to allow the easy use threadlyListenableFuture
withjava.util.concurrent.CompletableFuture
types. ConstantTimeWatchdog
was improved to reduceClock
updates when there is no futures ready to expire (goes from two clock updates to one)KeyDistributedScheduler
has minor GC overhead improvements for recurring tasks- All classes in
org.threadly.test.concurrent
package are marked as deprecated, now provided from theorg.threadly:threadly-test:0.1
artifact: https://github.com/threadly/threadly-test