activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Shannon <christopher.l.shan...@gmail.com>
Subject Re: ActiveMQ JDBC persistence with MSSql
Date Thu, 10 Sep 2015 21:32:50 GMT
The class can't be found because it isn't part of dbcp 2.
 org.apache.commons.dbcp.BasicDataSource is the package for dbcp 1.x not 2.x

Take a look at:
https://commons.apache.org/proper/commons-dbcp/apidocs/org/apache/commons/dbcp2/BasicDataSource.html

You should be using org.apache.commons.dbcp2.BasicDataSource if you want to
use dbcp2

-Chris

On Thu, Sep 10, 2015 at 5:21 PM, mtod <mtod@thetods.net> wrote:

> I'm trying to setup a MSSQL JDBC persistence and I keep getting the same
> error.
>
> My setup is ActiveMQ 5.12.0 on Windows 2012 R2 with JAVA 1.8
>
> I downloaded and installed the MS Drivers.
>
> *My ActiveMQ.xml is using the default and the only thing I added was :*
>
>
>         <bean id="mssql-ds" class="org.apache.commons.dbcp.BasicDataSource"
> destroy-method="close">
>                 <property name="driverClassName"
> value="com.microsoft.sqlserver.jdbc.SQLServerDriver"/>
>                 <property name="url"
>
> value="jdbc:sqlserver://dbdev003.corp.local:1433;databaseName=ActiveMQJournal;user=srv_activemqDEV;password=srv_activemqDEV1"/>
>                 <property name="username" value="srv_activemqDEV"/>
>                 <property name="password" value="srv_activemqDEV1"/>
>         </bean>
>
>
> *Console Error:*
>
> ERROR: *org.springframework.beans.factory.CannotLoadBeanClassException:
> Cannot find class [org.apache.commons.dbcp.BasicDataSource]* for bean with
> name 'mssql-ds' defined in class path resource [activemq.xml
> ]; nested exception is java.lang.ClassNotFoundException:
> org.apache.commons.dbcp.BasicDataSource
> org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find
> class [org.apache.commons.dbcp.BasicDataSource] for bean with name
> 'mssql-ds' defined in class path resource [activemq.xml]; nest
> ed exception is java.lang.ClassNotFoundException:
> org.apache.commons.dbcp.BasicDataSource
>
>
> I tried placing the commons-dbcp2-2.1 into the /lib folder and no luck same
> with the drivers.
>
> Thanks
>
> Mike
>
>
>
> --
> View this message in context:
> http://activemq.2283324.n4.nabble.com/ActiveMQ-JDBC-persistence-with-MSSql-tp4701883.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message