spring-projects / spring-projects/spring-data-commons
URI template with '*' for parameters that support multiple values [DATACMNS-780]
@odrotbohm is already working on this.
Since Dec 30, 2020.
- Dominant language
- Java
- Stars
- 838
- Forks
- 730
- PR merge metrics
- No merged PRs in 30d
Description
Mirco Andreon opened DATACMNS-780 and commented
Hello,
I created a search service like this for my resource:
List<Booking> findByStatusIn(@Param("status") Collection<BookingStatus> status);
Hence it allows multiple values for parameter "status".
When I invoke http://localhost:8080/myapp/rest/myresources I get:
{
"_links" : {
"findByStatusIn" : {
"href" : "http://localhost:8080/myapp/rest/myresources/search/findByStatusIn{?status}",
"templated" : true
}
}
}
This seems incorrect, since the "href" should be "http://localhost:8080/myapp/rest/myresources/search/findByStatusIn{?status*}, that is include an asterisk after the parameter name. This comes from RFC 6570 as stated here https://github.com/basti1302/traverson/issues/41
Affects: 1.9.3 (Evans SR3), 1.10.2 (Fowler SR2), 1.11 GA (Gosling)
Reference URL: https://github.com/basti1302/traverson/issues/41
1 votes, 3 watchers
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.