dev@glassfish.java.net

Re: REST API and slashes in resource names

From: Ken Paulsen <ken.paulsen_at_oracle.com>
Date: Fri, 28 May 2010 14:57:21 -0700

On 05/28/2010 02:41 PM, Bill Shannon wrote:
> Jason Lee wrote on 05/28/10 02:24 PM:
>>> Possibly we could use html encoding?
>> The HTML encoding of '/' is '/' unless I'm missing something. :)
>
> I meant &slash; or whatever the html equivalent is.
That doesn't work in a URL b/c '&' is a special character.
>>> Or even modified UTF-7 from RFC 3501?
>> I'm not familiar with that.
>
> It's kind of ugly, but it was created for a similar purpose.
> Read the RFC for details:
> http://tools.ietf.org/html/rfc3501#section-5.1.3
>
>> What about Andreas' {jndi/foo} suggestion? If we were on git with its
>> easy, lightweight local branches, I'd try that approach as well. As it
>> is, I'll wait for feedback. :)
>
> No git, hg is the way of the future! :-)
>
> I don't see how "{jndi/foo}" solves the original problem.
> Doesn't that just look like two elements in the URL name -
> "{jndi" and "foo}"?
I agree... plus, is now '{' is now reserved??

I think 2x urlencoding is the 2nd best answer. urlencoding (one time)
w/o proxies (or web servers) incorrectly interpreting %2F is the best
answer.

Ken

>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>