You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Grant Ingersoll (JIRA)" <ji...@apache.org> on 2007/02/09 04:20:05 UTC
[jira] Resolved: (LUCENE-762) [PATCH] Efficiently retrieve sizes of
field values
[ https://issues.apache.org/jira/browse/LUCENE-762?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Grant Ingersoll resolved LUCENE-762.
------------------------------------
Resolution: Fixed
I have committed the original patch. All tests pass. In the end, I could not find a way I felt comfortable with for getting rid of the if-then-else clause in FieldsReader. I did add a TODO item there to remind us to go back and take a look at it again later.
Since the if clauses are ordered according to their most common usages (I think), I don't think there will be much of a performance issue w/ the current approach.
> [PATCH] Efficiently retrieve sizes of field values
> --------------------------------------------------
>
> Key: LUCENE-762
> URL: https://issues.apache.org/jira/browse/LUCENE-762
> Project: Lucene - Java
> Issue Type: New Feature
> Components: Store
> Affects Versions: 2.1
> Reporter: Chuck Williams
> Assigned To: Grant Ingersoll
> Priority: Minor
> Attachments: SizeFieldSelector.patch
>
>
> Sometimes an application would like to know how large a document is before retrieving it. This can be important for memory management or choosing between algorithms, especially in cases where documents might be very large.
> This patch extends the existing FieldSelector mechanism with two new FieldSelectorResults: SIZE and SIZE_AND_BREAK. SIZE creates fields on the retrieved document that store field sizes instead of actual values. SIZE_AND_BREAK is especially efficient if one field comprises the bulk of the document size (e.g., the body field) and can thus be used as a reasonable size approximation.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org