PHP code example of adamczykpiotr / laravel-balanced-queues
1. Go to this page and download the library: Download adamczykpiotr/laravel-balanced-queues 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/ */
adamczykpiotr / laravel-balanced-queues example snippets
use AdamczykPiotr\LaravelBalancedQueues\Traits\HasBalancedQueues;
class ScrapeVideosJob implements ShouldQueue
{
public function __construct() {
$this->onHighNetworkBandwidthUsageQueu();
}
}
class CallApiJob implements ShouldQueue
{
public function __construct() {
$this->onHighNetworkRequestUsageQueue();
}
}
class ProcessBigDataJob implements ShouldQueue
{
public function __construct() {
$this->onHighCpuUsageQueue();
}
}
class ProcessSmallerDataJob implements ShouldQueue
{
public function __construct() {
$this->onMediumCpuUsageQueue();
}
}