Documented performance issue when sorting by visits or short URLs count

This commit is contained in:
Alejandro Celaya
2022-01-23 10:48:38 +01:00
parent 8adb6596fb
commit cdb18a5baf
3 changed files with 5 additions and 2 deletions

View File

@@ -84,7 +84,7 @@ class TagRepository extends EntitySpecificationRepository implements TagReposito
->groupBy('t.id_0', 't.name_1');
// Apply API key role conditions to the native query too, as they will affect the amounts on the aggregates
$apiKey?->mapRoles(fn (string $roleName, array $meta) => match ($roleName) {
$apiKey?->mapRoles(static fn (string $roleName, array $meta) => match ($roleName) {
Role::DOMAIN_SPECIFIC => $nativeQb->andWhere(
$nativeQb->expr()->eq('s.domain_id', $conn->quote(Role::domainIdFromMeta($meta))),
),