Promises/A+ implementation that handles promise chaining and resolution iteratively, allowing for "infinite" promise chaining while keeping the stack size constant. A promise represents the eventual result of an asynchronous operation. The primary way of interacting with a promise is through its then method, which registers callbacks to receive either a promise's eventual value or the reason why the promise cannot be fulfilled. Callbacks are registered with the then method by providing an optional $onFulfilled followed by an optional $onRejected function. Resolving a promise means that you either fulfill a promise with a value or reject a promise with a reason. Resolving a promises triggers callbacks registered with the promises's then method. These callbacks are triggered only once and in the order in which they were added.

Features

  • Promises/A+ implementation
  • Promise resolution and chaining is handled iteratively, allowing for "infinite" promise chaining
  • Promises have a synchronous wait method
  • Promises can be cancelled
  • Works with any object that has a then function
  • C# style async/await coroutine promises using GuzzleHttp\Promise\Coroutine

Project Samples

Project Activity

See All Activity >

Categories

Libraries

License

MIT License

Follow Guzzle Promises

Guzzle Promises Web Site

Other Useful Business Software
Cut Cloud Costs with Google Compute Engine Icon
Cut Cloud Costs with Google Compute Engine

Save up to 91% with Spot VMs and get automatic sustained-use discounts. One free VM per month, plus $300 in credits.

Save on compute costs with Compute Engine. Reduce your batch jobs and workload bill 60-91% with Spot VMs. Compute Engine's committed use offers customers up to 70% savings through sustained use discounts. Plus, you get one free e2-micro VM monthly and $300 credit to start.
Try Compute Engine
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Guzzle Promises!

Additional Project Details

Programming Language

PHP

Related Categories

PHP Libraries

Registered

2021-08-13