'staff_3', 'requestData' => [] ]; } public function handler() { $fileDownloader = FileDownloader::getInstance(); $fileDownloader->setFileName('backup.sql'); $mysqlDump = new IMysqldump\Mysqldump('mysql:host='. MYSQL_HOST . ';port=' . MYSQL_PORT . ';dbname=' . MYSQL_DATABASE , MYSQL_USER, MYSQL_PASSWORD); $mysqlDump->start($fileDownloader->getFullFilePath()); if($fileDownloader->download()) { $fileDownloader->eraseFile(); } } }