Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RestAPI: Change validation exceptions to respond with 400 status instead of 500 #7619

Closed
wants to merge 1 commit into from

Conversation

rjernst
Copy link
Member

@rjernst rjernst commented Sep 5, 2014

Validation errors are clearly in the realm of client errors (a program with the request). Thus they should return a 4xx response code.

…ead of 500.

Validation errors are clearly in the realm of client errors (a program
with the request).  Thus they should return a 4xx response code.
@s1monw
Copy link
Contributor

s1monw commented Sep 5, 2014

to me that is the right thing to do - @clintongormley what do you think? we should return 400 instead of 500 in the case the request doesn't validate?

@kimchy
Copy link
Member

kimchy commented Sep 5, 2014

LGTM

1 similar comment
@clintongormley
Copy link

LGTM

@rjernst rjernst closed this in 1a9c82d Sep 7, 2014
rjernst added a commit that referenced this pull request Sep 7, 2014
…ead of 500.

Validation errors are clearly in the realm of client errors (a program
with the request).  Thus they should return a 4xx response code.

closes #7619
@rjernst rjernst deleted the fix/validation-resp-code branch January 21, 2015 23:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants