users@jax-rs-spec.java.net

[jax-rs-spec users] [jsr339-experts] ContainerRequestContext setRequestURI

From: Sergey Beryozkin <sberyozkin_at_talend.com>
Date: Mon, 25 Feb 2013 13:09:09 +0000

Hi

What should happen when a single argument ContainerRequestContext
setRequestURI is called with an absolute URI ?

This absolute URI may have the same base as the current base URI, or it
can have a different base.
For example, current base URI is "http://localhost/rest",

I think that calling

requestContext.setRequestURI("http://localhost/rest/next")

is equivalent to calling a 2 arg method,

requestContext.setRequestURI("http://localhost/rest", "/next")

while

requestContext.setRequestURI("http://localhost/newbase/next")

is equivalent to calling

requestContext.setRequestURI("http://localhost/newbase", "/")

Is that right ?

Thanks, Sergey