Bugzilla – Bug 3242
If an RSS feed that has moved is requested, SlimServer fails to retrieve the file from the new location.
Last modified: 2009-09-08 09:29:37 UTC
If an RSS feed that has moved is requested, SlimServer fails to retrieve the file from the new location. For example, the BBC news RSS feed has moved from: http://news.bbc.co.uk/rss/newsonline_world_edition/front_page/rss091.xml to: http://news.bbc.co.uk/rss/newsonline_world_edition/front_page/rss.xml With d_remotestream enabled, the log says: 2006-04-04 23:16:58.4236 Opening connection to http://news.bbc.co.uk/rss/newsonline_world_edition/front_page/rss091.xml: [news.bbc.co.uk on port 80 with path /rss/newsonline_world_edition/front_page/rss091.xml with timeout 5] 2006-04-04 23:16:58.4597 Request: GET /rss/newsonline_world_edition/front_page/rss091.xml HTTP/1.0 Accept: */* Cache-Control: no-cache User-Agent: iTunes/4.7.1 (Windows; N; Windows XP; 586; EN; cp1252) SlimServer/6.2.2/6811 Icy-MetaData: 1 Connection: close Host: news.bbc.co.uk 2006-04-04 23:16:58.5060 Response: HTTP/1.1 301 Moved Permanently 2006-04-04 23:16:58.5074 header: Date: Tue, 04 Apr 2006 22:15:01 GMT 2006-04-04 23:16:58.5083 header: Server: Zeus/4.2 2006-04-04 23:16:58.5110 header: Location: http://news.bbc.co.uk/rss/newsonline_world_edition/front_page/rss.xml 2006-04-04 23:16:58.5120 header: Cache-Control: max-age=0 2006-04-04 23:16:58.5133 header: Expires: Tue, 04 Apr 2006 22:15:01 GMT 2006-04-04 23:16:58.5145 header: Content-Length: 277 2006-04-04 23:16:58.5170 header: Keep-Alive: timeout=10, max=156 2006-04-04 23:16:58.5183 header: Content-Type: text/html; charset=iso-8859-1 2006-04-04 23:16:58.5196 header: Connection: close 2006-04-04 23:16:58.5203 header: 2006-04-04 23:16:58.5204 Recieved final blank line... 2006-04-04 23:16:58.5211 Redirect to: http://news.bbc.co.uk/rss/newsonline_world_edition/front_page/rss.xml 2006-04-04 23:16:58.5234 ERROR: Slim::Player::Protocols::HTTP::request: Couldn't retrieve track object for: [http://news.bbc.co.uk/rss/newsonline_world_edition/front_page/rss091.xml]
see bug 2693
Bug 2693 deals with the fact that the RSS feeds have moved. This bug deals with SlimServer not being able to understand the redirect responses that it receives. Although I appreciate that it's not a major priority, is it not desirable to have SlimServer understand redirections, so that a software update / reconfiguration is not required whenever an RSS feed gets moved. Perhaps an optimal behaviour would be to have SlimServer retrieve the file from the new location, and to update its configuration whenever a 'Moved Permanently' is encountered.
Proper support for redirection is a requirement, not an enhancement.
then, perhaps bug 2693 should be considered irrelevant (at least the bbc news part of it) in that the remaining issue is really just what this bug report is about. new default is fixed, but existing setups would need this redirect.
Created attachment 1182 [details] Patch to RssNews.pm to use LWP This patches RssNews.pm to use LWP instead of the SlimServer HTTP client. LWP follows redirects correctly.
Unfortunately, LWP blocks, and could cause audio dropouts if the data takes too long. RSS is in line to be moved to using AsyncHTTP. I'm not sure how well that handles redirects at this point. I haven't even looked at it myself, since I have assumed that Andy is working on it as part of the other recent conversions.
Ah, I knew there had to be a reason that LWP wasn't in use. I've had a quick look throught the AsyncHTTP code and can't find anything that suggests that it handles redirects itself, although if it's a work in progress, I presume it'll appear in due course. If RssNews is due to be moved over to AsyncHTTP, then this bug presumably doesn't need any specific attention, as it'll be fixed during the course of those events.
Andy, you are handling redirection in the async http library now, right?
The new RssNews plugin supports redirection properly via SimpleAsyncHTTP.
*** Bug 3414 has been marked as a duplicate of this bug. ***
Verified fixed in SlimServer Version: 6.3.0 - 7895 - Windows XP - EN - cp1252
This bug fix is now part of a released version, and so has been marked closed. If you are still experiencing this problem, please reopen the bug.