dev@glassfish.java.net

Re: REST API and slashes in resource names

From: Andreas Loew <Andreas.Loew_at_Sun.COM>
Date: Tue, 01 Jun 2010 12:47:00 +0200

Hi Paul,

Paul Sandoz schrieb:

>> Not quite: '{' and '}' are just "unsafe" characters,
>
> They are disallowed in the URI syntax:
>
> http://greenbytes.de/tech/webdav/rfc2396.html#rfc.section.2.4.3

while I don't want to argue with you about the subtleties of the fact
that curly brackets are *not* part of *neither* "reserved" *nor*
"unreserved" characters, it seems to me that the following would be
fully sanctioned by the spec:

.../management/domain/resources/admin-object-resource/(jndi/foo)

because "normal" brackets are "unreserved" characters: "Data characters
that are allowed in a URI but do not have a reserved purpose are called
unreserved."

So how about wrapping resource values that contain "reserved" characters
by a pair of (unreserved) "normal" brackets '(' and ')'?

Best regards,

Andreas

-- 
Andreas Loew
Senior Java Architect
Sun Microsystems (Germany)