Amp Versions Save

A non-blocking concurrency framework for PHP applications. 🐘

v3.0.0-beta.6

2 years ago
  • Added ForbidCloning and ForbidSerialization traits as a convenient way to forbid cloning and/or serialization in a class.

v3.0.0-beta.5

2 years ago
  • Added Closable interface for closable resources such as streams (the interface of the same name will be removed from amphp/byte-stream in a future release) (#387)

v2.6.2

2 years ago
  • Fixed a memory leak in CombinedCancellationToken (#384)

v3.0.0-beta.4

2 years ago

Note: This is a pre-release, there might be breaking changes in the final stable version.

  • Mark Future template parameter as covariant
  • Add compatibility with revolt/event-loop v0.2.x
  • Improve exception message of UnhandledFutureError
  • Cancel DeferredCancellation when destroyed (#382)
  • Rename combinators, introduce CompositeLengthException (#383)
    • raceawaitFirst
    • anyawaitAny
    • someawaitAnyN
    • settleawaitAll
    • allawait
    • The old names have been kept for a migration phase, but will be removed before the final v3 release.

v3.0.0-beta.3

2 years ago

Note: This is a pre-release, there might be breaking changes in the final stable version.

  • Add optional args to Amp\async (#379)

v3.0.0-beta.2

2 years ago

Note: This is a pre-release, there might be breaking changes in the final stable version.

  • Fixed revolt/event-loop dependency declaration to use released ^0.1 version.

v3.0.0-beta.1

2 years ago

Note: This is a pre-release, there might be breaking changes in the final stable version.

Event Loop

Amp no longer ships its own event loop. It's now based on Revolt. Revolt\EventLoop is quite similar to Amp's previous Amp\Loop. A very important difference is using float $seconds instead of int $milliseconds for timers.

Futures

Future is a replacement for the previous Promise. It's await() method is based on fibers and replaces generator based coroutines / Amp\Promise\wait().

  • await() accepts an optional Cancellation, which can be used as a replacement for Amp\Promise\timeout().
  • Unhandled errors are now automatically thrown into the event loop, so there's no need for Amp\Promise\rethrow() anymore.
  • Unhandled errors can be ignored using Future::ignore().

Cancellation

  • CancellationToken has been renamed to Cancellation
  • CancellationTokenSource has been renamed to DeferredCancellation
  • NullCancellationToken has been renamed to NullCancellation
  • TimeoutCancellationToken has been renamed to TimeoutCancellation
  • CombinedCancellationToken has been renamed to CompositeCancellation

v2.6.1

2 years ago
  • Fixed destructor issue in EventDriver (#358)
  • Fixed EventDriver feature configuration to work with different kinds of FDs, e.g. under certain conditions in docker containers (#360)

v2.6.0

2 years ago
  • Add Deferred::isResolved()
  • Implement except handling on Windows (#341)
  • Drop PHP 7.0 support

v2.5.2

3 years ago
  • Ignore only stream_select errors due to signal interruptions (#338) Fixes stream_select handling on signal interruptions on PHP 8 and avoids suppressing errors that shouldn't be suppressed.
  • Improve type definition for combinators (any, first, some) (#334)
  • Removed internal `TimerQueueEntry