Return-Path: Delivered-To: apmail-commons-issues-archive@locus.apache.org Received: (qmail 19334 invoked from network); 19 Nov 2007 18:01:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 19 Nov 2007 18:01:22 -0000 Received: (qmail 82882 invoked by uid 500); 19 Nov 2007 18:01:08 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 82796 invoked by uid 500); 19 Nov 2007 18:01:08 -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 82787 invoked by uid 99); 19 Nov 2007 18:01:08 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Nov 2007 10:01:07 -0800 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Nov 2007 18:01:07 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id BF0BD714187 for ; Mon, 19 Nov 2007 10:00:45 -0800 (PST) Message-ID: <7087722.1195495245772.JavaMail.jira@brutus> Date: Mon, 19 Nov 2007 10:00:45 -0800 (PST) From: "Arie (JIRA)" To: issues@commons.apache.org Subject: [jira] Issue Comment Edited: (POOL-109) setting maxWait does not work as expected In-Reply-To: <6064972.1194916670994.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/POOL-109?page=3Dcom.atlassian.j= ira.plugin.system.issuetabpanels:comment-tabpanel#action_12543477 ]=20 aozarov@hotmail.com edited comment on POOL-109 at 11/19/07 10:00 AM: ------------------------------------------------------ Not sure what did you have in your mind but util.concurrent (if needed) is = available as concurrent.util for JDK < 1.5 was (Author: aozarov@hotmail.com): Not sure what did you have in your mind but util.concurrent (if needed)= is available as concurrent.util for JDK < 1.5Regards, Arie Ozarov=20 _________________________________________________________________ You keep typing, we keep giving. Download Messenger and join the i=E2=80=99= m Initiative now. http://im.live.com/messenger/im/home/?source=3DTAGLM =20 > setting maxWait does not work as expected > ----------------------------------------- > > Key: POOL-109 > URL: https://issues.apache.org/jira/browse/POOL-109 > Project: Commons Pool > Issue Type: Improvement > Reporter: Arie > Fix For: 2.0 > > > My expectation was that if maxWait is set to X seconds and there are N re= quests waiting to get a connection (in a case where the pool is bounded and= =20 > all the connection are used) if none of the used connection gets free tha= n all N requests will time-out at the same time. > In reality it seems that 1 request will be timed-out after X seconds the = second one after 2 * X and the last one after N * X. > The problem is that getPooledConnectionAndInfo is synchronized (and there= fore will look all N requests) and only one request will be processed at th= e time. > This process includes waiting until freed connection or timed-out (done b= y commons.pool GenericKeyedObjectPool). > I am not sure why the getPooledConnectionAndInfo has to be synchronized a= nd not only the pool creation part. --=20 This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.