Return-Path: Delivered-To: apmail-commons-user-archive@www.apache.org Received: (qmail 82120 invoked from network); 22 May 2008 12:31:59 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 22 May 2008 12:31:59 -0000 Received: (qmail 15951 invoked by uid 500); 22 May 2008 12:31:57 -0000 Delivered-To: apmail-commons-user-archive@commons.apache.org Received: (qmail 15876 invoked by uid 500); 22 May 2008 12:31:57 -0000 Mailing-List: contact user-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Commons Users List" Delivered-To: mailing list user@commons.apache.org Received: (qmail 15862 invoked by uid 99); 22 May 2008 12:31:57 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 May 2008 05:31:57 -0700 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of craig.spry@gmail.com designates 209.85.142.188 as permitted sender) Received: from [209.85.142.188] (HELO ti-out-0910.google.com) (209.85.142.188) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 May 2008 12:31:11 +0000 Received: by ti-out-0910.google.com with SMTP id u5so29908tia.10 for ; Thu, 22 May 2008 05:31:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; bh=Gw44vTDFwj69rCr1yKl4pX0VWWjvea5IhaQfU/VZYYc=; b=MmjMBLnoWPwaCBaA2tHBRisG0sRzEsRhoLU3nZyDuLPhweWkbobYBmqoFdTmc1KaqRAl6Z4F6eNXvIuZQCgeUBedph9cVSD5Rs4XTG3/FrkausPXA1D5BJ3fK/aefJJtYQgk9pnt/i2CF9a/n8FAFntAeqpBWRtqmHWKz2SxGVs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=Mnm/cUZio8uSMtiDwGpYHzaN6l+Yc3E/ZJeiO6zTboUEL+Qh+i7oHOSyYW2/PPCXgt8AoMNK7hM8551xxuHDBbKN560tFoGGNb1wPGlg6w6ZcWIskLvhokUecFnxKVQUC3LXlf3gxSg/VFQIsD4FjTDbgHQ6g7uEqvKcEvTOMDg= Received: by 10.110.14.12 with SMTP id 12mr1435949tin.31.1211459486442; Thu, 22 May 2008 05:31:26 -0700 (PDT) Received: by 10.110.46.8 with HTTP; Thu, 22 May 2008 05:31:26 -0700 (PDT) Message-ID: Date: Thu, 22 May 2008 22:31:26 +1000 From: "Craig Spry" To: "Commons Users List" Subject: Re: recreation of connections in the dbcp In-Reply-To: <483561D8.1020906@yale.edu> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_3274_31858124.1211459486449" References: <1841a3c10805220143w659fcd7dgc20223593babdbac@mail.gmail.com> <483561D8.1020906@yale.edu> X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_3274_31858124.1211459486449 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline For Postgres I use: select now() On Thu, May 22, 2008 at 10:06 PM, Mark Shifman wrote: > for Oracle use > > validationQuery="SELECT 1 from dual" > > James Carman wrote: > > I'd use a validation query. I believe that will solve your problem. > > That way, the pool implementation can check to see that the connection > > is "valid" before handing it off to you. For HSQLDB, I use: > > > > select 1 from INFORMATION_SCHEMA.SYSTEM_USERS > > > > You can come up with something similar for other database products. > > Hope that helps! > > > > On Thu, May 22, 2008 at 4:43 AM, wrote: > >> Hello, > >> > >> I use database connection pool BasicDataSource for manegment of DB > >> connections. When DB Server is restarted all connections are loosed. > >> How can I handle this situation? Should I create new BasicDataSource > >> or invoke some method. > >> > >> Thank you. > >> > >> --------------------------------------------------------------------- > >> To unsubscribe, e-mail: user-unsubscribe@commons.apache.org > >> For additional commands, e-mail: user-help@commons.apache.org > >> > >> > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: user-unsubscribe@commons.apache.org > > For additional commands, e-mail: user-help@commons.apache.org > > > > > -- > Mark Shifman MD. Ph.D. > Yale Center for Medical Informatics > Phone (203)737-5219 > mark.shifman@yale.edu > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscribe@commons.apache.org > For additional commands, e-mail: user-help@commons.apache.org > > ------=_Part_3274_31858124.1211459486449--