JavaMutex Changelog

What's new in JavaMutex 2016-12-06a

Feb 2, 2016
  • Minor improvements in SpinLockWaitList, SpinLockWaitListLong.
  • Minor cosmetic improvements in SpeedLock and friends.

New in JavaMutex 2015-05-21c (May 22, 2015)

  • Atomic.test.DiningPhilosopher minor cosmetic and efficiency
  • improvements.
  • SpinLockOperation.compareMultipleAndSwap added bit mask array
  • for overloaded methods for int[] and long[].

New in JavaMutex 2015-05-19a (May 20, 2015)

  • AtomicInteger added compareAndSwap with a mask.
  • AtomicLong added compareAndSwap with a mask.
  • SpinLockInteger added compareAndSwap with a mask.
  • SpinLockLong added compareAndSwap with a mask.
  • SpinLockOperation added compareAndSwap with a mask for int and long operations.

New in JavaMutex 2015-05-07a (May 8, 2015)

  • Added 2 methods to ExtendedScheduledExecutorService and WorkPool to provide a preConditional and postConditional
  • BooleanSupplier to control invoking the repeating task and rescheduling the repeating task.

New in JavaMutex 2015-05-03a (May 4, 2015)

  • Added another method to ExtendedExecutorService and WorkPool to submit an array of Runnable tasks as a single task.

New in JavaMutex 2015-05-01a (May 2, 2015)

  • Added methods to ExtendedExecutorService and WorkPool to submit an array of Runnable tasks as a single task.

New in JavaMutex 2015-04-28a (Apr 30, 2015)

  • Added FutureWork static methods to compose Runnable instances and to apply function transformation to a Callable instance. This for chaining multiple operations into a single Runnable or Callable instance.

New in JavaMutex 2015-04-28a (Apr 30, 2015)

  • Added FutureWork static methods to compose Runnable instances and to apply function transformation to a Callable instance. This for chaining multiple operations into a single Runnable or Callable instance.

New in JavaMutex 2015-04-20a (Apr 25, 2015)

  • ExtendedScheduledExecutorService added API for conditionally repeating the scheduled task. Updated accordingly the WorkPool implementation.

New in JavaMutex 2015-04-12a (Apr 14, 2015)

  • Refactored PortalDelayed and RunnableWrapper in the parallel

New in JavaMutex 2015-04-08a (Apr 9, 2015)

  • Fix termination detection path in PortalDelayed.

New in JavaMutex 2015-04-03a (Apr 6, 2015)

  • Minor code path improvements in WorkPool.

New in JavaMutex 2015-04-02a (Apr 3, 2015)

  • Minor code improvements in WorkPool. Added annotations.

New in JavaMutex 2015-03-20b (Mar 21, 2015)

  • Add WorkPool.createScheduledExecutorService() and friends to support ScheduledExecutorService for delayed and periodic tasks.
  • Add ExtendedRunnableScheduledFuture interface.
  • Add ExtendedScheduledExecutorService interface.

New in JavaMutex 2015-03-06a (Mar 7, 2015)

  • Add WorkPool.getWorkPoolName().

New in JavaMutex 2015-03-02a (Mar 3, 2015)

  • WorkPool.createWorkUnit() is now public.
  • Added a flag RestartOnFail to createWorkPool method to set a WorkUnitEnd callback outine to create a fresh WorkUnit and restart the failed worker with a fresh thread instance.
  • Added parallel.test.TestRestart test case.

New in JavaMutex 2015-02-25a (Feb 26, 2015)

  • Added getWorkUnits(), forEach() methods to WorkPool.

New in JavaMutex 2015-02-24a (Feb 26, 2015)

  • Added methods to WorkPool for get/set of the WorkUnitStart
  • and WorkUnitEnd references.

New in JavaMutex 2015-02-21a (Feb 23, 2015)

  • Added 2 methods to ExtendedExecutorService to create the CompletionService and ExtendedCompletionService instances from the current instance of ExtendedExecutorService.
  • Updated WorkPool for the ExtendedExecutorService changes.
  • Updated WorkUnit to report the Throwable that ended the task (or null for normal completion).

New in JavaMutex 2015-02-20a (Feb 21, 2015)

  • parallel package added WorkUnitEnd, WorkUnitStart interfaces and adjusted WorkPool, WorkUnit, and WorkUnitFactory to pass the owning WorkPool reference to the WorkUnit.

