我的是elasticsearch5点几的版本下面是我的json和报错信息
{
"settings": {
"number_of_shards":3,
"number_of_replicas":1
},
"mappings":{
"properties": {
"name": {
"type": "text"
},
"country": {
"type": "keyword"
},
"age": {
"type": "integer"
},
"data": {
"type": "date",
"format": "yyyy-MM-dd HH:mm:ss||yyyy-MM-dd||epoch_millis"
}
}
}
报错如下:
{
"error": {
"root_cause": [
{
"type": "mapper_parsing_exception",
"reason": "Root mapping definition has unsupported parameters: [birthday : {format=yyyy-MM-dd HHmmss||yyyyMMdd||epoch_millis, type=date}] [country : {type=keyword}] [name : {type=text}] [age : {type=integer}]"
}
],
"type": "mapper_parsing_exception",
"reason": "Failed to parse mapping [properties]: Root mapping definition has unsupported parameters: [birthday : {format=yyyy-MM-dd HHmmss||yyyyMMdd||epoch_millis, type=date}] [country : {type=keyword}] [name : {type=text}] [age : {type=integer}]",
"caused_by": {
"type": "mapper_parsing_exception",
"reason": "Root mapping definition has unsupported parameters: [birthday : {format=yyyy-MM-dd HHmmss||yyyyMMdd||epoch_millis, type=date}] [country : {type=keyword}] [name : {type=text}] [age : {type=integer}]"
}
},
"status": 400
}