Clearly DBCP isn't on the classpath and the solution is to get it in the
classpath; the easiest way to do that is to copy it into the lib directory.

Did you add the reference to it in your config file, or was that present in
something you downloaded with your ActiveMQ installation?

Tim
On Nov 10, 2015 8:09 AM, "Elazar Rosenthal" <elazar.rosent...@idt.net>
wrote:

> We have a working amq 5.9.1 with an oracle data store
> when trying to upgrade to am1 5.12.1 we get the following error on startup
> Is there a way I can fix this
>
> Error:
>
>
> 2015-11-10 11:07:54,050 | INFO  | Refreshing
> org.apache.activemq.xbean.XBeanBrokerFactory$1@5034c75a: startup date [Tue
> Nov 10 11:07:54 EST 2015]; root of context hierarchy |
> org.apache.activemq.xbean.XBeanBrokerFactory$1 | main
> 2015-11-10 11:07:55,145 | WARN  | Exception encountered during context
> initialization - cancelling refresh attempt |
> org.apache.activemq.xbean.XBeanBrokerFactory$1 | main
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean
> with name 'org.apache.activemq.xbean.XBeanBrokerService#0' defined in class
> path resource [activemq.xml]: Cannot create inner bean '(inner
> bean)#71809907' of type
> [org.apache.activemq.store.jdbc.JDBCPersistenceAdapter] while setting bean
> property 'persistenceAdapter'; nested exception is
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean
> with name '(inner bean)#71809907' defined in class path resource
> [activemq.xml]: Cannot resolve reference to bean 'oracle-ds' while setting
> bean property 'dataSource'; nested exception is
> org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find
> class [org.apache.commons.dbcp.BasicDataSource] for bean with name
> 'oracle-ds' defined in class path resource [activemq.xml]; nested exception
> is java.lang.ClassNotFoundException:
> org.apache.commons.dbcp.BasicDataSource
>         at
>
> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:287)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:129)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1419)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1160)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:191)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:636)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:934)[spring-context-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)[spring-context-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64)[xbean-spring-3.18.jar:3.18]
>         at
>
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52)[xbean-spring-3.18.jar:3.18]
>         at
>
> org.apache.activemq.xbean.XBeanBrokerFactory$1.<init>(XBeanBrokerFactory.java:104)[activemq-spring-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.xbean.XBeanBrokerFactory.createApplicationContext(XBeanBrokerFactory.java:104)[activemq-spring-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.xbean.XBeanBrokerFactory.createBroker(XBeanBrokerFactory.java:67)[activemq-spring-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:71)[activemq-broker-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:54)[activemq-broker-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:87)[activemq-console-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:62)[activemq-console-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.ShellCommand.runTask(ShellCommand.java:154)[activemq-console-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:62)[activemq-console-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.ShellCommand.main(ShellCommand.java:104)[activemq-console-5.12.1.jar:5.12.1]
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)[:1.8.0_25]
>         at
>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[:1.8.0_25]
>         at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.8.0_25]
>         at java.lang.reflect.Method.invoke(Method.java:483)[:1.8.0_25]
>         at
>
> org.apache.activemq.console.Main.runTaskClass(Main.java:262)[activemq.jar:5.12.1]
>         at
> org.apache.activemq.console.Main.main(Main.java:115)[activemq.jar:5.12.1]
> 2015-11-10 11:07:55,155 | ERROR | Failed to load: class path resource
> [activemq.xml], reason: Error creating bean with name
> 'org.apache.activemq.xbean.XBeanBrokerService#0' defined in class path
> resource [activemq.xml]: Cannot create inner bean '(inner bean)#71809907'
> of
> type [org.apache.activemq.store.jdbc.JDBCPersistenceAdapter] while setting
> bean property 'persistenceAdapter'; nested exception is
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean
> with name '(inner bean)#71809907' defined in class path resource
> [activemq.xml]: Cannot resolve reference to bean 'oracle-ds' while setting
> bean property 'dataSource'; nested exception is
> org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find
> class [org.apache.commons.dbcp.BasicDataSource] for bean with name
> 'oracle-ds' defined in class path resource [activemq.xml]; nested exception
> is java.lang.ClassNotFoundException:
> org.apache.commons.dbcp.BasicDataSource
> | org.apache.activemq.xbean.XBeanBrokerFactory | main
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean
> with name 'org.apache.activemq.xbean.XBeanBrokerService#0' defined in class
> path resource [activemq.xml]: Cannot create inner bean '(inner
> bean)#71809907' of type
> [org.apache.activemq.store.jdbc.JDBCPersistenceAdapter] while setting bean
> property 'persistenceAdapter'; nested exception is
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean
> with name '(inner bean)#71809907' defined in class path resource
> [activemq.xml]: Cannot resolve reference to bean 'oracle-ds' while setting
> bean property 'dataSource'; nested exception is
> org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find
> class [org.apache.commons.dbcp.BasicDataSource] for bean with name
> 'oracle-ds' defined in class path resource [activemq.xml]; nested exception
> is java.lang.ClassNotFoundException:
> org.apache.commons.dbcp.BasicDataSource
>         at
>
> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:287)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:129)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1419)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1160)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:191)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:636)[spring-beans-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:934)[spring-context-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)[spring-context-3.2.11.RELEASE.jar:3.2.11.RELEASE]
>         at
>
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64)[xbean-spring-3.18.jar:3.18]
>         at
>
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52)[xbean-spring-3.18.jar:3.18]
>         at
>
> org.apache.activemq.xbean.XBeanBrokerFactory$1.<init>(XBeanBrokerFactory.java:104)[activemq-spring-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.xbean.XBeanBrokerFactory.createApplicationContext(XBeanBrokerFactory.java:104)[activemq-spring-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.xbean.XBeanBrokerFactory.createBroker(XBeanBrokerFactory.java:67)[activemq-spring-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:71)[activemq-broker-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:54)[activemq-broker-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:87)[activemq-console-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:62)[activemq-console-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.ShellCommand.runTask(ShellCommand.java:154)[activemq-console-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:62)[activemq-console-5.12.1.jar:5.12.1]
>         at
>
> org.apache.activemq.console.command.ShellCommand.main(ShellCommand.java:104)[activemq-console-5.12.1.jar:5.12.1]
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> Method)[:1.8.0_25]
>         at
>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[:1.8.0_25]
>         at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.8.0_25]
>         at java.lang.reflect.Method.invoke(Method.java:483)[:1.8.0_25]
>         at
>
> org.apache.activemq.console.Main.runTaskClass(Main.java:262)[activemq.jar:5.12.1]
>         at
> org.apache.activemq.console.Main.main(Main.java:115)[activemq.jar:5.12.1]
>
>
>
>
>
> --
> View this message in context:
> http://activemq.2283324.n4.nabble.com/Amq-5-12-1-Failing-to-start-with-Oracle-Data-Store-tp4703806.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>

Reply via email to