Feign PathVariable annotation was empty on param 0

使用Feign的时候,如果参数中带有

@PathVariable形式的参数,则要用value=""标明对应的参数,否则会抛出IllegalStateException异常

@GetMapping("/payment/get/{id}")
public CommonResult<Payment> getPaymentById(@PathVariable(value = "id") String id);
posted @ 2020-05-28 09:27  keepup~  阅读(354)  评论(0编辑  收藏  举报