我使用的客户。大容量的方法插入弹性的搜索。 我需要通过retry_on_conflict param在的客户。大容量为每文件。
https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-update.html
以下代码我尝试,但得到的错误。
const options = {
index: config.aws.es.index,
body: bulkBody,
retry_on_conflict: 5
// retryOnCflict: 5 (Tried this also)
};
client.bulk(options, (err, { body }) => {
if (err) {
reject(err);
} else {
// console.log('ES bulk result: %j', body);
resolve(body);
}
});
错误:
warnings: [
'Client - Unknown parameter: "retryOnConflict", sending it as query parameter'
],
任何一个帮助我,如何加retry_on_conflict在的客户。批量().