PHPackages                             n0nag0n/simple-job-queue - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Queues &amp; Workers](/categories/queues)
4. /
5. n0nag0n/simple-job-queue

ActiveLibrary[Queues &amp; Workers](/categories/queues)

n0nag0n/simple-job-queue
========================

A simple library for interfacing with other job queue providers that gives you plenty of flexibility. Supports MySQL, PostgreSQL, SQLite, and Beanstalkd.

1.3.0(2w ago)393.4k↑2346.2%71MITPHPPHP ^7.4 || ^8.0CI passing

Since Sep 28Pushed 2w ago1 watchersCompare

[ Source](https://github.com/n0nag0n/simple-job-queue)[ Packagist](https://packagist.org/packages/n0nag0n/simple-job-queue)[ RSS](/packages/n0nag0n-simple-job-queue/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (9)Dependencies (5)Versions (10)Used By (1)

Simple PHP Job Queue
====================

[](#simple-php-job-queue)

I wanted/needed a simple job queue that could be used on a database, but also used with other adapters like beanstalkd/redis/etc if needed. Didn't really see a good option for a standalone job queue for a database.

Install
-------

[](#install)

```
composer require n0nag0n/simple-job-queue
```

**Requirements:** PHP 7.4 or higher.

> **Note on Beanstalkd:** The `pda/pheanstalk` package is only needed if you use the Beanstalkd adapter. It is listed under `suggest` in `composer.json` (not a hard requirement) so pure database users are not forced to install it.

Usage
-----

[](#usage)

In order for this to work, you need a way to add jobs to the queue and a way to process the jobs (a worker). Below are examples of how to add a job to the queue and how to process the job.

### Adding a new job

[](#adding-a-new-job)

#### MySQL

[](#mysql)

```