New in JavaMutex 2015-02-17a (Feb 18, 2015)

  • Minor cosmetic javadoc clean-up.

New in JavaMutex 2015-02-06a (Feb 7, 2015)

  • TestMultiServer streamlined class structure, removed unused references, moved ServicesDirectory population to the Server constructors.

New in JavaMutex 2015-02-04a (Feb 5, 2015)

  • Clean up javadoc.
  • Clean up TestMultiServer.
  • Clean up server package.

New in JavaMutex 2015-02-03a (Feb 4, 2015)

  • TestMultiServer refactored out the common server base classes to a new package concurrent.server.

New in JavaMutex 2015-01-24a (Jan 26, 2015)

  • TestMultiServer converted servers to use private persistent data table, instead of global (static) data fields. Removed getXXXX() methods when there is direct accessibility to the
  • underlying final field.

New in JavaMutex 2015-01-23c (Jan 24, 2015)

  • TestMultiServer adjusted transformation paradigm to support separately updating the global value, while returning a different value to the client. This is for operations like
  • getAndSet that retrieves the current value for the client and updates the global value with a computed result.

New in JavaMutex 2015-01-19a (Jan 20, 2015)

  • TestMultiServer added service parameters for modifying the "apple" and "prune" server values with optional bit masks and increment.

New in JavaMutex 2015-01-14a (Jan 16, 2015)

  • WorkPool removed maximum thread limit.

New in JavaMutex 2015-01-12b (Jan 13, 2015)

  • TestMultiServer renamed Server Beta to Server Gamma.
  • TestMultiServer added ServiceData.terminus() method to perform clean-up for either normal or cancellation paths.

New in JavaMutex 2015-01-07b (Jan 10, 2015)

  • Minor code clean-up in EventTokenSet.
  • Use diamond notation for instanting an object with
  • generic reference type. Multiple class sources updated.

New in JavaMutex 2014-12-29c (Dec 30, 2014)

  • Bug fixes in WorkPool, FutureWork.

New in JavaMutex 2014-12-28a (Dec 29, 2014)

  • Add preliminary support for ExecutorService to WorkPool.
  • Add FutureWorkStart, FutureWorkEnd interfaces for callback when a FutureWork starts and when it ends.

New in JavaMutex 2014-03-17a (Mar 27, 2014)

  • Minor javadoc cleanup.

New in JavaMutex 20130601b (Jun 3, 2013)

  • Removed useless static methods from SynchronousQueue.

New in JavaMutex 20130523a (May 24, 2013)

  • Minor JavaDoc changes.

New in JavaMutex 20130419a (Apr 20, 2013)

  • SynchronousQueue: added more static methods for creating wrapped
  • ReceivePipe and TransmitPipe from their respective Factory instances.

New in JavaMutex 20130418a (Apr 19, 2013)

  • Semaphore class removed "final" tags from public methods to allow for subclass overriding for instrumentation.

New in JavaMutex 20130416a (Apr 17, 2013)

  • Changed TestTransceivePipe to use a dedicated output processing Thread that uses ReceivePipe to receive String messages from the worker threads.
  • Changed the worker threads to use a TransmitPipe to send String messages to the output thread instead of directly printing to System.out.
  • The program shows how to use TransceivePipe, TransmitPipe, and ReceivePipe to send and get messages between a network of asynchronous Thread.
  • Minor cosmetic javadoc changes to SynchronousQueue.

New in JavaMutex 20130414b (Apr 15, 2013)

  • Minor cosmetic code changes in SynchronousQueue.

New in JavaMutex 20130411a (Apr 12, 2013)

  • Minor code rearrange in SynchronousQueue. Cosmetic javadoc changes.
  • Minor code rearrange in TrafficBarrier. Cosmetic javadoc changes.

New in JavaMutex 20130409a (Apr 10, 2013)

  • SynchronousQueue updated static methods createTransmitPipeFactory and createReceivePipeFactory to create instances that are wrapped to prevent casting to the implementing class.
  • SynchronousQueue updated static methods createTransceivePipeFactory to create instances that are wrapped to prevent casting to the implementing class.

New in JavaMutex 20130408a (Apr 9, 2013)

  • Added factory interfaces for TransceivePipeFactory, ReceivePipeFactory, and TransmitPipeFactory.
  • Added static methods to SynchronousQueue to create instances of TransferPipeFactory, ReceivePipeFactory, and TransmitPipeFactory.

