萝卜白菜。 2021-05-29 23:24 采纳率: 100%
浏览 241
已结题

TongWeb线程阻塞

请看如下线程信息,大部分线程BLOCKED,请问这是TongWeb什么问题?

"http-nio2-0.0.0.0-80-exec-200" id="625417" CPU Time=663578087780 
    java.lang.Thread.State: BLOCKED 
        at com.tongweb.log.SystemOutLogger.log(SystemOutLogger.java:188)
        at com.tongweb.log.SystemOutLogger.doLog(SystemOutLogger.java:210)
        at com.tongweb.log.SystemOutLogger.log(SystemOutLogger.java:233)
        at com.tongweb.log.PassThroughPrintStream.println(PassThroughPrintStream.java:66)
        at com.tongweb.web.util.log.SystemLogHandler.println(SystemLogHandler.java:267)
        at weaver.security.filter.SecurityMain.process(SecurityMain.java:1067)
        at sun.reflect.GeneratedMethodAccessor203.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at weaver.filter.SecurityFilter.doFilterInternal(SecurityFilter.java:51)
        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at com.cloudstore.dev.api.service.EMFilter.doFilterInternal(EMFilter.java:40)
        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at com.weaverboot.frame.ioc.filter.WeaSsoIocComponentFilter.doFilter(WeaSsoIocComponentFilter.java:60)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at weaver.security.encryptedtrans.SecurityTransFilter.doFilter(SecurityTransFilter.java:25)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at weaver.security.filter.EncodingFilter.doFilter(EncodingFilter.java:97)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at com.tongweb.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
        at com.tongweb.catalina.core.StandardContextValve.invoke(StandardContextValve.java:108)
        at com.tongweb.catalina.core.ThanosStandardContextValve.invoke(ThanosStandardContextValve.java:26)
        at com.tongweb.tomee.catalina.OpenEJBValve.invoke(OpenEJBValve.java:44)
        at com.tongweb.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
        at com.tongweb.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
        at com.tongweb.tomee.catalina.OpenEJBSecurityListener$RequestCapturer.invoke(OpenEJBSecurityListener.java:97)
        at com.tongweb.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:80)
        at com.tongweb.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
        at com.tongweb.catalina.core.ThanosStandardEngineValve.invoke(ThanosStandardEngineValve.java:71)
        at com.tongweb.catalina.realm.RealmValve.invoke(RealmValve.java:30)
        at com.tongweb.catalina.connector.ThanosCoyoteAdaptor.service(ThanosCoyoteAdaptor.java:425)
        at com.tongweb.coyote.http11.Http11Processor.service(Http11Processor.java:772)
        at com.tongweb.coyote.http11.ThanosHttp11Processor.service(ThanosHttp11Processor.java:19)
        at com.tongweb.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
        at com.tongweb.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:803)
        at com.tongweb.web.util.net.Nio2Endpoint$SocketProcessor.doRun(Nio2Endpoint.java:1610)
        at com.tongweb.web.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
        at com.tongweb.web.util.net.AbstractEndpoint.processSocket(AbstractEndpoint.java:832)
        at com.tongweb.web.util.net.Nio2Endpoint$Nio2SocketWrapper$4.completed(Nio2Endpoint.java:640)
        at com.tongweb.web.util.net.Nio2Endpoint$Nio2SocketWrapper$4.completed(Nio2Endpoint.java:618)
        at sun.nio.ch.Invoker.invokeUnchecked(Invoker.java:126)
        at sun.nio.ch.Invoker$2.run(Invoker.java:218)
        at sun.nio.ch.AsynchronousChannelGroupImpl$1.run(AsynchronousChannelGroupImpl.java:112)
        at com.tongweb.web.util.threads.TWThreadPoolExecutor.runWorker(TWThreadPoolExecutor.java:1167)
        at com.tongweb.web.util.threads.TWThreadPoolExecutor$Worker.run(TWThreadPoolExecutor.java:623)
        at com.tongweb.web.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:748)
