sunshinexp1
sunshinexp1
我提供一个Demo吧,三个类: 接口类: ``` public interface DemoInterface { void test(); } ``` 接口实现类: ``` @Service public class DemoInterfaceImpl implements DemoInterface { @RpcReference(microserviceName = "DemoService", schemaId = "demo-api") private IDemoService demoService; @Override...
> 能提供下具体的写法代码吗? Demo代码已经提供,可以看看是否有问题。
请问指导文档里负载均衡章节的“根据实例属性进行路由转发”,是否可以完成上述功能? 服务提供者B默认的tag都是notReady,只有在B初始化完成后,B中的代码把自己的tag设置为Ready; 消费者配置只访问tag为Ready的B的实例。 如果可以实现,还有个疑问,下面文档中这句话如何理解“实例属性可以在microservice.yaml中指定,也可以通过服务中心的API进行修改”,在代码中需要如何设置tag的属性,还需要单独调用服务中的API接口吗? 