New in JavaMutex 20130405a (Apr 5, 2013)

  • Fixed a bug in SynchronousPipe that reported the wrong number of awaiting producer threads (inverted 0 versus 1).

New in JavaMutex 20130401a (Apr 2, 2013)

  • Bit the bullet and renamed TransceiveQueue, TransmitQueue,
  • and ReceiveQueue to TransceivePipe, TransmitPipe, and ReceivePipe.
  • They are not really a "Queue", so I renamed them to avoid confusion.

New in JavaMutex 20130117a (Jan 18, 2013)

  • Minor cosmetic improvements in SynchronousQueue.

New in JavaMutex 20130114a (Jan 15, 2013)

  • Changed method and field names with "Pending" to "Awaiting" in TrafficBarrier and Street to conform better to the "awaiting" status of the thread.

New in JavaMutex 20130106a (Jan 7, 2013)

  • Added getTerminate() and setTerminate(boolean) for Street to inhibit accessing that particular Street reference.

New in JavaMutex 20130102a (Jan 3, 2013)

  • Fixed more bad JavaDoc in SynchronousQueue.

New in JavaMutex 20121226a (Dec 27, 2012)

  • Fixed more bad JavaDoc in SynchronousQueue.

New in JavaMutex 20121219a (Dec 20, 2012)

  • Fixed Exception propagation in SynchronousQueue to reinstate deferred interrupt before percolating.

New in JavaMutex 20121218b (Dec 19, 2012)

  • Added constructors to SynchronousQueue.

New in JavaMutex 20121207a (Dec 8, 2012)

  • Moved the explicit test for pending interrupt in ReenterableLockAbstract after the test for reentrant acquisition. Now the pending interrupt is not recognized for reentrant accesses, because there is no waiting.

New in JavaMutex 20121204a (Dec 4, 2012)

  • Minor code path improvements in TrafficBarrier.

New in JavaMutex 20121119b (Nov 20, 2012)

  • Adjusted some fields and methods in inner protected classes from protected to public to differentiate members that are intended for accessing outside of the inner protected versus accessed strictly from within the inner protected class.
  • Changed some static int fields in HoldState to be self-defining integers, instead of assigned within a static initializer.

New in JavaMutex 20121118a (Nov 19, 2012)

  • Fixed enqueueing bug in TrafficBarrier that caused a memory leak.
  • Added more internal closure API to TrafficBarrier for reducing code duplication.
  • Added assertion mode testing for TrafficBarrier deadlock detection.

New in JavaMutex 20121116a (Nov 17, 2012)

  • Added more internal closure API to TrafficBarrier for reducing code duplication.

New in JavaMutex 20121028a (Oct 29, 2012)

  • Minor cosmetic clean-up in TrafficBarrier.

New in JavaMutex 20121011a (Oct 12, 2012)

  • Minor cosmetic changes to JavaDoc.

New in JavaMutex 20121009a (Oct 10, 2012)

  • ConditionClosureAbstract now calls Thread.yield() immediately after releasing the Lock to allow lock waiters to proceed. This is for improving responsiveness for 0L time awaiters.
  • Minor cosmetic changes for TransferPipeAbstract.

New in JavaMutex 20121007c (Oct 8, 2012)

  • Fixed a bug introduced by refactoring TransferPipeAbstract.

New in JavaMutex 20121005c (Oct 6, 2012)

  • Fixed SynchronousPipe.produce(obj,0L) to release and reacquire the lock to allow an awaiting consumer to take the reference.

New in JavaMutex 20121004b (Oct 5, 2012)

  • Added interface TransferPipe and implementing class SynchronousPipe
  • for producer-consumer designs.

New in JavaMutex 20120928a (Sep 29, 2012)

  • Fixed another error path in TrafficBarrier.

New in JavaMutex 20120926b (Sep 27, 2012)

  • Refactored TrafficBarrier.gatherThreads closure to separate
  • eligibility test for StreetTrack and for Track.
  • Renamed TrafficBarrier.StreetTrack to StreetNode.
  • Fixed some error path code in TrafficBarrier.

New in JavaMutex 20120925a (Sep 26, 2012)

  • Added getThreadsPending() and interruptPending() methods to
  • Street and TrafficBarrier. Revised internal closure API.

New in JavaMutex 20120923d (Sep 24, 2012)

  • Made consistent the internal locking for TrafficBarrier and Street
  • methods interrupt() and getThreads().

