On 11/28/2018 6:22 PM, Wei wrote:
I use the following http request to start solr index optimization:

http://localhost:8983/solr/<core>/update?skipError=true -F stream.body='
<optimize />'

The request returns status code 200 shortly, but when looking at the solr
instance I noticed that actual optimization has not completed yet as there
are more than 1 segments. Is the optimize command async? What is the best
approach to validate that optimize is truly completed?

I do not know how that request can return a 200 before the optimize job completes.  The "wait" parameters (one of which Christopher mentioned) should all default to true, and I don't see them on your request.  As far as I know, the operation is NOT asynchronous.  Are you absolutely sure that it returned a 200? I'd like to see the actual response to verify.

I hate to assume you're wrong, but I think it's probably more likely that your HTTP request timed out because of overly aggressive timeout settings, probably a socket timeout.  If you have definitive proof that you received the 200 and a normal-looking response, then we'll need to look deeper.  Do you have the entry in solr.log for the optimize request?

Thanks,
Shawn

Reply via email to