On Apr 5, 2010, at 11:56 PM, Gregg Carrier wrote:
> Just updated to 1.5.1.1 and re-confirmed with your @Path that I
> still have the problem. I get a 406 on /queries and /queries/
>
A 406 is related to the matching of @Produces and not @Path matching:
http://greenbytes.de/tech/webdav/rfc2616.html#status.406
I would need to see more of your code. The best thing to do is send a
reproducible test case to the list.
> /queries.json resolves fine. Any ideas how I can track down what's
> going on and why it isn't working as in your example?
>
Enabling tracing can help:
https://jersey.dev.java.net/nonav/apidocs/latest/jersey/com/sun/jersey/api/core/ResourceConfig.html
#FEATURE_TRACE
BTW i am on leave this week so i may not respond until next week,
Paul.
> Thanks!
>
> Gregg
>
> On Mon, Apr 5, 2010 at 9:04 AM, Gregg Carrier
> <greggcarrier_at_gmail.com> wrote:
> Jersey 1.1.5 Thanks, Paul.
>
>
> On Thu, Apr 1, 2010 at 3:20 AM, Paul Sandoz <Paul.Sandoz_at_sun.com>
> wrote:
> Hi Gregg,
>
> The following worked for me:
>
> @GET
> @Path("{x: queries(\\.json)?}")
> public String get() {
> return "FOO";
> }
>
> for the following paths:
>
> /.../queries
> /.../queries/
> /.../queries.json
> /.../queries.json/
>
> what version of Jersey are you using?
>
> Paul.
>
> On Apr 1, 2010, at 12:47 AM, Gregg Carrier wrote:
>
>> Dropping the leading "/" makes it match /queries.json but not /
>> queries or /queries/
>>
>> Thanks for the idea.
>>
>> On Wed, Mar 31, 2010 at 12:21 PM, Marc Hadley
>> <marc.hadley_at_oracle.com> wrote:
>> On Mar 30, 2010, at 5:58 PM, Gregg Carrier wrote:
>>
>> > I'm trying to match
>> > /queries
>> > AND
>> > /queries.json
>> >
>> > This is my @Path:
>> > @Path("{dummy:/queries(\\.json)?}")
>> >
>> > Seems like a simple enough regex - can't get Jersey to do the
>> right thing.
>> >
>> Does it work if you drop the leading '/' in the regex ?
>>
>> Marc.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
>> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>>
>>
>
>
>