Class Unlock

java.lang.Object
org.ores.async.Unlock

public abstract class Unlock extends Object
Token returned to a acquire callback. The holder calls releaseLock() to relinquish the lock and let the next waiter (if any) proceed. Unlike synchronized or ReentrantLock, the release can be invoked from any thread — async.java's lock is callback-based, not thread-affine, which makes it suitable for callback-driven pipelines where the acquire and release frequently happen on different worker threads.

Marked public from 0.2.2 onwards so consumers outside org.ores.async can name the token type in their own lambdas / fields. Before 0.2.2 the class itself was package-private, which effectively made NeoLock unusable from downstream code — a long-latent API-accessibility bug surfaced by dd-spark-pipeline-server's composition-demo pipeline.

  • Constructor Details

    • Unlock

      public Unlock(boolean isImmediate)
  • Method Details

    • releaseLock

      public abstract void releaseLock()