当type声明string为时,Elasticsearch 6.0将显示此错误。
type
string
"name" => [ "type" => "string", "analyzer" => "ik_max_word" ]
Elasticsearch删除了该string类型,现在正在使用text。所以你的代码应该是这样的
text
"name" => [ "type" => "text", "analyzer" => "ik_max_word" ]