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

JAX-RS @PathParam Field is not validated against @Path annotation value

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 4.2.0.Beta3
    • 4.2.0.Beta2
    • webservices
    • None

      Take the following code:

      @Path("/")
      public class CarResource {
      	
      	@PathParam("id")
      	private Integer id;
      	
      	@GET
      	@Path("{id}")
      	public Object getCar() {
      		return null;
      	}
      }
      

      replace @PathParam("id") with @PathParam("i"), there is no problem reported in 'as-you-type', while there should be (user has to save the file to see the problem markers).
      Same goes when changing the value of the @Path annotation on the method: no 'as-you-type' problem report.

            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: