New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Java API: BulkProcessor does not call afterBulk when bulk throws eg NoNodeAvailableException #5038
Comments
Any progress on this yet? |
I'm trying to implement a workaround for #6314 and this is required. Any update here for a fix? |
Hello, I'm seeing an issue with the bulk request API where I am sending many bulk requests simultaneously. When my index reaches a certain size and the amount of memory assigned to each shard is increased (i.e. increasing from 56Mb allocated to 128Mb allocated) the pending bulk requests fail to respond (i.e. no call to 'onResponse' or 'onFailure' in the BulkRequest ActionListener) effectively locking my application from sending any additional requests as the semaphore flags acquired before calling 'execute' are never released. Could this issue relate to a problem that I am seeing with the bulk request API? Thanks, |
Hi @javanna, Within my own client application I manage the number of bulk requests which may be sent using a semaphore flag which is acquired before calling execute and released once a response is received. Also, I do not see any exceptions coming from the elasticsearch node. Simply the statement that the amount of memory allocated to each shard is to be increased at which point the number of pending requests in my client application steadily increases without any response from the server. I am still able to execute curl -XGet requests (i.e. elastisearch cluster state is reported as green on request). I hope that helps. All the best, |
Then the problem can't be in the |
Also strenghtened BulkProcessorTests by adding randomizations to existing tests and new tests for concurrent requests and expcetions Closes elastic#5038
… beforeBulk Moved BulkProcessor tests from BulkTests to newly added BulkProcessorTests class. Strenghtened BulkProcessorTests by adding randomizations to existing tests and new tests for concurrent requests and expcetions. Also made sure that afterBulk is called only once per request if concurrentRequests==0. Closes #5038
Thanks for the suggestion. I've switched to the BulkProcessor and found the On 13 June 2014 15:59, Luca Cavanna notifications@github.com wrote:
|
When using a BulkProcessor with setting concurrentRequests > 0 and an exception occurs on row 283 (client.bulk(...)) other than InterruptedException then it is not caught and subsequently the afterBulk function is never called.
It is reproducible by running:
This problem leads to that you only get exception for 1 of the documents in the bulk and there is no way to know that the other documents also failed.
The text was updated successfully, but these errors were encountered: