Add these files to your app namespace under the App/LaravelExtensions folder & namespace (change App to whatever you app folder is).
Open up your app/config/queue.php and edit the default value to mysqs. Add a new connection to the connections array with your AWS config:
return array(
'default' => 'mysqs',
'connections' => array(
'mysqs' => array(
'driver' => 'mysqs',
'key' => getenv('AWS_ACCESS_KEY_ID'),
'secret' => getenv('AWS_SECRET_KEY'),
'queue' => getenv('SQS_QUEUE'),
'region' => 'us-east-1',
),
),
);Finally open up your app/config/app.php file and find the providers array. Comment out Illuminate\Queue\QueueServiceProvider and replace with App\LaravelExtensions\MyQueueServiceProvider (replacing App with your namespace):
return array(
'providers' => array(
//'Illuminate\Queue\QueueServiceProvider',
'App\LaravelExtensions\MyQueueServiceProvider',
),
);Then you should be able to use push queues as normal:
// Process incoming push queues
Route::post('queue/receive', function()
{
Queue::marshal();
});