Support the ongoing development of Laravel.io →
Database Eloquent
Last updated 2 years ago.
0

some one help?

0

When this problem occurs?

0

"artisan queue:work --daemon --sleep=1 --tries=10 --queue=issue" i use at console. maybe long time run. i dont know .

0

and then ,i get so many failed job in database . i check the log , found so many error message like this.

0

and then ,i get so many failed job in database . i check the log , found so many error message like this.

0

i really don't know what happened.....

0

exception 'RuntimeException' with message 'Can't swap PDO instance while within transaction.' in /data/lightning5/vendor/laravel/framework/src/Illuminate/Database/Connection.php:854

0

ok.. its happened again.

0

php /data/lightning5/app/../artisan queue:work --daemon --sleep=1 --tries=5 --queue=task

0

my english no good. someone help?

0

I add DB::reconnect();

in the first line in handle method, and it's solved.

Like:

public function handle() {
    DB::reconnect();
}
0

Sign in to participate in this thread!

Eventy

Your banner here too?

topshark topshark Joined 27 Jul 2015

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.