Skip to content

Latest commit

 

History

History
123 lines (88 loc) · 9.17 KB

File metadata and controls

123 lines (88 loc) · 9.17 KB

Changelog

All notable changes to this project will be documented in this file.

Unreleased

New features

  • Add bounded MPMC reserve and try_reserve methods returning a borrowed Permit, so callers can wait for capacity before constructing a value; sends and reservations receive capacity in wait-queue order, and unused permits release it.

Bug fixes

  • Prevent deadlocks in singleflight::Group::work and try_work when a duplicate key's destructor calls back into the same group.

Notable changes

  • Executor waker operations, including cloning, waking, and dropping, are expected not to panic; recovery from panicking waker callbacks is no longer supported.

v0.7.3 (2026-09-29)

New features

  • Add event::AutoResetEvent, a reusable signal that releases one waiter, retains at most one unassigned signal that can be cleared with reset, and transfers assigned signals when waits are cancelled.
  • Add ManualResetEvent::try_wait to check readiness without registering a waiter or consuming the set state.
  • Implement broadcast::mpmc::bounded, a lossless bounded broadcast channel that retains at most the requested capacity and makes producers wait for the slowest active receiver.
  • Add opt-in bounded and unbounded asyncband::spmc queues with one non-cloneable sender requiring exclusive access, cloneable competing receivers, and cancellation-safe receive notification handoff.
  • Add opt-in bounded and unbounded asyncband::mpmc queues with cloneable producers and competing consumers, delivering each accepted value to exactly one receiver while a receiver remains.
  • Add an opt-in runtime-agnostic Phaser with shared observer handles, dynamic RAII participants registered individually or in batches through an owning iterator, u64 phase numbers, split arrival/wait with cancellation-resilient retries, and a close operation that releases unfinished waits with Closed.
  • Add bounded MPSC reserve and try_reserve methods returning a Permit, allowing callers to wait for capacity before constructing a message; pending sends and reservations receive capacity in wait-queue order, and unused permits release capacity without claiming message order.

Bug fixes

  • Complete semaphore permit releases and notify all eligible waiters even if a wake callback panics.
  • Release MPSC receiver wakers when the receiver is dropped, avoiding retained tasks and ownership cycles when a waker holds a sender.
  • Notify all blocked bounded MPSC senders on receiver disconnection even when a buffered message destructor panics.

Improvements

  • Allow Condvar waits with unsized mutex contents, including slices and trait objects, for both borrowed and owned guards.
  • Allow manual unbounded pools to use non-Send factory closures with get_or_create, including factories that borrow task-local state.
  • Allow watch::channel to store non-Clone values for publication and change notification; only owning reads through Receiver::get and Receiver::recv require Clone.
  • Finish releasing buffered bounded MPSC messages even if one message destructor panics.
  • Improve unbounded MPSC throughput with batched receiving and incremental storage reclamation; empty-buffer retention is bounded independently of previous peak occupancy.
  • Make completed and abandoned Completion waits lock-free while preserving cancellable pending registration.
  • Reduce allocations when notifying waiters in Barrier, broadcast, condvar, event, MPSC, and watch.

v0.7.2 (2026-09-11)

Improvements

  • Preserve applicable third-party licensing and copyright notices on derived source files, and record exact provenance mappings in LICENSE and source comments.

v0.7.1 (2026-09-04)

This is an interim non-ASF release. It has not been approved by the Apache Incubator PMC and is not an act of the Apache Software Foundation.

Bug fixes

  • Correct source-header treatment and make third-party derivation and test provenance records more precise in source distributions.

v0.7.0 (2026-09-04)

This non-ASF release was not approved by the Apache Incubator PMC, is not an act of the Apache Software Foundation, and has been yanked from crates.io.

