私は2つの完全に異なるURLについては、以下の取得と私は理由を説明することはできません:URLは完全に異なっているので、RESTEASY002142:複数のリソースメソッドの対戦要求
RESTEASY002142:
Multiple resource methods match request "GET /devices/distinctValues/3".
Selecting one.
Matching methods:
[public javax.ws.rs.core.Response
mypackage.DevService.getDistinctValues(int) throws java.lang.Exception,
public javax.ws.rs.core.Response
mypackage.DevRESTService.getDevice(int,java.lang.String)
throws java.lang.Exception]
この警告は、出てくるべきではありません。誰もが知っている場合は、なぜこれが起こっている:両方の方法について
のURL:
getDevice
:
@GET
@Path("devices/{customerId}/{deviceIds}")
@Produces({ "application/json" })
getDistinctValues
:あなたの要求文字列が両方のパスを一致させることができるので
@GET
@Path("devices/distinctValues/{customerId}")
@Consumes("application/json")
@Produces("application/json")