例外:使用Spring Client在Spring中对http-epoll-1线程进行泄漏检测

问题描述 投票:0回答:1

我在Spring应用程序中遇到以下异常。我使用Spring-boot-starter 2.2.1和spring-boot-starer-reactor-netty 2.2.1。 (其中的反应堆净值为0.9.1。)

我在我的应用程序中使用spring-boot-admin-starter-client 2.2.0。

它没有顺序抛出,我看不到出现的任何模式。我刚刚将我的应用程序作为unix服务启动,一段时间后就扔了。我的想法是关于Spring管理员和客户端,但是我将它们升级到了最新版本,但异常仍然存在。

您能给我任何建议为什么要扔吗?

此异常发生在线程或-http-epoll-1:

2019-12-12 17:24:46.756+0100 ERROR 15674 --- [or-http-epoll-1] i.n.u.ResourceLeakDetector

并且在此线程上,一切似乎都更早了:


2019-12-12 17:23:16.763+0100 DEBUG 15674 --- [or-http-epoll-1] r.n.h.s.HttpServer : [id: 0x967afa3f, L:/127.0.1.1:8080 - R:/127.0.0.1:54646] Handler is being applied: org.springframework.http.server.reactive.ReactorHttpHandlerAdapter@33681b9d

2019-12-12 17:23:16.763+0100 DEBUG 15674 --- [or-http-epoll-1] o.s.w.s.a.HttpWebHandlerAdapter : [967afa3f] HTTP GET "/actuator/health"

2019-12-12 17:23:16.764+0100 DEBUG 15674 --- [or-http-epoll-1] .b.a.e.w.r.WebFluxEndpointHandlerMapping : [967afa3f] Mapped to org.springframework.boot.actuate.endpoint.web.reactive.AbstractWebFluxEndpointHandlerMapping$ReadOperationHandler@6de54b40

2019-12-12 17:23:17.768+0100 DEBUG 15674 --- [or-http-epoll-1] r.n.h.s.HttpServerOperations : [id: 0x967afa3f, L:/127.0.1.1:8080 - R:/127.0.0.1:54646] Decreasing pending responses, now 0

2019-12-12 17:23:17.768+0100 DEBUG 15674 --- [or-http-epoll-1] o.s.w.s.a.HttpWebHandlerAdapter : [967afa3f] Completed 200 OK

2019-12-12 17:23:17.768+0100 DEBUG 15674 --- [or-http-epoll-1] r.n.h.s.HttpServerOperations : [id: 0x967afa3f, L:/127.0.1.1:8080 - R:/127.0.0.1:54646] Last HTTP response frame

2019-12-12 17:23:17.768+0100 DEBUG 15674 --- [or-http-epoll-1] r.n.h.s.HttpServerOperations : [id: 0x967afa3f, L:/127.0.1.1:8080 - R:/127.0.0.1:54646] Last HTTP packet was sent, terminating the channel

2019-12-12 17:24:17.959+0100 DEBUG 15674 --- [or-http-epoll-1] r.n.h.s.HttpServerOperations : [id: 0x967afa3f, L:/127.0.1.1:8080 - R:/127.0.0.1:54646] Decreasing pending responses, now 0

2019-12-12 17:24:17.959+0100 DEBUG 15674 --- [or-http-epoll-1] r.n.h.s.HttpServerOperations : [id: 0x967afa3f, L:/127.0.1.1:8080 - R:/127.0.0.1:54646] Last HTTP packet was sent, terminating the channel

2019-12-12 17:24:46.756+0100 ERROR 15674 --- [or-http-epoll-1] i.n.u.ResourceLeakDetector : LEAK: ByteBuf.release() was not called before it's garbage-collected. See https://netty.i o/wiki/reference-counted-objects.html for more information. 
Recent access records: 
Created at:
    #011io.netty.buffer.PooledByteBufAllocator.newDirectBuffer(PooledByteBufAllocator.java:349)
    #011io.netty.buffer.AbstractByteBufAllocator.directBuffer(AbstractByteBufAllocator.java:187)
    #011io.netty.buffer.AbstractByteBufAllocator.directBuffer(AbstractByteBufAllocator.java:178)
    #011io.netty.buffer.AbstractByteBufAllocator.buffer(AbstractByteBufAllocator.java:115)
    #011io.netty.buffer.ByteBufUtil.readBytes(ByteBufUtil.java:445) #011io.netty.handler.codec.http.websocketx.WebSocket08FrameDecoder.decode(WebSocket08FrameDecoder.java:314)
    #011io.netty.handler.codec.ByteToMessageDecoder.decodeRemovalReentryProtection(ByteToMessageDecoder.java:503)
    #011io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:442)
    #011io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:281)
    #011io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374)
    #011io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360)
    #011io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352)
    #011io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1422)
    #011io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374)
    #011io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360)
    #011io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:931)
    #011io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:792)
    #011io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:502)
    #011io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:407) #011io.netty.util.concurrent.SingleThreadEventExecutor$6.run(SingleThreadEventExecutor.java:1050)
    #011io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
    #011io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
    #011java.lang.Thread.run(Thread.java:748)
spring spring-boot netty spring-webflux
1个回答
0
投票

解决方案:我发现了message.getPayload()未释放的内容,我在那写道,问题不再发生。

© www.soinside.com 2019 - 2024. All rights reserved.