Skip to content

Conversation

@pugnascotia
Copy link
Contributor

Backport of #49552.

Closes #49428. The code that works out an HTTP code for an exception didn't
consider the JsonParseException case, meant that an invalid JSON request could
result in a 500 Internal Server Error. Now it returns 400 Bad Request.

Closes elastic#49428. The code that works out an HTTP code for an exception didn't
consider the JsonParseException case, meant that an invalid JSON request could
result in a 500 Internal Server Error. Now it returns 400 Bad Request.
@pugnascotia pugnascotia added >bug :Core/Infra/REST API REST infrastructure and utilities backport v7.6.0 labels Nov 25, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra (:Core/Infra/REST API)

@pugnascotia pugnascotia merged commit cf5f013 into elastic:7.x Nov 26, 2019
@pugnascotia pugnascotia deleted the 49428-invalid-json-400-response-7x branch November 26, 2019 12:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport >bug :Core/Infra/REST API REST infrastructure and utilities v7.6.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants