I tried nested mapping in the following way.
PUT /xyz
{
"mappings": {
"logs": {
"properties": {
"startTime": {"type": "date",
"format": "HH:mm:ss"
},
"stopTime": {"type": "date",
"format": "HH:mm:ss"
},
"acceptedRequests": {"type": "integer"},
"clientErrors": {"type": "integer"},
"serverErrors": {"type": "integer"}
},
"predicted":{"type":"nested",
"properties":{
"predict1": {"type":"nested",
"properties":{
"acceptedRequests":{"type":"integer"},
"clientErrors": {"type": "integer"},
"serverErrors": {"type": "integer"}
}
},
"predict2": {"type":"nested",
"properties":{
"acceptedRequests":{"type":"integer"},
"clientErrors": {"type": "integer"},
"serverErrors": {"type": "integer"} }
},
"predict3": {"type":"nested",
"properties":{
"acceptedRequests":{"type":"integer"},
"clientErrors": {"type": "integer"},
"serverErrors": {"type": "integer"}
}
}
}
}
}
}
}
I got an error stating "root_cause": [ { "type": "mapper_parsing_exception", "reason": "Root mapping definition has unsupported parameters: [type : nested]"
Any help is appreciated.