I have a situation where, using the Java API, I initiate a bunch of 
indexing operations, but throw away the Future object (I don't need the 
return status).  This is so I can do a lot of indexing reasonably 
asynchronously, so I don't have to hold up the GUI that triggers these 
calls.

However, if I fire off these indexing operations, and immediately after do 
a search operation on the same index, I get the following exception:

Caused by: org.elasticsearch.action.search.SearchPhaseExecutionException: 
Failed to execute phase [init_scan], all shards failed
at 
org.elasticsearch.action.search.type.TransportSearchTypeAction$BaseAsyncAction.onFirstPhaseResult(TransportSearchTypeAction.java:233)
 
[elasticsearch-1.4.1.jar:]
at 
org.elasticsearch.action.search.type.TransportSearchTypeAction$BaseAsyncAction$1.onFailure(TransportSearchTypeAction.java:179)
 
[elasticsearch-1.4.1.jar:]
at 
org.elasticsearch.search.action.SearchServiceTransportAction$23.run(SearchServiceTransportAction.java:565)
 
[elasticsearch-1.4.1.jar:]
at 
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) 
[rt.jar:1.7.0_60]
at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) 
[rt.jar:1.7.0_60]
... 1 more


... however, if I wait awhile after indexing before searching, the search 
succeeds, no errors.

Does anyone know what is going on there?  Shouldn't initiating an index 
operation asynchronously not affect search operations made on the same 
client?

I'm using a TransportClient, the same one for all operations.

- Tim

-- 
You received this message because you are subscribed to the Google Groups 
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to elasticsearch+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/7be3f287-edb3-4979-93c0-38e98317a545%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to