Issue Details (XML | Word | Printable)

Key: SEARCH-157
Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Normal Normal
Assignee: Paul Taylor
Reporter: Paul Taylor
Votes: 3
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
MusicBrainz Search Server

Be able to search for a track by its metadata OR its puid

Created: 09/Mar/10 02:35 PM   Updated: 09/May/12 01:04 PM   Resolved: 09/May/12 01:04 PM
Component/s: None
Affects Version/s: None
Fix Version/s: 2012-05-15


 Description  « Hide

In Current Musicbrainz system if I have one track with a puid that I want to identify I normally end up querying by Puid and then seperately by the user entered metadata, because I need both methods to get all potential matches
i.e.

http://musicbrainz.org/ws/1/track/?type=xml&query=track:gigantic
http://musicbrainz.org/ws/1/track/?type=xml&puid=0df59361-73bf-8172-e7e5-0e31a4b66b03

Id rather do
http://musicbrainz.org/ws/1/track/?type=xml&query=track:gigantic OR puid:0df59361-73bf-8172-e7e5-0e31a4b66b03

but that doesn't work because if you specify puid option it goes to the database and everything else is ignored.

In NGS the situation is no better because puid are no longer a query parameter, but a resource type of ther own so still end up with two queries.

http://test.musicbrainz.org/ws/2/recording/?query=gigantic
http://test.musicbrainz.org/ws/2/puid/0df59361-73bf-8172-e7e5-0e31a4b66b03

The new puid entity for when somebody just wants to look up a puid is fine but I think we can do better for fixing the search issue. The only solution to allow the OR query is to add puids to the search server recording index and allow searching by them. The reason this wasn't done before was that it would mean a larger percentage of ws queries would go to the search server rather than the dbserver and the sheer volume would slow down all ws queries. But this is just a question of load balancing, an individual query against the search server should be quicker than a db lookup because search is readonly and is optimized for searching whereas the db is not, and the search server can easily be replicated onto any number of machines to get the required performance.

So I suggest we look at this again when we have some time



Paul Taylor made changes - 09/Mar/10 02:37 PM
Field Original Value New Value
Assignee Oliver Charles [ acid2 ] Robert Kaye [ rob ]
Oliver Charles made changes - 06/Sep/10 12:30 PM
Fix Version/s Post NGS Release [ 10020 ]
voiceinsideyou made changes - 12/Aug/11 10:17 AM
Component/s Search [ 10003 ]
Component/s Web service [ 10000 ]
Nicolás Tamargo made changes - 12/Dec/11 08:57 PM
Project MusicBrainz Server [ 10000 ] MusicBrainz Search Server [ 10020 ]
Key MBS-587 SEARCH-157
Fix Version/s Post NGS [ 10020 ]
Component/s Web service [ 10000 ]
Component/s Search [ 10003 ]
Paul Taylor made changes - 30/Mar/12 07:30 AM
Assignee Robert Kaye [ rob ] Paul Taylor [ ijabz ]
Paul Taylor added a comment - 09/May/12 01:04 PM

FIxed with tests


Paul Taylor made changes - 09/May/12 01:04 PM
Status Open [ 1 ] Closed [ 6 ]
Fix Version/s next version [ 10131 ]
Resolution Fixed [ 1 ]