Skip to content

Getting _settings or _mapping for non-existing index returns 200 OK #1828

@karmi

Description

@karmi

When doing a request for index settings or mapping, when the index does not exist, ES returns a 200 OK response:

$ curl -i localhost:9200/NOTEXISTING/_mapping
HTTP/1.1 200 OK
Content-Type: application/json; charset=UTF-8
Content-Length: 2

{}

$ curl -i localhost:9200/NOTEXISTING/_settings
HTTP/1.1 200 OK
Content-Type: application/json; charset=UTF-8
Content-Length: 2

{}

It should return an error response, such as 404 Not Found.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions