lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <erickerick...@gmail.com>
Subject Re: Store Solr OpenBitSets In Solr Indexes
Date Mon, 04 Nov 2013 12:53:51 GMT
If the bitset is something you control you can use the binary
field type, although it's not a horribly efficient way to store binary
data.

If the bitset is bounded, you could do something with indexing
N long values that will contain the set and write a custom
similarity class to work with it.

Best,
Erick


On Sat, Nov 2, 2013 at 9:19 AM, David Philip <davidphilipsheron@gmail.com>wrote:

> Oh fine. Caution point was useful for me.
> Yes I wanted to do something similar to filer queries. It is not XY
> problem. I am simply trying to implement  something as described below.
>
> I have a [non-clinical] group sets in system and I want to build bitset
> based on the documents belonging to that group and save it.
> So that, While searching I want to retrieve similar bitset from Solr engine
> for matched document and then execute logical XOR. [Am I clear with problem
> explanation now?]
>
>
> So what I am looking for is, If I have to retrieve bitset instance from
> Solr search engine for the documents matched, how can I get it?
> And How do I save bit mapping for the documents belonging to a particular
> group. thus enable XOR operation.
>
> Thanks - David
>
>
>
>
>
>
>
>
>
>
> On Fri, Nov 1, 2013 at 5:05 PM, Erick Erickson <erickerickson@gmail.com
> >wrote:
>
> > Why are you saving this? Because if the bitset you're saving
> > has anything to do with, say, filter queries, it's probably useless.
> >
> > The internal bitsets are often based on the internal Lucene doc ID,
> > which will change when segment merges happen, thus the caution.
> >
> > Otherwise, theres the binary type you can probably use. It's not very
> > efficient since I believe it uses base-64 encoding under the covers
> > though...
> >
> > Is this an "XY" problem?
> >
> > Best,
> > Erick
> >
> >
> > On Wed, Oct 30, 2013 at 8:06 AM, David Philip
> > <davidphilipsheron@gmail.com>wrote:
> >
> > > Hi All,
> > >
> > > What should be the field type if I have to save solr's open bit set
> value
> > > within solr document object and retrieve it later for search?
> > >
> > >   OpenBitSet bits = new OpenBitSet();
> > >
> > >   bits.set(0);
> > >   bits.set(1000);
> > >
> > >   doc.addField("SolrBitSets", bits);
> > >
> > >
> > > What should be the field type of  SolrBitSets?
> > >
> > > Thanks
> > >
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message