-
Notifications
You must be signed in to change notification settings - Fork 38.6k
Closed
Labels
in: webIssues in web modules (web, webmvc, webflux, websocket)Issues in web modules (web, webmvc, webflux, websocket)type: bugA general bugA general bug
Milestone
Description
Francisco Lozano opened SPR-14383 and commented
I have a controller that looks more or less like this (just relevant parts):
@RequestMapping("/abcd/{myID}/stuff")
public class StuffController extends AbstractBaseController {
/* ... */
@ResponseBody
@ResponseStatus(value = HttpStatus.NO_CONTENT)
@RequestMapping(value = "/*", method = HEAD)
public void checkExists(@PathVariable MyID myID) throws StuffNotFoundException {
stuffService.checkExists(myID, parsePath());
}
@ResponseBody
@RequestMapping(value = "/*", method = GET, produces = StuffRetrievalResponse.JSON_MIME_TYPE)
public StuffRetrievalResponse get(@PathVariable MyID myID) throws StuffNotFoundException {
Stuff stuff = stuffService.get(myID, parsePath());
StuffRetrievalResponse res = new StuffRetrievalResponse();
fill(res, stuff);
return res;
}
}
Now, always GET gets invoked instead of HEAD. We are still debugging but we're thinking that the compareTo method in RequestMethodsRequestCondition is related to the issue.
Affects: 4.3 GA
Referenced from: commits 058279b
1 votes, 3 watchers
Metadata
Metadata
Assignees
Labels
in: webIssues in web modules (web, webmvc, webflux, websocket)Issues in web modules (web, webmvc, webflux, websocket)type: bugA general bugA general bug