"3.0.0 没出现这个问题,3.4.1 有时回报这个异常 java.lang.Exception: Apparent connection leak detected at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:12 .."

sym 3.4.1 异常

3.0.0 没出现这个问题,3.4.1 有时回报这个异常

java.lang.Exception: Apparent connection leak detected
        at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:128)
        at org.b3log.latke.repository.jdbc.util.Connections.getConnection(Connections.java:190)
        at org.b3log.latke.repository.jdbc.JdbcTransaction.<init>(JdbcTransaction.java:51)
        at org.b3log.latke.repository.jdbc.JdbcRepository.beginTransaction(JdbcRepository.java:801)
        at org.b3log.latke.repository.AbstractRepository.beginTransaction(AbstractRepository.java:212)
        at org.b3log.symphony.service.ArticleMgmtService.lambda$0(ArticleMgmtService.java:335)
        at java.lang.Thread.run(Thread.java:748)
[WARN]-[2018-11-09 17:54:19]-[com.zaxxer.hikari.pool.ProxyLeakTask:84]: Connection leak detection triggered for com.mysql.cj.jdbc.ConnectionImpl@7c413af9 on thread Thread-80, stack trace follows
java.lang.Exception: Apparent connection leak detected
        at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:128)
        at org.b3log.latke.repository.jdbc.util.Connections.getConnection(Connections.java:190)
        at org.b3log.latke.repository.jdbc.JdbcTransaction.<init>(JdbcTransaction.java:51)
        at org.b3log.latke.repository.jdbc.JdbcRepository.beginTransaction(JdbcRepository.java:801)
        at org.b3log.latke.repository.AbstractRepository.beginTransaction(AbstractRepository.java:212)
        at org.b3log.symphony.service.ArticleMgmtService.lambda$0(ArticleMgmtService.java:335)
        at java.lang.Thread.run(Thread.java:748)
