use persistent connection, still not good

This commit is contained in:
osaajani 2020-09-02 21:45:26 +02:00
parent b536c64df9
commit 9fc399e280
2 changed files with 3 additions and 2 deletions

View File

@ -148,7 +148,7 @@ class Phone extends AbstractDaemon
foreach ($tasks as $task)
{
$task['process']->run();
$task['process']->start();
}
$done = false;

View File

@ -37,7 +37,8 @@
{
$options = $options ?? [
\PDO::ATTR_DEFAULT_FETCH_MODE => \PDO::FETCH_ASSOC,
\PDO::ATTR_ERRMODE => \PDO::ERRMODE_EXCEPTION
\PDO::ATTR_ERRMODE => \PDO::ERRMODE_EXCEPTION,
\PDO::ATTR_PERSISTENT => true,
];
// On se connecte à MySQL