related albums, performance issues #1212

Closed
opened 2026-10-05 00:36:12 +02:00 by adam · 0 comments
Owner

As described on https://piwigo.org/forum/viewtopic.php?id=31187 we have a performance issue when Piwigo tries to find related albums of a "too big" set of photos. Indeed if a tag is associated to 10k photos and you open the page of the this tag, then Piwigo has to find related albums for these 10k photos. The resulting SQL queries are huge and slow.

They are also useless since you will probably find that "all" albums are related albums. Making the "related albums" menu the exact same as the "albums" menu.

For me, the solution comes in 2 steps:

  1. do not try to find related albums if the current set is "too big"
  2. only display heaviest related albums (just like we do for tags)
As described on https://piwigo.org/forum/viewtopic.php?id=31187 we have a performance issue when Piwigo tries to find related albums of a "too big" set of photos. Indeed if a tag is associated to 10k photos and you open the page of the this tag, then Piwigo has to find related albums for these 10k photos. The resulting SQL queries are huge and slow. They are also useless since you will probably find that "all" albums are related albums. Making the "related albums" menu the exact same as the "albums" menu. For me, the solution comes in 2 steps: 1. do not try to find related albums if the current set is "too big" 2. only display heaviest related albums (just like we do for tags) <!-- github-sync-id:875568874 -->
adam closed this issue 2026-10-05 00:36:13 +02:00
Sign in to join this conversation.
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: adam/Piwigo#1212