Download the PHP package kinetis/queue-redis without Composer

On this page you can find all versions of the php package kinetis/queue-redis. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package queue-redis

kinetis/queue-redis
A Redis-backed queue implementation for kinetis/queue's QueueInterface

Packagist Version Packagist Downloads PHP Version License CI


Part of Kinetis, a non-blocking PHP framework for API-first applications, developed in the kinetis-dev/kinetis monorepo.

Adds Redis as a queue backend. push()/pop()/ack()/release()/fail() work exactly like any other backend — only your configuration changes. A reservation is a finite lease: pop() moves a job from the queue's pending list into a leased sorted set scored with an expiry, and any worker's next pop() returns a lease past its expiry to pending with attempts incremented. A job whose worker died mid-execution is redelivered rather than stranded.

The factory opens the queue's own Kinetis\Redis\Client and hands the queue that client's close(), so RedisQueue declares Kinetis\Queue\DisposableQueueInterface and dispose() ends the connection when the worker does. Building one yourself means registering that — $app->onDispose($queue->dispose(...)); the bootstrap behind QUEUE_CONNECTION=redis already does. A RedisQueue constructed directly around an Amp\Redis\RedisClient you built closes nothing: that facade exposes no close, and the transport under it stays yours.

RedisQueue declares Kinetis\Queue\ClearableQueueInterface. Clearing counts and removes the queue's pending and delayed entries in one Lua script, so the number it reports is what it removed; live leases are untouched, since they are work a running worker still owns. size() counts pending, delayed and expired leases, not live ones.

The leased member is the exact envelope string handed back as the job's handle, and reclaiming rewrites it with the incremented attempt count. That makes the handle a fence: ack(), release() and fail() act only on that exact member, so a settlement for a delivery that has been reclaimed or already settled raises Kinetis\Queue\Exception\StaleJobHandleException and writes nothing.

RedisQueue also declares Kinetis\Queue\RenewableQueueInterface, so queue:work extends a running job's lease at half QUEUE_VISIBILITY_TIMEOUT_SECONDS: one Lua script resetting that exact leased member's expiry to Redis TIME plus the window, with ZADD ... XX as the fence. The setting therefore sizes crash recovery, not job duration.

Delivery is still at least once, so keep handlers idempotent. A lease still expires under a job whose worker died and under a handler that never yields to the event loop, and such a job can execute alongside its replacement. maxAttempts bounds handlers that throw; it cannot bound a succession of processes that each die mid-execution.

There is no reaper process. Every pop() promotes due delayed jobs and reclaims expired leases for each queue it is given, in priority order, before it waits.

Configuration

QUEUE_VISIBILITY_TIMEOUT_SECONDS is how long a reservation is leased before any worker may reclaim it. It defaults to 300 and must be a positive integer. Every other key this backend reads — REDIS_HOST/ REDIS_URL/REDIS_TLS/... — is the exact one kinetis/cache-redis's RedisSimpleCache already reads, scoped by the queue connection's name the same way every other backend is (see kinetis.dev/docs/queue.html). The connection's own REDIS_CLUSTER is read and rejected: this backend supports standalone Redis only, so true throws an InvalidArgumentException naming that key. A named connection reads only its scoped key, so a cluster on the unscoped keys leaves it alone. It opens its own connection over kinetis/redis rather than sharing the cache's, so its connection lifetime is its own. kinetis/queue's own keys (QUEUE_CONNECTION, QUEUE_MAX_ATTEMPTS, ...) are documented in that package; full reference: kinetis.dev/docs/config.html.

Installation

Requires PHP 8.4+, kinetis/framework, kinetis/queue, and kinetis/redis. Full documentation: kinetis.dev/docs/queue-redis.html.

License

MIT — see LICENSE.


All versions of queue-redis with dependencies

PHP Build Version
Package Version
Requires php Version >=8.4 <8.6
kinetis/framework Version ^1.29.1
kinetis/queue Version ^1.10.3
kinetis/redis Version ^1.0.5
amphp/redis Version ^2.0.4
amphp/socket Version ^2.4.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package kinetis/queue-redis contains the following files

Loading the files please wait ...