awesome-repositories.com
博客
MCP
awesome-repositories.com

通过 AI 驱动的搜索,发现最优秀的开源仓库。

探索精选搜索开源替代品自托管软件博客网站地图
项目关于排名机制媒体报道MCP 服务器
法律隐私政策服务条款
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
guzzle avatar

guzzle/promises

0
View on GitHub↗
7,717 星标·126 分支·PHP·MIT·2 次浏览

Promises

This project is a PHP implementation of the Promises/A+ specification, providing a library for managing asynchronous operations and deferred values. It serves as an asynchronous task coordinator that allows for the creation of non-blocking code through a promise-based pattern.

The library enables the simulation of asynchronous coroutines, allowing non-blocking code to be written in a linear style. It features duck-typed interoperability, which allows it to integrate with any foreign object that implements a then method regardless of class inheritance.

The project covers broader capabilities including task orchestration, concurrent request management with concurrency limits, and the coordination of operation chains. It includes a global queue for executing pending handlers to maintain a constant stack size and a mechanism to force synchronous completion when a final value must be retrieved.

Features

  • Specification Compliance - Implements the standardized Promises/A+ specification to ensure interoperability between different promise libraries.
  • Asynchronous Task Managers - Serves as a framework for coordinating concurrent non-blocking tasks and their eventual resolution within a PHP environment.
  • Promise Implementations - Provides a standard-compliant promise implementation for writing non-blocking code and handling deferred values in PHP.
  • Event Loop Integration - Processes a global queue of pending operations to maintain constant stack size while integrating with the event loop.
  • Event Loop Integrations - Implements a global queue for pending handlers to ensure compatibility with asynchronous event-driven runtimes in PHP.
  • Linear Asynchronous Syntax - Simulates asynchronous await patterns to allow non-blocking code to be written in a linear, synchronous-looking style.
  • Asynchronous Flow Coordination - Coordinates multiple concurrent tasks and their eventual resolution using a promise-based system.
  • Asynchronous PHP Development - Provides a comprehensive toolkit for managing non-blocking operations and concurrent tasks in PHP.
  • Manual Promise Resolution - Triggers the fulfillment or rejection of pending tasks by delivering specific values or errors to callbacks.
  • Promise-Based Chains - Links asynchronous operations into sequences that automatically propagate results and errors.
  • Asynchronous Operation Chaining - Implements a sequential execution pipeline by returning new promise objects from handlers.
  • Queue-Based Handler Dispatch - Processes resolved callbacks through a global task queue to prevent stack overflow during execution.
  • Execution Queues - Utilizes an execution queue to process pending promise handlers and ensure compatibility with the event loop.
  • Handler Execution Queues - Utilizes a global queue to process pending promise handlers, maintaining a constant stack size during execution.
  • Dependency-Aware Task Orchestration - Orchestrates the execution order of asynchronous tasks based on dependency constraints through promise chaining.
  • PHP Coroutine Runtimes - Enables writing non-blocking PHP code in a linear style by simulating asynchronous coroutines.
  • Task Schedulers - Provides mechanisms for scheduling background operations and managing execution timing through external queue injection.
  • Foreign Promise Interoperability - Integrates foreign objects implementing the then method to allow disparate promise libraries to work together.
  • Synchronous Value Extractors - Offers a mechanism to force synchronous completion of a promise to retrieve the final value or throw an exception.
  • Synchronous Execution Blocking - Provides mechanisms to hold the execution thread open until an asynchronous task completes.
  • Duck Typing Patterns - Integrates foreign objects using behavior-based matching by checking for a then method instead of class inheritance.
  • Forced Synchronous Completion - Provides a mechanism to block execution until a promise resolves to retrieve the final value synchronously.
  • Sequential Task Execution - Executes a collection of promises according to a specified concurrency limit to ensure orderly execution.
  • Asynchronous Task Executors - Allows the definition of custom queues to control the dispatch and execution of asynchronous futures.
  • Concurrent Request Limits - Provides mechanisms to restrict the absolute number of active concurrent asynchronous operations to optimize resource usage.
  • Update Completion Promises - Blocks execution until an asynchronous operation completes to return a final value or throw an exception.

Star 历史

guzzle/promises 的 Star 历史图表guzzle/promises 的 Star 历史图表

