11 2022 档案

摘要:1:Feign是什么 Feign是一个声明式的Web服务客户端,使得编写Web服务客户端变得非常容易,只需要创建一个接口,然后在上面添加注解即可。官网:https://github.com/OpenFeign/feign 2:Feign能干什么 Feign旨在使编写Java Http客户端变得更容易 阅读全文
posted @ 2022-11-13 12:09 小七1990 阅读(19) 评论(0) 推荐(0) 编辑
摘要:是NetFlix远程调用http服务客户端 整合feign: Spring cloud 三板斧:加依赖,加注解,写配置 1.加依赖 <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-s 阅读全文
posted @ 2022-11-11 15:28 小七1990 阅读(35) 评论(0) 推荐(0) 编辑
摘要:添加注解 @FeignClient(name = "user-center", configuration = UserCenterFeignConfiguration.class) 创建类 添加配置 logging: level: # feign 的日志级别是建立在接口日志级别基础上的 com.c 阅读全文
posted @ 2022-11-11 15:28 小七1990 阅读(250) 评论(0) 推荐(0) 编辑
摘要:1.加依赖 <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-actuator</artifactId></dependency> 2.写注解 3.写配置 启动项目: ht 阅读全文
posted @ 2022-11-11 15:28 小七1990 阅读(197) 评论(0) 推荐(0) 编辑
摘要:整合ribbon 1.加依赖--不用加 因为nacos-discovery里就包含了ribbon <dependency> <groupId>com.alibaba.cloud</groupId> <artifactId>spring-cloud-starter-alibaba-nacos-disc 阅读全文
posted @ 2022-11-11 15:28 小七1990 阅读(204) 评论(0) 推荐(0) 编辑
摘要:导入依赖 <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-starter-alibaba-sentinel</artifactId> </dependency> 下载sentinel 阅读全文
posted @ 2022-11-11 15:28 小七1990 阅读(21) 评论(0) 推荐(0) 编辑
摘要:什么是nacos https://nacos.io/zh-cn/docs/what-is-nacos.html 搭建Nacos v2版本中文文档 https://nacos.io/zh-cn/docs/v2/quickstart/quick-start.html 怎么确定nacos版本,下面介绍一个 阅读全文
posted @ 2022-11-11 15:27 小七1990 阅读(199) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示