[mb-devel] WebService usage
Robert Kaye
rob at eorbit.net
Wed Aug 2 21:25:53 UTC 2006
On Jul 26, 2006, at 7:34 PM, Vidar Wahlberg wrote:
> Further I wish to lookup the release:
> http://musicbrainz.org/ws/1/release/?
> type=xml&limit=5&title=1982-1992&artistid=ccfe7a3c-1a45-4984-
> a8d0-644549cefe61
> Here's where the unexpected values show. I've submitted the id of the
> artist and the title of the release, but yet I get results from other
> artists (with a different artist id) who've released something with a
> similar title.
> Why is this?
This query is being handled by Lucene and not the database. Lucene
may return results that do not match that artist, but match other
criteria if not many search results are returned. I may be able to
restrict lucene to never return any hits that do not match a given
artist. Please file a bug report and assign it to me.
> And then at last I want to look up the track:
> http://musicbrainz.org/ws/1/track/?type=xml&limit=5&title=Seven%
> 20Doors%20Hotel&artistid=ccfe7a3c-1a45-4984-
> a8d0-644549cefe61&releaseid=ea6be413-fbd7-49f2-8546-e162d481e857
> Again a bit unexpected values. Even though I've submitted both
> artist id
> and release id, I get results from completly different artists and
> releases.
I see tracks limited to only one artist. But I do see releases that
are not limited to the specified releaseid. I think this is the same
issue as above.
> Now someone might ask, "Why can't you just look the track directly
> up?"
> Well, the query would be something like this:
> http://musicbrainz.org/ws/1/track/?type=xml&limit=5&title=Seven%
> 20Doors%20Hotel&artist=Europe&release=1982-1992
> Yes, that would give me a result with only 1 query, but then I
> won't get
> metadata such as release type, asin, release date or artist sortname.
> That's metadata I can't go without (especially not the sortname, I
> sort
> my archive on that).
Again, you are doing a Lucene search and it doesn't make sense to
stuff everything into Lucene. When you find a match you like, take
the track id and then request the track resource separately. So, that
means doing two queries, not three.
> Also, why is it so that you need to log in to do a track query while
> it's not required to log in to do an artist or a release query?
I don't need to log in to do this query:
http://musicbrainz.org/ws/1/track/7cf9251e-1b63-405f-
a5ac-2512bb1d3cc2?type=xml&inc=tracks
Are you using GET or POST to talk to the service? If POST, it
requires authentication because the only POST action on track is a
submitting a PUID, which requires authentication. Do a GET and all
should be well.
--
--ruaok Somewhere in Texas a village is *still* missing its idiot.
Robert Kaye -- rob at eorbit.net -- http://mayhem-chaos.net
More information about the MusicBrainz-devel
mailing list