Return-Path: Delivered-To: apmail-geronimo-user-archive@www.apache.org Received: (qmail 94591 invoked from network); 21 Jan 2008 08:37:40 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 21 Jan 2008 08:37:40 -0000 Received: (qmail 74855 invoked by uid 500); 21 Jan 2008 08:37:27 -0000 Delivered-To: apmail-geronimo-user-archive@geronimo.apache.org Received: (qmail 74839 invoked by uid 500); 21 Jan 2008 08:37:27 -0000 Mailing-List: contact user-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: user@geronimo.apache.org List-Id: Delivered-To: mailing list user@geronimo.apache.org Received: (qmail 74828 invoked by uid 99); 21 Jan 2008 08:37:27 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 21 Jan 2008 00:37:27 -0800 X-ASF-Spam-Status: No, hits=0.2 required=10.0 tests=SPF_PASS,WHOIS_MYPRIVREG X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [69.147.95.87] (HELO smtp124.plus.mail.sp1.yahoo.com) (69.147.95.87) by apache.org (qpsmtpd/0.29) with SMTP; Mon, 21 Jan 2008 08:37:12 +0000 Received: (qmail 33414 invoked from network); 21 Jan 2008 08:37:04 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Received:X-YMail-OSG:X-Yahoo-Newman-Property:Mime-Version:In-Reply-To:References:Content-Type:Message-Id:Content-Transfer-Encoding:From:Subject:Date:To:X-Mailer; b=eyQwYQq6jy5hQg8zot08GbRa1lGmb3RofsfwdwzRgZjv+3+vxRCFVRLepQJO0kCv6+FERb6xPDmY5RVxn4yEyL1FyXXZiIFkn/gskMZe/hO7W0Srt+h0EYOhXpXCb2bKAhU7kEAS7aVaMo97I5b8B7rhMdXu7rMcXQCrzkXHuuc= ; Received: from unknown (HELO ?192.168.1.102?) (david_jencks@67.102.173.8 with plain) by smtp124.plus.mail.sp1.yahoo.com with SMTP; 21 Jan 2008 08:37:03 -0000 X-YMail-OSG: bJGGNKsVM1krlTEUJOQAoi8_0h.uWP7KZSS.vi7eviS3OZt0RJCjYfWRn7GvS1esQgYOi1ld8qOHJ7xB4L7MLw12ewrbaWkdU_vOBmIYsTobafs.Ow-- X-Yahoo-Newman-Property: ymail-3 Mime-Version: 1.0 (Apple Message framework v753) In-Reply-To: <14990200.post@talk.nabble.com> References: <14990200.post@talk.nabble.com> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <6C6EBE8F-28E6-40F3-981F-125A1F80576B@yahoo.com> Content-Transfer-Encoding: 7bit From: David Jencks Subject: Re: Adding DB pool JNDI in Jar Date: Mon, 21 Jan 2008 00:36:55 -0800 To: user@geronimo.apache.org X-Mailer: Apple Mail (2.753) X-Virus-Checked: Checked by ClamAV on apache.org java:comp/env only works in javaee components. To use a datasource in jndi in something like quartz you need to bind into global jndi. I think the best instructions are in this thread http://www.nabble.com/How-to-register-a-Datasource-in-GlobalJNDI- Namespace--tf4521379s134.html#a12902470 we need to get this class and some docs into geronimo 2.l... hope this helps david jencks On Jan 20, 2008, at 6:34 PM, Qaiser Mehmood wrote: > > I am using Geronimo 2.0.I want to use quartz in my Jar file and I > am using > quartz.properties to configure Quartz. In the properties file, I am > using > database pool through JNDI. I am getting this error: > > org.quartz.JobPersistenceException: Failed to obtain DB connection > from data > source 'myDS': java.sql.SQLException: Could not retrieve datasource > via JNDI > url 'java:comp/env/QuartzDS' java.lang.NullPointerException: null [See > nested exception: java.sql.SQLException: Could not retrieve > datasource via > JNDI url 'java:comp/env/QuartzDS' java.lang.NullPointerException: > null] > at > org.quartz.impl.jdbcjobstore.JobStoreSupport.getConnection > (JobStoreSupport.java:636) > at > org.quartz.impl.jdbcjobstore.JobStoreTX.getNonManagedTXConnection > (JobStoreTX.java:72) > at > org.quartz.impl.jdbcjobstore.JobStoreSupport.doCheckin > (JobStoreSupport.java:3070) > at > org.quartz.impl.jdbcjobstore.JobStoreSupport$ClusterManager.manage > (JobStoreSupport.java:3713) > at > org.quartz.impl.jdbcjobstore.JobStoreSupport > $ClusterManager.initialize(JobStoreSupport.java:3700) > at > org.quartz.impl.jdbcjobstore.JobStoreSupport.schedulerStarted > (JobStoreSupport.java:570) > at org.quartz.core.QuartzScheduler.start(QuartzScheduler.java:449) > at org.quartz.impl.StdScheduler.start(StdScheduler.java:146) > at > com.pervasive.phaip.services.scheduler.PhaipScheduler.doStart > (PhaipScheduler.java:31) > at > org.apache.geronimo.gbean.runtime.GBeanInstance.createInstance > (GBeanInstance.java:996) > at > org.apache.geronimo.gbean.runtime.GBeanInstanceState.attemptFullStart( > GBeanInstanceState.java:268) > at > org.apache.geronimo.gbean.runtime.GBeanInstanceState.start > (GBeanInstanceState.java:102) > at > org.apache.geronimo.gbean.runtime.GBeanInstanceState.startRecursive > (GBeanInstanceState.java:124) > at > org.apache.geronimo.gbean.runtime.GBeanInstance.startRecursive > (GBeanInstance.java:553) > at > org.apache.geronimo.kernel.basic.BasicKernel.startRecursiveGBean > (BasicKernel.java:379) > at > org.apache.geronimo.kernel.config.ConfigurationUtil.startConfiguration > GBeans(ConfigurationUtil.java:448) > at > org.apache.geronimo.kernel.config.KernelConfigurationManager.start > (KernelConfigurationManager.java:187) > at > org.apache.geronimo.kernel.config.SimpleConfigurationManager.startConf > iguration(SimpleConfigurationManager.java:530) > at > org.apache.geronimo.kernel.config.SimpleConfigurationManager$ > $FastClassByCGLIB$$ce77a924.invoke() > at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:53) > at > org.apache.geronimo.gbean.runtime.FastMethodInvoker.invoke > (FastMethodInvoker.java:38) > at > org.apache.geronimo.gbean.runtime.GBeanOperation.invoke > (GBeanOperation.java:124) > at > org.apache.geronimo.gbean.runtime.GBeanInstance.invoke > (GBeanInstance.java:830) > at org.apache.geronimo.gbean.runtime.RawInvoker.invoke > (RawInvoker.java:57) > at > org.apache.geronimo.kernel.basic.RawOperationInvoker.invoke > (RawOperationInvoker.java:35) > at > org.apache.geronimo.kernel.basic.ProxyMethodInterceptor.intercept > (ProxyMethodInterceptor.java:96) > at > org.apache.geronimo.gbean.GBeanLifecycle$$EnhancerByCGLIB$ > $b023c139.startConfiguration() > > > > JNDI URL in my quartz.properties file is: > > org.quartz.dataSource.myDS.jndiURL=java:comp/env/jdbc/MyDataSource > > > And my geronimo-service.xml : > > > > > > phaip-core > phaip-core > 1.1 > > > > > org.apache.activemq > activemq-core > 4.1.1 > jar > > > > dbunit > dbunit > 2.2 > jar > > > > dj800ec > dj800ec > 1.0 > jar > > > > postgresql > postgresql-8.2 > 506.jdbc4 > jar > > > > > spring > spring > 2.5.1 > jar > > > > commons-collections > commons-collections > 3.1 > jar > > > > commons-digester > commons-digester > 1.8 > jar > > > > > commons-logging > commons-logging > 1.0.4 > jar > > > > commons-beanutils > commons-beanutils > 1.6.1 > jar > > > > > jmx > jmx > 5.0_r16 > jar > > > > commons-logging-api > commons-logging-api > 1.0.4 > jar > > > > jdbc2_0-stdext > jdbc2_0-stdext > 2.0 > jar > > > > log4j > log4j > 1.2.15 > jar > > > > org.apache.geronimo.configs > openjpa > 2.0.2 > car > > > > > quartz > quartz-all > 1.6.0 > jar > > > > org.apache.geronimo.specs > geronimo-servlet_2.5_spec > 1.1 > jar > > > > j2ee > javaee > 9.1 > jar > > > > geronimo > geronimo-kernel > 2.0.2 > jar > > > > org.apache.geronimo.modules > geronimo-activation > 2.0.2 > jar > > > > org.apache.geronimo.specs > geronimo-ejb_3.0_spec > 1.0 > jar > > > > > org.apache.ws.scout > scout > 1.0rc1 > jar > > > > ejb > ejb > 1.0 > jar > > > > jms > jms > 1.0 > jar > > > > jta > jta > 1.0 > jar > > > > junit > junit > 1.0 > jar > > > > mail > mail > 1.3.3 > jar > > > > derby > derby > 10.3.2000001.599110 > jar > > > > phaip > phaip-core > 1.0 > jar > > > > org.apache.geronimo.configs > xmlbeans > 2.0.2 > car > > > > juddi > juddi-client > 2.0rc5 > jar > > > > juddi > juddi > 2.0rc5 > jar > > > > console.dbpool > QuartzDS > > > > > > jdbc/MyDataSource > QuartzDS > > > > > > > > > I have created database pool through Geronimo Console and using name > "QuartzDS".Please help. > > Qaiser Mehmood > > -- > View this message in context: http://www.nabble.com/Adding-DB-pool- > JNDI-in-Jar-tp14990200s134p14990200.html > Sent from the Apache Geronimo - Users mailing list archive at > Nabble.com. >