Return-Path: Delivered-To: apmail-db-torque-user-archive@www.apache.org Received: (qmail 83941 invoked from network); 12 Dec 2003 18:43:47 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 12 Dec 2003 18:43:47 -0000 Received: (qmail 34036 invoked by uid 500); 12 Dec 2003 18:43:35 -0000 Delivered-To: apmail-db-torque-user-archive@db.apache.org Received: (qmail 34007 invoked by uid 500); 12 Dec 2003 18:43:35 -0000 Mailing-List: contact torque-user-help@db.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Apache Torque Users List" Reply-To: "Apache Torque Users List" Delivered-To: mailing list torque-user@db.apache.org Received: (qmail 33924 invoked from network); 12 Dec 2003 18:43:34 -0000 Received: from unknown (HELO xbabe.wemove.lan) (213.138.48.149) by daedalus.apache.org with SMTP; 12 Dec 2003 18:43:34 -0000 Received: from localhost (localhost [127.0.0.1]) by xbabe.wemove.lan (Postfix) with ESMTP id 21923719 for ; Fri, 12 Dec 2003 19:44:44 +0100 (CET) Received: by xbabe.wemove.lan (Postfix, from userid 509) id 6F7B871A; Fri, 12 Dec 2003 19:44:36 +0100 (CET) Received: from wemove.com (unknown [192.168.0.104]) by xbabe.wemove.lan (Postfix) with ESMTP id 9B790719 for ; Fri, 12 Dec 2003 19:44:22 +0100 (CET) Message-ID: <3FDA0C41.6030602@wemove.com> Date: Fri, 12 Dec 2003 19:43:13 +0100 From: =?ISO-8859-1?Q?Joachim_M=FCller?= Organization: wemove digital solutions GmbH User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.6b) Gecko/20031205 Thunderbird/0.4 X-Accept-Language: en-us, en To: Apache Torque Users List Subject: Re: JDBC2 pool and Oracle References: <002901c3c0d3$f7077780$5a01a8c0@rsccd.org> In-Reply-To: <002901c3c0d3$f7077780$5a01a8c0@rsccd.org> X-Enigmail-Version: 0.82.4.0 X-Enigmail-Supports: pgp-inline, pgp-mime X-Spam-Status: No, hits=-4.9 required=5.0 tests=AWL,BAYES_01,EMAIL_ATTRIBUTION,HOT_NASTY,IN_REP_TO, QUOTED_EMAIL_TEXT,REFERENCES,REPLY_WITH_QUOTES, SIGNATURE_LONG_SPARSE,USER_AGENT_MOZILLA_UA autolearn=ham version=2.55 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) X-Sanitizer: Advosys mail filter MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1"; format="flowed" Content-Transfer-Encoding: 8bit X-Virus-Scanned: by AMaViS 0.3.12pre8 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N I've got the JNDI working. All you have to do is this: - configure a Datasource in your tomcat app via the tomcat admin interface (make sure the jdbc driver is in your common/lib of tomcat). the name of the datasource could be jdbc/mydb_res - put this in your torque.properties torque.dsfactory.default.factory=org.apache.torque.dsfactory.JndiDataSourceFactory torque.dsfactory.default.jndi.path=java:/comp/env/jdbc/mydb_res I am doing tests now... hoping the best ;-). btw: I know Torque from jetspeed1.4b4. There the sample jndi.path is like this: torque.dsfactory.default.jndi.path=jdbc/mydb_res took me half a day to figure out the missing 'java:/comp/env/'. :-( Rgds, joachim Ramesh Sabeti wrote: > Hi, > > Yes, I found out my validationQuery wasn't meant for Oracle :) The > suggested one by a few sources is > > ...pool.validationQuery=SELECT sysdate from dual > > Please let me know if you get anywhere with JNDI. I'm still trying to > get JDBC2 pool to work. > > Thanks, > > Ramesh. > > >>-----Original Message----- >>From: Joachim M�ller [mailto:joachim@wemove.com] >>Sent: Friday, December 12, 2003 1:49 AM >>To: Apache Torque Users List >>Subject: Re: JDBC2 pool and Oracle >> >> >>I also have serious problems with the connection pools. Both the > > Torque > >>and the JDBC2 Pool did not work right. (The application can not make >>connections to the oracle after a certain time.) >> >>Did you try the JNDI datasource? that's the next step for me. hope it >>will resolve the problem. >> >>By the way. I think your validation query is wrong. SELECT 1 does not >>work with Oracle. My JDBC2 config looks like this: >> >> > > torque.dsfactory.default.factory=org.apache.torque.dsfactory.Jdbc2PoolDa > ta > >>SourceFactory >>torque.dsfactory.default.pool.defaultMaxActive=10 >>torque.dsfactory.default.pool.testOnBorrow=true >>torque.dsfactory.default.pool.validationQuery=SELECT 1 FROM DUAL >> >>torque.database.default.adapter=oracle >>torque.dsfactory.default.connection.driver = >>oracle.jdbc.driver.OracleDriver >>torque.dsfactory.default.connection.url = >>jdbc:oracle:thin:@xxx.xxx.xxx.xxx:1521:MyDB >>torque.dsfactory.default.connection.user = xxx >>torque.dsfactory.default.connection.password = xxx >> >> >> >>rgds. joachim >> >> >>Ramesh Sabeti wrote: >> >> >>>Hi all, >>>I'm trying to get jdbc2 pool work with Oracle and it's not happening > > for > >>>me... >>> >>>Here's my old settings, and it was working fine during development: >>> >>> > > torque.dsfactory.default.factory=org.apache.torque.dsfactory.TorqueDataS > >>>ourceFactory >>>torque.dsfactory.default.pool.defaultMaxConnections=10 >>>torque.dsfactory.default.pool.maxExpiryTime=3600 >>>torque.dsfactory.default.pool.connectionWaitTimeout=10 >>> >>>But when it's deployed to production, we get the following error >>>message: >>> >>>ORA-00020: maximum number of processes (50) exceeded >>> >>> >>>Seems like Oracle doesn't expire connections. Some posting > > suggested a > >>>problem with Oracle 9.2 JDBC driver. So I'm trying to use jdbc2 > > pool > >>>and changed the settings to this: >>> >>> > > torque.dsfactory.default.factory=org.apache.torque.dsfactory.Jdbc2PoolDa > >>>taSourceFactory >>>torque.dsfactory.default.pool.defaultMaxActive=10 >>>torque.dsfactory.default.pool.testOnBorrow=true >>>torque.dsfactory.default.pool.validationQuery=SELECT 1 >>> >>>Now, nothing works, even Tomcat. When I deploy the app and restart >>>Tomcat, it first opens 14 connections to Oracle, and then hangs > > Tomcat > >>>right when Torque starts to initialize. Any ideas? Does anyone > > have a > >>>different jdbc2 pool setting for Oracle? >>> >>>Thanks in advance, >>> >>>Ramesh >>> >> >> >>-- >> >>joachim m�ller >>joachim@wemove.com . tel +49-69-759003-11 >> >>wemove digital solutions >>contact@wemove.com . tel +49-69-759003-0 . fax +49-69-759003-22 >>eschersheimer landstrasse 5-7 >>60322 frankfurt . germany >>http://www.wemove.com/ >> >>--------------------------------------------------------------------- >>To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org >>For additional commands, e-mail: torque-user-help@db.apache.org > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org > For additional commands, e-mail: torque-user-help@db.apache.org > > -- joachim m�ller joachim@wemove.com . tel +49-69-759003-11 wemove digital solutions contact@wemove.com . tel +49-69-759003-0 . fax +49-69-759003-22 eschersheimer landstrasse 5-7 60322 frankfurt . germany http://www.wemove.com/ --------------------------------------------------------------------- To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org For additional commands, e-mail: torque-user-help@db.apache.org