Skip to content

Collection parameters for @Query-annotated methods get escaped wrongly #1858

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

Closed
herder opened this issue Jul 1, 2021 · 1 comment · Fixed by #1856
Closed

Collection parameters for @Query-annotated methods get escaped wrongly #1858

herder opened this issue Jul 1, 2021 · 1 comment · Fixed by #1856
Labels
status: waiting-for-triage An issue we've not yet triaged

Comments

@herder
Copy link
Contributor

herder commented Jul 1, 2021

The @Query annotation breaks when providing a collection parameter - it calls toString() on the parameter and escapes the result, which makes the list look like this [\"some\",\"params\"], causing a 400 from Elasticsearch

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Jul 1, 2021
sothawo pushed a commit that referenced this issue Jul 3, 2021
@sothawo sothawo added this to the 4.3 M1 (2021.1.0) milestone Jul 3, 2021
sothawo pushed a commit that referenced this issue Jul 3, 2021
Original Pull Request #1856
Closes #1858

(cherry picked from commit 6f84a1c)
(cherry picked from commit 254948d)
(cherry picked from commit 979c164)
sothawo pushed a commit that referenced this issue Jul 3, 2021
Original Pull Request #1856
Closes #1858

(cherry picked from commit 6f84a1c)
(cherry picked from commit 254948d)
sothawo pushed a commit that referenced this issue Jul 3, 2021
Original Pull Request #1856
Closes #1858

(cherry picked from commit 6f84a1c)
@sothawo
Copy link
Collaborator

sothawo commented Jul 3, 2021

backported to branches 4.2.x, 4.1.x, 4.0.x

sothawo pushed a commit that referenced this issue Jul 6, 2021
Original Pull Request #1856
Closes #1858

(cherry picked from commit 6f84a1c)
(cherry picked from commit 254948d)
(cherry picked from commit 979c164)
(cherry picked from commit d6cfc20)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: waiting-for-triage An issue we've not yet triaged
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants