incubator-blur-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aaron McCurry (JIRA)" <>
Subject [jira] [Commented] (BLUR-174) Respect family order from given selector
Date Sat, 03 Aug 2013 00:53:48 GMT


Aaron McCurry commented on BLUR-174:

- If we can have only row_id as a term in query then this is fine.

When fetching a row there can be only one rowId.

- How can we fetch documents based on fieldName/fieldValue from indexSearcher. Because TopDocs
only provides the document Ids. So might be we need to have some other datastructure like
Map to maintain all the documents with their family name as key. 

Since we are just going to convert all the documents to Records to be embedded in the Row
(for delivery) where they are just a list of Records.  Currently the way the code works it
searches for all documents that contain the rowid.  If one or more families are provided in
the Selector then the query is modified to only find the families that are provided.  Since
there is Record paging involved here (you can page through the Records within a single Row)
I think the best way to do this is break up the search into multiple searches.

For instance if there Row being fetched has 6 Records within it, 2 Records in family "cf1"
and 1 in "cf2" and 3 in "cf3".  The order in the Row may not be determinate because the order
can be random when the MapReduce indexing is used.  So to fetch only the "cf1" and "cf3" families
in that order I would search for rowId + cf1.  Fill the List of Documents.  If more can/should
fetch fetched based on paging run a second search or rowid + cf3 add the result into the list
of documents and return.

- Can we have Multiple records with same family name in a particular row?

Yes they can.

> Respect family order from given selector
> ----------------------------------------
>                 Key: BLUR-174
>                 URL:
>             Project: Apache Blur
>          Issue Type: Bug
>          Components: Blur
>    Affects Versions: 0.2.0
>            Reporter: Aaron McCurry
>            Priority: Minor
>             Fix For: 0.2.0
> We need to respect the order of the families in the selector.  For instance if a table
contains 3 families, "cf1","cf2", and "cf3".  And a fetch (during a query or a fetch call)
is performed and the order of the families are "cf2", "cf1" then all the records from the
Row that contain "cf2" should come before "cf1".
> Changes needed:
> The families in the Selector object in thrift need to be changed from a set to a list.
> The fetchDocuments method in the BlurUtil class in blur-core needs to be modified to
respect the family order.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message