lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shai Erera (JIRA)" <>
Subject [jira] [Commented] (LUCENE-4575) Allow IndexWriter to commit, even just commitData
Date Thu, 29 Nov 2012 15:16:58 GMT


Shai Erera commented on LUCENE-4575:

We use commitData extensively but we don't care about the order. We store key/value pairs.

I don't think though that it's trivial to support. Currently the user can pass any Map, but
IndexReader returns in practice a HashMap (DataInput.readStringStringMap initializes a HashMap).
Therefore, if we want to preserve the type of the Map, we'd need to change DataInput/Output
code. I'm not sure it's worth the hassle, but let's discuss that anyway on a separate issue?
It's not really related to how the map is set.
> Allow IndexWriter to commit, even just commitData
> -------------------------------------------------
>                 Key: LUCENE-4575
>                 URL:
>             Project: Lucene - Core
>          Issue Type: Improvement
>          Components: core/index
>            Reporter: Shai Erera
>            Priority: Minor
>         Attachments: LUCENE-4575.patch
> Spinoff from here
> In some cases, it is valuable to be able to commit changes to the index, even if the
changes are just commitData. Such data is sometimes used by applications to register in the
index some global application information/state.
> The proposal is:
> * Add a setCommitData() API and separate it from commit() and prepareCommit() (simplify
their API)
> * When that API is called, flip on the dirty/changes bit, so that this gets committed
even if no other changes were made to the index.
> I will work on a patch a post.

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:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message