You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Jack L <jl...@yahoo.ca> on 2007/04/01 01:41:19 UTC

Update doc boost and field boost w/o reposting?

I understand that I'm supposed to delete the old record and
re-post in order to update a document. But in many cases,
it takes time to extract data (from a database, etc.) and all
I want to change is the document boost. I wonder if it's possible
to adjust the document boost without deleting and re-posting
a whole document?

-- 
Best regards,
Jack


Re: Update doc boost and field boost w/o reposting?

Posted by Chris Hostetter <ho...@fucit.org>.
: Lucene does not have any way to modify existing fields, so solr can't
: do it either...  (document boosts are stored as part of the field)

Actually, this question crossess over into a special case area.  While you
certianly can't "update" a Lucene doc, you can modify the fieldNorm of any
[doc,field] pair using IndexReder.setNorm.  So if you used
TermFreqVectors (to see how many terms oare in the field), you could
update the norm of a field using a new boost.

changing just hte field boost or just the doc boost would be impossible
(because no record is kept of what those independent values were) but
changing just the total boost for some fields would be possible.




-Hoss


Re: Re[2]: Update doc boost and field boost w/o reposting?

Posted by Ryan McKinley <ry...@gmail.com>.
Yes, it is only solr - and will have a normal HTTP interface, no lucene.

But as i said, the catch is that *all* fields must be stored, not only
the ones you want to change.  Solr will pull the document out of the
index, modify it and put it back - it can only pull out stored fields
so you must store everything...



On 4/1/07, Jack L <jl...@yahoo.ca> wrote:
> Hello Ryan,
>
> Interesting. So it's solr only and does not require new Lucene
> functionality? I think storing the fields that may change in
> the future is ok.
>
> --
> Best regards,
> Jack
>
> Saturday, March 31, 2007, 5:50:20 PM, you wrote:
>
> > Lucene does not have any way to modify existing fields, so solr can't
> > do it either...  (document boosts are stored as part of the field)
>
> > In http://issues.apache.org/jira/browse/SOLR-139, I'm working on a
> > convenience function to let the client modify an existing solr
> > document - the one catch is that all fields must be stored so they can
> > be extracted and re-indexed on the server side.  This may not help
> > your performance concern, but it may be easier to deal with.
>
> > ryan
>
>
> > On 3/31/07, Jack L <jl...@yahoo.ca> wrote:
> >> I understand that I'm supposed to delete the old record and
> >> re-post in order to update a document. But in many cases,
> >> it takes time to extract data (from a database, etc.) and all
> >> I want to change is the document boost. I wonder if it's possible
> >> to adjust the document boost without deleting and re-posting
> >> a whole document?
> >>
> >> --
> >> Best regards,
> >> Jack
> >>
> >>
>
>

Re[2]: Update doc boost and field boost w/o reposting?

Posted by Jack L <jl...@yahoo.ca>.
Hello Ryan,

Interesting. So it's solr only and does not require new Lucene
functionality? I think storing the fields that may change in
the future is ok.

-- 
Best regards,
Jack

Saturday, March 31, 2007, 5:50:20 PM, you wrote:

> Lucene does not have any way to modify existing fields, so solr can't
> do it either...  (document boosts are stored as part of the field)

> In http://issues.apache.org/jira/browse/SOLR-139, I'm working on a
> convenience function to let the client modify an existing solr
> document - the one catch is that all fields must be stored so they can
> be extracted and re-indexed on the server side.  This may not help
> your performance concern, but it may be easier to deal with.

> ryan


> On 3/31/07, Jack L <jl...@yahoo.ca> wrote:
>> I understand that I'm supposed to delete the old record and
>> re-post in order to update a document. But in many cases,
>> it takes time to extract data (from a database, etc.) and all
>> I want to change is the document boost. I wonder if it's possible
>> to adjust the document boost without deleting and re-posting
>> a whole document?
>>
>> --
>> Best regards,
>> Jack
>>
>>


Re: Update doc boost and field boost w/o reposting?

Posted by Ryan McKinley <ry...@gmail.com>.
Lucene does not have any way to modify existing fields, so solr can't
do it either...  (document boosts are stored as part of the field)

In http://issues.apache.org/jira/browse/SOLR-139, I'm working on a
convenience function to let the client modify an existing solr
document - the one catch is that all fields must be stored so they can
be extracted and re-indexed on the server side.  This may not help
your performance concern, but it may be easier to deal with.

ryan


On 3/31/07, Jack L <jl...@yahoo.ca> wrote:
> I understand that I'm supposed to delete the old record and
> re-post in order to update a document. But in many cases,
> it takes time to extract data (from a database, etc.) and all
> I want to change is the document boost. I wonder if it's possible
> to adjust the document boost without deleting and re-posting
> a whole document?
>
> --
> Best regards,
> Jack
>
>