"http-nio2-0.0.0.0-80-exec-216" id="625423" CPU Time=655006011040 
    java.lang.Thread.State: BLOCKED 
        at com.tongweb.log.SystemOutLogger.log(SystemOutLogger.java:188)
        at com.tongweb.log.SystemOutLogger.doLog(SystemOutLogger.java:210)
        at com.tongweb.log.SystemOutLogger.log(SystemOutLogger.java:233)
        at com.tongweb.log.PassThroughPrintStream.println(PassThroughPrintStream.java:66)
        at com.tongweb.web.util.log.SystemLogHandler.println(SystemLogHandler.java:267)
        at weaver.security.filter.SecurityMain.process(SecurityMain.java:1067)
        at sun.reflect.GeneratedMethodAccessor203.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at weaver.filter.SecurityFilter.doFilterInternal(SecurityFilter.java:51)
        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at com.cloudstore.dev.api.service.EMFilter.doFilterInternal(EMFilter.java:40)
        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at com.weaverboot.frame.ioc.filter.WeaSsoIocComponentFilter.doFilter(WeaSsoIocComponentFilter.java:60)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at weaver.security.encryptedtrans.SecurityTransFilter.doFilter(SecurityTransFilter.java:25)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at weaver.security.filter.EncodingFilter.doFilter(EncodingFilter.java:97)
        at com.tongweb.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
        at com.tongweb.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
        at com.tongweb.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
        at com.tongweb.catalina.core.StandardContextValve.invoke(StandardContextValve.java:108)
        at com.tongweb.catalina.core.ThanosStandardContextValve.invoke(ThanosStandardContextValve.java:26)
        at com.tongweb.tomee.catalina.OpenEJBValve.invoke(OpenEJBValve.java:44)
        at com.tongweb.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
        at com.tongweb.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
        at com.tongweb.tomee.catalina.OpenEJBSecurityListener$RequestCapturer.invoke(OpenEJBSecurityListener.java:97)
        at com.tongweb.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:80)
        at com.tongweb.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
        at com.tongweb.catalina.core.ThanosStandardEngineValve.invoke(ThanosStandardEngineValve.java:71)
        at com.tongweb.catalina.realm.RealmValve.invoke(RealmValve.java:30)
        at com.tongweb.catalina.connector.ThanosCoyoteAdaptor.service(ThanosCoyoteAdaptor.java:425)
        at com.tongweb.coyote.http11.Http11Processor.service(Http11Processor.java:772)
        at com.tongweb.coyote.http11.ThanosHttp11Processor.service(ThanosHttp11Processor.java:19)
        at com.tongweb.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
        at com.tongweb.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:803)
        at com.tongweb.web.util.net.Nio2Endpoint$SocketProcessor.doRun(Nio2Endpoint.java:1610)
        at com.tongweb.web.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
        at com.tongweb.web.util.net.AbstractEndpoint.processSocket(AbstractEndpoint.java:832)
        at com.tongweb.web.util.net.Nio2Endpoint$Nio2SocketWrapper$4.completed(Nio2Endpoint.java:640)
        at com.tongweb.web.util.net.Nio2Endpoint$Nio2SocketWrapper$4.completed(Nio2Endpoint.java:618)
        at sun.nio.ch.Invoker.invokeUnchecked(Invoker.java:126)
        at sun.nio.ch.Invoker$2.run(Invoker.java:218)
        at sun.nio.ch.AsynchronousChannelGroupImpl$1.run(AsynchronousChannelGroupImpl.java:112)
        at com.tongweb.web.util.threads.TWThreadPoolExecutor.runWorker(TWThreadPoolExecutor.java:1167)
        at com.tongweb.web.util.threads.TWThreadPoolExecutor$Worker.run(TWThreadPoolExecutor.java:623)
        at com.tongweb.web.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:748)

  • 写回答

1条回答 默认 最新

  • 萝卜白菜。 2021-05-29 23:26
    关注

    该问题原因是TongWeb的日志输出同步,造成日志输出阻塞。 从TongWeb7.0.4.1版本开始,增加了异步日志功能,通过设置-DlogThreads=1 进行异步日志输出。

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

问题事件

  • 已结题 (查看结题原因) 1月16日

悬赏问题

  • ¥15 用C语言完成一个复杂的游戏
  • ¥15 如何批量更改很多个文件夹里的文件名中包含文件夹名?
  • ¥50 MTK手机模拟HID鼠标出现卡顿
  • ¥20 求下下面这个数据结构代码
  • ¥20 前端 二进制文件流图片转化异常
  • ¥15 github上的这个C语言项目如何跑起来
  • ¥15 java 判断某个数 区间是否存在
  • ¥15 appium控制多个雷电模拟器问题
  • ¥15 C# iMobileDevice
  • ¥15 谁会做这个啊#ensp#Boson NetSim