[ERROR]-[2018-11-09 17:57:13]-[org.b3log.latke.servlet.HttpControl:102]: Request [
    method=GET,
    contentType=null,
    characterEncoding=UTF-8,
    local=[
        addr=127.0.0.1,
        port=8080,
        name=localhost],
   
    headers=[
        connection=close
        user-agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:63.0) Gecko/20100101 Firefox/63.0
        accept=*/*
        accept-language=zh-CN,zh;q=0.8,zh-TW;q=0.7,zh-HK;q=0.5,en-US;q=0.3,en;q=0.2
        accept-encoding=gzip, deflate, br
        cookie=JSESSIONID=C40F90903ADD85CFA6E30B5FBFADE8EB; sym-ce=5c682a66213d9d4dfdb19c5948a4d413e2fdda09201e5c0a5688f7c829d1e74428e55086370891a751a4003bccba330560c12224d89b55e215e6a795e89aa69b68a33144667b39cfc28a0a66e4aedd0ca05bace8f25391bd61c06cbe4031dabe7c905096d81b8c0440e4f6db918297c5d86d6c853ea02c6b1e169f3374e929bd565513027550a29bedc6cb28b188adbb
    ]
] processing failed
java.lang.reflect.InvocationTargetException
        at sun.reflect.GeneratedMethodAccessor90.invoke(Unknown Source)
Type  :quit<Enter>  to exit Vim          


] processing failed
java.lang.reflect.InvocationTargetException
        at sun.reflect.GeneratedMethodAccessor90.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.b3log.latke.servlet.handler.MethodInvokeHandler.handle(MethodInvokeHandler.java:57)
        at org.b3log.latke.servlet.HttpControl.nextHandler(HttpControl.java:97)
        at org.b3log.latke.servlet.handler.AdviceHandler.handle(AdviceHandler.java:106)
        at org.b3log.latke.servlet.HttpControl.nextHandler(HttpControl.java:97)
        at org.b3log.latke.servlet.handler.ArgsHandler.handle(ArgsHandler.java:61)
        at org.b3log.latke.servlet.HttpControl.nextHandler(HttpControl.java:97)
        at org.b3log.latke.servlet.handler.RequestDispatchHandler.handle(RequestDispatchHandler.java:86)
        at org.b3log.latke.servlet.HttpControl.nextHandler(HttpControl.java:97)
        at org.b3log.latke.servlet.handler.RequestPrepareHandler.handle(RequestPrepareHandler.java:46)
        at org.b3log.latke.servlet.HttpControl.nextHandler(HttpControl.java:97)
        at org.b3log.latke.servlet.handler.StaticResourceHandler.handle(StaticResourceHandler.java:119)
        at org.b3log.latke.servlet.HttpControl.nextHandler(HttpControl.java:97)
        at org.b3log.latke.servlet.DispatcherServlet.service(DispatcherServlet.java:78)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.b3log.latke.servlet.filter.EncodingFilter.doFilter(EncodingFilter.java:66)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:490)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
        at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:668)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
        at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408)
        at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
        at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:770)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1415)
        at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:748)
Caused by: org.apache.catalina.connector.ClientAbortException: java.io.IOException: Broken pipe
        at org.apache.catalina.connector.OutputBuffer.realWriteBytes(OutputBuffer.java:333)
        at org.apache.catalina.connector.OutputBuffer.appendByteArray(OutputBuffer.java:728)
        at org.apache.catalina.connector.OutputBuffer.append(OutputBuffer.java:657)
        at org.apache.catalina.connector.OutputBuffer.writeBytes(OutputBuffer.java:368)
        at org.apache.catalina.connector.OutputBuffer.write(OutputBuffer.java:346)
        at org.apache.catalina.connector.CoyoteOutputStream.write(CoyoteOutputStream.java:96)
        at org.apache.catalina.connector.CoyoteOutputStream.write(CoyoteOutputStream.java:89)
        at org.apache.commons.io.IOUtils.write(IOUtils.java:1687)
        at org.b3log.symphony.processor.FileUploadProcessor.getFile(FileUploadProcessor.java:138)

  • Sym

    Sym 是一个用 Java 实现的现代化社区(论坛 / 社交网络 / 博客)平台,“下一代的社区系统,为未来而构建”。黑客派就是使用该系统搭建的 ❤️

    368 引用 • 3870 回帖 • 647 关注
  • 异常
    7 引用 • 18 回帖
  • Q&A

    提问之前请先看一下这篇文章 《提问的智慧》精读注解版,好的问题比好的答案更有价值。

    867 引用 • 5386 回帖 • 610 关注
感谢    关注    收藏    赞同    反对    举报    分享
被采纳的回答
  • 88250  

    这个报错是数据库连接有泄露,后面我会仔细看下,感谢反馈。

13 回帖    
请输入回帖内容...
  • 88250      

    最新版应该已经解决。

    2 回复 
    感谢    赞同    反对    举报    分享       评论    回复
  • 8595250            

    我在 3.4.1 基础上做了修改的。这个问题需要修改代码那个地方

    1 回复 
    感谢    赞同    反对    举报    分享       评论    回复
  • 88250            

    你看下提交历史吧。

    1 回复 
    感谢    赞同    反对    举报    分享       评论    回复
  • 8595250            

    好的

    感谢    赞同    反对    举报    分享       评论    回复
  • 8595250            

    升级来代码,还是有这个问题,我在检查下 看看

    [WARN ]-[2018-11-11 00:57:33]-[com.zaxxer.hikari.pool.ProxyLeakTask:84]: Connection leak detection triggered for com.mysql.cj.jdbc.ConnectionImpl@72ceafeb on thread Thread-25, stack trace follows
    java.lang.Exception: Apparent connection leak detected
            at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:128)
            at org.b3log.latke.repository.jdbc.util.Connections.getConnection(Connections.java:190)
            at org.b3log.latke.repository.jdbc.JdbcTransaction.<init>(JdbcTransaction.java:61)
            at org.b3log.latke.repository.jdbc.JdbcRepository.beginTransaction(JdbcRepository.java:749)
            at org.b3log.latke.repository.AbstractRepository.beginTransaction(AbstractRepository.java:184)
            at org.b3log.symphony.service.ArticleMgmtService.lambda$0(ArticleMgmtService.java:333)
            at java.lang.Thread.run(Thread.java:748)
    [WARN ]-[2018-11-11 00:57:41]-[com.zaxxer.hikari.pool.ProxyLeakTask:84]: Connection leak detection triggered for com.mysql.cj.jdbc.ConnectionImpl@7d29cb42 on thread Thread-26, stack trace follows
    java.lang.Exception: Apparent connection leak detected
            at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:128)
            at org.b3log.latke.repository.jdbc.util.Connections.getConnection(Connections.java:190)
            at org.b3log.latke.repository.jdbc.JdbcTransaction.<init>(JdbcTransaction.java:61)
            at org.b3log.latke.repository.jdbc.JdbcRepository.beginTransaction(JdbcRepository.java:749)
            at org.b3log.latke.repository.AbstractRepository.beginTransaction(AbstractRepository.java:184)
            at org.b3log.symphony.service.ArticleMgmtService.lambda$0(ArticleMgmtService.java:333)
            at java.lang.Thread.run(Thread.java:748) 
    
    1 回复 
    感谢    赞同    反对    举报    分享       评论    回复
  • 88250            

    这个报错是数据库连接有泄露,后面我会仔细看下,感谢反馈。

    1 回复 
    感谢    赞同    反对    举报    分享       评论    回复
  • 8595250            

    噢 [WARN]-[2018-11-11 08:58:45]-[com.zaxxer.hikari.pool.ProxyLeakTask:84]: Connection leak detection triggered for com.mysql.cj.jdbc.ConnectionImpl@7fbb1b83 on thread Thread-146, stack trace follows java.lang.Exception: Apparent connection leak detected at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:128) at org.b3log.latke.repository.jdbc.util.Connections.getConnection(Connections.java:190) at org.b3log.latke.repository.jdbc.JdbcTransaction.(JdbcTransaction.java:61) at org.b3log.latke.repository.jdbc.JdbcRepository.beginTransaction(JdbcRepository.java:749) at org.b3log.latke.repository.AbstractRepository.beginTransaction(AbstractRepository.java:184) at org.b3log.symphony.service.ArticleMgmtService.lambda$0(ArticleMgmtService.java:333) at java.lang.Thread.run(Thread.java:748) [WARN]-[2018-11-11 08:58:56]-[com.zaxxer.hikari.pool.ProxyLeakTask:84]: Connection leak detection triggered for com.mysql.cj.jdbc.ConnectionImpl@5a26a567 on thread Thread-147, stack trace follows java.lang.Exception: Apparent connection leak detected … [WARN]-[2018-11-11 09:00:16]-[com.zaxxer.hikari.pool.ProxyLeakTask:84]: Connection leak detection triggered for com.mysql.cj.jdbc.ConnectionImpl@42af8e02 on thread Thread-148, stack trace follows java.lang.Exception: Apparent connection leak detected at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:128) … [WARN]-[2018-11-11 09:00:19]-[com.zaxxer.hikari.pool.ProxyLeakTask:84]: Connection leak detection triggered for com.mysql.cj.jdbc.ConnectionImpl@69a5e494 on thread Thread-149, stack trace follows java.lang.Exception: Apparent connection leak detected …

    感谢    赞同    反对    举报    分享       评论    回复
  • terminus      

    3.42 也有这个问题,请指教

    1 回复 
    感谢    赞同    反对    举报    分享       评论    回复
  • 8595250            

    3.4.3 修复过这个问题,我升级到 3.4.3,工程启动隔一段时间,还是会报数据库连接泄漏,你升级试试 https://gitee.com/dl88250/symphony/commit/cc871eeb4e889b40f73df72267128865ed06d472

    2 回复 
    感谢    赞同    反对    举报    分享       评论    回复
  • terminus            

    我试试 谢谢您

    感谢    赞同    反对    举报    分享       评论    回复
  • terminus            

    我昨天试过了 3.43 也会有这个问题

    [WARN]-[2018-11-13 13:29:21]-[com.zaxxer.hikari.pool.ProxyLeakTask:84]: Connection leak detection triggered for com.mysql.cj.jdbc.ConnectionImpl@dc1a4e on thread pool-1-thread-3, stack trace follows java.lang.Exception: Apparent connection leak detected at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:128) at org.b3log.latke.repository.jdbc.util.Connections.getConnection(Connections.java:190) at org.b3log.latke.repository.jdbc.JdbcTransaction.(JdbcTransaction.java:61) at org.b3log.latke.repository.jdbc.JdbcRepository.beginTransaction(JdbcRepository.java:749) at org.b3log.latke.repository.AbstractRepository.beginTransaction(AbstractRepository.java:184) at org.b3log.symphony.service.ArticleMgmtService.lambda$genArticleAudio$21(ArticleMgmtService.java:330) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)

    1 回复 
    感谢    赞同    反对    举报    分享       评论    回复
  • 8595250                

    该内容仅作者和楼主可见。

    感谢    赞同    反对    举报    分享       评论    回复
  • 8595250   1 感谢      

    org.b3log.symphony.service.ArticleMgmtService.genArticleAudio 代码 有个 bug,这样改下就好来。 @terminus

    imagepng

    感谢    赞同    反对    举报    分享       评论    回复
请输入回帖内容...