mirror of https://github.com/apache/activemq.git
remove compile dep on dbcp2 in favour or generic datasource
This commit is contained in:
parent
2a8218a9a8
commit
c8d96c6e8e
|
@ -24,6 +24,7 @@ import javax.jms.MessageConsumer;
|
|||
import javax.jms.MessageProducer;
|
||||
import javax.jms.Session;
|
||||
import javax.jms.TextMessage;
|
||||
import javax.sql.DataSource;
|
||||
import javax.transaction.TransactionManager;
|
||||
import org.apache.activemq.ActiveMQConnectionFactory;
|
||||
import org.apache.activemq.broker.BrokerService;
|
||||
|
@ -33,7 +34,6 @@ import org.apache.activemq.util.Wait;
|
|||
import org.apache.camel.Exchange;
|
||||
import org.apache.camel.component.jms.JmsMessage;
|
||||
import org.apache.camel.test.spring.CamelSpringTestSupport;
|
||||
import org.apache.commons.dbcp2.BasicDataSource;
|
||||
import org.junit.Test;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
@ -75,7 +75,7 @@ public class JmsJdbcXARollbackTest extends CamelSpringTestSupport {
|
|||
}
|
||||
|
||||
private java.sql.Connection getJDBCConnection() throws Exception {
|
||||
BasicDataSource dataSource = getMandatoryBean(BasicDataSource.class, "managedDataSourceWithRecovery");
|
||||
DataSource dataSource = getMandatoryBean(DataSource.class, "managedDataSourceWithRecovery");
|
||||
return dataSource.getConnection();
|
||||
}
|
||||
|
||||
|
|
|
@ -25,6 +25,7 @@ import javax.jms.MessageProducer;
|
|||
import javax.jms.Session;
|
||||
import javax.jms.TextMessage;
|
||||
|
||||
import javax.sql.DataSource;
|
||||
import org.apache.activemq.ActiveMQConnectionFactory;
|
||||
import org.apache.activemq.broker.BrokerPlugin;
|
||||
import org.apache.activemq.broker.BrokerPluginSupport;
|
||||
|
@ -34,8 +35,6 @@ import org.apache.activemq.command.ActiveMQQueue;
|
|||
import org.apache.activemq.command.TransactionId;
|
||||
import org.apache.activemq.util.Wait;
|
||||
import org.apache.camel.test.spring.CamelSpringTestSupport;
|
||||
import org.apache.commons.dbcp2.BasicDataSource;
|
||||
import org.junit.Ignore;
|
||||
import org.junit.Test;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
@ -76,7 +75,7 @@ public class JmsJdbcXATest extends CamelSpringTestSupport {
|
|||
}
|
||||
|
||||
private java.sql.Connection getJDBCConnection() throws Exception {
|
||||
BasicDataSource dataSource = getMandatoryBean(BasicDataSource.class, "managedDataSourceWithRecovery");
|
||||
DataSource dataSource = getMandatoryBean(DataSource.class, "managedDataSourceWithRecovery");
|
||||
return dataSource.getConnection();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue