Skip to content
Commit 3baa4675 authored by Phil Trimble's avatar Phil Trimble Committed by Andrés G. Aragoneses
Browse files

Audioscrobbler: avoid 414 Request-URI Too Large (bgo#689018)



Lastfm has the policy of not accepting more than 50 songs per
audioscrobbling submission; but it also has a limit on how long
an HTTP request should be, so there could be occassions when
the metadata of the 30 songs (our MAX) could surpass this limit.

Now, LastfmRequest can receive parameters in batches (all
parameters for a song, in a NameValueCollection). If that
addition makes the request too large, a MaxSizeExceeded
exception is thrown which means that no more parameters
can be added and the request is ready to be sent.

(All LastFmRequest tests still pass after this refactoring.)

Co-authored-by: default avatarAndres G. Aragoneses <knocte@gmail.com>
Signed-off-by: default avatarAndres G. Aragoneses <knocte@gmail.com>
parent 84c491c8
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment