You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to return status of 201 Created along with the URI. However, how do i get the request-path in the first place..
@OverridepublicResponseEntity<Void> createPet (Petp ) {
Petp1 = petRepository.save(p);
returnResponseEntity.created(" request-path.. ?? " + p1.id); // <-- how can i get the input path here
}
Hi @kush20. I might misinterpred your question, but if your question is how to get the request path of the request made to the spring controller. I don't think this is a bug of the generator. This is existing Spring functionality, you can use HttpServletRequest to get the request path of the current request handling thread.
While implementing a
POST
body.I want to return status of
201 Created
along with theURI
. However, how do i get therequest-path
in the first place..i dont want to hard-code
request-path
.The text was updated successfully, but these errors were encountered: