This is a follow-up to RESTEASY-1077.
getPath() and getPath(false) are missing the trailing slash, when getAbsolutePath() correctly contains it.
This contradicts the javadoc for getAbsolutePath() saying that it's equivalent to uriInfo.getBaseUri().resolve(uriInfo.getPath(false)).
This breaks code such as:
if (!uriInfo.getPath().endsWith("/")) { // make sure there's a trailing slash (for correct relative URI resolution) return Response .status(Response.Status.MOVED_PERMANENTLY) .location(uriInfo.getBaseUriBuilder().path("/test/").build()) .build(); } …
- clones
-
RESTEASY-1124 UriInfo#getPath() is missing trailing slash
- Closed
- is incorporated by
-
JBEAP-4600 Upgrade Resteasy to 3.0.17.Final
- Closed