Hi, I've never seen Solr's behaviour with a huge amount of values in a multi valued but i think it should work alright. Then you can stored a list of user ID's along with each book document and user filter queries to include or exclude the book from the result set.
Cheers, > Hi, > > I'm looking for ideas on how to make an efficient facet query on a > user's history with respect to the catalog of documents (something > like "Read document already: yes / no"). The catalog is around 100k > titles and there are several thousand users. Of course, each user has > a different history, many having read fewer than 500 titles, but some > heavy users having read perhaps 50k titles. > > Performance is not terribly important right now so all I did was bump > up the boolean query limit and put together a big string of document > id's that the user has read. The first query is slow but once it's in > the query cache it's fine. I would like to find a better way of doing > it though. > > What type of solr plugin would be best suited to helping in this > situation? I could make a function plugin that provides something like > hasHadBefore() - true/false, but would that be efficient for faceting > and filtering? Another idea is a QParserPlugin that looks for a field > like hasHadBefore:userid and somehow substitutes in the list of docs. > But I'm not sure how a new parser plugin would interact with the > existing parser. Can solr use a parser plugin to only handle one > field, and leave all the other fields to the default parser? > > Thanks, > Jon