users@jax-rs-spec.java.net

[jax-rs-spec users] [jsr339-experts] Re: Link.fromResourceMethod

From: Santiago Pericas-Geertsen <Santiago.PericasGeertsen_at_oracle.com>
Date: Mon, 12 Nov 2012 09:53:45 -0500

On Nov 12, 2012, at 2:47 AM, Jan Algermissen <jan.algermissen_at_nordsc.com> wrote:

> Hi,
>
> I am doing this: (don't worry that it does not make sense - it is just test code)
>
> @Path("customer/{id}")
> public class CustomerResource {
>
> @GET
> public Customer getCustomer() {
>
> Link li = Link.fromResourceMethod(CustomerResource.class, "getCustomer","edit").build("42");
> System.out.println("Link: " + li.toString());
>
>
>
> This yields:
>
> Link: <customer/%7Bid%7D>; rel="edit"
>
> That is a bug, isn't it? It should be
>
> Link: <customer/42>; rel="edit"

 Yes, this is a bug. I don't know if the bug is in the API or the RI. Please file a JAX-RS JIRA for this, thanks.

-- Santiago