AI 搜索

探索更多 awesome 仓库

用简单的语言描述您的需求 —— AI 将根据相关性为您从数千个精选开源项目中进行排序。

Start searching with AI

常见问题解答

guzzle/promises 是做什么的?

This project is a PHP implementation of the Promises/A+ specification, providing a library for managing asynchronous operations and deferred values. It serves as an asynchronous task coordinator that allows for the creation of non-blocking code through a promise-based pattern.

guzzle/promises 的主要功能有哪些?

guzzle/promises 的主要功能包括:Specification Compliance, Asynchronous Task Managers, Promise Implementations, Event Loop Integration, Event Loop Integrations, Linear Asynchronous Syntax, Asynchronous Flow Coordination, Asynchronous PHP Development。

guzzle/promises 有哪些开源替代品?

guzzle/promises 的开源替代品包括: stefanpenner/es6-promise — es6-promise is an ES6 promise polyfill and JavaScript compatibility layer. It provides a standardized interface for… reactphp/reactphp — ReactPHP is an asynchronous runtime and event-driven I/O framework for PHP. It provides an environment for executing… alibaba/coobjc — coobjc is an Objective-C coroutine library that provides await methods and generators to simplify asynchronous… nodejs/nan — This project is a compatibility layer and abstraction library for building native C++ addons for Node.js. It provides… boltsframework/bolts-android — Bolts-Android is a mobile development library for Android that provides a framework for deep-linking and a system for… amphp/amp — Amp is a non-blocking concurrency framework for PHP. It provides a core infrastructure for writing asynchronous…

Promises 的开源替代方案

相似的开源项目,按与 Promises 的功能重合度排序。
  • stefanpenner/es6-promiseS

    stefanpenner/es6-promise

    7,263在 GitHub 上查看↗

    es6-promise is an ES6 promise polyfill and JavaScript compatibility layer. It provides a standardized interface for managing asynchronous flow control and background tasks in environments that lack native support for the ES6 Promise specification. The project serves as a bridge to ensure consistent asynchronous behavior across different browser engines and legacy environments. It includes utilities for global promise injection and polyfilling, which add the implementation to the global namespace for application-wide availability. The library covers the coordination of asynchronous workflows,

    JavaScript
    在 GitHub 上查看↗7,263
  • reactphp/reactphpreactphp 的头像

    reactphp/reactphp

    9,091在 GitHub 上查看↗

    ReactPHP is an asynchronous runtime and event-driven I/O framework for PHP. It provides an environment for executing concurrent tasks through a central event loop implementation and reactor pattern, allowing applications to handle multiple operations without pausing the main execution thread. The project includes a specialized asynchronous socket library for TCP, UDP, and TLS communication, alongside a non-blocking HTTP server and client for streaming web requests and responses. Its capability surface covers asynchronous control flow via promises and fibers, non-blocking network connectivity

    PHP
    在 GitHub 上查看↗9,091
  • alibaba/coobjcalibaba 的头像

    alibaba/coobjc

    4,016在 GitHub 上查看↗

    coobjc is an Objective-C coroutine library that provides await methods and generators to simplify asynchronous programming in Objective-C and Swift. It enables the implementation of non-blocking workflows to eliminate nested callbacks and thread blocking. The toolkit includes a non-blocking Foundation wrapper to convert synchronous Foundation and UIKit APIs into suspendable operations. It provides a lazy sequence generator for producing values on demand via yield, as well as a channel-based communication tool for exchanging data between concurrent tasks using buffered and unbuffered channels.

    Objective-Cactoractor-modelarm64
    在 GitHub 上查看↗4,016
  • nodejs/nannodejs 的头像

    nodejs/nan

    3,351在 GitHub 上查看↗

    This project is a compatibility layer and abstraction library for building native C++ addons for Node.js. It provides a consistent C++ API that allows a single codebase to compile against multiple versions of the V8 JavaScript engine by hiding version-specific differences behind macros and inline functions. The toolkit differentiates itself through specialized wrappers and managers, including a monadic wrapper for handles to avoid explicit null checks, a persistent reference manager for objects that must survive handle scope disposal, and a buffer abstraction API for version-compatible memory

    C++nodenodejs
    在 GitHub 上查看↗3,351
  • 查看 Promises 的所有 30 个替代方案→