Return-Path: Delivered-To: apmail-geronimo-scm-archive@www.apache.org Received: (qmail 46689 invoked from network); 12 Dec 2005 22:04:56 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 12 Dec 2005 22:04:56 -0000 Received: (qmail 11024 invoked by uid 500); 12 Dec 2005 22:04:55 -0000 Delivered-To: apmail-geronimo-scm-archive@geronimo.apache.org Received: (qmail 11000 invoked by uid 500); 12 Dec 2005 22:04:55 -0000 Mailing-List: contact scm-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@geronimo.apache.org List-Id: Delivered-To: mailing list scm@geronimo.apache.org Received: (qmail 10989 invoked by uid 99); 12 Dec 2005 22:04:54 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Dec 2005 14:04:54 -0800 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.29) with SMTP; Mon, 12 Dec 2005 14:04:54 -0800 Received: (qmail 46418 invoked by uid 65534); 12 Dec 2005 22:04:34 -0000 Message-ID: <20051212220434.46416.qmail@minotaur.apache.org> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r356392 - /geronimo/branches/1.0/applications/console-standard/src/java/org/apache/geronimo/console/databasemanager/wizard/DatabasePoolPortlet.java Date: Mon, 12 Dec 2005 22:04:33 -0000 To: scm@geronimo.apache.org From: hogstrom@apache.org X-Mailer: svnmailer-1.0.5 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Author: hogstrom Date: Mon Dec 12 14:04:32 2005 New Revision: 356392 URL: http://svn.apache.org/viewcvs?rev=356392&view=rev Log: Changed processing order for the max / min pool sizes in the DatabaseWizardPortlet Modified: geronimo/branches/1.0/applications/console-standard/src/java/org/apache/geronimo/console/databasemanager/wizard/DatabasePoolPortlet.java Modified: geronimo/branches/1.0/applications/console-standard/src/java/org/apache/geronimo/console/databasemanager/wizard/DatabasePoolPortlet.java URL: http://svn.apache.org/viewcvs/geronimo/branches/1.0/applications/console-standard/src/java/org/apache/geronimo/console/databasemanager/wizard/DatabasePoolPortlet.java?rev=356392&r1=356391&r2=356392&view=diff ============================================================================== --- geronimo/branches/1.0/applications/console-standard/src/java/org/apache/geronimo/console/databasemanager/wizard/DatabasePoolPortlet.java (original) +++ geronimo/branches/1.0/applications/console-standard/src/java/org/apache/geronimo/console/databasemanager/wizard/DatabasePoolPortlet.java Mon Dec 12 14:04:32 2005 @@ -812,7 +812,7 @@ Connector15DCBRoot root = (Connector15DCBRoot) config.getDConfigBeanRoot(ddBeanRoot); ConnectorDCB connector = (ConnectorDCB) root.getDConfigBean(ddBeanRoot.getChildBean(root.getXpaths()[0])[0]); connector.setConfigID("user/database-pool"+data.getName() + "/1/car"); - connector.setParentID("geronimo/j2ee-server/1.0/car"); + connector.setParentID("geronimo/j2ee-server/1.0-SNAPSHOT/car"); if(data.jar1 != null && !data.jar1.equals("")) { Dependency dep = new Dependency(); connector.setDependency(new Dependency[]{dep}); @@ -869,11 +869,15 @@ SinglePool pool = new SinglePool(); manager.setPoolSingle(pool); pool.setMatchOne(true); - if(data.minSize != null && !data.minSize.equals("")) { - pool.setMinSize(new Integer(data.minSize)); - } + // Max Size needs to be set before the minimum. This is because + // the connection manager will constrain the minimum based on the + // current maximum value in the pool. We might consider adding a + // setPoolConstraints method to allow specifying both at the same time. if(data.maxSize != null && !data.maxSize.equals("")) { pool.setMaxSize(new Integer(data.maxSize)); + } + if(data.minSize != null && !data.minSize.equals("")) { + pool.setMinSize(new Integer(data.minSize)); } if(data.blockingTimeout != null && !data.blockingTimeout.equals("")) { pool.setBlockingTimeoutMillis(new Integer(data.blockingTimeout));