Return-Path: X-Original-To: apmail-commons-issues-archive@minotaur.apache.org Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B82B110F3D for ; Wed, 16 Oct 2013 03:33:49 +0000 (UTC) Received: (qmail 72499 invoked by uid 500); 16 Oct 2013 03:33:47 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 72151 invoked by uid 500); 16 Oct 2013 03:33:44 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 72062 invoked by uid 99); 16 Oct 2013 03:33:42 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Oct 2013 03:33:42 +0000 Date: Wed, 16 Oct 2013 03:33:42 +0000 (UTC) From: "Paulo Costa (JIRA)" To: issues@commons.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (DBCP-401) PoolableConnectionFactory.validateConnection() doesn't test connection.isValid() MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Paulo Costa created DBCP-401: -------------------------------- Summary: PoolableConnectionFactory.validateConnection() doesn't test connection.isValid() Key: DBCP-401 URL: https://issues.apache.org/jira/browse/DBCP-401 Project: Commons Dbcp Issue Type: Bug Reporter: Paulo Costa Priority: Minor On my environment, we sometimes get notified that something was changed on the DB servers (servers added/removed from the pool, master/slave promotion, etc). In these cases, we want to discard all existing connections in the pool and let it create new ones with the updated configuration. My initial idea is to have existing Connections returning isValid() == false after these events. But, after lots of debugging, it turns out that having the connection.isValid() returning false doesn't make it go away from the connection pool, since it is never checked. Fixing it would be very simple, and I can send you the patch, but I don't know if there is any reason it was left out in the first place, or if it would cause compatibility issues (Probably not). -- This message was sent by Atlassian JIRA (v6.1#6144)