Simplify geolocation_db_updates indexes

This commit is contained in:
Alejandro Celaya 2024-12-15 10:08:22 +01:00
parent a77e07f906
commit f10a9d3972
2 changed files with 4 additions and 4 deletions

View File

@ -53,6 +53,6 @@ return static function (ClassMetadata $metadata, array $emConfig): void {
// Index on date_updated, as we'll usually sort the query by this field
$builder->addIndex(['date_updated'], 'IDX_geolocation_date_updated');
// Index on status and filesystem_id, as we'll usually filter the query by those fields
$builder->addIndex(['status', 'filesystem_id'], 'IDX_geolocation_status_filesystem');
// Index on filesystem_id, as we'll usually filter the query by this field
$builder->addIndex(['filesystem_id'], 'IDX_geolocation_status_filesystem');
};

View File

@ -46,8 +46,8 @@ final class Version20241212131058 extends AbstractMigration
// Index on date_updated, as we'll usually sort the query by this field
$table->addIndex(['date_updated'], 'IDX_geolocation_date_updated');
// Index on status and filesystem_id, as we'll usually filter the query by those fields
$table->addIndex(['status', 'filesystem_id'], 'IDX_geolocation_status_filesystem');
// Index on filesystem_id, as we'll usually filter the query by this field
$table->addIndex(['filesystem_id'], 'IDX_geolocation_status_filesystem');
}
public function down(Schema $schema): void