Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@www.apache.org Received: (qmail 66749 invoked from network); 30 Sep 2005 13:56:31 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 30 Sep 2005 13:56:31 -0000 Received: (qmail 71097 invoked by uid 500); 30 Sep 2005 13:56:15 -0000 Delivered-To: apmail-jakarta-tomcat-user-archive@jakarta.apache.org Received: (qmail 71082 invoked by uid 500); 30 Sep 2005 13:56:15 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Tomcat Users List" Reply-To: "Tomcat Users List" Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 71071 invoked by uid 99); 30 Sep 2005 13:56:15 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 Sep 2005 06:56:15 -0700 X-ASF-Spam-Status: No, hits=0.4 required=10.0 tests=SPF_HELO_FAIL,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of funkman@joedog.org designates 204.74.20.252 as permitted sender) Received: from [204.74.20.252] (HELO sid.armstrong.com) (204.74.20.252) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 Sep 2005 06:56:20 -0700 Received: from [10.38.20.105] (tafunk-lt.americas.armstrong.com [10.38.20.105]) by sid.armstrong.com (8.12.8p1/8.12.8) with ESMTP id j8UDjABR016031 for ; Fri, 30 Sep 2005 08:45:10 -0500 Message-ID: <433D43F9.1080506@joedog.org> Date: Fri, 30 Sep 2005 09:56:09 -0400 From: Tim Funk Organization: Human being User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.11) Gecko/20050728 X-Accept-Language: en-us, en, es-mx, de, sv MIME-Version: 1.0 To: Tomcat Users List Subject: Re: Multiple Threads for one webapp References: In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N It seems you have a thread started in the background during the life of the application. This thread goes to some external place of storage and to look for emails to send. It seems this thread is not stopped when a context is reloaded. When the app is reloaded - a new thread is started. In this case - the app was restarted 6 times - leaving you 7 threads all looking to the smae external loctation for sending emails. Solution: Use a ServletContextListerner to detect webapp shutdown so the thread may be stopped. -Tim Mahesh S Kudva wrote: > Hi All > > I have setup virtual hosts for 3 apps with virtual hosts config as > follows. These virtual hosts are first handled by Apache and mod_jk. My > apps have scheduler and automated mailing services. > > unpackWARs="true"> > www.vhost.domain.com > directory="${jboss.server.home.dir}/log" > prefix="vhost_log1." suffix=".log" timestamp="true"/> > docBase="${jboss.server.home.dir}/deploy/application.war" debug="0" > reloadable="true"/> > > > This config is mailing the same mail 7 time. Further I noticed that > there were 7 service started of the same kind. Querying the developer, > he said that he had coded the apps to have the mail sent once every week. > The mails are sent once every week but as said 7 copies of the same mail > is delivered. > > The request for the app results in page not found if I follow the > following config, even thought there is no error in startup. > > docBase="${jboss.server.home.dir}/deploy/application.war" debug="0" > reloadable="true"/> > > > > Can you guys have any idea on this and help me troubleshoot ??? > > > Regards & Thanks > ================ > Mahesh S Kudva > > > ------------------------------------------------------- > Robosoft Technologies - Partners in Product Development > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: tomcat-user-help@jakarta.apache.org