Skip to content

PHP Fatal Error – yii\base\ErrorException #1

@chinmay235

Description

@chinmay235

I have followed your document. Here is getting error message. Could you pleae check.

PHP Fatal Error – yii\base\ErrorException
Class 'php\multithreading\Exception' not found

Code:

$start = microtime(true);
require(__DIR__ . '/../../vendor/grandmasterx/yii2-multithreading/Threads.php');
$threads = new Threads;
$threads->newThread(dirname(__FILE__).'/file.php', array());
while (false !== ($result = $threads->iteration())) {
  if (!empty($result)) {
      echo $result."\r\n";
   }
}
echo (date("H:i:s"));
$end = microtime(true);
echo "Execution time ".round($end - $start, 2)."\r\n";
die;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions