You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by mtod <mt...@thetods.net> on 2017/03/20 22:07:00 UTC

ActiveMQ lease-database-locker in Servicemix - Class not found

I'm working with ActiveMQ in Servicemix 7.0 trying to get the
lease-database-locker working.

I have it working in stand alone mode using MSSql but when I place the same
configuration in Servicemix it says :

Caused by: java.lang.ClassNotFoundException:
org.apache.commons.dbcp2.BasicDataSource not found by
org.apache.activemq.activemq-osgi.

I can't find how to install that class in Servicemix.

I'm not sure what I'm missing or if there is another way to do this.

Thanks

Mike 

ActiveMQ.xml config

		
		<persistenceAdapter>            
			<kahaDB directory="${data}/kahadb" lockKeepAlivePeriod="5000"
checkForCorruptJournalFiles="true" enableAckCompaction="false" >
				<locker>
				  
				  <lease-database-locker lockAcquireSleepInterval="10000"
dataSource="#mssql-ds" createTablesOnStartup="true">
					<statements>
					  
					  <statements lockTableName="activemq_lock"/>
					</statements>
				  </lease-database-locker>
				</locker>
			</kahaDB>
        </persistenceAdapter>

.....

	<bean id="mssql-ds" class="org.apache.commons.dbcp2.BasicDataSource"
destroy-method="close">
		<property name="driverClassName"
value="com.microsoft.sqlserver.jdbc.SQLServerDriver"/>
		<property name="url" value="jdbc:sqlserver://
servicemixdb.cfpkhb1rjo9n.us-east-1.rds.amazonaws.com:1433;databaseName=ActiveMQJournal"/>
		<property name="username" value="xxxxxx"/>
		<property name="password" value="xxxxx"/>
		<property name="poolPreparedStatements" value="true"/>
	</bean>






--
View this message in context: http://activemq.2283324.n4.nabble.com/ActiveMQ-lease-database-locker-in-Servicemix-Class-not-found-tp4723913.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: ActiveMQ lease-database-locker in Servicemix - Class not found

Posted by Tim Bain <tb...@alumni.duke.edu>.
I have no experience with ServiceMix, but is it available as an optional
feature (http://servicemix.apache.org/docs/7.x/quickstart/features.html)?

Otherwise, you'll probably want to post to the ServiceMix mailing list:
http://servicemix.apache.org/community/mailing-lists.html

Tim

On Mar 20, 2017 4:14 PM, "mtod" <mt...@thetods.net> wrote:

> I'm working with ActiveMQ in Servicemix 7.0 trying to get the
> lease-database-locker working.
>
> I have it working in stand alone mode using MSSql but when I place the same
> configuration in Servicemix it says :
>
> Caused by: java.lang.ClassNotFoundException:
> org.apache.commons.dbcp2.BasicDataSource not found by
> org.apache.activemq.activemq-osgi.
>
> I can't find how to install that class in Servicemix.
>
> I'm not sure what I'm missing or if there is another way to do this.
>
> Thanks
>
> Mike
>
> ActiveMQ.xml config
>
>
>                 <persistenceAdapter>
>                         <kahaDB directory="${data}/kahadb"
> lockKeepAlivePeriod="5000"
> checkForCorruptJournalFiles="true" enableAckCompaction="false" >
>                                 <locker>
>
>                                   <lease-database-locker
> lockAcquireSleepInterval="10000"
> dataSource="#mssql-ds" createTablesOnStartup="true">
>                                         <statements>
>
>                                           <statements
> lockTableName="activemq_lock"/>
>                                         </statements>
>                                   </lease-database-locker>
>                                 </locker>
>                         </kahaDB>
>         </persistenceAdapter>
>
> .....
>
>         <bean id="mssql-ds" class="org.apache.commons.
> dbcp2.BasicDataSource"
> destroy-method="close">
>                 <property name="driverClassName"
> value="com.microsoft.sqlserver.jdbc.SQLServerDriver"/>
>                 <property name="url" value="jdbc:sqlserver://
> servicemixdb.cfpkhb1rjo9n.us-east-1.rds.amazonaws.com:1433;
> databaseName=ActiveMQJournal"/>
>                 <property name="username" value="xxxxxx"/>
>                 <property name="password" value="xxxxx"/>
>                 <property name="poolPreparedStatements" value="true"/>
>         </bean>
>
>
>
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.
> nabble.com/ActiveMQ-lease-database-locker-in-Servicemix-
> Class-not-found-tp4723913.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>