users@jax-rs-spec.java.net

[jax-rs-spec users] [jsr339-experts] Re: Support for case-insensitive URI parameters ?

From: Jan Algermissen <jan.algermissen_at_nordsc.com>
Date: Fri, 4 Oct 2013 15:47:55 +0200

On 04.10.2013, at 15:24, Sergey Beryozkin <sberyozkin_at_talend.com> wrote:

> Hi
>
> I've got a question from my colleague re supporting case insensitive URI parameters.
>
> I don't see anything in the API regarding it so I assume it is all case-sensitive (PathParam, QueryParam, and MatrixParam), except for HeaderParam.
>
> I guess it is technically correct.

Yep - URIs are and have always been case sensitive.

Anybody mentioning 'case insensitive' and URI in the same sentence should be encouraged to fix his or her use case - putting such anti-patterns in a framework is at best misguiding others.

Don't do it.

Jan

> But IMHO it makes sense to relax it at least for QueryParam and MatrixParam given that they do not affect the matching algorithm, and would simplify it all for the code dealing with the query/matrix params. At the very list this may be can be done optionally, example, UriInfo can have getters for query and matrix param maps with a 'case-sensitive' flag
>
> Will I open a minor enhancement request ?
>
> Thanks, Sergey
>
>
>
>
>