• 大小: 283KB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2021-01-09
  • 语言: 其他
  • 标签: Springcloud  

资源简介

实现Springcloud向dubbo项目的接口调用。 FeignToDubbo-starter模块负责利用Feign将底层的Http协议转化为dubbo协议,供SpringCloud项目使用。引入FeignToDubbo-starter后会引入dubbo的依赖,使用注解DubboRefence可以标注接口类为调用dubbo api的接口,同时 @DubboReference 的注解可以像Dubbo的Refence一样指定接口的调用参数,@DubboReference 注解标注的接口类会执行Http协议转Dubbo协议,之后的接口调用使用dubbo方式。

资源截图

代码片段和文件信息

package com.example.dubbo.demo.api;

public interface HelloService {

    String sayHello();
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2019-08-21 16:49  demos\
     目录           0  2019-08-21 14:03  demos\springcloud-sentinel-demo\
     文件          80  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-demo.iml
     文件       11567  2019-08-21 11:07  demos\springcloud-sentinel-demo\springcloud-dubbo-demo.iml
     文件        4669  2019-08-21 14:03  demos\springcloud-sentinel-demo\pom.xml
     目录           0  2019-08-22 09:21  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\
     文件         194  2019-08-21 12:34  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\Dockerfile
     文件       14583  2019-08-21 11:07  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\springcloud-dubbo-provider.iml
     文件         899  2019-08-21 14:03  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\pom.xml
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\test\
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\test\java\
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\
     目录           0  2019-08-21 12:32  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\resources\
     文件         311  2019-08-21 12:32  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\resources\application.properties
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\java\
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\java\com\
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\java\com\example\
     文件        1120  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\java\com\example\ProviderApp.java
     文件         992  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\java\com\example\ProviderServiceImpl.java
     文件         174  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\java\com\example\AnotherService.java
     文件          80  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-provider\src\main\java\com\example\ProviderService.java
     目录           0  2019-08-22 09:21  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\
     文件         194  2019-08-21 12:34  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\Dockerfile
     文件         899  2019-08-21 14:02  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\pom.xml
     文件       14583  2019-08-21 11:07  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\springcloud-dubbo-consumer.iml
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\src\
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\src\test\
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\src\test\java\
     目录           0  2019-08-17 12:00  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\src\main\
     目录           0  2019-08-21 12:32  demos\springcloud-sentinel-demo\springcloud-sentinel-consumer\src\main\resources\
............此处省略524个文件信息

评论

共有 条评论