腾讯云
开发者社区
文档
建议反馈
控制台
首页
学习
活动
专区
工具
TVP
最新优惠活动
文章/答案/技术大牛
搜索
搜索
关闭
发布
登录/注册
精选内容/技术社群/优惠产品,
尽在小程序
立即前往
文章
问答
(1283)
视频
沙龙
1
回答
在
spring
cloud
gateway
中
禁止
未经
认证
的
请求
,
并在
http
body
中
写入
错误信息
我有一个自定义
的
网关过滤器工厂来检查
请求
是否有效或者抛出一个异常,我有一个ErrorWebExceptionHandler来处理这个异常。我已经读过Forbid Unauthenticated requests in
Spring
Cloud
Gateway
了,我
在
我
的
ErrorWebExceptionHandler
中
尝试过:// error
body
is some Object exch
浏览 43
提问于2020-10-22
得票数 0
回答已采纳
1
回答
在
Spring
中转发
请求
之前,我们如何进行一些处理?
、
、
我
的
用例如下:X (作为反向代理
的
spring
云应用程序)A、B、C(分别部署了
spring
引导应用程序)
spring
:
gateway
: - id: A uri:
http
所以流程会是
浏览 2
提问于2021-08-12
得票数 0
回答已采纳
1
回答
Spring
Cloud
Gateway
和DiscoveryClient路由
我正在尝试将一个使用
spring
-
cloud
-starter-netflix-zuul
的
网关迁移到
Spring
Cloud
Gateway
,我遇到了
请求
路由
的
问题。以下是我
的
Netflix Zuul配置
中
的
一段代码: zuul: account-service: /accounts/** 下面是
Spring
Cloud</em
浏览 28
提问于2019-03-13
得票数 7
1
回答
Eureka服务器
在
微服务体系结构
中
的
应用
、
、
我
在
我
的
微服务应用程序Ex中使用"
Spring
网关“:
spring
.
cloud
.
gateway
.routes[0].uri=
http
://localhost:8100/
spring
.
cloud
.
gateway
.routes[0
浏览 5
提问于2022-08-10
得票数 0
3
回答
如何在application.yml
Spring
Cloud
Gateway
中指定自定义过滤器
、
、
、
、
我有一个自定义网关过滤器MYGatewayFilter.java文件,现在我想对以application.yml编写
的
路由使用此网关过滤器
cloud
: - id: login2_route predicates: - Path
浏览 0
提问于2018-01-12
得票数 15
回答已采纳
1
回答
为什么
spring
网关与url不完全匹配?
、
我
在
application.properties
中
配置
spring
云网关(v3.0.3) url,如下所示:
spring
.
cloud
.
gateway
.routes[5].id = dict-auth
spring
.
c
浏览 21
提问于2022-02-26
得票数 0
1
回答
如何禁用Netty
HTTP
客户端连接池?
、
、
、
我们使用
Spring
Cloud
Gateway
进行身份验证。
Spring
Security OAuth2LoginAuthenticationWebFilter使用Netty
HTTP
客户端向身份提供者发送
请求
。Netty有一个连接池,由于负载均衡服务器
在
Netty和身份提供商之间搞乱了连接池,从而断开了池中
的
空闲连接。有没有办法
在
Spring
Security
中
禁用Netty
HTTP<
浏览 2
提问于2019-12-18
得票数 1
1
回答
用JWT调用资源服务器,通过
Spring
Cloud
Gateway
返回
HTTP
403
、
、
、
、
两者都是反应式
Spring
。第一个项目是Javascript应用程序和
Spring
Cloud
Gateway
的
组合,用于反向代理。第二个项目是
Spring
资源服务器。项目一
在
http
://localhost:8081/v1/artists代理来自/api/artists
的
请求
到项目二。 如果我使用有效
的
JWT直接调用资源服务器(项目2),
浏览 153
提问于2020-12-25
得票数 0
回答已采纳
1
回答
spring
-
cloud
-config应该包含什么文件
、
、
、
我使用
spring
-
cloud
-
gateway
、
spring
-
cloud
-config、eureka 对于我
的
spring
-
cloud
服务器,
在
application.properties
中
server.port
中
的
云服务器
spring
.application.name=
gateway
-service
spring
.prof
浏览 53
提问于2019-06-27
得票数 0
4
回答
+
Spring
网关:找不到k8s服务
的
实例
、
、
、
我使用+(SCG),
在
GKE上部署我
的
应用程序有一些困难。我
的
配置: profiles:
cloud
: reload我不想要"route_id": "CompositeDiscoveryClient_
gateway
"<dependency> <groupId&g
浏览 0
提问于2019-08-21
得票数 4
回答已采纳
1
回答
带有弹簧云网关
的
双CORS报头
、
如何禁用网关上
的
CORS?我
的
意思是真正
的
禁用,
在
stackoeverflow或其他地方搜索“禁用网关CORS”时,不允许来自所有来源
的
所有方法
的
请求
。我
的
问题是
spring
云网关也设置了一些头,这会导致重复
的
CORS头和客户端应用程序
中
的
CORS错误。=true
spring
.
cloud
.
gateway
.globalcors.
浏览 16
提问于2022-11-15
得票数 0
回答已采纳
4
回答
从ServerHttpRequest / Flux<DataBuffer>获取
请求
正文字符串
、
、
我使用
的
是
spring
boot版本- 2.0.6.RELEASE和
spring
cloud
版本- Finchley.SR2 并且我已经创建了我
的
自定义网关过滤器来修改
请求
正文。但是
在
使用Flux将
请求
正文转换为字符串时,我得到了一个空字符串。我需要一个方法来获取与我
的
请求
主体相对应
的
字符串。private String resolveBodyFromRequest(ServerHttpReques
浏览 3
提问于2019-08-20
得票数 8
2
回答
Spring
网关上
的
CORS配置问题
、
、
我能够使用
Spring
中
的
RouteLocator将
请求
路由到相应
的
服务。但我无法为正在通过RouteLocator路由
的
路径配置CORS。我
的
代码看起来像Application.javapublic class Application { publ
浏览 1
提问于2019-01-21
得票数 2
回答已采纳
1
回答
是否可以
在
spring
网关
的
application.properties配置中注册路由过滤器?
、
但是,我已经
在
application.properties
中
像这样配置了路由:
spring
.
cloud
.
gateway
.discovery.locator.enabled=true
spring
.
cloud
.
gateway
.routes
浏览 2
提问于2021-09-19
得票数 0
回答已采纳
1
回答
清理
Spring
Cloud
Gateway
中
的
请求
URI
我想在使用
Spring
Cloud
Gateway
时清理部分uri。 例如:
http
://localhost:8080//login。
在
本例
中
,我希望
在
Spring
Gateway
尝试为该
请求
找到合适
的
路由之前,就删除双斜杠和单斜杠。 使用全局过滤器是正确
的
方法吗?或者有没有其他
的
钩子可以用来拦截
请求
并修改
浏览 29
提问于2019-09-12
得票数 0
3
回答
Spring
Cloud
Gateway
简单示例不起作用
、
大多数基础
的
Spring
Cloud
Gateway
应用程序无法正常工作。builder.routes() .uri("
http
浏览 0
提问于2019-06-27
得票数 1
1
回答
我可以使用
Spring
进行基于角色
的
授权吗?
、
、
我
的
架构中有几个微服务。我想要实现一个API网关来将
请求
路由到服务。为此,我实现了
spring
-
cloud
-
gateway
,这是我
的
application.yml port: 9090 application:
cloud
: routes: - id: task-se
浏览 2
提问于2022-05-19
得票数 1
1
回答
在
AWS Lambda中使用API
Gateway
实现函数路由
的
Spring
Cloud
Function
、
、
我尝试
在
AWS Lambda中部署一个具有多种功能
的
Spring
Cloud
Function。我想使用这里描述
的
函数路由:https://
cloud
.
spring
.io/
spring
-
cloud
-static/
spring
-
cloud
-function/3.0.1.RELEASE/reference使用以下配置,RoutingFuncti
浏览 33
提问于2020-01-17
得票数 1
3
回答
每个alternate
请求
spring
cloud
gateway
错误404
、
、
、
我
在
spring
cloud
gateway
中
遇到了一个非常奇怪
的
问题。每个备用
请求
都会返回404。我
在
api-
gateway
中
配置
的
所有服务都会发生这种情况,没有例外。: DEBUG web.reactive: DEBUG application:
浏览 0
提问于2020-05-26
得票数 5
2
回答
Spring
网关Redis会话存储类型-保存问题
、
、
我有一个微服务体系结构
的
spring
网关。创建会话
并在
redis
中
设置会话。路由对Microservice B
的
请求
接收sessionId并从session.获取属性。
在
尝试实现此功能时,(第2点)
在
调用微服务B并返回其响应(第4点)之后,将发生保存sessionId
的
操作。(即第2点发生在第4点之后)。但是,预期
在
将
请求
浏览 3
提问于2021-02-23
得票数 2
点击加载更多
扫码
添加站长 进交流群
领取专属
10元无门槛券
手把手带您无忧上云
相关
资讯
Spring Cloud推出新成员Spring Cloud Gateway
基于 Spring Cloud 完整的微服务架构实战
Spring Cloud 完整的微服务架构实战
JWT对SpringCloud进行系统认证和服务鉴权(一)
SpringBoot2.x中Json基础使用详解
热门
标签
更多标签
云服务器
ICP备案
实时音视频
即时通信 IM
对象存储
活动推荐
运营活动
广告
关闭
领券