New in JavaMutex 20120921d (Sep 22, 2012)

  • Renamed TrafficBarrier internal locking methods for consistency with the ReenterableLock interface.

New in JavaMutex 20120920c (Sep 21, 2012)

  • Fixed interrupt detection in ConditionClosureAbstract.awaitNanos(long) method.

New in JavaMutex 20120915a (Sep 17, 2012)

  • Fixed a deadlock issue in TrafficBarrier.

New in JavaMutex 20120911b (Sep 12, 2012)

  • Added a test case for TrafficBarrier to test 2 pairs
  • of threads accessing 2 streets.

New in JavaMutex 20120910b (Sep 11, 2012)

  • Refactored TrafficBarrier.Street into a top level interface.

New in JavaMutex 20120822a (Aug 23, 2012)

  • Fixed the timed await loop in CountDownAwait(long) to correctly adjust the remaining duration.

New in JavaMutex 20120820a (Aug 21, 2012)

  • Added another broken barrier test in CountDownLatch.await() methods.

New in JavaMutex 20120809a (Aug 13, 2012)

  • Fixed the duration translation in countDownAndAwait(long,TimeUnit).

New in JavaMutex 20120712a (Jul 13, 2012)

  • Added ConditionIntersectPathway, IntersectPathway API for creating a Condition object with an implied accessor Pathway.
  • Updated Intersect to add a new method createCondition to create a Condition object using the specified IntersectPathway reference to obtain the currently accessing Pathway.
  • Updated IntersectLatch to support the new method.

New in JavaMutex 20120511a (May 12, 2012)

  • More minor editorial changes to the JavaDoc in the locks package.

New in JavaMutex 20120509a (May 10, 2012)

  • Updated the Atomic and SpinLock methods in the atomic package. Updated SpinLockOperation to add compareAndSet methods for int, long, and reference types. The SpinLockInteger, SpinLockLong, and SpinLockReference methods now use VolatileInt, VolatileLong, and VolatileReference wrappers. The classes are updated to use SpinLockOperation.compareAndSet methods.
  • Some minor editorial changes to the locks package.

New in JavaMutex 20110810a (Aug 11, 2011)

  • Fixed CellPoolAnchor.deactivate() method to pre-fetch the next CellPoolExtent before deactivating the current extent. If the current extent is set for auto-disconnect, then the next extent pointer is null upon return from CellPoolExtent.deactivate().

New in JavaMutex 20110524a (May 25, 2011)

  • Cosmetic change to CellPoolAnchor and CellPoolExtent to move the
  • definition of the static singleton array EMPTY_ARRAY_CELL_POOL_EXTENT
  • from CellPoolAnchor to CellPoolExtent and create a reference in CellPoolAnchor.

New in JavaMutex 20101229b (Dec 30, 2010)

  • Added compareDoubleAndFetch, compareDoubleAndStore methods
  • to SpinLockOperation class for consistency with other methods that
  • support arrays and single parameters for source, target.

New in JavaMutex 20101020a (Dec 21, 2010)

  • Minor code changes to shorten some code paths in Intersect and
  • friends.

New in JavaMutex 20101015a (Oct 16, 2010)

  • Minor code changes SpinLockOperation class for local variable
  • naming consistency. No functional changes.

New in JavaMutex 20101014a (Oct 15, 2010)

  • Minor code changes SpinLockOperation class to nullify dangling references.

New in JavaMutex 20101011a (Oct 12, 2010)

  • Minor code movement in SpinLockOperations class methods to move comparand[0] access before the SpinLock acquisition to test for array element availability.
  • This reduces the probability of throwing an ArrayIndexOutOfBoundsException while hold the SpinLock.

New in JavaMutex 20101002a (Oct 4, 2010)

  • Fixed more JavaDoc in SpinLockOperation class.

New in JavaMutex 20100927a (Sep 28, 2010)

  • Simplified the code paths in ConditionClosureAbstract regarding the management of a ConditionControl instance.

New in JavaMutex 20100917a (Sep 18, 2010)

  • Minor JavaDoc improvements.
  • Minor code re-organization in the CellPool package; no functional changes.

New in JavaMutex 20100915a (Sep 16, 2010)

  • Minor JavaDoc improvements.
  • Minor code re-organization; no functional changes.

New in JavaMutex 20100907a (Sep 8, 2010)

  • Minor JavaDoc improvements.
  • ConditionClosureAbstract methods improved to allow unexpected exceptions
  • to percolate up the stack.

