Hi,

We are doing a test where mySQL server goes down when user is accessing a
webapplication.
We have setup tomcat with the required parameters for DBCP to handle such a
case.
It works fine in a set up where Tomcat and mySQL are on the same windows
machine.
But in a setup where Tomcat is on Windows machine connecting to mySQL
running on a linux machine, it does not work.

Here are the versions:

Tomcat 5.0
mySQL 4.1
Linux 2.6 Fedora

We have configured Tomcat with the following in our webapp xml file (I'm
pasting a part of it)

<parameter>
<name>validationQuery</name>
<value>select 1</value>
</parameter>

<parameter>
<name>testOnBorrow</name>
<value>true</value>
</parameter>

<parameter>
<name>testWhileIdle</name>
<value>true</value>
</parameter>

<parameter>
<name>timeBetweenEvictionRunsMillis</name>
<value>10000</value>
</parameter>

<parameter>
<name>minEvictableIdleTimeMillis</name>
<value>60000</value>
</parameter>

<parameter>
<name>url</name>
<value>jdbc:mysql://190.162.50.20:3306/xyz_office?autoReconnect=true</value>
</parameter>

Here is the test we are doing;
1. Enter the web application, do something which accesses the database
2. Stop mysql server and restart on linux
3. Try to do something in the web application
4. Tomcat gives the following exception

stdout.log

java.sql.SQLException: No operations allowed after statement closed.
This comes many many times, basically an overflow.

In the browser:

javax.servlet.ServletException: Servlet execution threw an exception

org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:670
)
        
org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:637)
        org.apache.jsp.index_jsp._jspService(index_jsp.java:46)
        org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:3
24)
        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:802)

org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:10
69)

org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProces
sor.java:455)

org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
        org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
        org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

This comes many many times, basically an overflow.

root cause

java.lang.StackOverflowError

org.apache.coyote.tomcat5.CoyoteRequest.getAttribute(CoyoteRequest.java:909)

org.apache.coyote.tomcat5.CoyoteRequestFacade.getAttribute(CoyoteRequestFaca
de.java:214)

Could anyone please give us some hints?

Thanks
Seetha


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to