-
Notifications
You must be signed in to change notification settings - Fork 231
problems upgrade
chengyouling edited this page Mar 3, 2025
·
6 revisions
- 问题描述
从 Spring Cloud Huawei老版本升级到1.10.4及其以上版本,Gateway启动报告错误:
Caused by: java.lang.IllegalArgumentException: Unable to find GatewayFilterFactory with name governance
- 问题原因和解决方案
1.10.4及其以上版本不需要显示的在routes里面启用 governance
Filter。删除即可。
spring:
cloud:
gateway:
discovery:
locator:
enabled: true
lowerCaseServiceId: true
routes:
- id: price
uri: lb://price
predicates:
- Path=/gateway/**
filters:
## 删除 -name governance 配置
- name: governance
- name: Retry
args:
retries: 3
series: SERVER_ERROR
- 问题描述
Spring Cloud Huawei版本升级后,注册中心对应的框架版本展示位置还是原来的版本号:
- 问题原因和解决方案
原因:因为框架版本信息在注册中心中属于服务信息,当bootstrap.yaml中的version版本号不更新时,不更新注册中心服务信息。
解决方案:配置文件bootstrap.yaml调整版本号配置,另外可以增加CAS_INSTANCE_VERSION变量,适配servicestage部署时调整版本号,这样升级时不用手工修改版本号以更新框架版本号。
spring:
cloud:
servicecomb:
discovery:
version: ${CAS_INSTANCE_VERSION:0.0.1}
- 问题描述
基于Spring Cloud Huawei框架使用优雅上、下线能力部署微服务,当服务异常重启后,注册的实例无法访问,状态始终为DOWN。
- 问题原因
服务启动的配置中设置的状态为DOWN,通过优雅上线脚本改变微服务状态对外提供服务,当触发异常重启时,注册的状态为配置中设置的DOWN状态,且无法触发优雅上线改变状态。
- 解决方案
升级Spring Cloud Huawei版本至1.11.8-2021.0.x/2022.0.x/2023.0.X及以上版本。
-
使用Spring Cloud Huawei功能
-
使用服务治理
-
生态集成
-
迁移改造问题
-
配置参考
-
优秀实践
-
常见问题