-
Notifications
You must be signed in to change notification settings - Fork 18
Library loads extremely slowly on large collections (All Albums / All Songs) #119
Description
Bug Description
Opening "All Albums" or "All Songs" for the first time (or after cache expires) can take several minutes on large libraries. The root cause is _refreshAllDataInBackground() in LibraryProvider, which fetches the entire library via hundreds of sequential HTTP requests:
- getArtists() — 1 request
- getArtistAlbums(id) — 1 request per artist, sequentially
- getAlbumSongs(id) — 1 request per album, sequentially
On a collection of ~500 albums across ~200 artists this results in 700+ sequential API calls, blocking the screen for minutes.
Additionally, _onScroll() in AllSongsScreen is defined but empty — there is no lazy/paginated loading once the screen opens.
Steps to Reproduce
- Fresh install or cache older than 6 hours
- Connect to a Subsonic/Navidrome server with 200+ albums
- Open Library → All Albums or All Songs
- Observe loading spinner that can take 2–5+ minutes before any content appears
Expected Behavior
Albums and songs should appear quickly using paginated API calls (getAlbumList2 supports size + offset).
Content should load incrementally as the user scrolls rather than waiting for the entire library to be fetched upfront.
App Version
v1.0.8
Subsonic Server
Navidrome