I'm a little bit confused.. The advantage of using this package is that we can schedule and retrieve the jobs in a "laravel standard" way?
Currently I've created some POST routes, available only in the worker environment and they process all the time consuming tasks directlly, returning 200 if all went fine.
So, the web environment push a message to the SQS and the SQS itself post that message to the worker environment.. Using this package will lead to a better performance ? Or the goal is just to use the standard laravel queue pushing-pulling.. ?
Hi,
I'm a little bit confused.. The advantage of using this package is that we can schedule and retrieve the jobs in a "laravel standard" way?
Currently I've created some POST routes, available only in the worker environment and they process all the time consuming tasks directlly, returning 200 if all went fine.
Example:
if(isWebEnvironment){
$app->post('/email', function(){
....
$client->sendMessage(array(
'QueueUrl' => $queueUrl,
'MessageBody' => 'An awesome message!',
));
});
}
if(isWorkerEnvironment){
$app->post('/sqs', function(){
... "send email"..
});
}
So, the web environment push a message to the SQS and the SQS itself post that message to the worker environment.. Using this package will lead to a better performance ? Or the goal is just to use the standard laravel queue pushing-pulling.. ?
Thanks in advance !