2.8.2 gateway启动报错

Blade 未结 1 950
forisen
forisen 剑童 2021-09-16 16:46

一、该问题的重现步骤是什么?

    运行GatewayApplication出现以下错误,并且一直循环出现,同时访问http://127.0.0.1不能访问

2021-09-16 16:29:31.070 ERROR 16264 --- [ctor-http-nio-2] o.s.w.s.adapter.HttpWebHandlerAdapter    : [ca34689d-1] 500 Server Error for HTTP GET "/"


java.lang.NullPointerException: null

at org.springblade.gateway.handler.ErrorExceptionHandler.getHttpStatus(ErrorExceptionHandler.java:76) ~[classes/:na]

at org.springframework.boot.autoconfigure.web.reactive.error.DefaultErrorWebExceptionHandler.renderErrorResponse(DefaultErrorWebExceptionHandler.java:146) ~[spring-boot-autoconfigure-2.3.12.RELEASE.jar:2.3.12.RELEASE]

at org.springframework.boot.autoconfigure.web.reactive.error.AbstractErrorWebExceptionHandler.lambda$handle$0(AbstractErrorWebExceptionHandler.java:304) ~[spring-boot-autoconfigure-2.3.12.RELEASE.jar:2.3.12.RELEASE]

at reactor.core.publisher.MonoFlatMap$FlatMapMain.onNext(MonoFlatMap.java:118) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxSwitchIfEmpty$SwitchIfEmptySubscriber.onNext(FluxSwitchIfEmpty.java:67) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators$ScalarSubscription.request(Operators.java:2393) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators$MultiSubscriptionSubscriber.set(Operators.java:2190) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators$MultiSubscriptionSubscriber.onSubscribe(Operators.java:2064) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoJust.subscribe(MonoJust.java:54) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Mono.subscribe(Mono.java:4252) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxOnErrorResume$ResumeSubscriber.onError(FluxOnErrorResume.java:97) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxOnErrorResume$ResumeSubscriber.onError(FluxOnErrorResume.java:100) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onError(FluxOnAssembly.java:390) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators.error(Operators.java:196) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoError.subscribe(MonoError.java:52) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Mono.subscribe(Mono.java:4252) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxOnErrorResume$ResumeSubscriber.onError(FluxOnErrorResume.java:97) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onError(FluxOnAssembly.java:390) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoPeekTerminal$MonoTerminalPeekSubscriber.onError(MonoPeekTerminal.java:251) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoPeekTerminal$MonoTerminalPeekSubscriber.onError(MonoPeekTerminal.java:251) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onError(FluxOnAssembly.java:390) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onError(FluxOnAssembly.java:390) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoFlatMap$FlatMapMain.onError(MonoFlatMap.java:165) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoFlatMap$FlatMapMain.secondError(MonoFlatMap.java:185) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoFlatMap$FlatMapInner.onError(MonoFlatMap.java:251) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoIgnoreThen$ThenIgnoreMain.onError(MonoIgnoreThen.java:268) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoFlatMap$FlatMapMain.onError(MonoFlatMap.java:165) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators$MultiSubscriptionSubscriber.onError(Operators.java:2059) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators.error(Operators.java:196) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoError.subscribe(MonoError.java:52) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoDefer.subscribe(MonoDefer.java:52) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Mono.subscribe(Mono.java:4252) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxSwitchIfEmpty$SwitchIfEmptySubscriber.onComplete(FluxSwitchIfEmpty.java:75) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators.complete(Operators.java:135) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoEmpty.subscribe(MonoEmpty.java:45) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Mono.subscribe(Mono.java:4252) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoIgnoreThen$ThenIgnoreMain.subscribeNext(MonoIgnoreThen.java:253) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoIgnoreThen.subscribe(MonoIgnoreThen.java:51) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoFlatMap$FlatMapMain.onNext(MonoFlatMap.java:150) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxSwitchIfEmpty$SwitchIfEmptySubscriber.onNext(FluxSwitchIfEmpty.java:67) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoNext$NextSubscriber.onNext(MonoNext.java:76) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxConcatMap$ConcatMapImmediate.innerNext(FluxConcatMap.java:274) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxConcatMap$ConcatMapInner.onNext(FluxConcatMap.java:851) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxMapFuseable$MapFuseableSubscriber.onNext(FluxMapFuseable.java:121) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators$ScalarSubscription.request(Operators.java:2393) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxMapFuseable$MapFuseableSubscriber.request(FluxMapFuseable.java:162) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators$MultiSubscriptionSubscriber.set(Operators.java:2190) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Operators$MultiSubscriptionSubscriber.onSubscribe(Operators.java:2064) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxMapFuseable$MapFuseableSubscriber.onSubscribe(FluxMapFuseable.java:90) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoJust.subscribe(MonoJust.java:54) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Mono.subscribe(Mono.java:4252) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxConcatMap$ConcatMapImmediate.drain(FluxConcatMap.java:441) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxConcatMap$ConcatMapImmediate.onSubscribe(FluxConcatMap.java:211) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxIterable.subscribe(FluxIterable.java:161) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.FluxIterable.subscribe(FluxIterable.java:86) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.InternalMonoOperator.subscribe(InternalMonoOperator.java:64) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoDefer.subscribe(MonoDefer.java:52) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.InternalMonoOperator.subscribe(InternalMonoOperator.java:64) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoDefer.subscribe(MonoDefer.java:52) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.InternalMonoOperator.subscribe(InternalMonoOperator.java:64) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoDefer.subscribe(MonoDefer.java:52) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.InternalMonoOperator.subscribe(InternalMonoOperator.java:64) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoDefer.subscribe(MonoDefer.java:52) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.InternalMonoOperator.subscribe(InternalMonoOperator.java:64) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoDefer.subscribe(MonoDefer.java:52) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.Mono.subscribe(Mono.java:4252) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoIgnoreThen$ThenIgnoreMain.subscribeNext(MonoIgnoreThen.java:253) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.MonoIgnoreThen.subscribe(MonoIgnoreThen.java:51) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.core.publisher.InternalMonoOperator.subscribe(InternalMonoOperator.java:64) ~[reactor-core-3.3.17.RELEASE.jar:3.3.17.RELEASE]

