lucene-solr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ryan McKinley (JIRA)" <>
Subject [jira] Commented: (SOLR-139) Support updateable/modifiable documents
Date Sun, 04 Feb 2007 19:22:05 GMT


Ryan McKinley commented on SOLR-139:

> If the field modes were parameters, they could be reused for other update handlers like
> Perhaps something like:
> /update/xml?modify=true&f.price.mode=increment,f.features.mode=append

Yes.  I think we should decide a standard 'modify modes' syntax that can be used across handlers.
 In this example, I am using the string:


and passing it to 'parseFieldModes' in XmlUpdateRequestHandler.

Personally, I think all the modes should be specified in a single param rather then a list
of them.  I vote for a syntax like:

<lst name="params">
 <str name="mode">cat=DISTINCT,features=APPEND,price=INCREMENT,sku=REMOVE,OVERWRITE</str>
<lst name="params">
 <str name="mode">cat:DISTINCT,features:APPEND,price:INCREMENT,sku:REMOVE,OVERWRITE</str>

rather then:

<lst name="params">
 <str name="">DISTINCT</str>
 <str name="f.features.mode">APPEND</str>
 <str name="f.price.mode">INCREMENT</str>
 <str name="f.sku.mode">REMOVE</str>
 <str name="modify.default.mode">OVERWRITE</str>

>> sku=REMOVE is required because sku is a stored field that is written to with copyField.
> I'm not sure I quite grok what REMOVE means yet, and how it fixes the copyField problem.

I'm using 'REMOVE' to say "remove the previous value of this field before doing anything."
 Essentially, this makes sure you new document does not start with a value for 'sku'.

> Another way to work around copyField is to only collect stored fields that aren't copyField

I just implemented this.  It is the most normal case, so it should be the default.  It can
be overridden by setting the mode for a copyField explicitly.

> Support updateable/modifiable documents
> ---------------------------------------
>                 Key: SOLR-139
>                 URL:
>             Project: Solr
>          Issue Type: Improvement
>          Components: update
>            Reporter: Ryan McKinley
>         Attachments: SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch,
> It would be nice to be able to update some fields on a document without having to insert
the entire document.
> Given the way lucene is structured, (for now) one can only modify stored fields.
> While we are at it, we can support incrementing an existing value - I think this only
makes sense for numbers.
> for background, see:

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message