New in JavaMutex 20100823a (Aug 24, 2010)

  • Fixed timed access in IntersectLimited.PathwayLimited to release the semaphore upon failed access attempt.

New in JavaMutex 20100820a (Aug 21, 2010)

  • Minor JavaDoc improvements.
  • Minor code clarification changes.
  • This is yet another final stabilized release of this library.
  • Only bug fixes and JavaDoc improvements will be considered while the Java community reviews this library. Requests for new features and functionality will be considered during the maturity period.

New in JavaMutex 20100805a (Aug 6, 2010)

  • Added utility class SpinLockYield to create a wrapper for SpinLockFactory. The wrapper wraps the SpinLock instances with calls to Thread.yield() to reduce the probability of
  • preemption while holding the spin lock.
  • Updated SpinLockGeneral and SpinLockPair to add dispenser
  • methods for SpinLockFactory that wrap the instance with
  • SpinLockYield wrappers. The client should use these dispensers
  • in preference to the SpinLockYield wrapper utility methods to
  • reduce the probability that the application would use both
  • the factory underlying instance and the wrapper instance.

New in JavaMutex 20100804a (Aug 5, 2010)

  • No code changes.
  • Minor JavaDoc improvements.
  • Minor internal commentary changes.

New in JavaMutex 20100726b (Jul 28, 2010)

  • Added SpinLockOperation.getSpinLockFactory() instance method to
  • return the SpinLockFactory instance of the implied SpinLock.
  • The client may compare (by equality of instance pointers) the SpinLockFactory
  • references of two distinct SpinLockOperation instances to determine
  • whether the SpinLockOperation instances synchronize the same logical
  • resource.

New in JavaMutex 20100726a (Jul 27, 2010)

  • Added SpinLockOperation methods for compareDoubleAndFetch, compareDoubleAndStore, compareMultipleAndFetch, compareMultipleAndStore.

New in JavaMutex 20100718b (Jul 19, 2010)

  • Renamed and refactored LockAvailable to ReenterableLockAvailable
  • to maintain consistency with other similar API.

New in JavaMutex 20100716b (Jul 17, 2010)

  • Changed the parameter type from Lock to ReenterableLock in
  • LockAvailable.lockAvailable method signature.

New in JavaMutex 20100714b (Jul 15, 2010)

  • Minor JavaDoc improvements to SpinLock.
  • Added "final" qualifier to implementations of SpinLock
  • methods tryAcquire(), acquire(), and release() in
  • SpinLockGeneral and SpinLockPair classes. In some JVMs,
  • this qualifier will improve the time required to look up
  • the method at run time.
  • Fixed JavaDoc links to deleted condition support classes.

New in JavaMutex 20100713a (Jul 14, 2010)

  • Updated package JavaDoc for concurrent and locks packages.
  • Fixed a potential deadlock in ConditionClosureAbsract.
  • Deleted the broken deprecated classes ConditionAbstract,
  • ConditionReenterableLock, ConditionReenterableDualLock, and
  • LatchConditionRequestor.

New in JavaMutex 20100707a (Jul 8, 2010)

  • Refactor Intersect, Pathway and friends into the locks package.
  • Added acquisition count parameters for access, release methods
  • in the Intersect, Pathway and friends.

New in JavaMutex 20100705a (Jul 6, 2010)

  • Clean-up more JavaDoc in SpinLockOperation.
  • Improve generic types in SpinLockOperation.

New in JavaMutex 20100629b (Jun 30, 2010)

  • Fixed some JavaDoc in IntersectLatch and IntersectLimited.

New in JavaMutex 20100626a (Jun 28, 2010)

  • Added SpinLockOperation methods for compareDoubleAndFetch, compareDoubleAndStore, compareMultipleAndFetch, compareMultipleAndStore.

New in JavaMutex 20100622d (Jun 23, 2010)

  • Fixed some JavaDoc in IntersectLatch and IntersectLimited.
  • Minor code changes for clarity in IntersectLatch, IntersectLimited

New in JavaMutex 20100621c (Jun 22, 2010)

  • More clarification of SpinLockOperation JavaDoc.
  • Added loadDouble and loadMultiple methods to complement the
  • compare-and-swap methods in SpinLockOperation. These methods are
  • for atomically marshalling a consistent set of the initial comparand
  • values from the volatile comparators.
  • Added compareAndFetch methods for marshalling an array of
  • volatile values of int, long, or reference type, while verifying
  • the serial number.