Hi,
I'm trying to implement a solution for fast bulk insert of data into ES.
I'm currently noticing that it is the fastest way of inserting data. I have
also tried to implement it through a multi threaded approach with
BulkRequestBuilder but I wasn't able to reach the throughput of
BulkProcessor.
My problem is that at some point I receive exceptions in Listener like no
node is available and the most important is that if I stress it much i see
more docs than the ones inserted (e.g. i insert 500000 docs and i finally
see something like 518018 docs)
Your help will be much appreciated.
I create a processor as follows:
----- CODE ------
processor = BulkProcessor.builder(client, new BulkProcessor.Listener() {
public void beforeBulk(long executionId, BulkRequest
request) {
log.debug(String.format("Execution: %s, about execute
new bulk insert composed of {%s} actions", executionId,
request.numberOfActions()));
}
public void afterBulk(long executionId, BulkRequest
request, BulkResponse response) {
log.debug(String.format("Execution: %s, bulk insert
composed of {%s} actions, took %s", executionId,
request.numberOfActions(),
formatUtils.getDurationDHMS(response.getTookInMillis())));
}
public void afterBulk(long executionId, BulkRequest
request, Throwable failure) {
// throw new RuntimeException(String.format("Execution
with id %s failed", executionId), failure);
}
}).setConcurrentRequests(500).build();
----- CODE ------
--
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+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.