Breaking changes

  • Gate all exported primitives behind opt-in Cargo features and enable no features by default; downstream dependencies must explicitly enable the APIs they use.
  • Raise the minimum supported Rust version from 1.85.0 to 1.86.0.
  • Remove the admission module, including FairShare, FairSharePermit, and OwnedFairSharePermit.
  • Remove the asyncband::atomicbox module and its AtomicBox and AtomicOptionBox types from the public API.
  • Remove the lossy broadcast::overflow channel; use the new lossless broadcast::mpmc::unbounded channel instead.
  • Remove OnceMap::with_capacity and OnceMap::with_capacity_and_hasher; use OnceMap::new or OnceMap::with_hasher, which allocate the backing table lazily.
  • Remove the unconstructible LatchWait and OwnedLatchWait types from the public API; Latch::wait and Latch::wait_owned continue to return anonymous futures through their async fn signatures.
  • Rename oneshot::Sender::is_closed and oneshot::Receiver::is_closed to is_disconnected.
  • Remove Semaphore::try_acquire_and_forget, Semaphore::acquire_and_forget, Semaphore::try_acquire_owned_and_forget, and Semaphore::acquire_owned_and_forget; acquire a permit and call its forget method instead.
  • Replace Semaphore::forget with Semaphore::drain_permits and Semaphore::forget_exact with Semaphore::reduce_permits; permit-level forget methods are unchanged.
  • Redesign graceful shutdown: rename ShutdownSend and ShutdownRecv to Shutdown and ShutdownGuard, and shutdown::new_pair to shutdown::new; replace ShutdownSend::shutdown with Shutdown::request_shutdown and ShutdownSend::await_shutdown with awaiting Shutdown; rename is_shutdown_now, is_shutdown, and is_shutdown_owned to is_shutdown_requested, shutdown_requested, and shutdown_requested_owned; and add ShutdownGuard::into_watch.

New features

  • Implement broadcast::mpmc::unbounded, an unbounded broadcast channel that retains messages until all active receivers consume them or are dropped.
  • Add an opt-in clone-based latest-state channel under asyncband::watch, including retained replacement updates through Sender::send_replace.
  • Add opt-in asyncband::event::ManualResetEvent, a reusable level-triggered signal that releases registered waits and remains ready for future waits until explicitly reset.
  • Add an opt-in shared one-shot completion primitive under asyncband::completion with a single-use completer, cloneable observers, a retained borrowed result, and observable abandonment.
  • Add opt-in asyncband::once::LazyCell for values that own one asynchronous initializer and preserve its in-flight future across caller cancellation.
  • Add opt-in bounded and unbounded runtime-agnostic object pools under asyncband::pool.
  • Add an opt-in asyncband::blocking::FutureExt bridge with block_on and wait_timeout methods for waiting on runtime-agnostic futures from synchronous code.

Bug fixes

  • Reject semaphore permit merges whose combined count exceeds usize::MAX instead of wrapping and losing permits.
  • Release cancelled wait registrations promptly and reclaim fulfilled Semaphore::reduce_permits debt nodes.
  • Preserve fan-out notifications, including semaphore permit grants, when one registered waker panics.

Improvements

  • Reduce fan-out notification overhead by avoiding heap allocation for a single waiter and transferring terminal waiter storage out of state locks.
  • Reduce MPSC receiver registration and wake latency by storing receiver wakers inline instead of allocating them on the heap.
  • Reduce semaphore and mutex hot-path overhead by avoiding wake-buffer allocation when no tasks are queued and batching queued wakes on the stack.
  • Allocate OnceMap and singleflight::Group registries lazily to reduce construction overhead.
  • Describe disconnected channel states consistently in channel error messages.
  • Avoid fixed CPU spinning before registering WaitGroup, Latch, and Once waiters.
  • Specialize WaitGroup's one-shot completion state to reduce handle registration and multi-waiter notification overhead while preserving cancellable multi-observer waits.
  • Reduce waiter state and notification overhead across Barrier, broadcast, completion, Latch, Once, and watch by reusing each primitive's existing lifecycle state instead of maintaining duplicate waiter epochs.