xiaomanstudy

今天写微服务项目加入gateway网关时访问一直有如下错误

后来进入filter方法中发现host为null

后来查找博客发现
在gateway中配置uri配置有三种方式,包括
第一种:ws(websocket)方式: uri: ws://localhost:9000
第二种:http方式: uri: http://localhost:8130/
第三种:lb(注册中心中服务名字)方式: uri: lb://brilliance-consumer
能被gateway uri识别的

 "[a-zA-Z]([a-zA-Z]|\\d|\\+|\\.|-)*:.*"

这也意味着,java命名规范中可以使用的英文下划线("_")不能被识别
于是我把hms_user改为了hms-user

分类:

技术点:

相关文章:

  • 2021-11-20
  • 2021-11-20
  • 2021-06-19
  • 2022-12-23
  • 2021-07-11
  • 2022-12-23
  • 2022-12-23
  • 2021-12-03
猜你喜欢
  • 2021-10-27
  • 2021-07-30
  • 2022-12-23
  • 2021-07-23
  • 2021-11-20
  • 2021-12-23
  • 2021-07-05
相关资源
相似解决方案