Return-Path: X-Original-To: apmail-lucene-dev-archive@www.apache.org Delivered-To: apmail-lucene-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 82E3997B3 for ; Sat, 5 May 2012 16:46:22 +0000 (UTC) Received: (qmail 51871 invoked by uid 500); 5 May 2012 16:46:22 -0000 Delivered-To: apmail-lucene-dev-archive@lucene.apache.org Received: (qmail 51799 invoked by uid 500); 5 May 2012 16:46:22 -0000 Mailing-List: contact dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@lucene.apache.org Delivered-To: mailing list dev@lucene.apache.org Received: (qmail 51758 invoked by uid 99); 5 May 2012 16:46:22 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 05 May 2012 16:46:22 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 05 May 2012 16:46:19 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 6D641432D60 for ; Sat, 5 May 2012 16:45:58 +0000 (UTC) Date: Sat, 5 May 2012 16:45:58 +0000 (UTC) From: "Yonik Seeley (JIRA)" To: dev@lucene.apache.org Message-ID: <229156610.30553.1336236358458.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (SOLR-139) Support updateable/modifiable documents MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/SOLR-139?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yonik Seeley updated SOLR-139: ------------------------------ Attachment: SOLR-139.patch Here's a patch for updateable docs that reuses the infrastructure we put in place around versioning and realtime-get. Only the JSON parser is currently implemented. Recall that a normal field value in JSON is of the form: {code} "myfield":10 {code} This patch extends the JSON parser to support extended values as a Map. For example, to add an additional value to a multi-valued field, you would use {code} "myfield":{"add":10} {code} Using an existing data structure (a Map) should allow us to pass this through javabin format w/o any additional changes. This patch depends on optimistic locking (it's currently included in this patch) and updating documents fully supports optimistic locking (i.e. you can conditionally update a document based on it's version) Right now only "add" and "set" are supported as mutators (and setting a null value is like "remove"), but I figured it would be best to do a slice first from start to finish. Comments? > Support updateable/modifiable documents > --------------------------------------- > > Key: SOLR-139 > URL: https://issues.apache.org/jira/browse/SOLR-139 > Project: Solr > Issue Type: New Feature > Components: update > Reporter: Ryan McKinley > Attachments: Eriks-ModifiableDocument.patch, Eriks-ModifiableDocument.patch, Eriks-ModifiableDocument.patch, Eriks-ModifiableDocument.patch, Eriks-ModifiableDocument.patch, Eriks-ModifiableDocument.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-IndexDocumentCommand.patch, SOLR-139-ModifyInputDocuments.patch, SOLR-139-ModifyInputDocuments.patch, SOLR-139-ModifyInputDocuments.patch, SOLR-139-ModifyInputDocuments.patch, SOLR-139-XmlUpdater.patch, SOLR-139.patch, SOLR-269+139-ModifiableDocumentUpdateProcessor.patch, getStoredFields.patch, getStoredFields.patch, getStoredFields.patch, getStoredFields.patch, getStoredFields.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: > http://www.nabble.com/loading-many-documents-by-ID-tf3145666.html#a8722293 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org For additional commands, e-mail: dev-help@lucene.apache.org