Open fufroma opened 4 months ago
If I play "swap left / right / left / right" on a list on the main page, it download the same image in a loop.
I think local cache is missing or faulty
thanks for the report. I use a library called Coil to get images, and I'm using a pretty aggressive cache, this seems like a bug. The library should not retrieve the image multiple times, and the cache should kick in immediately. I will double check my library initialization, in case I will file a bug to the developers of Coil.
Is your phone low in space by any chance? I just checked Coil logger and it looks like it's using the cache without making the network request:
2024-06-02 16:46:37.929 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1270&object_type=album
2024-06-02 16:46:37.930 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=317&object_type=artist
2024-06-02 16:46:37.948 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1081&object_type=album
2024-06-02 16:46:38.068 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1270&object_type=album
2024-06-02 16:46:38.069 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1191&object_type=album
2024-06-02 16:46:38.071 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1330&object_type=album
2024-06-02 16:46:43.264 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1270&object_type=album
2024-06-02 16:46:43.269 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=317&object_type=artist
2024-06-02 16:46:43.320 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1081&object_type=album
2024-06-02 16:46:43.403 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1270&object_type=album
2024-06-02 16:46:43.404 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1191&object_type=album
2024-06-02 16:46:43.418 8104-8104 RealImageLoader ...ix.powerampache2.fdroid.debug I 💾 Successful (DISK) - http://192.168.66.121/image.php?object_id=1330&object_type=album
I will do some more investigation today.
I increased the memory size of the image-cache in version 1.00-59 . https://github.com/icefields/Power-Ampache-2/releases/tag/v1.00-59 The Dogmazic version follows the name pattern as the previous releases ( PowerAmpache2-v1.00-59-PlayFree-release.apk )
It got worst on some point, better on other:
PowerAmpache2-1.00-60-free
1.00-61-free still have only one issue : many identical request for the art when we open an album
REDACTED - - [09/Jul/2024:08:06:16 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:16 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:16 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224623 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224623 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224623 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224623 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224623 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
REDACTED - - [09/Jul/2024:08:06:17 +0200] "GET /image.php?object_id=9515&object_type=album&name=art.png HTTP/1.1" 200 224299 "-" "okhttp/5.0.0-alpha.9"
everything else look fine :)
When I open an album on
Power Ampache 1.00.58-free (58) - DB: 82
, it look like it download the art for each song of the album.But the image is the same for all the song, so it download the same image with the same URL a lot of time :
On top of having the server with unnecessary request (not a big deal), because the link for art are to full-size art, on this example we download 5.5M instead of 0.5M, it may be relevant for some country for the cell phone data.
Ampache know how to handle Etag correctly since Ampache 5.5.5, it may be useful here.