[opencms-dev] OpenCms crashes, Timeout waiting for idle object / Exception Processing ErrorPage

Achim Westermann a.westermann at alkacon.com
Thu Feb 19 09:18:49 CET 2009


Hi Marc,

try to set the option:

# action to take when the pool is exhausted {grow|block|fail}
db.pool.default.whenExhaustedAction=block

from "block" to "grow".

I assume there is some potential deadlock - code in commons-dbpc when 
that option is set to "block".

also try to turn on eviction by commenting in the test query in that file.

Kind Regards,
Achim.

-------------------
Achim Westermann

Alkacon Software GmbH  - The OpenCms Experts
http://www.alkacon.com - http://www.opencms.org


Marc Johnen schrieb:
> For a while now OpenCms keeps crashing every day. What happens is that the
> maximum number of connections
> is reached (db.pool.default.maxActive) and then no further connections are
> possible. I get a lot of 
> NoSuchElementException from all directions (see bottom for one example).
> After a restart everything works fine again 
> for a while. The connections are all to the opencms-database and are not
> coming from my code, I'm certain.
> The load of the page is not overwhelmingly high.
> 
> Configuration: Debian 4.0,  MySql 5.0.51a, Apache 2.2.3, Tomcat 6.0.18.
> 
> There is only one noticable Error occuring (you can find the message below)
> which still should not lead to the rising of connections, I think.
> 
> Can anyone help me?
> Thank you and greetings
> Marc Johnen
> 
> 
> 18.02.2009 17:40:52 org.apache.catalina.core.StandardHostValve custom
> SEVERE: Exception Processing ErrorPage[errorCode=404,
> location=/opencms/handle404]
> org.apache.jasper.JasperException: java.lang.ArrayIndexOutOfBoundsException:
> -1
> 	at
> org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:522)
> 	at
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:416)
> 	at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
> 	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> 	at
> org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630)
> 	at
> org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:535)
> 	at
> org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:472)
> 	at
> org.opencms.flex.CmsFlexRequestDispatcher.includeExternal(CmsFlexRequestDispatcher.java:194)
> 	at
> org.opencms.flex.CmsFlexRequestDispatcher.include(CmsFlexRequestDispatcher.java:169)
> 	at org.opencms.loader.CmsJspLoader.service(CmsJspLoader.java:1193)
> 	at
> org.opencms.flex.CmsFlexRequestDispatcher.includeInternalWithCache(CmsFlexRequestDispatcher.java:423)
> 	at
> org.opencms.flex.CmsFlexRequestDispatcher.include(CmsFlexRequestDispatcher.java:173)
> 	at org.opencms.loader.CmsJspLoader.dispatchJsp(CmsJspLoader.java:1227)
> 	at org.opencms.loader.CmsJspLoader.load(CmsJspLoader.java:1171)
> 	at
> org.opencms.loader.CmsResourceManager.loadResource(CmsResourceManager.java:964)
> 	at
> org.opencms.main.OpenCmsServlet.openErrorHandler(OpenCmsServlet.java:317)
> 	at org.opencms.main.OpenCmsServlet.handle(OpenCmsServlet.java:214)
> 	at org.opencms.main.OpenCmsServlet.invokeHandler(OpenCmsServlet.java:269)
> 	at org.opencms.main.OpenCmsServlet.doGet(OpenCmsServlet.java:149)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> 	at
> org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630)
> 	at
> org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:438)
> 	at
> org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374)
> 	at
> org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302)
> 	at
> org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:424)
> 	at
> org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:343)
> 	at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:144)
> 	at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> 	at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> 	at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
> 	at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
> 	at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
> 	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
> 	at java.lang.Thread.run(Thread.java:619)
> Caused by: java.lang.ArrayIndexOutOfBoundsException: -1
> 	at
> org.opencms.loader.CmsResourceManager.getLoader(CmsResourceManager.java:605)
> 	at
> org.opencms.loader.CmsResourceManager.getLoader(CmsResourceManager.java:594)
> 	at
> org.opencms.flex.CmsFlexRequestDispatcher.includeInternalWithCache(CmsFlexRequestDispatcher.java:403)
> 	at
> org.opencms.flex.CmsFlexRequestDispatcher.include(CmsFlexRequestDispatcher.java:173)
> 	at
> org.opencms.jsp.CmsJspTagInclude.includeActionWithCache(CmsJspTagInclude.java:364)
> 	at
> org.opencms.jsp.CmsJspTagInclude.includeTagAction(CmsJspTagInclude.java:241)
> 	at org.opencms.jsp.CmsJspTagInclude.doEndTag(CmsJspTagInclude.java:472)
> 	at
> org.apache.jsp.WEB_002dINF.jsp.online.system.modules.mysite.templates.standard_jsp._jspx_meth_cms_005finclude_005f0(standard_jsp.java:318)
> 	at
> org.apache.jsp.WEB_002dINF.jsp.online.system.modules.mysite.templates.standard_jsp._jspService(standard_jsp.java:215)
> 	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
> 	at
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:374)
> 	... 38 more
> 
> [..]
> 
> 17.02.2009 12:21:18 org.apache.catalina.core.ApplicationDispatcher invoke
> SEVERE: Servlet.service() for servlet jsp threw exception
> java.util.NoSuchElementException: Timeout waiting for idle object
>         at
> org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:756)
>         at
> org.apache.commons.dbcp.PoolingDriver.connect(PoolingDriver.java:175)
>         at java.sql.DriverManager.getConnection(DriverManager.java:582)
>         at java.sql.DriverManager.getConnection(DriverManager.java:207)
>         at
> org.opencms.db.CmsSqlManager.getConnectionByUrl(CmsSqlManager.java:104)
>         at
> org.opencms.db.generic.CmsSqlManager.getConnection(CmsSqlManager.java:231)
>         at
> org.opencms.db.generic.CmsVfsDriver.readResource(CmsVfsDriver.java:1963)
>         at
> org.opencms.db.CmsDriverManager.readResource(CmsDriverManager.java:6542)
>         at
> org.opencms.db.CmsSecurityManager.readResource(CmsSecurityManager.java:5850)
>         at
> org.opencms.db.CmsSecurityManager.readResource(CmsSecurityManager.java:4035)
>         at org.opencms.file.CmsObject.readResource(CmsObject.java:3488)
>         at org.opencms.file.CmsObject.readResource(CmsObject.java:3455)
>         at
> org.opencms.flex.CmsFlexRequestDispatcher.include(CmsFlexRequestDispatcher.java:157)
>         at
> org.opencms.jsp.CmsJspTagInclude.includeActionWithCache(CmsJspTagInclude.java:364)
>         at
> org.opencms.jsp.CmsJspTagInclude.includeTagAction(CmsJspTagInclude.java:241)
>         at
> org.opencms.jsp.CmsJspTagInclude.includeTagAction(CmsJspTagInclude.java:166)
>         at
> org.opencms.jsp.CmsJspActionElement.include(CmsJspActionElement.java:510)
>         at
> org.opencms.jsp.CmsJspActionElement.include(CmsJspActionElement.java:534)
>         at
> org.opencms.jsp.util.CmsJspStatusBean.includeTemplatePart(CmsJspStatusBean.java:335)
>         at
> org.opencms.jsp.util.CmsJspStatusBean.includeTemplatePart(CmsJspStatusBean.java:312)
> [...]



More information about the opencms-dev mailing list