我曾经有ElasticSearch 5.2,并且刚升级到6.0。
我正在尝试按照此处的指南创建索引模板,但出现错误
Content-Type header [application/x-www-form-urlencoded] is not supported
我的查询是
curl -X PUT localhost:9200/_template/template_1 -d '
{
"index_patterns": ["te*", "bar*"],
"mappings": {
"type1": {
"properties": {
"host_name": {
"type": "keyword"
}
}
}
}
}'