After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 569007 - [jamendo] Only update catalog if it changes (or after specific interval)
[jamendo] Only update catalog if it changes (or after specific interval)
Status: RESOLVED NOTABUG
Product: rhythmbox
Classification: Other
Component: Plugins (other)
0.11.x
Other Linux
: Normal enhancement
: ---
Assigned To: RhythmBox Maintainers
RhythmBox Maintainers
: 647539 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2009-01-24 18:37 UTC by Kim Sullivan
Modified: 2012-03-28 22:30 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Changed update Jamendo catalog functionality (17.66 KB, patch)
2009-11-20 21:34 UTC, Maxim Dobriakov
rejected Details | Review

Description Kim Sullivan 2009-01-24 18:37:34 UTC
Currently, the jamendo database seems to be downloaded every time rhytmbox is started and the Jamendo catalogue is activated. The documentation on http://developer.jamendo.com/en/wiki/NewDatabaseDumps states it is "updated each night".

I'm not sure if the http headers for the database dump are correctly set to the file's last modification time, if not, it would be nice if the period would be configurable (24hrs default + manual refresh).
Comment 1 Kim Sullivan 2009-01-24 22:02:01 UTC
Running  rhythmbox -D jamendo gives me the following error:
(20:00:49) [0x870e408] [JamendoSource.info_cb] /usr/lib/rhythmbox/plugins/jamendo/JamendoSource.py:538: error checking times
(20:00:49) [0x870e408] [JamendoSource.info_cb] /usr/lib/rhythmbox/plugins/jamendo/JamendoSource.py:538:  
(20:00:49) [0x870e408] [JamendoSource.info_cb] /usr/lib/rhythmbox/plugins/jamendo/JamendoSource.py:538: mtime field has no valid value
Comment 2 Jonathan Matthew 2009-01-24 23:36:20 UTC
This needs to be fixed on the server side.  The HTTP response headers offer no indication of the modification time and don't include an etag, and the cache control headers state that the response is valid for 15 days.  I don't see any reason to add configuration and associated logic to rhythmbox to work around this.
Comment 3 Nick Perez 2009-10-22 11:17:12 UTC
Sorry for not fully understanding the technical details of this-- would this server-side stuff make it impossible to cache the catalog? It would be great if there were an option to only reload upon the click of a refresh button. Often I go to listen to a specific artist/song/album, and there's no need on my end to wait out the long update.
Comment 4 Maxim Dobriakov 2009-11-20 21:34:07 UTC
Hello All,

I made the patch for resolve it problem and implemented functionality similar to proposed Nick Perez and Kim Sullivan. I added combobox with update intervals items to configuration dialog and re-wrote check updates functionality. Now it functionality download catalog only when selected interval was expired. Also for Jamendo store item (in tree) I add context menu which user can use for update Jamendo catalog manually.

Can you verify my patch and say how can I improve it?.

Thanks
Comment 5 Maxim Dobriakov 2009-11-20 21:34:46 UTC
Created attachment 148196 [details] [review]
Changed update Jamendo catalog functionality
Comment 6 Jonathan Matthew 2009-11-22 01:00:07 UTC
As I already said in comment 2, this needs to be fixed on the server side.  I don't see any point in working around the problem on the client side.
Comment 7 Maxim Dobriakov 2009-11-22 11:22:02 UTC
Hello, Jonathan Matthew

Jamendo server should not return last-modified header because Jamendo developers can set some request headers they want. 
Also last-modified header shows modification time of file, but file content can be unchanged (for example Jamendo developers use CRON job to generate dump file every hight, but new changes commit only on Friday or Monday (see http://developer.jamendo.com/ru/wiki/NewDatabaseDumps , URLs section)). 

My conclusion: This problem is client side problem and it can be fixed in rhythmbox. Please, verify my patch again.

P.S.

If I didn't see workarounds on client side I wouldn't start making that patch. But I made workaround on client side and it works.

Thanks
Comment 8 Jonathan Matthew 2009-12-28 02:59:34 UTC
Comment on attachment 148196 [details] [review]
Changed update Jamendo catalog functionality

No, this is exactly what the http caching headers are for.  Any other solution is wrong.
Comment 9 Jonathan Matthew 2011-04-12 12:39:39 UTC
*** Bug 647539 has been marked as a duplicate of this bug. ***
Comment 10 axel 2011-04-12 12:56:07 UTC
Hi, I reported  Bug 647539, the problem is still present. I see there is a patch but I don't know what to do with it. 
It would be great if this problem could be solved as an option in Jamendo and Magnatune plugins' settings.

Please, could you release enhanced versions of these plugins?
Comment 11 Jonathan Matthew 2011-04-12 13:04:44 UTC
I've already explained repeatedly why I'm not going to do that.
Comment 12 axel 2011-04-12 13:43:23 UTC
The patch is described as rejected. So what am I suppose to do if developers don't care? 
I don't think Jamendo or Magantune developers will change it. The only thing I can do is not to use Rythmbox. 
I wander why you are doing this program at all if you don't care about users...

Users don't think in the same categories as developers. They want to have comfortable work with programs. Gnome and Gnome apps are becoming worse and worse.