Skip to content

Commit

Permalink
Try to speed up jobs chart generation
Browse files Browse the repository at this point in the history
  • Loading branch information
Vítězslav Dvořák committed Jun 4, 2024
1 parent 8db1baf commit 43d9711
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions db/migrations/20240604101343_job_times_index.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?php
declare(strict_types=1);

use Phinx\Migration\AbstractMigration;

final class JobTimesIndex extends AbstractMigration
{
/**
* Change Method.
*
* Write your reversible migrations using this method.
*
* More information on writing migrations is available here:
* https://book.cakephp.org/phinx/0/en/migrations.html#the-change-method
*
* Remember to call "create()" or "update()" and NOT "save()" when working
* with the Table class.
*/
public function change(): void
{
$table = $this->table('job');
$table->addIndex('begin')->addIndex('end')->addIndex('exitcode');
$table->save();
}
}

0 comments on commit 43d9711

Please sign in to comment.