If there is no way to do this with Jersey is there a way to do it with any other frame work?
Spring is capable of achieving this desired mapping: https://docs.spring.io/spring-framework/reference/web/webmvc/mvc-controller/ann-requestmapping.html#mvc-ann-requestmapping-params-and-headers
This can be accomplished using the params
element of the request mapping annotation. For example:
@GetMapping(value = "/tagSets", produces = MediaType.APPLICATION_JSON_VALUE, params = "entityId")
public TagSets getTagSets(@RequestParam("entityId") Integer entityId) {
...
}
@GetMapping(value = "/tagSets", produces = MediaType.APPLICATION_JSON_VALUE)
public TagSets getTagSets() {
...
}