GeopJr / Tuba

Browse the Fediverse
https://tuba.geopjr.dev/
GNU General Public License v3.0
506 stars 55 forks source link

feat(emoji): libsoup cache lookup #915

Closed GeopJr closed 3 weeks ago

GeopJr commented 2 months ago

Suggested by Fabian on matrix, instead of going through libsoup's cache process, let's look it up ourselves.

Why? Because libsoup does complex cache checking that also needs to be decoded:

Compared to just, checking if the file exists already and loading it.

Libsoup's cache is important, especially on profile avatars and API responses. It's not that much on emojis and in situations where it has to load thousands at the same time (CEP), this seems faster

Quirk: libsoup maps images to cache entries using g_str_hash based on the url