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 S G <sg...@gmail.com> on 2017/12/26 22:24:01 UTC

"add-field" completes in minutes and sends replicas into full recovery

Hi,

I have a Solr 6.5.1 cluster with a collection spawning 30 VMs.

I see that commands like the below "add-field" command complete in minutes
and send replicas into full recovery:

curl -X POST -H 'Content-type:application/json' --data-binary
'{"add-field":{"name":"some_new_field","type":"string","indexed":true,"stored":true,"required":false
}}' http://my-solr-host:8983/solr/my_collection/schema

{
  "responseHeader":{
    "status":0,
    "QTime":239578}
}


Any idea why that might be so?

We are not stopping the read/write traffic to Solr when adding fields like
the above.

Thanks
SG

Re: "add-field" completes in minutes and sends replicas into full recovery

Posted by Erick Erickson <er...@gmail.com>.
bq: We are not stopping the read/write traffic to Solr ...

The read traffic should be OK, the write traffic is a problem here.

Adding a new field requires a collection reload. As each replica is
reloading, the incoming updates are backing up. If a replica gets
further than 100 docs behind it'll go into a full recovery. Plus all
the leadership changes.

Why the add-field should take minutes I'm not quite sure. Do you have
excessive autowarming going on? Or build suggesters? How long does it
take a single replica to come up when you first start Solr? Does an
add-field take that long when the system is quiescent?

In general the intended use of the schema modification is to help you
get the schema correct before going live. I'd be really reluctant to
modify my collection while it was being indexed to on general
principles...

Best,
Erick

On Tue, Dec 26, 2017 at 2:24 PM, S G <sg...@gmail.com> wrote:
> Hi,
>
> I have a Solr 6.5.1 cluster with a collection spawning 30 VMs.
>
> I see that commands like the below "add-field" command complete in minutes
> and send replicas into full recovery:
>
> curl -X POST -H 'Content-type:application/json' --data-binary
> '{"add-field":{"name":"some_new_field","type":"string","indexed":true,"stored":true,"required":false
> }}' http://my-solr-host:8983/solr/my_collection/schema
>
> {
>   "responseHeader":{
>     "status":0,
>     "QTime":239578}
> }
>
>
> Any idea why that might be so?
>
> We are not stopping the read/write traffic to Solr when adding fields like
> the above.
>
> Thanks
> SG