PHP code example of g41797 / queue-beanstalkd
1. Go to this page and download the library: Download g41797/queue-beanstalkd library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
g41797 / queue-beanstalkd example snippets
[
'host' => '127.0.0.1', // IP or hostname of the target server
'port' => 11300, // TCP/IP port of the target server
]
// Push a job into the queue and get a message ID.
$id = $queue->push(new SomeJob());
// Get job status.
$status = $queue->status($id);