Consider the code above
@Path("a")
@Produces("text/plain")
public class A {
@GET
@Path("a")
public String getA() {
return "a";
}
@GET
@Path("a")
public String getB() {
return "b";
}
}
Requesting http://host/a/a i always get “b”.
What is the strategy to select the appropiated method ?
Any way to get informed about multiple paths to diferent resources ?
Further edited in light of the comment
I don’t know of any reporting tool within RESTEasy that offers a list of duplicated matching patterns across a range of annotated service classes. However, you could approach this problem using one of the following methods:
Edited to better target the question
RESTEasy uses a regex based system for paths and selects the most closely matching pattern. In the event of a collision the last one matched is used.