使用ES的_bulk进行批处理
相关的报错:
(1){ “error”: “Content-Type header [text/plain;charset=UTF-8] is not supported”, “status”: 406 }
(2)“reason”: “The bulk request must be terminated by a newline [\n]”
【0726存疑】将Content-Type设为application/json,会出现新的错误"The bulk request must be terminated by a newline [\n]”,而这个error解决方法是不能用json改回text。
官网是最好的解决问题的途径。document API,有个NOTE解决了上述主要问题,
【总结如下】
(0)API:POST {
{base_url}}/recip