update to spring-boot-2.1.8.RELEASE & spring-cloud-Greenwich.SR3
This commit is contained in:
+1
-1
@@ -10,7 +10,7 @@ import org.springframework.web.bind.annotation.RequestParam;
|
||||
*
|
||||
* @author ujued
|
||||
*/
|
||||
@FeignClient(value = "txlcn-demo-spring-service-b", fallback = ServiceBFallback.class)
|
||||
@FeignClient(value = "txlcn-demo-spring-service-b")
|
||||
public interface ServiceBClient {
|
||||
|
||||
@GetMapping("/rpc")
|
||||
|
||||
-17
@@ -1,17 +0,0 @@
|
||||
package org.txlcn.demo.common.spring;
|
||||
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
/**
|
||||
* Description:
|
||||
* Date: 19-2-19 下午1:53
|
||||
*
|
||||
* @author ujued
|
||||
*/
|
||||
@Component
|
||||
public class ServiceBFallback implements ServiceBClient {
|
||||
@Override
|
||||
public String rpc(String name) {
|
||||
return "fallback";
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -10,7 +10,7 @@ import org.springframework.web.bind.annotation.RequestParam;
|
||||
*
|
||||
* @author ujued
|
||||
*/
|
||||
@FeignClient(value = "txlcn-demo-spring-service-c", fallback = ServiceCFallback.class)
|
||||
@FeignClient(value = "txlcn-demo-spring-service-c")
|
||||
public interface ServiceCClient {
|
||||
|
||||
@GetMapping("/rpc")
|
||||
|
||||
-19
@@ -1,19 +0,0 @@
|
||||
package org.txlcn.demo.common.spring;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
/**
|
||||
* Description:
|
||||
* Date: 19-2-19 下午1:53
|
||||
*
|
||||
* @author ujued
|
||||
*/
|
||||
@Component
|
||||
@Slf4j
|
||||
public class ServiceCFallback implements ServiceCClient {
|
||||
@Override
|
||||
public String rpc(String name) {
|
||||
return "fallback";
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user