at reactor.netty.http.server.HttpServerHandle.onStateChange(HttpServerHandle.java:65) ~[reactor-netty-0.9.20.RELEASE.jar:0.9.20.RELEASE]

at reactor.netty.ReactorNetty$CompositeConnectionObserver.onStateChange(ReactorNetty.java:537) ~[reactor-netty-0.9.20.RELEASE.jar:0.9.20.RELEASE]

at reactor.netty.tcp.TcpServerBind$ChildObserver.onStateChange(TcpServerBind.java:278) ~[reactor-netty-0.9.20.RELEASE.jar:0.9.20.RELEASE]

at reactor.netty.http.server.HttpServerOperations.onInboundNext(HttpServerOperations.java:475) ~[reactor-netty-0.9.20.RELEASE.jar:0.9.20.RELEASE]

at reactor.netty.channel.ChannelOperationsHandler.channelRead(ChannelOperationsHandler.java:96) ~[reactor-netty-0.9.20.RELEASE.jar:0.9.20.RELEASE]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at reactor.netty.http.server.HttpTrafficHandler.channelRead(HttpTrafficHandler.java:191) ~[reactor-netty-0.9.20.RELEASE.jar:0.9.20.RELEASE]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:436) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324) ~[netty-codec-4.1.65.Final.jar:4.1.65.Final]

at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:296) ~[netty-codec-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:251) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:719) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:655) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:581) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493) ~[netty-transport-4.1.65.Final.jar:4.1.65.Final]

at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) ~[netty-common-4.1.65.Final.jar:4.1.65.Final]

at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) ~[netty-common-4.1.65.Final.jar:4.1.65.Final]

at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) ~[netty-common-4.1.65.Final.jar:4.1.65.Final]

at java.base/java.lang.Thread.run(Thread.java:834) ~[na:na]

 


二、你期待的结果是什么?实际看到的又是什么?

        能正常启动,可以访问http://127.0.0.1, swagger能正常访问

三、你正在使用的是什么产品,什么版本?在什么操作系统上?

         开发工具 Idea 2021.1, JDK 1.8.202, Mac及windows 10上问题相同

四、请提供详细的错误堆栈信息,这很重要。

        同一中描述

五、若有更多详细信息,请在下面提供。

1条回答
提交回复