Open tolinwei opened 9 years ago
You should increase max_bulk_actions
to a higher number like 5000 or 10000, this reduces the number of concurrent bulk requests.
Changing threadpool.bulk.queue_size
is not the correct solution and should be avoided because it overwhelms the cluster when value is set too high. The default value is carefully chosen and is ok.
Thanks @jprante
Now I understand the point that not to change the value of threadpool.bulk.queue_size
. However, I didn't set the value of max_bulk_actions, which mean it's 10000 by default according to your README, why would this error still happens?
In that case, the ES cluster might got very slow in accepting bulk index requests so they piled up. Maybe the server log file contains messages with more details.
[1277]: index [authors], type [author], id [19341514], message [RemoteTransportException[[node-181][192.168.1.181:9300][indices:data/write/bulk[s]]]; nested: EsRejectedExecutionException[rejected execution of org.elasticsearch.action.support.replication.TransportReplicationAction$PrimaryPhase$1@85080 on EsThreadPoolExecutor[bulk, queue capacity = 50, org.elasticsearch.common.util.concurrent.EsThreadPoolExecutor@1cc1d3f[Running, pool size = 8, active threads = 8, queued tasks = 50, completed tasks = 3300]]];]
Any help?
I deleted and re-submitted a river job. After the execution, I noticed that parts of the data in the index was NOT updated, by tailing the log file, there are lots errors like this:
I tried to search this error, and there're several posts say that it's because of too many bulk operation to be contained in the queue, we need to adjust the value of
I also noticed that there are parameters like
'threadpoolsize'
,'interval'
,'max_bulk_actions'
and etc in the README of this repo here. Is there any suggestion to adjust the setting to avoid this error? Thanks in advance.