Hi all,

    My doc has two fileds namely "length" and "fingerprint", which stand for 
the length and text of the doc. I have a custom SearchComponent that enum all 
the docs according to the term to search the fingerprint. That could be very 
slow because the number of docs is very huge and the operation is time consume. 
Since I only care about the docs with the length within a close range around 
that specified in the query, what's the right way to accelerate? Thanks


        DocsEnum docsEnum = sub_reader.termDocsEnum(term);
        if (docsEnum == null) {
              continue;
        }
        while ((doc = docsEnum.nextDoc()) != DocsEnum.NO_MORE_DOCS) {
        // do something expensive
        }

Reply via email to