[GH-ISSUE #1377] Question about api structure #789

Closed
opened 2026-02-26 02:34:16 +03:00 by kerem · 0 comments
Owner

Originally created by @SvanteRichter on GitHub (Nov 8, 2021).
Original GitHub issue: https://github.com/koel/koel/issues/1377

I have a question about the api structure and the how the backend is used by koel.

It seems that when the frontend loads it grabs /api/data which (I think) contains everything one has access to except "recently played", images and the actual music files. This can get pretty large (on my current library it is 5.6MB and I wouldn't consider this a large library), which also means it is pretty slow and heavy to both download and parse. It also requires quite a bit of work from the backend (1.5s TTFB for my library on a pretty good machine).

My questions are:

  • Is this by design? Is the full library meant to be downloaded on each pageload and held in memory?
  • Was a api design whereby pagination and different endpoints for artists/albums/songs and those are fetched on-demand considered?
  • Why is search done via the backend if the full library is already loaded on the frontend?
Originally created by @SvanteRichter on GitHub (Nov 8, 2021). Original GitHub issue: https://github.com/koel/koel/issues/1377 I have a question about the api structure and the how the backend is used by koel. It seems that when the frontend loads it grabs `/api/data` which (I think) contains everything one has access to except "recently played", images and the actual music files. This can get pretty large (on my current library it is 5.6MB and I wouldn't consider this a large library), which also means it is pretty slow and heavy to both download and parse. It also requires quite a bit of work from the backend (1.5s TTFB for my library on a pretty good machine). My questions are: * Is this by design? Is the full library meant to be downloaded on each pageload and held in memory? * Was a api design whereby pagination and different endpoints for artists/albums/songs and those are fetched on-demand considered? * Why is search done via the backend if the full library is already loaded on the frontend?
kerem closed this issue 2026-02-26 02:34:16 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/koel-koel#789
No description provided.