Return-Path: Delivered-To: apmail-tomcat-dev-archive@www.apache.org Received: (qmail 85199 invoked from network); 25 Jun 2008 15:33:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 25 Jun 2008 15:33:30 -0000 Received: (qmail 33326 invoked by uid 500); 25 Jun 2008 15:33:28 -0000 Delivered-To: apmail-tomcat-dev-archive@tomcat.apache.org Received: (qmail 33286 invoked by uid 500); 25 Jun 2008 15:33:28 -0000 Mailing-List: contact dev-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Developers List" Delivered-To: mailing list dev@tomcat.apache.org Received: (qmail 33275 invoked by uid 500); 25 Jun 2008 15:33:28 -0000 Delivered-To: apmail-jakarta-tomcat-dev@jakarta.apache.org Received: (qmail 33272 invoked by uid 99); 25 Jun 2008 15:33:28 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Jun 2008 08:33:28 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Jun 2008 15:32:35 +0000 Received: by brutus.apache.org (Postfix, from userid 33) id 25B15234C14B; Wed, 25 Jun 2008 08:32:25 -0700 (PDT) From: bugzilla@apache.org To: tomcat-dev@jakarta.apache.org Subject: DO NOT REPLY [Bug 43683] Accessing Servlet while Reloading context gives 404 error X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: newchanged X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Tomcat 6 X-Bugzilla-Component: Catalina X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: joe@k12s.phast.umass.edu X-Bugzilla-Status: REOPENED X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: tomcat-dev@jakarta.apache.org X-Bugzilla-Target-Milestone: default X-Bugzilla-Changed-Fields: In-Reply-To: Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Message-Id: <20080625153225.25B15234C14B@brutus.apache.org> Date: Wed, 25 Jun 2008 08:32:25 -0700 (PDT) X-Virus-Checked: Checked by ClamAV on apache.org https://issues.apache.org/bugzilla/show_bug.cgi?id=43683 --- Comment #18 from Joe Kislo 2008-06-25 08:32:23 PST --- Well that's frustrating :) I've done some work on it today to try to narrow down when it happens. I've written a java program that will make the required calls to the URLs in parallel to cause the issue. I wrapped it in a loop, and it happened the first time I ran it! Then I ran it again, and let it run for 2 hours without it happening once. Then I restarted tomcat, and it happened first time! So it seems to happen a lot *more* when tomcat has first started... but still not every time. I'm using Sun's 1.5.0_15 jvm if that somehow makes a difference. So I am attaching a unix shell script that will start+stop tomcat between each test run, and my java program that does the URL calling. You may need to tweak a couple variables to make this work on your machine: TestServiceDuringDestroy.sh: TOMCAT_BIN_DIR - Set this to where the catalina.sh script is TestServiceDuringDestroy.java: TESTCASE3_URL - Put the url to testcase3 (the one that spins cpu during init) RESTART_TOMCAT_URL - Put the url to restart that servlet RESTART_TOMCAT_BASIC_AUTH - Put in the basic authentication credentials for the manager servlet in format username:password With those changes... I think that will get it going for you. The theory here is: while (true) { start tomcat Request the servlet Restart the servlet Request the servlet stop tomcat } When the testcase fails you'll see something like this: Using CATALINA_BASE: /var/tmp/tomcat/apache-tomcat-6.0.16 Using CATALINA_HOME: /var/tmp/tomcat/apache-tomcat-6.0.16 Using CATALINA_TMPDIR: /var/tmp/tomcat/apache-tomcat-6.0.16/temp Using JRE_HOME: /usr/local/java Sleeping for tomcat to start Testcase Call 1: Requesting URL Restart call: Requesting URL Testcase Call 2: Requesting URL Testcase Call 1: IOException in URL request java.io.IOException: Server returned HTTP response code: 500 for URL: http://localhost:8080/ServletRestartTest3/ServletRestartTest at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1174) at WebRequestThread.run(WebRequestThread.java:28) Using CATALINA_BASE: /var/tmp/tomcat/apache-tomcat-6.0.16 Using CATALINA_HOME: /var/tmp/tomcat/apache-tomcat-6.0.16 Using CATALINA_TMPDIR: /var/tmp/tomcat/apache-tomcat-6.0.16/temp Using JRE_HOME: /usr/local/java Sleeping for tomcat to stop --- In the cases where it tomcat succeeds, I see this on the server side: INFO: Waiting for 1 instance(s) to be deallocated I do not see that when my testcase fails. FWIW, I am using a apache-tomcat-6.0.16 binary installation, and I dropped in lib/* and bin/*.jar from a newly compiled trunk svn checkout from yesterday (06-24-08) Good luck! -- Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org For additional commands, e-mail: dev-help@tomcat.apache.org