php – Repeated DB connection at max user connections

I am trying to create class with connect to mysql database. And if there is max number of connections I want to wait and try it again. I figured out, how it can works, but I am not sure, if its the right way of doing it. So, my code looks like this:

<?php

class DbConnect {

  private $attemps = 1;
  private $errorCode;
  private $maxAttemps = 10;
  private $pdo;
  private $dsn = "mysql:host=localhost;dbname=...;charset=utf8";
  private $options = (
    PDO::ATTR_EMULATE_PREPARES   => false, // turn off emulation mode for "real" prepared statements
    PDO::ATTR_ERRMODE            => PDO::ERRMODE_EXCEPTION, //turn on errors in the form of exceptions
    /*PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,*/ //make the default fetch be an associative array
  );

  public function __construct(){
    $this->tryConnect();
    while ($this->errorCode == 1040 && $this->attemps <= $this->maxAttemps) {
      usleep(pow(2, $this->attemps)*10000);
      $this->tryConnect();
    }

  }


  protected function tryConnect(){
    try {
      $this->pdo = new PDO($this->dsn, "root", "", $this->options);
    } catch (Exception $e) {
      error_log($e->getMessage());
      $this->errorCode = $e->getCode();
      $this->attemps++;
    }
  }



}

?>

Is there anything i should change? Thank you very much.