Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@www.apache.org Received: (qmail 69616 invoked from network); 21 Jun 2004 12:28:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 21 Jun 2004 12:28:37 -0000 Received: (qmail 12110 invoked by uid 500); 21 Jun 2004 12:28:00 -0000 Delivered-To: apmail-jakarta-tomcat-user-archive@jakarta.apache.org Received: (qmail 12092 invoked by uid 500); 21 Jun 2004 12:28:00 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: 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 12059 invoked by uid 99); 21 Jun 2004 12:27:59 -0000 Received: from [205.150.136.12] (HELO mail.squigly.com) (205.150.136.12) by apache.org (qpsmtpd/0.27.1) with ESMTP; Mon, 21 Jun 2004 05:27:59 -0700 Received: by mail.squigly.com (Postfix, from userid 511) id 8BEFC2740; Mon, 21 Jun 2004 08:07:28 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by mail.squigly.com (Postfix) with ESMTP id 860879518 for ; Mon, 21 Jun 2004 08:07:28 -0400 (EDT) Date: Mon, 21 Jun 2004 08:07:28 -0400 (EDT) From: Alex X-Sender: To: Tomcat Users List Subject: Re: How to recover from a database server restart when using connection pools? In-Reply-To: <200406182159.i5ILxYqf013132@lobus.fungible.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Use a validationQuery when creating your connection pools. This can be defined where you define your resource. validationQuery select 1 On Fri, 18 Jun 2004, Tim Freeman wrote: > Date: Fri, 18 Jun 2004 14:57:01 -0700 > From: Tim Freeman > Reply-To: Tomcat Users List > To: tomcat-user@jakarta.apache.org > Subject: How to recover from a database server restart when using > connection pools? > > > I am using database connection pooling and I would like my Tomcat > server to be able to cope gracefully with the database server being > stopped and restarting. This creates a confusing situation because > the connections in the pool all become invalid in that case. > > Is there a standard way to deal with this? Googling around didn't > turn up anything, but it's surely a common situation. I must have > searched for the wrong keywords. --------------------------------------------------------------------- To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: tomcat-user-help@jakarta.apache.org