Closed
Description
Describe the bug
"." as field name yields array_index_out_of_bounds_exception
Related component
Indexing
To Reproduce
Dev Tools:
POST index_name/_doc
{".":"foo"}
Yields
{
"error": {
"root_cause": [
{
"type": "mapper_parsing_exception",
"reason": "failed to parse"
}
],
"type": "mapper_parsing_exception",
"reason": "failed to parse",
"caused_by": {
"type": "array_index_out_of_bounds_exception",
"reason": "Index -1 out of bounds for length 0"
}
},
"status": 400
}
Expected behavior
We could either index the document or yield a better error message.
Additional Details
Plugins
Defaults in docker
Screenshots
n/a
Host/Environment (please complete the following information):
- OS: n/a - using docker.io/opensearchproject/opensearch:latest
- Version - affects 2.15.0 and earlier
Additional context
n/a