Uploaded image for project: 'Tools (JBoss Tools)'
  1. Tools (JBoss Tools)
  2. JBIDE-15600

MatrixParam and QueryParam field names are used instead of the annotation values

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • 4.1.1.Beta1
    • 4.1.0.Final
    • webservices
    • None

      Take the following classes:

      @Path("/products")
      public class ProductResourceLocator {
      
      	@QueryParam("foo1")
      	private String foo2;
      
              @Path("/{productType}")
      	public Object getProductResourceLocator() {
      		return new BookResource(); 
      	}
      }
      

      and

      @Produces({ MediaType.APPLICATION_XML, "application/json" })
      public class BookResource {
      
      	@GET
      	@Path("/{id}")
      	@Produces({ "application/xml", "application/json" })
      	public Book getProduct(@PathParam("id") Integer id) {
      		return null;
      	}
      }
      

      ASSERT: the URL Template for the Endpoint should be something like

      /products/{productType}/{id}?foo1={String}
      

      FAIL: the URL Template for the Endpoint should be something like

      /products/{productType}/{id}?foo2={String}
      

            xcoulon@redhat.com Xavier Coulon
            xcoulon@redhat.com Xavier Coulon
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: