It doesn’t have to be a “real”
query, following settings worked for me (mysql)
<dataSource type="SIMPLE">
…
<property
name="Pool.PingQuery" value="SELECT 1"/>
<property
name="Pool.PingEnabled" value="true" />
<property
name="Pool.PingConnectionsOlderThan" value="1000000" />
…
From: TNO [mailto:[EMAIL PROTECTED]
Sent: 19 August 2005 03:45 PM
To: ibatis
Subject: Error when web
application is unused for a long time
Hello,
I am working on a web application using Ibatis,
Spring and JSP on Jonasz Server with DB PostGre.
Sometime after 2 hours of inactivity, we have this
error. With a F5 refresh on the navigator, the application re-works fine.
I wonder if Ibatis and my cache configuration can
be involved in my error...
By the way, I have no cache configuration !
Here the exception, sorry it's the french one !
Thanks, Thomas
org.apache.jasper.JasperException: (SqlMapClient
operation): encountered SQLException [ --- The error occurred in
arc/cons/dao/ibatis/config/ConsFormulaireSQL.xml. --- The error occurred
while applying a parameter map. --- Check the
getConsFormulaire-InlineParameterMap. --- Check the statement (query
failed). --- Cause: org.postgresql.util.PSQLException: Une erreur
d''entrée/sortie a eu lieu lors d''envoi vers le serveur.]; nested exception is
com.ibatis.common.jdbc.exception.NestedSQLException: --- The error
occurred in arc/cons/dao/ibatis/config/ConsFormulaireSQL.xml. --- The
error occurred while applying a parameter map. --- Check the
getConsFormulaire-InlineParameterMap. --- Check the statement (query
failed). --- Cause: org.postgresql.util.PSQLException: Une erreur
d''entrée/sortie a eu lieu lors d''envoi vers le serveur.
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:372)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
sun.reflect.GeneratedMethodAccessor68.invoke(Unknown
Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:243)
java.security.AccessController.doPrivileged(Native
Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:272)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:161)
org.springframework.jdbc.UncategorizedSQLException:
(SqlMapClient operation): encountered SQLException [ --- The error
occurred in arc/cons/dao/ibatis/config/ConsFormulaireSQL.xml. --- The
error occurred while applying a parameter map. --- Check the
getConsFormulaire-InlineParameterMap. --- Check the statement (query
failed). --- Cause: org.postgresql.util.PSQLException: Une erreur
d''entrée/sortie a eu lieu lors d''envoi vers le serveur.]; nested exception is
com.ibatis.common.jdbc.exception.NestedSQLException: --- The error
occurred in arc/cons/dao/ibatis/config/ConsFormulaireSQL.xml. --- The
error occurred while applying a parameter map. --- Check the
getConsFormulaire-InlineParameterMap. --- Check the statement (query
failed). --- Cause: org.postgresql.util.PSQLException: Une erreur
d''entrée/sortie a eu lieu lors d''envoi vers le serveur.
org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.translate(SQLStateSQLExceptionTranslator.java:99)
org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator.translate(SQLErrorCodeSQLExceptionTranslator.java:257)
org.springframework.orm.ibatis.SqlMapClientTemplate.execute(SqlMapClientTemplate.java:184)
org.springframework.orm.ibatis.SqlMapClientTemplate.queryForObject(SqlMapClientTemplate.java:222)
arc.cons.dao.ibatis.ConsFormulaireDAOiBatis.get(ConsFormulaireDAOiBatis.java:27)
arc.cons.service.impl.ConsFormulaireMgrImpl.get(ConsFormulaireMgrImpl.java:49)
sun.reflect.GeneratedMethodAccessor81.invoke(Unknown
Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:287)
org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:155)
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:122)
arc.common.advice.PerformanceInterceptor.invoke(PerformanceInterceptor.java:65)
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:144)
org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:174)
$Proxy8.get(Unknown
Source)
sun.reflect.GeneratedMethodAccessor81.invoke(Unknown
Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:287)
org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:155)
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:122)
org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:57)
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:144)
org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:174)
$Proxy9.get(Unknown
Source)
org.apache.jsp.tdb.tdbFormChamp_jsp._jspService(tdbFormChamp_jsp.java:103)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
sun.reflect.GeneratedMethodAccessor68.invoke(Unknown
Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:243)
java.security.AccessController.doPrivileged(Native
Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:272)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:161)