Dubbo与HTTP端口混用导致转发异常,如何排查处理
我user中心暴露了dubbo端口和http端口,我网关转发的时候一次转发到了dubbo端口一次就到http端口,怎么解决这种问题。转发到dubbo端口的时候报错日志如下2025-10-24T10:28:53.970+08:00 DEBUG 23076 --- [api-gateway] [ioEventLoop-7-2] c.apimanage.gateway.filter.AuthFilter : [AuthFilter] Token validated for user: 'admin' 2025-10-24T10:28:53.970+08:00 INFO 23076 --- [api-gateway] [ioEventLoop-7-2] c.apimanage.gateway.filter.AuthFilter : [AuthFilter] 认证成功,转发请求到下游服务 2025-10-24T10:28:53.971+08:00 DEBUG 23076 --- [api-gateway] [ioEventLoop-7-2] c.a.gateway.config.RateLimiterConfig : Path based rate limit for: /user/list 2025-10-24T10:28:53.976+08:00 DEBUG 23076 --- [api-gateway] [ioEventLoop-7-2] o.s.c.g.f.ratelimit.RedisRateLimiter : response: Response{allowed=true, headers={X-RateLimit-Remaining=19, X-RateLimit-Requested-Tokens=1, X-RateLimit-Burst-Capacity=20, X-RateLimit-Replenish-Rate=10}, tokensRemaining=-1} 2025-10-24T10:28:53.993+08:00 WARN 23076 --- [api-gateway] [ctor-http-nio-9] r.netty.http.client.HttpClientConnect : [60891de0-1, L:/192.168.70.35:58972 - R:/192.168.70.35:20884] The connection observed an error
java.lang.IllegalArgumentException: invalid version format: UNSUPPORTED at io.netty.handler.codec.http.HttpVersion.(HttpVersion.java:123) ~[netty-codec-http-4.1.101.Final.jar:4.1.101.Final] at io.netty.handler.codec.http.HttpVersion.valueOf(HttpVersion.java:85) ~[netty-codec-http-4.1.101.Final.jar:4.1.101.Final] at io.netty.handler.codec.http.HttpResponseDecoder.createMessage(HttpResponseDecoder.java:155) ~[netty-codec-http-4.1.101.Final.jar:4.1.101.Final] at io.netty.handler.codec.http.HttpObjectDecoder.decode(HttpObjectDecoder.java:277) ~[netty-codec-http-4.1.101.Final.jar:4.1.101.Final] at io.netty.handler.codec.http.HttpClientCodec$Decoder.decode(HttpClientCodec.java:238) ~[netty-codec-http-4.1.101.Final.jar:4.1.101.Final] at io.netty.handler.codec.ByteToMessageDecoder.decodeRemovalReentryProtection(ByteToMessageDecoder.java:529) ~[netty-codec-4.1.101.Final.jar:4.1.101.Final] at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:468) ~[netty-codec-4.1.101.Final.jar:4.1.101.Final] at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:290) ~[netty-codec-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:251) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:440) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:788) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:724) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:650) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:562) ~[netty-transport-4.1.101.Final.jar:4.1.101.Final] at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997) ~[netty-common-4.1.101.Final.jar:4.1.101.Final] at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) ~[netty-common-4.1.101.Final.jar:4.1.101.Final] at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) ~[netty-common-4.1.101.Final.jar:4.1.101.Final] at java.base/java.lang.Thread.run(Thread.java:840) ~[na:na]
2025-10-24T10:28:54.000+08:00 WARN 23076 --- [api-gateway] [ task-2] c.a.g.controller.FallbackController : 服务降级处理 - 用户中心服务不可用


