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

Fail search with an error on unknown search parameters #243

Open
acfo opened this issue Mar 21, 2023 · 0 comments
Open

Fail search with an error on unknown search parameters #243

acfo opened this issue Mar 21, 2023 · 0 comments

Comments

@acfo
Copy link

acfo commented Mar 21, 2023

We have a use case where we would like to fail a search with an error if an unknown search parameter was passed to a GET or POST endpoint. Is there a way to hook into the arg resolver to throw an exception if unsupported search parameters are in the request?

Neither the annotation @JsonIgnoreProperties(ignoreUnknown = false) nor the global setting spring.jackson.deserialization.fail-on-unknown-properties=true seem to work for json bodies.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants