You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-commits@lucene.apache.org by ko...@apache.org on 2009/02/08 15:32:13 UTC
svn commit: r742106 - in /lucene/solr/trunk: CHANGES.txt
src/java/org/apache/solr/handler/XMLLoader.java
Author: koji
Date: Sun Feb 8 14:32:13 2009
New Revision: 742106
URL: http://svn.apache.org/viewvc?rev=742106&view=rev
Log:
SOLR-976: deleteByQuery is ignored when deleteById is placed prior to deleteByQuery in a <delete>
Modified:
lucene/solr/trunk/CHANGES.txt
lucene/solr/trunk/src/java/org/apache/solr/handler/XMLLoader.java
Modified: lucene/solr/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/CHANGES.txt?rev=742106&r1=742105&r2=742106&view=diff
==============================================================================
--- lucene/solr/trunk/CHANGES.txt (original)
+++ lucene/solr/trunk/CHANGES.txt Sun Feb 8 14:32:13 2009
@@ -247,6 +247,13 @@
28. SOLR-1008: Fix stats.jsp XML encoding for <stat> item entries with ampersands in their names. (ehatcher)
+29. SOLR-976: deleteByQuery is ignored when deleteById is placed prior to deleteByQuery in a <delete>.
+ Now both delete by id and delete by query can be specified at the same time as follows. (koji)
+ <delete>
+ <id>05991</id><id>06000</id>
+ <query>office:Bridgewater</query><query>office:Osaka</query>
+ </delete>
+
Other Changes
----------------------
Modified: lucene/solr/trunk/src/java/org/apache/solr/handler/XMLLoader.java
URL: http://svn.apache.org/viewvc/lucene/solr/trunk/src/java/org/apache/solr/handler/XMLLoader.java?rev=742106&r1=742105&r2=742106&view=diff
==============================================================================
--- lucene/solr/trunk/src/java/org/apache/solr/handler/XMLLoader.java (original)
+++ lucene/solr/trunk/src/java/org/apache/solr/handler/XMLLoader.java Sun Feb 8 14:32:13 2009
@@ -231,6 +231,8 @@
"unexpected XML tag /delete/" + currTag);
}
processor.processDelete(deleteCmd);
+ deleteCmd.id = null;
+ deleteCmd.query = null;
break;
// Add everything to the text
Re: svn commit: r742106 - in /lucene/solr/trunk: CHANGES.txt src/java/org/apache/solr/handler/XMLLoader.java
Posted by Koji Sekiguchi <ko...@r.email.ne.jp>.
Chris Hostetter wrote:
> : I think it is true. Unfortunately I didn't have time to write test for it, but
> : I
> : tested it by manual when I committed it... Do you see it doesn't work?
>
> Hmmm.
>
> It does work ... I don't understand why it works, but it works.
>
>
> -Hoss
>
>
>
It should work. I don't understand why you think so...
Koji
Re: svn commit: r742106 - in /lucene/solr/trunk: CHANGES.txt
src/java/org/apache/solr/handler/XMLLoader.java
Posted by Chris Hostetter <ho...@fucit.org>.
: I think it is true. Unfortunately I didn't have time to write test for it, but
: I
: tested it by manual when I committed it... Do you see it doesn't work?
Hmmm.
It does work ... I don't understand why it works, but it works.
-Hoss
Re: svn commit: r742106 - in /lucene/solr/trunk: CHANGES.txt src/java/org/apache/solr/handler/XMLLoader.java
Posted by Koji Sekiguchi <ko...@r.email.ne.jp>.
> is this really true?
I think it is true. Unfortunately I didn't have time to write test for
it, but I
tested it by manual when I committed it... Do you see it doesn't work?
Koji
Chris Hostetter wrote:
> :
> : +29. SOLR-976: deleteByQuery is ignored when deleteById is placed prior to deleteByQuery in a <delete>.
> : + Now both delete by id and delete by query can be specified at the same time as follows. (koji)
> : + <delete>
> : + <id>05991</id><id>06000</id>
> : + <query>office:Bridgewater</query><query>office:Osaka</query>
> : + </delete>
> : +
>
> is this really true? the patch only modifies XMLLoader, but don't
> DeleteUpdateCommand and RunUpdateProcessor also need to be changed to make
> this work ... there's was no test commited with this patch so i'm not
> convinced, and i see this code in RunUpdateProcessor...
>
> if( cmd.id != null ) {
> updateHandler.delete(cmd);
> }
> else {
> updateHandler.deleteByQuery(cmd);
> }
>
>
>
> -Hoss
>
>
>
Re: svn commit: r742106 - in /lucene/solr/trunk: CHANGES.txt
src/java/org/apache/solr/handler/XMLLoader.java
Posted by Chris Hostetter <ho...@fucit.org>.
:
: +29. SOLR-976: deleteByQuery is ignored when deleteById is placed prior to deleteByQuery in a <delete>.
: + Now both delete by id and delete by query can be specified at the same time as follows. (koji)
: + <delete>
: + <id>05991</id><id>06000</id>
: + <query>office:Bridgewater</query><query>office:Osaka</query>
: + </delete>
: +
is this really true? the patch only modifies XMLLoader, but don't
DeleteUpdateCommand and RunUpdateProcessor also need to be changed to make
this work ... there's was no test commited with this patch so i'm not
convinced, and i see this code in RunUpdateProcessor...
if( cmd.id != null ) {
updateHandler.delete(cmd);
}
else {
updateHandler.deleteByQuery(cmd);
}
-Hoss