realwangpu
2021-05-29 23:24
采纳率: 96.7%
浏览 89
已采纳

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条回答 默认 最新

  • realwangpu 2021-05-29 23:26
    已采纳

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

    打赏 评论

相关推荐 更多相似问题