Caching (?) issues when requesting transcoded files

First of all: thank you so much for developing symfonium - love it!

Issue description:

My issue might be related to the way caching of transcoded files is done:

  • I use gonic as provider.
  • As per gonic-settings, songs are transcoded prior to being sent to symfonium.
  • On Symfonium I request to start playback of a song (e.g. see the song “Color” by “Ojos de Brujo” in the attached log)
  • Playback of song starts, I can observe the timeline-bar of the song ‘fill’ up in a darker grey for approximately the first 20seconds of the song. (I assume this indicates the caching of the file).
  • However, caching doesnt move on on. Playback reaches end of cached file (e.g. 20seconds) and then jumps to next song in playlist. (in case of attached log files, it jumpes to song “Sultanas de merkaillo”
  • Now this song has almost half of the song ‘cached’.
  • I assume while I was listening to song 1 (and urgently needed song 1 to finish to transcode/cache), somehow song 2 (and maybe song 3) started to transcode and cache.

Is there a way to prioritize caching of song 1?


debug.log (136.1 KB)

What you see is the player buffer, not related to actual caching at all.

From the logs everything seems to works correctly and current song is always prioritized and is not cancelled in those logs.

Check Gonic logs and see if there’s issue there with multiple transcode at the same time causing something. @sentriz

yes i think it is possible that in some cases parallel transcode requests could be a bit funny. i just pushed a commit to gonic master to make that a bit more robust

thanks for both of your quick replies!

will give it a try with nightly gonic as soon as possible.


i updated gonic to latest (v0.16.2).

however, the issue still remains.

i will open an issue at gonic, the parallel transcoding theory seems to be most promising.

(e.g. with symfonium the issue arises, but not with dsub, which seems to only do one transcoding request at a time).

happy new year everyone :slight_smile:

unfortunately I wasnt able to solve this issue - so im reopening it.

i did a screenrecording and collected logs from both symfonium and gonic:

notice how song “1. Desecration smile” at the first playback-try doesnt further transcode/buffer and playback hangs after a few seconds. afterwards, when i come back to it, it nicely transcodes/buffers and everything seems fine.

i hope this provides some clues?

best, ken

Seems that you force transcode server side and that Gonic returns chunked content.

Symfonium can’t really detect that and ogg files forced like that are not really suited for streaming as we need to read the granule at the end of the file. (But can’t know when it will be available in this situation)

If the transcoding and cache is fast enough then it can work, but this is not ideal at all.

You can probably easily workaround the issue by force transcoding to mp3.

ok, thanks for the input. will give it a try with mp3 and report back soon.

Yes indeed - forcing transcoding to mp3 did the trick. Works flawlessly now.
Thank you!

(And yes, I’m enforcing transcoding server side due to gonic’s way of handling transcoding, which is a bit counter-intutive. Buet helas - it does the job).