Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@jakarta.apache.org Received: (qmail 82523 invoked by uid 500); 6 Jul 2001 09:01:53 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk Reply-To: tomcat-user@jakarta.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 82300 invoked from network); 6 Jul 2001 09:01:48 -0000 Received: from unknown (HELO dominio?gestao.intra.cet.pt) (194.65.138.12) by h31.sny.collab.net with SMTP; 6 Jul 2001 09:01:48 -0000 Received: from VITORIA ([10.44.20.12]) by dominio_gestao.intra.cet.pt with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2653.13) id NTQ4YTMV; Fri, 6 Jul 2001 10:02:04 +0100 Message-ID: <003601c105fa$43606c00$0c142c0a@INTRA.CET.PT> From: "pedro salazar" To: Subject: creating a instance of a servlet: takes too long!! Date: Fri, 6 Jul 2001 10:01:37 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4133.2400 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N Greetings, why is that my servlet when the first time is invoked, it takes about 30 seconds or more to start when the servlets that came in tomcat are instantaneous? After the servlet container instantiated and initialized my servlet, all the following requests are very fast. Is there any advice for what we should do and don't do in init() method? I just initialize some properties and a connection pool.... Well is it possible that my servlet container at any time my may shutdown my servlet to release memory, and another time it will be requested to start again and take another time too long to start, correct? How can I benchmark the time of instantiation of my servlet and the time of my init method? System configuration: -Tomcat 3.2.1 -JDK 1.3 -Linux RedHat 6.2 [kernel 2.2.18] -PII400Mhz 256Mbytes thanks. --