14 lines
449 B
Java
14 lines
449 B
Java
|
package cn.bunny.feign;
|
||
|
|
||
|
import org.springframework.cloud.openfeign.FeignClient;
|
||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||
|
import org.springframework.web.bind.annotation.RequestParam;
|
||
|
|
||
|
@FeignClient(value = "service-cloud2", path = "/api")
|
||
|
public interface CloudFeignClient {
|
||
|
|
||
|
// 调用时如果请求类型不同需要考虑加上 @RequestParam
|
||
|
@GetMapping("feignCloud2")
|
||
|
String getFeignCloud2(@RequestParam Long id);
|
||
|
}
|