You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have following code that throw exception. This makes me wondering whether I shouldn't use Octane::concurrently inside Octane::tick. I'm trying to lookup the documentation and understand what's the issue. However, I'm new to Laravel Octane and stuck here for 1 day.
[2024-03-31 05:50:35] local.ERROR: OpenSwoole\Server::taskWaitMulti(): taskWaitMulti method can only be used in the worker process {"exception":"[object] (ErrorException(code: 0): OpenSwoole\Server::taskWaitMulti(): taskWaitMulti method can only be used in the worker process at /home/sites/access-queue/vendor/laravel/octane/src/Swoole/SwooleTaskDispatcher.php:30)
class AppServiceProvider extends ServiceProvider
{
public function register(): void
{
// Nothing for now
}
public function boot(): void
{
Octane::tick('test flow', function () {
$results = Octane::concurrently([
'task1' => fn () => Log::debug('task 1'),
'task2' => fn () => Log::debug('task 2'),
]);
})->seconds(60);
}
}
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I have following code that throw exception. This makes me wondering whether I shouldn't use Octane::concurrently inside Octane::tick. I'm trying to lookup the documentation and understand what's the issue. However, I'm new to Laravel Octane and stuck here for 1 day.
[2024-03-31 05:50:35] local.ERROR: OpenSwoole\Server::taskWaitMulti(): taskWaitMulti method can only be used in the worker process {"exception":"[object] (ErrorException(code: 0): OpenSwoole\Server::taskWaitMulti(): taskWaitMulti method can only be used in the worker process at /home/sites/access-queue/vendor/laravel/octane/src/Swoole/SwooleTaskDispatcher.php:30)
Beta Was this translation helpful? Give feedback.
All reactions